YetAnotherCoupler 3.5.2
Loading...
Searching...
No Matches
interp_method_spmap.h File Reference
#include "interp_method.h"
Include dependency graph for interp_method_spmap.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Data Structures

struct  yac_spmap_scale_config
 
struct  yac_spmap_scale_config::yac_spmap_cell_area_config
 
struct  yac_spmap_scale_config::yac_spmap_cell_area_config::yac_spmap_cell_area_file_config
 

Macros

#define YAC_INTERP_SPMAP_SPREAD_DISTANCE_DEFAULT   (0.0)
 
#define YAC_INTERP_SPMAP_MAX_SEARCH_DISTANCE_DEFAULT   (0.0)
 
#define YAC_INTERP_SPMAP_WEIGHTED_DEFAULT   (YAC_INTERP_SPMAP_AVG)
 
#define YAC_INTERP_SPMAP_SCALE_TYPE_DEFAULT   (YAC_INTERP_SPMAP_NONE)
 
#define YAC_INTERP_SPMAP_SPHERE_RADIUS_DEFAULT   (1.0)
 
#define YAC_INTERP_SPMAP_FILENAME_DEFAULT   (NULL)
 
#define YAC_INTERP_SPMAP_VARNAME_DEFAULT   (NULL)
 
#define YAC_INTERP_SPMAP_MIN_GLOBAL_ID_DEFAULT   (0)
 
#define YAC_INTERP_SPMAP_CELL_AREA_CONFIG_DEFAULT
 
#define YAC_INTERP_SPMAP_SCALE_CONFIG_DEFAULT
 

Enumerations

enum  yac_interp_spmap_weight_type { YAC_INTERP_SPMAP_AVG = 0 , YAC_INTERP_SPMAP_DIST = 1 }
 
enum  yac_interp_spmap_scale_type { YAC_INTERP_SPMAP_NONE = 0 , YAC_INTERP_SPMAP_SRCAREA = 1 , YAC_INTERP_SPMAP_INVTGTAREA = 2 , YAC_INTERP_SPMAP_FRACAREA = 3 }
 
enum  yac_interp_spmap_cell_area_provider { YAC_INTERP_SPMAP_CELL_AREA_FILE = 0 , YAC_INTERP_SPMAP_CELL_AREA_YAC = 1 }
 

Functions

struct interp_methodyac_interp_method_spmap_new (double spread_distance, double max_search_distance, enum yac_interp_spmap_weight_type weight_type, struct yac_spmap_scale_config scale_config)
 

Macro Definition Documentation

◆ YAC_INTERP_SPMAP_CELL_AREA_CONFIG_DEFAULT

#define YAC_INTERP_SPMAP_CELL_AREA_CONFIG_DEFAULT
Value:
((struct yac_spmap_cell_area_config) { \
.cell_area_provider = YAC_INTERP_SPMAP_CELL_AREA_YAC, \
.file_config.filename = YAC_INTERP_SPMAP_FILENAME_DEFAULT, \
.file_config.varname = YAC_INTERP_SPMAP_VARNAME_DEFAULT, \
.file_config.min_global_id = YAC_INTERP_SPMAP_MIN_GLOBAL_ID_DEFAULT})
#define YAC_INTERP_SPMAP_VARNAME_DEFAULT
#define YAC_INTERP_SPMAP_FILENAME_DEFAULT
@ YAC_INTERP_SPMAP_CELL_AREA_YAC
#define YAC_INTERP_SPMAP_SPHERE_RADIUS_DEFAULT
#define YAC_INTERP_SPMAP_MIN_GLOBAL_ID_DEFAULT

Definition at line 60 of file interp_method_spmap.h.

◆ YAC_INTERP_SPMAP_FILENAME_DEFAULT

#define YAC_INTERP_SPMAP_FILENAME_DEFAULT   (NULL)
Examples
test_couple_config.c.

Definition at line 57 of file interp_method_spmap.h.

◆ YAC_INTERP_SPMAP_MAX_SEARCH_DISTANCE_DEFAULT

#define YAC_INTERP_SPMAP_MAX_SEARCH_DISTANCE_DEFAULT   (0.0)

◆ YAC_INTERP_SPMAP_MIN_GLOBAL_ID_DEFAULT

#define YAC_INTERP_SPMAP_MIN_GLOBAL_ID_DEFAULT   (0)
Examples
test_couple_config.c.

Definition at line 59 of file interp_method_spmap.h.

◆ YAC_INTERP_SPMAP_SCALE_CONFIG_DEFAULT

#define YAC_INTERP_SPMAP_SCALE_CONFIG_DEFAULT

◆ YAC_INTERP_SPMAP_SCALE_TYPE_DEFAULT

#define YAC_INTERP_SPMAP_SCALE_TYPE_DEFAULT   (YAC_INTERP_SPMAP_NONE)

Definition at line 55 of file interp_method_spmap.h.

◆ YAC_INTERP_SPMAP_SPHERE_RADIUS_DEFAULT

#define YAC_INTERP_SPMAP_SPHERE_RADIUS_DEFAULT   (1.0)

Definition at line 56 of file interp_method_spmap.h.

◆ YAC_INTERP_SPMAP_SPREAD_DISTANCE_DEFAULT

#define YAC_INTERP_SPMAP_SPREAD_DISTANCE_DEFAULT   (0.0)
Examples
test_interp_method_spmap_parallel.c.

Definition at line 52 of file interp_method_spmap.h.

◆ YAC_INTERP_SPMAP_VARNAME_DEFAULT

#define YAC_INTERP_SPMAP_VARNAME_DEFAULT   (NULL)
Examples
test_couple_config.c.

Definition at line 58 of file interp_method_spmap.h.

◆ YAC_INTERP_SPMAP_WEIGHTED_DEFAULT

#define YAC_INTERP_SPMAP_WEIGHTED_DEFAULT   (YAC_INTERP_SPMAP_AVG)
Examples
test_interp_method_spmap_parallel.c.

Definition at line 54 of file interp_method_spmap.h.

Enumeration Type Documentation

◆ yac_interp_spmap_cell_area_provider

Enumerator
YAC_INTERP_SPMAP_CELL_AREA_FILE 
YAC_INTERP_SPMAP_CELL_AREA_YAC 

Definition at line 34 of file interp_method_spmap.h.

◆ yac_interp_spmap_scale_type

Enumerator
YAC_INTERP_SPMAP_NONE 

weights are not scaled

YAC_INTERP_SPMAP_SRCAREA 

weights are multiplied by the area of the associated source cell

YAC_INTERP_SPMAP_INVTGTAREA 

weights are muliplied by the inverse of the area of the associated target cell

YAC_INTERP_SPMAP_FRACAREA 

weights are multiplied by the area of the associated source cell and the inverse of the area of the associated target cell

Definition at line 21 of file interp_method_spmap.h.

◆ yac_interp_spmap_weight_type

Enumerator
YAC_INTERP_SPMAP_AVG 
YAC_INTERP_SPMAP_DIST 

Definition at line 16 of file interp_method_spmap.h.

Function Documentation

◆ yac_interp_method_spmap_new()

struct interp_method * yac_interp_method_spmap_new ( double spread_distance,
double max_search_distance,
enum yac_interp_spmap_weight_type weight_type,
struct yac_spmap_scale_config scale_config )

Constructor for a interpolation method of type interp_method_spmap
This method searches for each unmasked source point the closest unmasked target point.
If the maximum search distance is > 0.0, only target points that are within this distance from the source points are being considered. If spread_distance is > 0.0, the method uses the previously found target points as a starting point. Around each starting point, a bounding circle is generated. Afterwards for each starting point all target cells whose bounding circles intersect with the generated one are put into a list. Out of this list all target cells connected directly or indirectly through other cells from this list to the target cell of the starting are selected for the interpolation. Then a weighting method is applied to the selected target cells to generate the weights. Afterwards the weights are scaled.

Parameters
[in]spread_distancespreading distance
[in]max_search_distancemaximum search distance
[in]weight_typeweighting type
[in]scale_configscaling configuration
Remarks
the unit for the spread and maximum search distance is Radian

Definition at line 982 of file interp_method_spmap.c.

Here is the call graph for this function:
Here is the caller graph for this function: