NC_MapInterpolationΒΆ

NC_MapInterpolation calculates new channels by map interpolation and adds the new channels to an NC file.

bool = NC_MapInterpolation(ssNCMap, ssXMap, ssYMap, svZMap, ssNCFile, ssXChanName, ssYChanName)

Return Value

bool

Parameters

ssNCMap

ssNCMap is the name of the netCDF file containing the maps. This file will be opened with read access.

ssXMap

ssXMap is the channel name with the map x coordinates.

ssYMap

ssYMap is the channel name with the map y coordinates.

svZMap

svZMap is a vector with the channel names with the map z coordinates.

ssNCFile

ssNCFile is the netCDF file name. The interpolated channels will be added to this file. This file will be opened with write access.

ssXChanName

ssXChanName is the channel name with the x coordinate.

ssYChanName

ssXChanName is the channel name with the x coordinate.

Comment

The function calculates a map for ssYMap, svZMap and each channel in svZMap, using the Thin-Plate-Spline interpolation method.

The channels ssXChanName and ssYChanName are loaded from the file ssNCFile. These channels must have the same physical unit and approx. the same data range as the map channels ssXMap and ssYMap. If the coordinates are outside the map, the z-coordiantes are calculated by an extrapolation.

The calculated vector with z-coordinates will have the same length as the channe ssXChanName. The data will be saved in the ssNCFile file using the names in svZMap.

If a map cannot be interpolated, the channel in ssNCFile is filled with missing_values (1e10).

Example

ssNCMap = "c:/program files/uniplot/samples/kennfeld.nc"; // map
ssXMap = "N"
ssYMap = "EWGMOM"
svZMap = ["BEEWG", "Pans"]
ssNCFile = "c:/program files/uniplot/samples/vollast.nc";
ssXChanName = "N"
ssYChanName = "MEFF"

NC_MapInterpolation(ssNCMap, ssXMap, ssYMap, svZMap, ssNCFile, ssXChanName, ssYChanName)

History

Version Description
5.9.0 New function.

id-301498