YAC 3.18.0
Yet Another Coupler
Loading...
Searching...
No Matches
yac.c File Reference
#include "config.h"
#include <limits.h>
#include <stdlib.h>
#include <stdio.h>
#include <string.h>
#include <mpi.h>
#include "yac_mpi_common.h"
#include "ensure_array_size.h"
#include "event.h"
#include "yac.h"
#include "yac_pak.h"
#include "mpi_handshake.h"
#include "utils_mci.h"
#include "version.h"
#include "instance.h"
#include "fields.h"
#include "couple_config/couple_config.h"
#include "config_yaml.h"
#include "geometry.h"
#include "yac_mpi.h"
#include "yac_assert.h"
#include "utils_common.h"
#include "interpolation/interpolation_exchange.h"
#include "interpolation/interp_weights.h"
#include "interpolation/interp_stack_config.h"
#include "collection_selection_internal.h"
Include dependency graph for yac.c:

Go to the source code of this file.

Data Structures

struct  user_input_data_grid
 
struct  user_input_data_component
 
struct  user_input_data_points
 
struct  user_input_data_masks
 
struct  yac_ext_couple_config
 
struct  yac_cell_area_config
 
struct  yac_ext_spmap_config
 
struct  yac_ext_spmap_config_overwrite_config
 

Macros

#define NO_CHECK   (1)
 
#define PUT_CHECK   (put_mask[i][j])
 
#define SUM   +=
 
#define ASSIGN   =
 
#define AGGREGATE_FRAC(CHECK, EXTRA_CHECK, ACCU_OP)
 
#define AGGREATE_NOFRAC(CHECK, EXTRA_CHECK, ACCU_OP)
 
#define AGGREGATE(EXTRA_CHECK, ACCU_OP)
 
#define NO_CHECK   (1)
 
#define PUT_CHECK   (put_mask[i][j])
 
#define WEIGHT_ACC_(ACC, CHECK, EXTRA_CHECK)
 
#define WEIGHT_ACC(ACC, EXTRA_CHECK)
 

Typedefs

typedef struct yac_cell_area_config CellAreaConfig
 
typedef struct yac_ext_spmap_config ExtSpmapConfig
 
typedef struct yac_ext_spmap_config_overwrite_config ExtSpmapConfigOverwriteConfig
 

Enumerations

enum  { YAC_CONFIG_OUTPUT_SYNC_LOC_DEF_COMP_ = 0 , YAC_CONFIG_OUTPUT_SYNC_LOC_SYNC_DEF_ = 1 , YAC_CONFIG_OUTPUT_SYNC_LOC_ENDDEF_ = 2 }
 

Functions

static int yac_pointer_to_unique_id (void *pointer)
 
static void * yac_unique_id_to_pointer (int id, char const *id_name)
 
static int yac_lookup_pointer (void const *pointer)
 
static void yac_free_pointer_unique_lookup ()
 
static void yac_invalidate_unique_id (int id)
 
static int trace_coupling_start (int field_id, yac_pak_event_type_t type, int put_idx, int level)
 
static void trace_coupling_stop (int field_id, int h_pak_trace)
 
static int trace_setup_start (int yac_instance_id, char const *caller, yac_pak_event_type_t type)
 
static void trace_setup_stop (int yac_instance_id, int h_pak_trace)
 
static void check_name_string (char const *caller, char const *name, char const *name_type)
 
static struct user_input_data_gridget_grid_info (int grid_id, char const *caller, int allow_preliminary)
 
static struct user_input_data_griduser_input_data_get_or_create_grid (char const *grid_name, char const *caller, int *grid_id)
 
static int yac_add_grid (const char *grid_name, struct yac_basic_grid_data grid_data)
 
static void yac_free_global_grids ()
 
static void yac_free_global_points ()
 
static void yac_free_global_masks ()
 
static void yac_free_global_components ()
 
static void yac_free_global_interp_stack_configs ()
 
static int default_instance_id_defined ()
 
static void check_default_instance_id (char const *routine_name)
 
static void yac_check_version (MPI_Comm comm)
 
static void yac_check_yac_int (MPI_Comm comm)
 
static void check_mpi_initialised (char const *routine_name)
 
void yac_cmpi_handshake (MPI_Comm comm, size_t n, char const **group_names, MPI_Comm *group_comms)
 
void yac_cmpi_handshake_f2c (MPI_Fint comm, int n, char const **group_names, MPI_Fint *group_comms)
 
static int yac_init (MPI_Comm comm)
 
int yac_cget_default_instance_id ()
 
int yac_cdefault_instance_defined (void)
 
void yac_cinit_comm_instance (MPI_Comm comm, int *yac_instance_id)
 
void yac_cinit_comm_instance_f2c (MPI_Fint comm, int *yac_instance_id)
 
void yac_cinit_comm (MPI_Comm comm)
 
void yac_cinit_comm_f2c (MPI_Fint comm_f)
 
void yac_cinit_instance (int *yac_instance_id)
 
void yac_cinit (void)
 
void yac_cinit_comm_dummy (MPI_Comm comm)
 
void yac_cinit_comm_dummy_f2c (MPI_Fint comm_f)
 
void yac_cinit_dummy (void)
 
void yac_cget_instance_rank_c2py (int yac_instance_id, int *rank)
 
void yac_cget_instance_size_c2py (int yac_instance_id, int *size)
 
int yac_cyaml_get_emitter_flag_default_c2f ()
 
int yac_cyaml_get_emitter_flag_json_c2f ()
 
void yac_cread_config_yaml_instance (int yac_instance_id, const char *yaml_filename)
 
void yac_cread_config_yaml (const char *yaml_filename)
 
void yac_cread_config_json_instance (int yac_instance_id, const char *yaml_filename)
 
void yac_cread_config_json (const char *yaml_filename)
 
void yac_cset_config_output_file_instance (int yac_instance_id, const char *filename, int fileformat, int sync_location, int include_definitions)
 
void yac_cset_config_output_file (const char *filename, int filetype, int sync_location, int include_definitions)
 
void yac_cset_grid_output_file_instance (int yac_instance_id, const char *gridname, const char *filename)
 
void yac_cset_grid_output_file (const char *gridname, const char *filename)
 
void yac_cset_coordinates_check_instance (int yac_instance_id, int apply_check)
 
void yac_cset_coordinates_check (int apply_check)
 
void yac_cset_coordinates_mismatch_is_fatal_instance (int yac_instance_id, int is_fatal)
 
void yac_cset_coordinates_mismatch_is_fatal (int is_fatal)
 
static void yac_ccleanup_instance_ (int yac_instance_id)
 
void yac_ccleanup_instance (int yac_instance_id)
 Clean-up a YAC instance (see Restarting YAC)
 
void yac_ccleanup ()
 Clean-up default YAC instance (see Restarting YAC)
 
static void cleanup ()
 
void yac_cfinalize_instance (int yac_instance_id)
 Finalises YAC.
 
void yac_cfinalize ()
 Finalises YAC.
 
void yac_cdef_datetime_instance (int yac_instance_id, const char *start_datetime, const char *end_datetime)
 
void yac_cdef_datetime (const char *start_datetime, const char *end_datetime)
 
void yac_cdef_calendar (int calendar)
 
int yac_cget_calendar ()
 
char * yac_cget_start_datetime_instance (int yac_instance_id)
 
char * yac_cget_start_datetime (void)
 
char * yac_cget_end_datetime_instance (int yac_instance_id)
 
char * yac_cget_end_datetime (void)
 
char * yac_cget_version (void)
 
const char * yac_cget_mpi_handshake_group_name (void)
 Retrieve the MPI handshake group name used by YAC.
 
static struct user_input_data_componentget_comp_info (int comp_id, char const *routine)
 
static struct user_input_data_pointsget_points_info (int points_id, char const *routine)
 
void yac_cget_comp_comm (int comp_id, MPI_Comm *comp_comm)
 
void yac_get_comp_comm_f2c (int comp_id, MPI_Fint *comp_comm_f)
 
void yac_cget_comp_size_c2py (int comp_id, int *size)
 
void yac_cget_comp_rank_c2py (int comp_id, int *rank)
 
void yac_cget_comps_comm_instance (int yac_instance_id, char const **comp_names, int num_comps, MPI_Comm *comps_comm)
 
void yac_cget_comps_comm (const char **comp_names, int num_comps, MPI_Comm *comps_comm)
 
void yac_cget_comps_comm_instance_f2c (int yac_instance_id, char const **comp_names, int num_comps, MPI_Fint *comps_comm_f)
 
void yac_cget_comps_comm_f2c (char const **comp_names, int num_comps, MPI_Fint *comps_comm_f)
 
static struct user_input_data_componentuser_input_data_get_or_create_comp (struct yac_instance *instance, char const *name, char const *caller, int *comp_id)
 
void yac_cpredef_comp_instance (int yac_instance_id, char const *name, int *comp_id)
 
void yac_cpredef_comp (char const *name, int *comp_id)
 
void yac_cdef_comps_instance (int yac_instance_id, char const **comp_names, int num_comps, int *comp_ids)
 
void yac_cdef_comps (char const **comp_names, int num_comps, int *comp_ids)
 
void yac_cdef_comp_instance (int yac_instance_id, char const *comp_name, int *comp_id)
 
void yac_cdef_comp (char const *comp_name, int *comp_id)
 
static struct user_input_data_pointsuser_input_data_get_or_create_points (struct user_input_data_grid *grid_info, enum yac_location location, char const *name, char const *caller, int *point_id)
 
static int user_input_data_add_points (struct user_input_data_grid *grid_info, enum yac_location location, yac_coordinate_pointer coordinates, char const *name, char const *caller)
 
static void check_x_vertices (double const *x_vertices, size_t count, char const *routine_name)
 
static void check_y_vertices (double const *y_vertices, size_t count, char const *routine_name)
 
static void check_cell_to_vertex (int *cell_to_vertex, int *num_vertices_per_cell, int nbr_cells, int nbr_vertices, char const *routine_name)
 
static void check_cell_to_edge (int *cell_to_edge, int *num_edges_per_cell, int nbr_cells, int nbr_edges, char const *routine_name)
 
void yac_cdef_points_reg2d_named (int const grid_id, int const *nbr_points, int const located, double const *x_points, double const *y_points, char const *name, int *point_id)
 
void yac_cdef_points_reg2d (int const grid_id, int const *nbr_points, int const located, double const *x_points, double const *y_points, int *point_id)
 
void yac_cdef_points_curve2d_named (int const grid_id, int const *nbr_points, int const located, double const *x_points, double const *y_points, char const *name, int *point_id)
 
void yac_cdef_points_curve2d (int const grid_id, int const *nbr_points, int const located, double const *x_points, double const *y_points, int *point_id)
 
void yac_cdef_points_unstruct_named (int const grid_id, int const nbr_points, int const located, double const *x_points, double const *y_points, char const *name, int *point_id)
 
void yac_cdef_points_unstruct (int const grid_id, int const nbr_points, int const located, double const *x_points, double const *y_points, int *point_id)
 
void yac_cdef_points_reg2d_rot_named (int const grid_id, int const *nbr_points, int const located, double const *x_points, double const *y_points, double x_north_pole, double y_north_pole, char const *name, int *point_id)
 
void yac_cdef_points_reg2d_rot (int const grid_id, int const *nbr_points, int const located, double const *x_points, double const *y_points, double x_north_pole, double y_north_pole, int *point_id)
 
static struct user_input_data_masksuser_input_data_get_or_create_masks (struct user_input_data_grid *grid_info, enum yac_location location, char const *name, char const *caller, int *mask_id)
 
static int user_input_data_add_mask (struct user_input_data_grid *grid_info, enum yac_location location, int const *is_valid, size_t nbr_points, char const *name)
 
void yac_cdef_mask_named (int const grid_id, int const nbr_points, int const located, int const *is_valid, char const *name, int *mask_id)
 
void yac_cdef_mask (int const grid_id, int const nbr_points, int const located, int const *is_valid, int *mask_id)
 
void yac_cset_mask (int const *is_valid, int points_id)
 
void yac_cdef_field_mask (char const *name, int const comp_id, int const *point_ids, int const *mask_ids, int const num_pointsets, int collection_size, const char *timestep, int time_unit, int *field_id)
 
void yac_cdef_field (char const *name, int const comp_id, int const *point_ids, int const num_pointsets, int collection_size, const char *timestep, int time_unit, int *field_id)
 
void yac_cenable_field_frac_mask_instance (int yac_instance_id, const char *comp_name, const char *grid_name, const char *field_name, double frac_mask_fallback_value)
 
void yac_cenable_field_frac_mask (const char *comp_name, const char *grid_name, const char *field_name, double frac_mask_fallback_value)
 
void yac_cdef_component_metadata_instance (int yac_instance_id, const char *comp_name, const char *metadata)
 
void yac_cdef_component_metadata (const char *comp_name, const char *metadata)
 
void yac_cdef_grid_metadata_instance (int yac_instance_id, const char *grid_name, const char *metadata)
 
void yac_cdef_grid_metadata (const char *grid_name, const char *metadata)
 
void yac_cdef_field_metadata_instance (int yac_instance_id, const char *comp_name, const char *grid_name, const char *field_name, const char *metadata)
 
void yac_cdef_field_metadata (const char *comp_name, const char *grid_name, const char *field_name, const char *metadata)
 
const char * yac_cget_component_metadata_instance (int yac_instance_id, const char *comp_name)
 
const char * yac_cget_component_metadata (const char *comp_name)
 
const char * yac_cget_grid_metadata_instance (int yac_instance_id, const char *grid_name)
 
const char * yac_cget_grid_metadata (const char *grid_name)
 
const char * yac_cget_field_metadata_instance (int yac_instance_id, const char *comp_name, const char *grid_name, const char *field_name)
 
const char * yac_cget_field_metadata (const char *comp_name, const char *grid_name, const char *field_name)
 
static void init_ext_couple_config (struct yac_ext_couple_config *ext_couple_config)
 
void yac_cget_ext_couple_config (int *ext_couple_config_id)
 
static void yac_cfree_ext_couple_config_ (struct yac_ext_couple_config ext_couple_config)
 
void yac_cfree_ext_couple_config (int ext_couple_config_id)
 
void yac_cset_ext_couple_config_weight_file_ (struct yac_ext_couple_config *ext_couple_config, char const *weight_file)
 
void yac_cset_ext_couple_config_weight_file (int ext_couple_config_id, char const *weight_file)
 
void yac_cget_ext_couple_config_weight_file (int ext_couple_config_id, char const **weight_file)
 
void yac_cset_ext_couple_config_weight_file_on_existing_ (struct yac_ext_couple_config *ext_couple_config, int weight_file_on_existing)
 
void yac_cset_ext_couple_config_weight_file_on_existing (int ext_couple_config_id, int weight_file_on_existing)
 
void yac_cget_ext_couple_config_weight_file_on_existing (int ext_couple_config_id, int *weight_file_on_existing)
 
void yac_cset_ext_couple_config_mapping_side_ (struct yac_ext_couple_config *ext_couple_config, int mapping_side)
 
void yac_cset_ext_couple_config_mapping_side (int ext_couple_config_id, int mapping_side)
 
void yac_cget_ext_couple_config_mapping_side (int ext_couple_config_id, int *mapping_side)
 
void yac_cset_ext_couple_config_scale_factor_ (struct yac_ext_couple_config *ext_couple_config, double scale_factor)
 
void yac_cset_ext_couple_config_scale_factor (int ext_couple_config_id, double scale_factor)
 
void yac_cget_ext_couple_config_scale_factor (int ext_couple_config_id, double *scale_factor)
 
void yac_cset_ext_couple_config_scale_summand_ (struct yac_ext_couple_config *ext_couple_config, double scale_summand)
 
void yac_cset_ext_couple_config_scale_summand (int ext_couple_config_id, double scale_summand)
 
void yac_cget_ext_couple_config_scale_summand (int ext_couple_config_id, double *scale_summand)
 
void yac_cset_ext_couple_config_src_mask_names_ (struct yac_ext_couple_config *ext_couple_config, size_t num_src_mask_names, char const *const *src_mask_names)
 
void yac_cset_ext_couple_config_src_mask_names (int ext_couple_config_id, size_t num_src_mask_names, char const *const *src_mask_names)
 
void yac_cget_ext_couple_config_src_mask_names (int ext_couple_config_id, size_t *num_src_mask_names, char const *const **src_mask_names)
 
void yac_cset_ext_couple_config_tgt_mask_name_ (struct yac_ext_couple_config *ext_couple_config, char const *tgt_mask_name)
 
void yac_cset_ext_couple_config_tgt_mask_name (int ext_couple_config_id, char const *tgt_mask_name)
 
void yac_cget_ext_couple_config_tgt_mask_name (int ext_couple_config_id, char const **tgt_mask_name)
 
void yac_cset_ext_couple_config_yaxt_exchanger_name_ (struct yac_ext_couple_config *ext_couple_config, char const *yaxt_exchanger_name)
 
void yac_cset_ext_couple_config_yaxt_exchanger_name (int ext_couple_config_id, char const *yaxt_exchanger_name)
 
void yac_cget_ext_couple_config_yaxt_exchanger_name (int ext_couple_config_id, char const **yaxt_exchanger_name)
 
void yac_cset_ext_couple_config_use_raw_exchange_ (struct yac_ext_couple_config *ext_couple_config, int use_raw_exchange)
 
void yac_cset_ext_couple_config_use_raw_exchange (int ext_couple_config_id, int use_raw_exchange)
 
void yac_cget_ext_couple_config_use_raw_exchange (int ext_couple_config_id, int *use_raw_exchange)
 
void yac_cset_ext_couple_config_collection_selection_ (struct yac_ext_couple_config *ext_couple_config, int collection_size, int const *collection_indices)
 
void yac_cset_ext_couple_config_collection_selection (int ext_couple_config_id, int collection_size, int const *collection_indices)
 
void yac_cget_ext_couple_config_collection_selection (int ext_couple_config_id, int *collection_size, int **collection_indices)
 
void yac_cdef_couple_custom_instance_ (int yac_instance_id, char const *src_comp_name, char const *src_grid_name, char const *src_field_name, char const *tgt_comp_name, char const *tgt_grid_name, char const *tgt_field_name, char const *coupling_timestep, int time_unit, int time_reduction, int interp_stack_config_id, int src_lag, int tgt_lag, struct yac_ext_couple_config *ext_couple_config)
 
void yac_cdef_couple_custom_instance (int yac_instance_id, char const *src_comp_name, char const *src_grid_name, char const *src_field_name, char const *tgt_comp_name, char const *tgt_grid_name, char const *tgt_field_name, char const *coupling_timestep, int time_unit, int time_reduction, int interp_stack_config_id, int src_lag, int tgt_lag, int ext_couple_config_id)
 
void yac_cdef_couple_custom (char const *src_comp_name, char const *src_grid_name, char const *src_field_name, char const *tgt_comp_name, char const *tgt_grid_name, char const *tgt_field_name, char const *coupling_timestep, int time_unit, int time_reduction, int interp_stack_config_id, int src_lag, int tgt_lag, int ext_couple_config_id)
 
void yac_cdef_couple_instance (int yac_instance_id, char const *src_comp_name, char const *src_grid_name, char const *src_field_name, char const *tgt_comp_name, char const *tgt_grid_name, char const *tgt_field_name, char const *coupling_timestep, int time_unit, int time_reduction, int interp_stack_config_id, int src_lag, int tgt_lag)
 
void yac_cdef_couple (char const *src_comp_name, char const *src_grid_name, char const *src_field_name, char const *tgt_comp_name, char const *tgt_grid_name, char const *tgt_field_name, char const *coupling_timestep, int time_unit, int time_reduction, int interp_stack_config_id, int src_lag, int tgt_lag)
 
void yac_cdef_couple_instance_ (int yac_instance_id, char const *src_comp_name, char const *src_grid_name, char const *src_field_name, char const *tgt_comp_name, char const *tgt_grid_name, char const *tgt_field_name, char const *coupling_timestep, int time_unit, int time_reduction, int interp_stack_config_id, int src_lag, int tgt_lag, char const *weight_file, int weight_file_on_existing, int mapping_side, double scale_factor, double scale_summand, int num_src_mask_names, char const *const *src_mask_names, char const *tgt_mask_name, char const *yaxt_exchanger_name, int collection_size, int const *collection_indices, int use_raw_exchange)
 
void yac_cdef_couple_ (char const *src_comp_name, char const *src_grid_name, char const *src_field_name, char const *tgt_comp_name, char const *tgt_grid_name, char const *tgt_field_name, char const *coupling_timestep, int time_unit, int time_reduction, int interp_stack_config_id, int src_lag, int tgt_lag, char const *weight_file, int weight_file_on_existing, int mapping_side, double scale_factor, double scale_summand, int num_src_mask_names, char const *const *src_mask_names, char const *tgt_mask_name, char const *yaxt_exchanger_name, int collection_size, int const *collection_indices, int use_raw_exchange)
 
void yac_ccheck_field_dimensions (int field_id, int collection_size, int num_interp_fields, int const *interp_field_sizes)
 
void yac_ccheck_src_field_buffer_size (int field_id, int collection_size, int src_field_buffer_size_)
 
void yac_ccheck_src_field_buffer_sizes (int field_id, int num_src_fields_, int collection_size, int *src_field_buffer_sizes_)
 
void yac_cget_raw_interp_weights_data (int const field_id, double *frac_mask_fallback_value, double *scaling_factor, double *scaling_summand, size_t *num_fixed_values, double **fixed_values, size_t **num_tgt_per_fixed_value, size_t **tgt_idx_fixed, size_t *num_wgt_tgt, size_t **wgt_tgt_idx, size_t **num_src_per_tgt, double **weights, size_t **src_field_idx, size_t **src_idx, size_t *num_src_fields, size_t **src_field_buffer_size)
 
void yac_cget_raw_interp_weights_data_csr (int const field_id, double *frac_mask_fallback_value, double *scaling_factor, double *scaling_summand, size_t *num_fixed_values, double **fixed_values, size_t **num_tgt_per_fixed_value, size_t **tgt_idx_fixed, size_t **src_indptr_, double **weights, size_t **src_field_idx, size_t **src_idx, size_t *num_src_fields, size_t **src_field_buffer_sizes)
 
void yac_cget_raw_interp_weights_data_csr_c2f (int const field_id, double *frac_mask_fallback_value, double *scaling_factor, double *scaling_summand, size_t *num_fixed_values, double **fixed_values, size_t **num_tgt_per_fixed_value, size_t **tgt_idx_fixed, size_t **src_indptr, double **weights, size_t **src_field_idx, size_t **src_idx, size_t *num_src_fields, size_t **src_field_buffer_sizes, size_t *tgt_field_data_size)
 
void yac_cget_action (int field_id, int *action)
 
const char * yac_cget_field_datetime (int field_id)
 
static void yac_cupdate_ (struct coupling_field *cpl_field, struct event *event, int is_source)
 
void yac_cupdate (int field_id)
 
static double ** get_recv_field_pointers (int const field_id, int const collection_size, double *recv_field)
 
static double *** get_src_field_buffer_pointers (int field_id, size_t collection_size, double *src_field_buffer)
 
static double *** get_src_field_buffer_pointers_ptr (int field_id, size_t collection_size, double **src_field_buffer)
 
static void * yac_cget_pre_processing (int const field_id, int collection_size, int *info, int *ierr)
 
static void yac_get (int const field_id, int collection_size, double **recv_field, int is_async, int *info, int *ierr)
 
void yac_get_raw_frac (int const field_id, int const collection_size, double ***src_field_buffer, double ***src_frac_mask_buffer, int is_async, int *info, int *ierror)
 
void yac_get_ (int const field_id, int const collection_size, double *recv_field, int is_async, int *info, int *ierr)
 
void yac_cget_ (int const field_id, int const collection_size, double *recv_field, int *info, int *ierr)
 
void yac_cget_async_ (int const field_id, int const collection_size, double *recv_field, int *info, int *ierr)
 
void yac_cget (int const field_id, int collection_size, double **recv_field, int *info, int *ierr)
 
void yac_cget_async (int const field_id, int collection_size, double **recv_field, int *info, int *ierr)
 
void yac_get_raw_frac_ (int const field_id, int const collection_size, double *src_field_buffer, double *src_frac_mask_buffer, int is_async, int *info, int *ierr)
 
static void yac_get_raw_frac_ptr_ (int const field_id, int const collection_size, double **src_field_buffer, double **src_frac_mask_buffer, int is_async, int *info, int *ierr)
 
void yac_cget_raw_ (int const field_id, int const collection_size, double *src_field_buffer, int *info, int *ierr)
 
void yac_cget_raw_frac_ (int const field_id, int const collection_size, double *src_field_buffer, double *src_frac_mask_buffer, int *info, int *ierr)
 
void yac_cget_raw_ptr_ (int const field_id, int const collection_size, double **src_field_buffer, int *info, int *ierr)
 
void yac_cget_raw_frac_ptr_ (int const field_id, int const collection_size, double **src_field_buffer, double **src_frac_mask_buffer, int *info, int *ierr)
 
void yac_cget_raw_async_ (int const field_id, int const collection_size, double *src_field_buffer, int *info, int *ierr)
 
void yac_cget_raw_frac_async_ (int const field_id, int const collection_size, double *src_field_buffer, double *src_frac_mask_buffer, int *info, int *ierr)
 
void yac_cget_raw_async_ptr_ (int const field_id, int const collection_size, double **src_field_buffer, int *info, int *ierr)
 
void yac_cget_raw_frac_async_ptr_ (int const field_id, int const collection_size, double **src_field_buffer, double **src_frac_mask_buffer, int *info, int *ierr)
 
void yac_cget_raw (int const field_id, int collection_size, double ***src_field_buffer, int *info, int *ierr)
 
void yac_cget_raw_async (int const field_id, int collection_size, double ***src_field_buffer, int *info, int *ierr)
 
void yac_cget_raw_frac (int const field_id, int collection_size, double ***src_field_buffer, double ***src_frac_mask_buffer, int *info, int *ierr)
 
void yac_cget_raw_frac_async (int const field_id, int collection_size, double ***src_field_buffer, double ***src_frac_mask_buffer, int *info, int *ierr)
 
static double *** get_send_field_pointers (int field_id, size_t collection_size, double *send_field)
 
void yac_cput_ (int const field_id, int const collection_size, double *send_field, int *info, int *ierr)
 
void yac_cput_frac_ (int const field_id, int const collection_size, double *send_field, double *send_frac_mask, int *info, int *ierr)
 
static void get_send_field_pointers_ptr_ (int const field_id, int const collection_size, double **send_field, double **send_frac_mask, double ****send_field_, double ****send_frac_mask_)
 
void yac_cput_ptr_ (int const field_id, int const collection_size, double **send_field, int *info, int *ierr)
 
void yac_cput_frac_ptr_ (int const field_id, int const collection_size, double **send_field, double **send_frac_mask, int *info, int *ierr)
 
void yac_ctest (int field_id, int *flag)
 
void yac_cwait (int field_id)
 
void * yac_get_field_put_mask_c2f (int field_id)
 
void * yac_get_field_get_mask_c2f (int field_id)
 
static void * yac_cput_pre_processing (struct coupling_field *cpl_field, unsigned put_idx, int const collection_size, double ***send_field, double ****send_field_acc_, double ***send_frac_mask, double ****send_frac_mask_acc_, int *with_frac_mask_, int *use_raw_exchange_, int *info, int *ierr)
 
void yac_cput_frac (int const field_id, int const collection_size, double ***const send_field, double ***const send_frac_mask, int *info, int *ierr)
 
void yac_cput (int const field_id, int const collection_size, double ***const send_field, int *info, int *ierr)
 
void yac_cexchange_ (int const send_field_id, int const recv_field_id, int const collection_size, double *send_field, double *recv_field, int *send_info, int *recv_info, int *ierr)
 
void yac_cexchange_raw_frac_ (int const send_field_id, int const recv_field_id, int const collection_size, double *send_field, double *send_frac_mask, double *src_field_buffer, double *src_frac_mask_buffer, int *send_info, int *recv_info, int *ierr)
 
void yac_cexchange_raw_ (int const send_field_id, int const recv_field_id, int const collection_size, double *send_field, double *src_field_buffer, int *send_info, int *recv_info, int *ierr)
 
void yac_cexchange_frac_ (int const send_field_id, int const recv_field_id, int const collection_size, double *send_field, double *send_frac_mask, double *recv_field, int *send_info, int *recv_info, int *ierr)
 
void yac_cexchange_ptr_ (int const send_field_id, int const recv_field_id, int const collection_size, double **send_field, double **recv_field, int *send_info, int *recv_info, int *ierr)
 
void yac_cexchange_raw_ptr_ (int const send_field_id, int const recv_field_id, int const collection_size, double **send_field, double **src_field_buffer, int *send_info, int *recv_info, int *ierr)
 
void yac_cexchange_frac_ptr_ (int const send_field_id, int const recv_field_id, int const collection_size, double **send_field, double **send_frac_mask, double **recv_field, int *send_info, int *recv_info, int *ierr)
 
void yac_cexchange_raw_frac_ptr_ (int const send_field_id, int const recv_field_id, int const collection_size, double **send_field, double **send_frac_mask, double **src_field_buffer, double **src_frac_mask_buffer, int *send_info, int *recv_info, int *ierr)
 
void yac_cexchange_frac (int const send_field_id, int const recv_field_id, int const collection_size, double ***const send_field, double ***const send_frac_mask, double **recv_field, int *send_info, int *recv_info, int *ierr)
 
void yac_cexchange_raw_frac (int const send_field_id, int const recv_field_id, int const collection_size, double ***const send_field, double ***const send_frac_mask, double ***src_field_buffer, double ***src_frac_mask_buffer, int *send_info, int *recv_info, int *ierr)
 
void yac_cexchange (int const send_field_id, int const recv_field_id, int const collection_size, double ***const send_field, double **recv_field, int *send_info, int *recv_info, int *ierr)
 
void yac_cexchange_raw (int const send_field_id, int const recv_field_id, int const collection_size, double ***const send_field, double ***src_field_buffer, int *send_info, int *recv_info, int *ierr)
 
void yac_csync_def_instance (int yac_instance_id)
 
void yac_csync_def (void)
 
void yac_csync_def_comps_instance (int yac_instance_id, char const **comp_names, int num_comp_names)
 
void yac_csync_def_comps (char const **comp_names, int num_comp_names)
 
static void check_preliminary_entries (struct yac_instance *instance, char const *caller)
 
void yac_cenddef_instance (int yac_instance_id)
 
void yac_cenddef (void)
 
void yac_cenddef_and_emit_config_instance (int yac_instance_id, int emit_flags, char **config)
 
void yac_cenddef_and_emit_config (int emit_flags, char **config)
 
int yac_cget_comp_id_instance (int yac_instance_id, const char *comp_name)
 
int yac_cget_comp_id (const char *comp_name)
 
int yac_cget_grid_id (const char *grid_name)
 
int yac_cget_points_id (int grid_id, int location, const char *point_name)
 
int yac_cget_mask_id (int grid_id, int location, const char *mask_name)
 
int yac_cget_field_is_defined_instance (int yac_instance_id, const char *comp_name, const char *grid_name, const char *field_name)
 
int yac_cget_field_is_defined (const char *comp_name, const char *grid_name, const char *field_name)
 
int yac_cget_field_id_instance (int yac_instance_id, const char *comp_name, const char *grid_name, const char *field_name)
 
int yac_cget_field_id (const char *comp_name, const char *grid_name, const char *field_name)
 
int yac_cget_nbr_comps_instance (int yac_instance_id)
 
int yac_cget_nbr_comps (void)
 
int yac_cget_nbr_grids_instance (int yac_instance_id)
 
int yac_cget_nbr_grids ()
 
int yac_cget_comp_nbr_grids_instance (int yac_instance_id, const char *comp_name)
 
int yac_cget_comp_nbr_grids (const char *comp_name)
 
int yac_cget_nbr_fields_instance (int yac_instance_id, const char *comp_name, const char *grid_name)
 
int yac_cget_nbr_fields (const char *comp_name, const char *grid_name)
 
void yac_cget_comp_names_instance (int yac_instance_id, int nbr_comps, const char **comp_names)
 
void yac_cget_comp_names (int nbr_comps, const char **comp_names)
 
void yac_cget_grid_names_instance (int yac_instance_id, int nbr_grids, const char **grid_names)
 
void yac_cget_grid_names (int nbr_grids, const char **grid_names)
 
void yac_cget_comp_grid_names_instance (int yac_instance_id, const char *comp_name, int nbr_grids, const char **grid_names)
 
void yac_cget_comp_grid_names (const char *comp_name, int nbr_grids, const char **grid_names)
 
void yac_cget_field_names_instance (int yac_instance_id, const char *comp_name, const char *grid_name, int nbr_fields, const char **field_names)
 
void yac_cget_field_names (const char *comp_name, const char *grid_name, int nbr_fields, const char **field_names)
 
const char * yac_cget_component_name_from_field_id (int field_id)
 
const char * yac_cget_grid_name_from_field_id (int field_id)
 
const char * yac_cget_field_name_from_field_id (int field_id)
 
const char * yac_cget_timestep_from_field_id (int field_id)
 
int yac_cget_collection_size_from_field_id (int field_id)
 
int yac_cget_role_from_field_id (int field_id)
 
const char * yac_cget_field_timestep_instance (int yac_instance_id, const char *comp_name, const char *grid_name, const char *field_name)
 
const char * yac_cget_field_timestep (const char *comp_name, const char *grid_name, const char *field_name)
 
double yac_cget_field_frac_mask_fallback_value_instance (int yac_instance_id, const char *comp_name, const char *grid_name, const char *field_name)
 
int yac_cget_field_collection_size_instance (int yac_instance_id, const char *comp_name, const char *grid_name, const char *field_name)
 
double yac_cget_field_frac_mask_fallback_value (const char *comp_name, const char *grid_name, const char *field_name)
 
int yac_cget_field_collection_size (const char *comp_name, const char *grid_name, const char *field_name)
 
int yac_cget_field_role_instance (int yac_instance_id, const char *comp_name, const char *grid_name, const char *field_name)
 
int yac_cget_field_role (const char *comp_name, const char *grid_name, const char *field_name)
 
void yac_cget_field_source_instance (int yac_instance_id, const char *tgt_comp_name, const char *tgt_grid_name, const char *tgt_field_name, const char **src_comp_name, const char **src_grid_name, const char **src_field_name)
 
void yac_cget_field_source (const char *tgt_comp_name, const char *tgt_grid_name, const char *tgt_field_name, const char **src_comp_name, const char **src_grid_name, const char **src_field_name)
 
void yac_cdef_grid_reg2d (const char *grid_name, int nbr_vertices[2], int cyclic[2], double *x_vertices, double *y_vertices, int *grid_id)
 
void yac_cdef_grid_curve2d (const char *grid_name, int nbr_vertices[2], int cyclic[2], double *x_vertices, double *y_vertices, int *grid_id)
 
void yac_cdef_grid_unstruct (const char *grid_name, int nbr_vertices, int nbr_cells, int *num_vertices_per_cell, double *x_vertices, double *y_vertices, int *cell_to_vertex, int *grid_id)
 
void yac_cdef_grid_unstruct_ll (const char *grid_name, int nbr_vertices, int nbr_cells, int *num_vertices_per_cell, double *x_vertices, double *y_vertices, int *cell_to_vertex, int *grid_id)
 
void yac_cdef_grid_unstruct_edge (const char *grid_name, int nbr_vertices, int nbr_cells, int nbr_edges, int *num_edges_per_cell, double *x_vertices, double *y_vertices, int *cell_to_edge, int *edge_to_vertex, int *grid_id)
 
void yac_cdef_grid_unstruct_edge_ll (const char *grid_name, int nbr_vertices, int nbr_cells, int nbr_edges, int *num_edges_per_cell, double *x_vertices, double *y_vertices, int *cell_to_edge, int *edge_to_vertex, int *grid_id)
 
void yac_cdef_grid_cloud (const char *grid_name, int nbr_points, double *x_points, double *y_points, int *grid_id)
 
void yac_cdef_grid_reg2d_rot (const char *grid_name, int nbr_vertices[2], int cyclic[2], double *x_vertices, double *y_vertices, double x_north_pole, double y_north_pole, int *grid_id)
 
static void get_global_ids_reference (char const *caller, int location, int grid_id, yac_int **grid_global_ids, size_t *count)
 
void yac_cset_global_index_yac_int (yac_int const *global_index, int location, int grid_id)
 
void yac_cset_global_index (int const *global_index, int location, int grid_id)
 
void yac_cset_core_mask (int const *is_core, int location, int grid_id)
 
size_t yac_cget_grid_size (int located, int grid_id)
 
void yac_ccompute_grid_cell_areas (int grid_id, double *cell_areas)
 
size_t yac_cget_points_size (int points_id)
 
void yac_cget_interp_stack_config (int *interp_stack_config_id)
 
void yac_cfree_interp_stack_config (int interp_stack_config_id)
 
void yac_cadd_interp_stack_config_average (int interp_stack_config_id, int reduction_type, int partial_coverage)
 
void yac_cadd_interp_stack_config_ncc (int interp_stack_config_id, int weight_type, int partial_coverage)
 
void yac_cadd_interp_stack_config_nnn (int interp_stack_config_id, int type, size_t n, double max_search_distance, double scale)
 
void yac_cadd_interp_stack_config_dnn (int interp_stack_config_id, int weight_type, int search_distance_type, double search_distance, double scale)
 
void yac_cadd_interp_stack_config_rbf (int interp_stack_config_id, size_t n, double max_search_distance, double scale)
 
void yac_cadd_interp_stack_config_conservative (int interp_stack_config_id, int order, int enforced_conserv, int partial_coverage, int normalisation)
 
void yac_cget_ext_spmap_config (int *ext_spmap_config_id)
 
void yac_cfree_ext_spmap_config (int ext_spmap_config_id)
 
void yac_cset_ext_spmap_config_spread_distance (int ext_spmap_config_id, double spread_distance)
 
void yac_cset_ext_spmap_config_max_search_distance (int ext_spmap_config_id, double max_search_distance)
 
void yac_cset_ext_spmap_config_weight_type (int ext_spmap_config_id, int weight_type)
 
void yac_cset_ext_spmap_config_scale_type (int ext_spmap_config_id, int scale_type)
 
void yac_cset_ext_spmap_config_src_cell_area_config_yac (int ext_spmap_config_id, double sphere_radius)
 
void yac_cset_ext_spmap_config_tgt_cell_area_config_yac (int ext_spmap_config_id, double sphere_radius)
 
void set_cell_area_config_file (CellAreaConfig *cell_area_config, char const *filename, char const *varname, int min_global_id, char const *role)
 
void yac_cset_ext_spmap_config_src_cell_area_config_file (int ext_spmap_config_id, char const *filename, char const *varname, int min_global_id)
 
void yac_cset_ext_spmap_config_tgt_cell_area_config_file (int ext_spmap_config_id, char const *filename, char const *varname, int min_global_id)
 
void yac_cget_spmap_overwrite_config (int *spmap_overwrite_config_id)
 
void yac_cfree_spmap_overwrite_config (int spmap_overwrite_config_id)
 
void yac_cset_spmap_overwrite_config_src_point_selection_bnd_circle (int spmap_overwrite_config_id, double center_lon, double center_lat, double inc_angle)
 
void yac_cset_spmap_overwrite_config_spread_distance (int spmap_overwrite_config_id, double spread_distance)
 
void yac_cset_spmap_overwrite_config_max_search_distance (int spmap_overwrite_config_id, double max_search_distance)
 
void yac_cset_spmap_overwrite_config_weight_type (int spmap_overwrite_config_id, int weight_type)
 
void yac_cadd_interp_stack_config_spmap (int interp_stack_config_id, double spread_distance, double max_search_distance, int weight_type, int scale_type, double src_sphere_radius, char const *src_filename, char const *src_varname, int src_min_global_id, double tgt_sphere_radius, char const *tgt_filename, char const *tgt_varname, int tgt_min_global_id)
 
static struct yac_spmap_cell_area_configgenerate_cell_area_config (CellAreaConfig config)
 
static struct yac_spmap_overwrite_configgenerate_overwrite_config (int spmap_overwrite_config_id)
 
void yac_cadd_interp_stack_config_spmap_ext (int interp_stack_config_id, int ext_spmap_config_id, int *spmap_overwrite_config_ids, int spmap_overwrite_config_count)
 
void yac_cadd_interp_stack_config_spmap_f2c (int interp_stack_config_id, double spread_distance, double max_search_distance, int weight_type, int scale_type, double src_sphere_radius, char const *src_filename, char const *src_varname, int src_min_global_id, double tgt_sphere_radius, char const *tgt_filename, char const *tgt_varname, int tgt_min_global_id, int *overwrite_config_ids, int overwrite_config_count)
 
void yac_cadd_interp_stack_config_hcsbb (int interp_stack_config_id)
 
void yac_cadd_interp_stack_config_user_file_2 (int interp_stack_config_id, char const *filename, int on_missing_file, int on_succes)
 
void yac_cadd_interp_stack_config_user_file (int interp_stack_config_id, char const *filename)
 
void yac_cadd_interp_stack_config_fixed (int interp_stack_config_id, double value)
 
void yac_cadd_interp_stack_config_check (int interp_stack_config_id, char const *constructor_key, char const *do_search_key)
 
void yac_cadd_interp_stack_config_creep (int interp_stack_config_id, int creep_distance)
 
void yac_cadd_interp_stack_config_user_callback (int interp_stack_config_id, char const *func_compute_weights_key)
 
void yac_cadd_compute_weights_callback (yac_func_compute_weights compute_weights_callback, void *user_data, char const *key)
 
static int yac_cget_interp_stack_config_from_string (char const *interp_stack_config, int parse_flags)
 
void yac_cget_interp_stack_config_from_string_yaml (char const *interp_stack_config, int *interp_stack_config_id)
 
void yac_cget_interp_stack_config_from_string_json (char const *interp_stack_config, int *interp_stack_config_id)
 

Variables

int const YAC_LOCATION_CELL = YAC_LOC_CELL
 
int const YAC_LOCATION_CORNER = YAC_LOC_CORNER
 
int const YAC_LOCATION_EDGE = YAC_LOC_EDGE
 
int const YAC_EXCHANGE_TYPE_INVALID = INVALID
 
int const YAC_EXCHANGE_TYPE_NONE = NOTHING
 
int const YAC_EXCHANGE_TYPE_SOURCE = SOURCE
 
int const YAC_EXCHANGE_TYPE_TARGET = TARGET
 
int const YAC_ACTION_NONE = NONE
 no data exchanges
 
int const YAC_ACTION_REDUCTION = REDUCTION
 data reduction, but data exchange
 
int const YAC_ACTION_COUPLING = COUPLING
 data exchange
 
int const YAC_ACTION_RESTART = RESTART
 
int const YAC_ACTION_GET_FOR_RESTART = GET_FOR_RESTART
 last valid get
 
int const YAC_ACTION_PUT_FOR_RESTART = PUT_FOR_RESTART
 last valid put
 
int const YAC_ACTION_GET_FOR_CHECKPOINT = GET_FOR_CHECKPOINT
 
int const YAC_ACTION_PUT_FOR_CHECKPOINT = PUT_FOR_CHECKPOINT
 
int const YAC_ACTION_OUT_OF_BOUND = OUT_OF_BOUND
 put/get is outside of the valid range
 
int const YAC_REDUCTION_TIME_NONE = TIME_NONE
 
int const YAC_REDUCTION_TIME_ACCUMULATE = TIME_ACCUMULATE
 
int const YAC_REDUCTION_TIME_AVERAGE = TIME_AVERAGE
 
int const YAC_REDUCTION_TIME_MINIMUM = TIME_MINIMUM
 
int const YAC_REDUCTION_TIME_MAXIMUM = TIME_MAXIMUM
 
int const YAC_TIME_UNIT_MILLISECOND = C_MILLISECOND
 
int const YAC_TIME_UNIT_SECOND = C_SECOND
 
int const YAC_TIME_UNIT_MINUTE = C_MINUTE
 
int const YAC_TIME_UNIT_HOUR = C_HOUR
 
int const YAC_TIME_UNIT_DAY = C_DAY
 
int const YAC_TIME_UNIT_MONTH = C_MONTH
 
int const YAC_TIME_UNIT_YEAR = C_YEAR
 
int const YAC_TIME_UNIT_ISO_FORMAT = C_ISO_FORMAT
 
int const YAC_CALENDAR_NOT_SET = CALENDAR_NOT_SET
 
int const YAC_PROLEPTIC_GREGORIAN = PROLEPTIC_GREGORIAN
 
int const YAC_YEAR_OF_365_DAYS = YEAR_OF_365_DAYS
 
int const YAC_YEAR_OF_360_DAYS = YEAR_OF_360_DAYS
 
int const YAC_AVG_ARITHMETIC = YAC_INTERP_AVG_ARITHMETIC
 
int const YAC_AVG_DIST = YAC_INTERP_AVG_DIST
 
int const YAC_AVG_BARY = YAC_INTERP_AVG_BARY
 
int const YAC_NCC_AVG = YAC_INTERP_NCC_AVG
 
int const YAC_NCC_DIST = YAC_INTERP_NCC_DIST
 
int const YAC_NNN_AVG = YAC_INTERP_NNN_AVG
 
int const YAC_NNN_DIST = YAC_INTERP_NNN_DIST
 
int const YAC_NNN_GAUSS = YAC_INTERP_NNN_GAUSS
 
int const YAC_NNN_RBF = YAC_INTERP_NNN_RBF
 
int const YAC_NNN_ZERO = YAC_INTERP_NNN_ZERO
 
int const YAC_DNN_AVG = YAC_INTERP_DNN_WEIGHT_AVG
 
int const YAC_DNN_DIST = YAC_INTERP_DNN_WEIGHT_DIST
 
int const YAC_DNN_GAUSS = YAC_INTERP_DNN_WEIGHT_GAUSS
 
int const YAC_DNN_RBF = YAC_INTERP_DNN_WEIGHT_RBF
 
int const YAC_DNN_SEARCH_DISTANCE_FIXED = YAC_INTERP_DNN_SEARCH_DISTANCE_FIXED
 
int const YAC_DNN_SEARCH_DISTANCE_CELL_AREA = YAC_INTERP_DNN_SEARCH_DISTANCE_CELL_AREA
 
int const YAC_CONSERV_DESTAREA = YAC_INTERP_CONSERV_DESTAREA
 
int const YAC_CONSERV_FRACAREA = YAC_INTERP_CONSERV_FRACAREA
 
int const YAC_SPMAP_AVG = YAC_INTERP_SPMAP_AVG
 
int const YAC_SPMAP_DIST = YAC_INTERP_SPMAP_DIST
 
int const YAC_SPMAP_NONE = YAC_INTERP_SPMAP_NONE
 
int const YAC_SPMAP_SRCAREA = YAC_INTERP_SPMAP_SRCAREA
 
int const YAC_SPMAP_INVTGTAREA = YAC_INTERP_SPMAP_INVTGTAREA
 
int const YAC_SPMAP_FRACAREA = YAC_INTERP_SPMAP_FRACAREA
 
int const YAC_FILE_MISSING_ERROR = YAC_INTERP_FILE_MISSING_ERROR
 abort on missing file
 
int const YAC_FILE_MISSING_CONT = YAC_INTERP_FILE_MISSING_CONT
 continue on missing file
 
int const YAC_FILE_SUCCESS_STOP = YAC_INTERP_FILE_SUCCESS_STOP
 
int const YAC_FILE_SUCCESS_CONT = YAC_INTERP_FILE_SUCCESS_CONT
 
int const YAC_CONFIG_OUTPUT_FORMAT_YAML = YAC_TEXT_FILETYPE_YAML
 
int const YAC_CONFIG_OUTPUT_FORMAT_JSON = YAC_TEXT_FILETYPE_JSON
 
int const YAC_WGT_ON_EXISTING_ERROR = YAC_WEIGHT_FILE_ERROR
 
int const YAC_WGT_ON_EXISTING_KEEP = YAC_WEIGHT_FILE_KEEP
 keep existing weight file
 
int const YAC_WGT_ON_EXISTING_OVERWRITE = YAC_WEIGHT_FILE_OVERWRITE
 overwrite existing weight file
 
int const YAC_CONFIG_OUTPUT_SYNC_LOC_DEF_COMP
 after component definition
 
int const YAC_CONFIG_OUTPUT_SYNC_LOC_SYNC_DEF
 after synchronization of definition
 
int const YAC_CONFIG_OUTPUT_SYNC_LOC_ENDDEF
 after end of definitions
 
static const char * mpi_handshake_group_name = "yac"
 Name of the MPI group used by YAC in MPI handshake.
 
static int default_instance_id = INT_MAX
 
static int yac_instance_count = 0
 
static void ** pointer_lookup_table = NULL
 
static int pointer_lookup_table_size = 0
 
static struct user_input_data_grid ** global_grids = NULL
 
static size_t num_global_grids = 0
 
static struct user_input_data_component ** global_components = NULL
 
static size_t num_global_components = 0
 
static struct user_input_data_points ** global_points = NULL
 
static size_t num_global_points = 0
 
static struct user_input_data_masks ** global_masks = NULL
 
static size_t num_global_masks = 0
 
static struct yac_interp_stack_config ** global_interp_stack_configs = NULL
 
static size_t num_global_interp_stack_configs = 0
 
static int yac_invalid_pointer_sentinel
 

Macro Definition Documentation

◆ AGGREATE_NOFRAC

#define AGGREATE_NOFRAC ( CHECK,
EXTRA_CHECK,
ACCU_OP )
Value:
{ \
{ \
YAC_OMP_FOR \
for (size_t j = 0; j < data_size; ++j) {\
double send_field_value = send_field[h][i][j]; \
if (CHECK && (EXTRA_CHECK)) \
send_field_acc[h][i][j] ACCU_OP send_field_value; \
} \
} \
}
#define YAC_OMP_PARALLEL

◆ AGGREGATE

#define AGGREGATE ( EXTRA_CHECK,
ACCU_OP )
Value:
{ \
for (int h = 0; h < collection_size; h++) { \
for (size_t i = 0; i < num_interp_fields; i++) { \
size_t data_size = \
yac_coupling_field_get_data_size( \
cpl_field, \
if (with_frac_mask) { \
if (put_mask) AGGREGATE_FRAC(PUT_CHECK, EXTRA_CHECK, ACCU_OP) \
else AGGREGATE_FRAC(NO_CHECK, EXTRA_CHECK, ACCU_OP) \
} else { \
if (put_mask) AGGREATE_NOFRAC(PUT_CHECK, EXTRA_CHECK, ACCU_OP) \
else AGGREATE_NOFRAC(NO_CHECK, EXTRA_CHECK, ACCU_OP) \
} \
} \
} \
break; \
}
struct yac_interp_field const * yac_coupling_field_get_interp_fields(struct coupling_field *cpl_field)
Definition fields.c:746
int collection_size
int const * location
#define AGGREATE_NOFRAC(CHECK, EXTRA_CHECK, ACCU_OP)
#define NO_CHECK
#define AGGREGATE_FRAC(CHECK, EXTRA_CHECK, ACCU_OP)
#define PUT_CHECK

◆ AGGREGATE_FRAC

#define AGGREGATE_FRAC ( CHECK,
EXTRA_CHECK,
ACCU_OP )
Value:
{ \
{ \
YAC_OMP_FOR \
for (size_t j = 0; j < data_size; ++j) { \
double frac_mask = send_frac_mask[h][i][j]; \
double send_field_value = send_field[h][i][j] * frac_mask; \
if (CHECK && (EXTRA_CHECK)) { \
if (frac_mask != 0.0) { \
send_field_acc[h][i][j] ACCU_OP send_field_value; \
send_frac_mask_acc[h][i][j] ACCU_OP frac_mask; \
} \
} \
} \
} \
}

◆ ASSIGN

#define ASSIGN   =

◆ NO_CHECK [1/2]

#define NO_CHECK   (1)

◆ NO_CHECK [2/2]

#define NO_CHECK   (1)

◆ PUT_CHECK [1/2]

#define PUT_CHECK   (put_mask[i][j])

◆ PUT_CHECK [2/2]

#define PUT_CHECK   (put_mask[i][j])

◆ SUM

#define SUM   +=

◆ WEIGHT_ACC

#define WEIGHT_ACC ( ACC,
EXTRA_CHECK )
Value:
{ \
if (put_mask) WEIGHT_ACC_(ACC, PUT_CHECK, EXTRA_CHECK) \
else WEIGHT_ACC_(ACC, NO_CHECK, EXTRA_CHECK) \
}
#define WEIGHT_ACC_(ACC, CHECK, EXTRA_CHECK)

◆ WEIGHT_ACC_

#define WEIGHT_ACC_ ( ACC,
CHECK,
EXTRA_CHECK )
Value:
{ \
for (size_t j = 0; j < data_size; j++) \
if (CHECK && (EXTRA_CHECK)) ACC[h][i][j] *= weight; \
}

Typedef Documentation

◆ CellAreaConfig

◆ ExtSpmapConfig

◆ ExtSpmapConfigOverwriteConfig

Enumeration Type Documentation

◆ anonymous enum

anonymous enum
Enumerator
YAC_CONFIG_OUTPUT_SYNC_LOC_DEF_COMP_ 
YAC_CONFIG_OUTPUT_SYNC_LOC_SYNC_DEF_ 
YAC_CONFIG_OUTPUT_SYNC_LOC_ENDDEF_ 

Definition at line 123 of file yac.c.

Function Documentation

◆ check_cell_to_edge()

static void check_cell_to_edge ( int * cell_to_edge,
int * num_edges_per_cell,
int nbr_cells,
int nbr_edges,
char const * routine_name )
static

Definition at line 1519 of file yac.c.

Here is the caller graph for this function:

◆ check_cell_to_vertex()

static void check_cell_to_vertex ( int * cell_to_vertex,
int * num_vertices_per_cell,
int nbr_cells,
int nbr_vertices,
char const * routine_name )
static

Definition at line 1499 of file yac.c.

Here is the caller graph for this function:

◆ check_default_instance_id()

static void check_default_instance_id ( char const * routine_name)
static

Definition at line 597 of file yac.c.

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

◆ check_mpi_initialised()

static void check_mpi_initialised ( char const * routine_name)
static

Definition at line 658 of file yac.c.

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

◆ check_name_string()

static void check_name_string ( char const * caller,
char const * name,
char const * name_type )
static

checks that the given grid name is valid, i.e. not NULL, not empty, and not too long

Definition at line 416 of file yac.c.

Here is the caller graph for this function:

◆ check_preliminary_entries()

static void check_preliminary_entries ( struct yac_instance * instance,
char const * caller )
static

Checks that there are no preliminary entries for the given instance, and raises an error if there are any. This is used to check that all forward declarations have been resolved before finalizing the instance definition.

Definition at line 5027 of file yac.c.

Here is the caller graph for this function:

◆ check_x_vertices()

static void check_x_vertices ( double const * x_vertices,
size_t count,
char const * routine_name )
static

Definition at line 1478 of file yac.c.

Here is the caller graph for this function:

◆ check_y_vertices()

static void check_y_vertices ( double const * y_vertices,
size_t count,
char const * routine_name )
static

Definition at line 1488 of file yac.c.

Here is the caller graph for this function:

◆ cleanup()

static void cleanup ( )
static

Definition at line 1006 of file yac.c.

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

◆ default_instance_id_defined()

static int default_instance_id_defined ( )
static

Definition at line 593 of file yac.c.

Here is the caller graph for this function:

◆ generate_cell_area_config()

static struct yac_spmap_cell_area_config * generate_cell_area_config ( CellAreaConfig config)
static

Definition at line 6398 of file yac.c.

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

◆ generate_overwrite_config()

static struct yac_spmap_overwrite_config * generate_overwrite_config ( int spmap_overwrite_config_id)
static

Definition at line 6422 of file yac.c.

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

◆ get_comp_info()

static struct user_input_data_component * get_comp_info ( int comp_id,
char const * routine )
static

Definition at line 1120 of file yac.c.

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

◆ get_global_ids_reference()

static void get_global_ids_reference ( char const * caller,
int location,
int grid_id,
yac_int ** grid_global_ids,
size_t * count )
static

Retrieves reference to global IDs for a specified grid and location.

Parameters
[in]callerName of the calling function or context for debugging.
[in]locationLocation (cell, corner, or edge).
[in]grid_idGrid id for which the global id reference is to be retrieved.
[out]grid_global_idsReference to an allocated global IDs array
[out]countSize of the global IDs array.

Definition at line 5777 of file yac.c.

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

◆ get_grid_info()

static struct user_input_data_grid * get_grid_info ( int grid_id,
char const * caller,
int allow_preliminary )
static

returns the user input data grid with the given name, or NULL if no such grid exists

Definition at line 434 of file yac.c.

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

◆ get_points_info()

static struct user_input_data_points * get_points_info ( int points_id,
char const * routine )
static

Definition at line 1141 of file yac.c.

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

◆ get_recv_field_pointers()

static double ** get_recv_field_pointers ( int const field_id,
int const collection_size,
double * recv_field )
static

Definition at line 3078 of file yac.c.

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

◆ get_send_field_pointers()

static double *** get_send_field_pointers ( int field_id,
size_t collection_size,
double * send_field )
static

Definition at line 3636 of file yac.c.

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

◆ get_send_field_pointers_ptr_()

static void get_send_field_pointers_ptr_ ( int const field_id,
int const collection_size,
double ** send_field,
double ** send_frac_mask,
double **** send_field_,
double **** send_frac_mask_ )
static

Definition at line 3724 of file yac.c.

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

◆ get_src_field_buffer_pointers()

static double *** get_src_field_buffer_pointers ( int field_id,
size_t collection_size,
double * src_field_buffer )
static

Definition at line 3106 of file yac.c.

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

◆ get_src_field_buffer_pointers_ptr()

static double *** get_src_field_buffer_pointers_ptr ( int field_id,
size_t collection_size,
double ** src_field_buffer )
static

Definition at line 3137 of file yac.c.

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

◆ init_ext_couple_config()

static void init_ext_couple_config ( struct yac_ext_couple_config * ext_couple_config)
static

Definition at line 2122 of file yac.c.

Here is the caller graph for this function:

◆ set_cell_area_config_file()

void set_cell_area_config_file ( CellAreaConfig * cell_area_config,
char const * filename,
char const * varname,
int min_global_id,
char const * role )

Definition at line 6212 of file yac.c.

Here is the caller graph for this function:

◆ trace_coupling_start()

static int trace_coupling_start ( int field_id,
yac_pak_event_type_t type,
int put_idx,
int level )
static

Definition at line 339 of file yac.c.

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

◆ trace_coupling_stop()

static void trace_coupling_stop ( int field_id,
int h_pak_trace )
static

Stop a trace event started by trace_coupling_start.

Definition at line 383 of file yac.c.

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

◆ trace_setup_start()

static int trace_setup_start ( int yac_instance_id,
char const * caller,
yac_pak_event_type_t type )
static

Start a setup-phase trace event for the given instance.

Definition at line 392 of file yac.c.

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

◆ trace_setup_stop()

static void trace_setup_stop ( int yac_instance_id,
int h_pak_trace )
static

Stop a setup-phase trace event started by trace_setup_start.

Definition at line 402 of file yac.c.

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

◆ user_input_data_add_mask()

static int user_input_data_add_mask ( struct user_input_data_grid * grid_info,
enum yac_location location,
int const * is_valid,
size_t nbr_points,
char const * name )
static

Definition at line 1820 of file yac.c.

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

◆ user_input_data_add_points()

static int user_input_data_add_points ( struct user_input_data_grid * grid_info,
enum yac_location location,
yac_coordinate_pointer coordinates,
char const * name,
char const * caller )
static

Definition at line 1450 of file yac.c.

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

◆ user_input_data_get_or_create_comp()

static struct user_input_data_component * user_input_data_get_or_create_comp ( struct yac_instance * instance,
char const * name,
char const * caller,
int * comp_id )
static

finds an existing component entry matching the given instance and name, or creates a new preliminary entry if no match is found. The unique id for the returned entry is stored in *comp_id.

Definition at line 1244 of file yac.c.

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

◆ user_input_data_get_or_create_grid()

static struct user_input_data_grid * user_input_data_get_or_create_grid ( char const * grid_name,
char const * caller,
int * grid_id )
static

finds an existing grid entry with the given name, or creates a new preliminary entry if no match is found. The unique id for the returned entry is stored in *grid_id.

Definition at line 460 of file yac.c.

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

◆ user_input_data_get_or_create_masks()

static struct user_input_data_masks * user_input_data_get_or_create_masks ( struct user_input_data_grid * grid_info,
enum yac_location location,
char const * name,
char const * caller,
int * mask_id )
static

finds an existing mask entry matching the given grid, location, and name, or creates a new preliminary entry if no match is found. The unique id for the returned entry is stored in *mask_id.

Definition at line 1766 of file yac.c.

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

◆ user_input_data_get_or_create_points()

static struct user_input_data_points * user_input_data_get_or_create_points ( struct user_input_data_grid * grid_info,
enum yac_location location,
char const * name,
char const * caller,
int * point_id )
static

finds an existing point entry matching the given grid, location, and name, or creates a new preliminary entry if no match is found. The unique id for the returned entry is stored in *point_id.

Definition at line 1395 of file yac.c.

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

◆ yac_add_grid()

static int yac_add_grid ( const char * grid_name,
struct yac_basic_grid_data grid_data )
static

Adds a grid with the given name and data, and returns its unique id. An existing preliminary definition with the same name will be overwritten, while keeping the same unique id.

Definition at line 505 of file yac.c.

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

◆ yac_cadd_compute_weights_callback()

void yac_cadd_compute_weights_callback ( yac_func_compute_weights compute_weights_callback,
void * user_data,
char const * key )

registers a callback routine for the computation of weights by the interpolation method user_callback

Parameters
[in]compute_weights_callbackpointer to a weight computation routine
[in]user_datadata pointer that will be passed to compute_weights_callback
[in]keykey for identifying the callback routine
Remarks
the callback has to be set on all source processes taking part in respective coupling
the key has to match the one provided in coupling configuration

Definition at line 6685 of file yac.c.

Here is the call graph for this function:

◆ yac_cadd_interp_stack_config_average()

void yac_cadd_interp_stack_config_average ( int interp_stack_config_id,
int reduction_type,
int partial_coverage )

adds average interpolation to the bottom of an interpolation stack

Parameters
[in]interp_stack_config_idinterpolation stack
[in]reduction_typereduction type
[in]partial_coverageallow partial coverage

Definition at line 5959 of file yac.c.

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

◆ yac_cadd_interp_stack_config_check()

void yac_cadd_interp_stack_config_check ( int interp_stack_config_id,
char const * constructor_key,
char const * do_search_key )

adds fixed interpolation to the bottom of an interpolation stack

Parameters
[in]interp_stack_config_idinterpolation stack
[in]constructor_keykey provided to yac_interp_method_check_add_constructor_callback for a constructor callback routine
[in]do_search_keykey provided to yac_interp_method_check_add_do_search_callback for a do_search callback routine

Definition at line 6650 of file yac.c.

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

◆ yac_cadd_interp_stack_config_conservative()

void yac_cadd_interp_stack_config_conservative ( int interp_stack_config_id,
int order,
int enforced_conserv,
int partial_coverage,
int normalisation )

adds conservative interpolation to the bottom of an interpolation stack

Parameters
[in]interp_stack_config_idinterpolation stack
[in]orderfirst or second order
[in]enforced_conservenforce local conservation
[in]partial_coverageallow partial coverage
[in]normalisationnormalisation type

Definition at line 6056 of file yac.c.

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

◆ yac_cadd_interp_stack_config_creep()

void yac_cadd_interp_stack_config_creep ( int interp_stack_config_id,
int creep_distance )

adds creep interpolation to the bottom of an interpolation stack

Parameters
[in]interp_stack_config_idinterpolation stack
[in]creep_distancecreep distance

Definition at line 6662 of file yac.c.

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

◆ yac_cadd_interp_stack_config_dnn()

void yac_cadd_interp_stack_config_dnn ( int interp_stack_config_id,
int weight_type,
int search_distance_type,
double search_distance,
double scale )

adds distance-nearest-neighbour (DNN) interpolation to the bottom of a interpolation stack

Parameters
[in]interp_stack_config_idinterpolation stack
[in]weight_typeweight type (YAC_DNN_AVG, YAC_DNN_DIST, YAC_DNN_GAUSS, or YAC_DNN_RBF)
[in]search_distance_typemethod for determining search distance (YAC_DNN_SEARCH_DISTANCE_FIXED or YAC_DNN_SEARCH_DISTANCE_CELL_AREA)
[in]search_distancesearch distance in radians (if search_distance_type is YAC_DNN_SEARCH_DISTANCE_FIXED) or scale factor (if search_distance_type is YAC_DNN_SEARCH_DISTANCE_CELL_AREA)
[in]scalescale parameter for Gauss or RBF weighting
Remarks
When using YAC_DNN_SEARCH_DISTANCE_CELL_AREA, the target field location must be YAC_LOC_CELL

Definition at line 6017 of file yac.c.

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

◆ yac_cadd_interp_stack_config_fixed()

void yac_cadd_interp_stack_config_fixed ( int interp_stack_config_id,
double value )

adds fixed interpolation to the bottom of an interpolation stack

Parameters
[in]interp_stack_config_idinterpolation stack
[in]valuefixed value

Definition at line 6640 of file yac.c.

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

◆ yac_cadd_interp_stack_config_hcsbb()

void yac_cadd_interp_stack_config_hcsbb ( int interp_stack_config_id)

adds HCSBB interpolation to the bottom of an interpolation stack

Parameters
[in]interp_stack_config_idinterpolation stack

Definition at line 6596 of file yac.c.

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

◆ yac_cadd_interp_stack_config_ncc()

void yac_cadd_interp_stack_config_ncc ( int interp_stack_config_id,
int weight_type,
int partial_coverage )

adds nearest corner cells (NCC) interpolation to the bottom of a interpolation stack

Parameters
[in]interp_stack_config_idinterpolation stack
[in]weight_typereduction type
[in]partial_coverageallow partial coverage

Definition at line 5978 of file yac.c.

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

◆ yac_cadd_interp_stack_config_nnn()

void yac_cadd_interp_stack_config_nnn ( int interp_stack_config_id,
int type,
size_t n,
double max_search_distance,
double scale )

adds n-nearest-neighbour (NNN) interpolation to the bottom of a interpolation stack

Parameters
[in]interp_stack_config_idinterpolation stack
[in]typereduction type
[in]nnumber of nearest neighbour points
[in]max_search_distancemaximum search distance for each point
[in]scalescale parameter required by some reduction types
Remarks
a max_search_distance of 0.0 results in the search distance not being restricted

Definition at line 5996 of file yac.c.

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

◆ yac_cadd_interp_stack_config_rbf()

void yac_cadd_interp_stack_config_rbf ( int interp_stack_config_id,
size_t n,
double max_search_distance,
double scale )

adds rbf interpolation to the bottom of an interpolation stack

Parameters
[in]interp_stack_config_idinterpolation stack
[in]nnumber of nearest neighbour points
[in]max_search_distancemaximum search distance for each point
[in]scalescale parameter
Remarks
a max_search_distance of 0.0 results in the search distance not being restricted

Definition at line 6044 of file yac.c.

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

◆ yac_cadd_interp_stack_config_spmap()

void yac_cadd_interp_stack_config_spmap ( int interp_stack_config_id,
double spread_distance,
double max_search_distance,
int weight_type,
int scale_type,
double src_sphere_radius,
char const * src_filename,
char const * src_varname,
int src_min_global_id,
double tgt_sphere_radius,
char const * tgt_filename,
char const * tgt_varname,
int tgt_min_global_id )

adds source point mapping (SPMAP) interpolation to the bottom of an interpolation stack

Parameters
[in]interp_stack_config_idinterpolation stack
[in]spread_distancespread distance (in rad)
[in]max_search_distancemaximum search distance (in rad)
[in]weight_typereduction type
[in]scale_typescaling type
[in]src_sphere_radiussphere radius used for source cell area computation
[in]src_filenamenetCDF file contain the source cell areas
[in]src_varnamevariable name of source cell areas
[in]src_min_global_idminimum global id used to map global cell ids to values in the netCDF file
[in]tgt_sphere_radiussphere radius used for target cell area computation
[in]tgt_filenamenetCDF file contain the target cell areas
[in]tgt_varnamevariable name of target cell areas
[in]tgt_min_global_idminimum global id used to map global cell ids to values in the netCDF file
Remarks
cell areas for the scaling can either be computed by YAC or read from a netCDF file (see Source to Target mapping)
for computing cell areas:
(sphere_radius > 0.0; filename == NULL; varname == NULL)
for reading cell areas:
(sphere_radius == 0.0; filename != NULL; varname != NULL)

Definition at line 6363 of file yac.c.

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

◆ yac_cadd_interp_stack_config_spmap_ext()

void yac_cadd_interp_stack_config_spmap_ext ( int interp_stack_config_id,
int ext_spmap_config_id,
int * spmap_overwrite_config_ids,
int spmap_overwrite_config_count )

Adds source point mapping (SPMAP) interpolation with extended configuration options to the bottom of an interpolation stack

Parameters
[in]interp_stack_config_idinterpolation stack
[in]ext_spmap_config_idmain configuration
[in]spmap_overwrite_config_idsoverwrite configurations
[in]spmap_overwrite_config_countnumber of overwrite configurations
See also
Extended configuration

Definition at line 6467 of file yac.c.

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

◆ yac_cadd_interp_stack_config_spmap_f2c()

void yac_cadd_interp_stack_config_spmap_f2c ( int interp_stack_config_id,
double spread_distance,
double max_search_distance,
int weight_type,
int scale_type,
double src_sphere_radius,
char const * src_filename,
char const * src_varname,
int src_min_global_id,
double tgt_sphere_radius,
char const * tgt_filename,
char const * tgt_varname,
int tgt_min_global_id,
int * overwrite_config_ids,
int overwrite_config_count )

Definition at line 6518 of file yac.c.

Here is the call graph for this function:

◆ yac_cadd_interp_stack_config_user_callback()

void yac_cadd_interp_stack_config_user_callback ( int interp_stack_config_id,
char const * func_compute_weights_key )

adds user callback interpolation to the bottom of an interpolation stack

Parameters
[in]interp_stack_config_idinterpolation stack
[in]func_compute_weights_keykey provided to yac_cadd_compute_weights_callback for a compute_weights callback routine

Definition at line 6672 of file yac.c.

Here is the call graph for this function:

◆ yac_cadd_interp_stack_config_user_file()

void yac_cadd_interp_stack_config_user_file ( int interp_stack_config_id,
char const * filename )

adds user weight file interpolation to the bottom of an interpolation stack

Parameters
[in]interp_stack_config_idinterpolation stack
[in]filenameweight file name
Remarks
YAC will read the weight file in parallel. This parallel output can be configured as described here: Configuration of parallel IO in YAC

Definition at line 6631 of file yac.c.

Here is the call graph for this function:

◆ yac_cadd_interp_stack_config_user_file_2()

void yac_cadd_interp_stack_config_user_file_2 ( int interp_stack_config_id,
char const * filename,
int on_missing_file,
int on_success )

adds user weight file interpolation to the bottom of an interpolation stack

Parameters
[in]interp_stack_config_idinterpolation stack
[in]filenameweight file name
[in]on_missing_filespecifies how YAC should behave if no file was found
[in]on_successspecifies how YAC should behave in case a weight file was successfully read
Remarks
YAC will read the weight file in parallel. This parallel output can be configured as described here: Configuration of parallel IO in YAC

Definition at line 6605 of file yac.c.

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

◆ yac_ccheck_field_dimensions()

void yac_ccheck_field_dimensions ( int field_id,
int collection_size,
int num_pointsets,
int const * pointset_sizes )

Checks whether the field dimensions match with field definition and aborts if there is a mismatch

Parameters
[in]field_id
[in]collection_sizecollection size
[in]num_pointsetsnumber of pointsets
[in]pointset_sizessize of each pointset
Remarks
if num_pointsets is -1, its value will not be checked
if pointset_sizes is NULL, its values will not be checked

Definition at line 2635 of file yac.c.

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

◆ yac_ccheck_src_field_buffer_size()

void yac_ccheck_src_field_buffer_size ( int field_id,
int collection_size,
int src_field_buffer_size )

Checks whether the source field buffer size matches the one expected by YAC for this field and abort if there is a mismatch

Parameters
[in]field_id
[in]collection_sizecollection size
[in]src_field_buffer_sizesource buffer size (SUM(src_field_buffer_sizes(:)))

Definition at line 2696 of file yac.c.

Here is the call graph for this function:

◆ yac_ccheck_src_field_buffer_sizes()

void yac_ccheck_src_field_buffer_sizes ( int field_id,
int num_src_fields,
int collection_size,
int * src_field_buffer_sizes )

Checks whether the source field buffer sizes matches the one expected by YAC for this field and abort if there is a mismatch

Parameters
[in]field_id
[in]num_src_fieldsnumber of source fields
[in]collection_sizecollection size
[in]src_field_buffer_sizessource field buffer sizes

Definition at line 2734 of file yac.c.

Here is the call graph for this function:

◆ yac_ccleanup()

void yac_ccleanup ( )

Clean-up default YAC instance (see Restarting YAC)

Frees all memory associated with the default YAC instance.

Remarks
Call yac_cfinalize for freeing all memory allocated by YAC.

Definition at line 997 of file yac.c.

Here is the call graph for this function:

◆ yac_ccleanup_instance()

void yac_ccleanup_instance ( int yac_instance_id)

Clean-up a YAC instance (see Restarting YAC)

Frees all memory associated with the provided YAC instance.

Parameters
[in]yac_instance_idid of the YAC instance to be cleaned up
Remarks
Call yac_cfinalize for freeing all memory allocated by YAC.

Definition at line 989 of file yac.c.

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

◆ yac_ccleanup_instance_()

static void yac_ccleanup_instance_ ( int yac_instance_id)
static

Definition at line 969 of file yac.c.

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

◆ yac_ccompute_grid_cell_areas()

void yac_ccompute_grid_cell_areas ( int grid_id,
double * cell_areas )

computes the areas of all cells in a grid (an earth radius of 1.0 is assumed)

Parameters
[in]grid_id
[out]cell_areas

Definition at line 5899 of file yac.c.

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

◆ yac_cdef_calendar()

void yac_cdef_calendar ( int calendar)

Defines the calendar of the default instance

Parameters
[in]calendarThe calendar
See also
YAC_PROLEPTIC_GREGORIAN etc.

Definition at line 1063 of file yac.c.

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

◆ yac_cdef_comp()

void yac_cdef_comp ( const char * comp_name,
int * comp_id )

Elementary definition of the component for the default YAC instance

Parameters
[in]comp_namename of the component
[out]comp_idcomponent Id
Remarks
this call is collective for all processes that initialised the default YAC instance
components can only be defined once in the initialisation phase of a YAC instance. If you want to predefine a component, please use yac_cpredef_comp.
Examples
dummy_atmosphere_c.c, dummy_io_c.c, and dummy_ocean_c.c.

Definition at line 1383 of file yac.c.

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

◆ yac_cdef_comp_instance()

void yac_cdef_comp_instance ( int yac_instance_id,
const char * comp_name,
int * comp_id )

Elementary definition of the component.

Parameters
[in]yac_instance_idid of the YAC instance
[in]comp_namename of the component
[out]comp_idcomponent Id
Remarks
this call is collective for all processes that initialised the provided YAC instance
components can only be defined once in the initialisation phase of a YAC instance. If you want to predefine a component, please use yac_cpredef_comp_instance.

Definition at line 1377 of file yac.c.

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

◆ yac_cdef_component_metadata()

void yac_cdef_component_metadata ( const char * comp_name,
const char * metadata )

Define metadata for a component

Parameters
[in]comp_name
[in]metadata

Definition at line 2045 of file yac.c.

Here is the call graph for this function:

◆ yac_cdef_component_metadata_instance()

void yac_cdef_component_metadata_instance ( int yac_instance_id,
const char * comp_name,
const char * metadata )

Define metadata for a component

Parameters
[in]yac_instance_id
[in]comp_name
[in]metadata

Definition at line 2037 of file yac.c.

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

◆ yac_cdef_comps()

void yac_cdef_comps ( const char ** comp_names,
int num_comps,
int * comp_ids )

Elementary definition of the components for the default YAC instance

Parameters
[in]comp_namesnames of the components
[in]num_compsnumber of components
[out]comp_idscomponent Id's
Remarks
this call is collective for all processes that initialised the default YAC instance
components can only be defined once in the initialisation phase of a YAC instance

Definition at line 1369 of file yac.c.

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

◆ yac_cdef_comps_instance()

void yac_cdef_comps_instance ( int yac_instance_id,
const char ** comp_names,
int num_comps,
int * comp_ids )

Elementary definition of the components.

Parameters
[in]yac_instance_idid of the YAC instance
[in]comp_namesnames of the components
[in]num_compsnumber of components
[out]comp_idscomponent Id's
Remarks
this call is collective for all processes that initialised the provided YAC instance
components can only be defined once in the initialisation phase of a YAC instance

Definition at line 1326 of file yac.c.

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

◆ yac_cdef_couple()

void yac_cdef_couple ( char const * src_comp_name,
char const * src_grid_name,
char const * src_field_name,
char const * tgt_comp_name,
char const * tgt_grid_name,
char const * tgt_field_name,
char const * coupling_timestep,
int time_unit,
int time_reduction,
int interp_stack_config_id,
int src_lag,
int tgt_lag )

Define couple in the default YAC instance

Parameters
[in]src_comp_namecomponent name of the source component
[in]src_grid_namegrid name of the source grid
[in]src_field_namefield name of the source field
[in]tgt_comp_namecomponent name of the target component
[in]tgt_grid_namegrid name of the target grid
[in]tgt_field_namefield name of the target field
[in]coupling_timesteptime step for the coupling given in the defined timestep unit
[in]time_unitunit of coupling_timestep argument
[in]time_reductiontype for reducing multiple timesteps
See also
YAC_REDUCTION_TIME_NONE etc.
Parameters
[in]interp_stack_config_idid of the interpolation stack config to be used
[in]src_laglag for this couple on the source component
[in]tgt_laglag for this couple on the target component

Definition at line 2541 of file yac.c.

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

◆ yac_cdef_couple_()

void yac_cdef_couple_ ( char const * src_comp_name,
char const * src_grid_name,
char const * src_field_name,
char const * tgt_comp_name,
char const * tgt_grid_name,
char const * tgt_field_name,
char const * coupling_timestep,
int time_unit,
int time_reduction,
int interp_stack_config_id,
int src_lag,
int tgt_lag,
char const * weight_file,
int weight_file_on_existing,
int mapping_side,
double scale_factor,
double scale_summand,
int num_src_mask_names,
char const *const * src_mask_names,
char const * tgt_mask_name,
char const * yaxt_exchanger_name,
int collection_size,
int const * collection_indices,
int use_raw_exchange )

Definition at line 2611 of file yac.c.

Here is the call graph for this function:

◆ yac_cdef_couple_custom()

void yac_cdef_couple_custom ( char const * src_comp_name,
char const * src_grid_name,
char const * src_field_name,
char const * tgt_comp_name,
char const * tgt_grid_name,
char const * tgt_field_name,
char const * coupling_timestep,
int time_unit,
int time_reduction,
int interp_stack_config_id,
int src_lag,
int tgt_lag,
int ext_couple_config_id )

Define couple in the default YAC instance using an extended coupling configuration

Parameters
[in]src_comp_namecomponent name of the source component
[in]src_grid_namegrid name of the source grid
[in]src_field_namefield name of the source field
[in]tgt_comp_namecomponent name of the target component
[in]tgt_grid_namegrid name of the target grid
[in]tgt_field_namefield name of the target field
[in]coupling_timesteptime step for the coupling given in the defined timestep unit
[in]time_unitunit of coupling_timestep argument
[in]time_reductiontype for reducing multiple timesteps
See also
YAC_REDUCTION_TIME_NONE etc.
Parameters
[in]interp_stack_config_idid of the interpolation stack config to be used
[in]src_laglag for this couple on the source component
[in]tgt_laglag for this couple on the target component
[in]ext_couple_config_idextended coupling configuration

Definition at line 2509 of file yac.c.

Here is the call graph for this function:

◆ yac_cdef_couple_custom_instance()

void yac_cdef_couple_custom_instance ( int yac_instance_id,
char const * src_comp_name,
char const * src_grid_name,
char const * src_field_name,
char const * tgt_comp_name,
char const * tgt_grid_name,
char const * tgt_field_name,
char const * coupling_timestep,
int time_unit,
int time_reduction,
int interp_stack_config_id,
int src_lag,
int tgt_lag,
int ext_couple_config_id )

Define couple using an extended coupling configuration

Parameters
[in]yac_instance_idid of the YAC instance for that the couple should be defined
[in]src_comp_namecomponent name of the source component
[in]src_grid_namegrid name of the source grid
[in]src_field_namefield name of the source field
[in]tgt_comp_namecomponent name of the target component
[in]tgt_grid_namegrid name of the target grid
[in]tgt_field_namefield name of the target field
[in]coupling_timesteptime step for the coupling
[in]time_unitunit of coupling_timestep argument
[in]time_reductiontype for reducing multiple timesteps
See also
YAC_REDUCTION_TIME_NONE etc.
Parameters
[in]interp_stack_config_idid of the interpolation stack config to be used
[in]src_laglag for this couple on the source component
[in]tgt_laglag for this couple on the target component
[in]ext_couple_config_idextended coupling configuration

Definition at line 2494 of file yac.c.

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

◆ yac_cdef_couple_custom_instance_()

void yac_cdef_couple_custom_instance_ ( int yac_instance_id,
char const * src_comp_name,
char const * src_grid_name,
char const * src_field_name,
char const * tgt_comp_name,
char const * tgt_grid_name,
char const * tgt_field_name,
char const * coupling_timestep,
int time_unit,
int time_reduction,
int interp_stack_config_id,
int src_lag,
int tgt_lag,
struct yac_ext_couple_config * ext_couple_config )

Definition at line 2463 of file yac.c.

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

◆ yac_cdef_couple_instance()

void yac_cdef_couple_instance ( int yac_instance_id,
char const * src_comp_name,
char const * src_grid_name,
char const * src_field_name,
char const * tgt_comp_name,
char const * tgt_grid_name,
char const * tgt_field_name,
char const * coupling_timestep,
int time_unit,
int time_reduction,
int interp_stack_config_id,
int src_lag,
int tgt_lag )

Define couple

Parameters
[in]yac_instance_idid of the YAC instance for that the couple should be defined
[in]src_comp_namecomponent name of the source component
[in]src_grid_namegrid name of the source grid
[in]src_field_namefield name of the source field
[in]tgt_comp_namecomponent name of the target component
[in]tgt_grid_namegrid name of the target grid
[in]tgt_field_namefield name of the target field
[in]coupling_timesteptime step for the coupling
[in]time_unitunit of coupling_timestep argument
[in]time_reductiontype for reducing multiple timesteps
See also
YAC_REDUCTION_TIME_NONE etc.
Parameters
[in]interp_stack_config_idid of the interpolation stack config to be used
[in]src_laglag for this couple on the source component
[in]tgt_laglag for this couple on the target component

Definition at line 2524 of file yac.c.

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

◆ yac_cdef_couple_instance_()

void yac_cdef_couple_instance_ ( int yac_instance_id,
char const * src_comp_name,
char const * src_grid_name,
char const * src_field_name,
char const * tgt_comp_name,
char const * tgt_grid_name,
char const * tgt_field_name,
char const * coupling_timestep,
int time_unit,
int time_reduction,
int interp_stack_config_id,
int src_lag,
int tgt_lag,
char const * weight_file,
int weight_file_on_existing,
int mapping_side,
double scale_factor,
double scale_summand,
int num_src_mask_names,
char const *const * src_mask_names,
char const * tgt_mask_name,
char const * yaxt_exchanger_name,
int collection_size,
int const * collection_indices,
int use_raw_exchange )

Definition at line 2555 of file yac.c.

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

◆ yac_cdef_datetime()

void yac_cdef_datetime ( const char * start_datetime,
const char * end_datetime )

Definition of job start and end datetime for the default YAC instance

Parameters
[in]start_datetimecalendar job start datetime
[in]end_datetimecalendar job end datetime

Definition at line 1055 of file yac.c.

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

◆ yac_cdef_datetime_instance()

void yac_cdef_datetime_instance ( int yac_instance_id,
const char * start_datetime,
const char * end_datetime )

Definition of job start and end datetime

Parameters
[in]yac_instance_idid of the YAC instance
[in]start_datetimecalendar job start datetime
[in]end_datetimecalendar job end datetime

Definition at line 1046 of file yac.c.

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

◆ yac_cdef_field()

void yac_cdef_field ( char const * field_name,
int const component_id,
int const * point_ids,
int const num_pointsets,
int collection_size,
const char * timestep,
int time_unit,
int * field_id )

Definition of the coupling field (using default mask, if defined)

Parameters
[in]field_namecharacter string providing the name of the coupling field
[in]component_idcomponent ID
[in]point_idspoint IDs
[in]num_pointsetsnumber of pointsets per grid
[in]collection_sizecollection size
[in]timesteptimestep
[in]time_unittime unit
[out]field_idreturned field_id which has to be used to identify coupling fields in yac_cput and yac_cget.
Remarks
A calendar has to be defined before this routine is called. This can be done by a call to yac_cdef_calendar, by reading of configuration file that defines a calendar, or by synchronizing with other processes that already have defined a calendar using yac_csync_def.
Examples
dummy_atmosphere_c.c, dummy_io_c.c, and dummy_ocean_c.c.

Definition at line 1985 of file yac.c.

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

◆ yac_cdef_field_mask()

void yac_cdef_field_mask ( char const * field_name,
int const component_id,
int const * point_ids,
int const * mask_ids,
int const num_pointsets,
int collection_size,
const char * timestep,
int time_unit,
int * field_id )

Definition of the coupling field

Parameters
[in]field_namecharacter string providing the name of the coupling field
[in]component_idcomponent ID
[in]point_idspoint IDs
[in]mask_idsmask IDs
[in]num_pointsetsnumber of pointsets per grid
[in]collection_sizecollection size
[in]timesteptimestep
[in]time_unit
[out]field_idreturned field_id which has to be used to identify coupling fields in yac_cput and yac_cget.
Remarks
A calendar has to be defined before this routine is called. This can be done by a call to yac_cdef_calendar, by reading of configuration file that defines a calendar, or by synchronizing with other processes that already have defined a calendar using yac_csync_def.

Definition at line 1901 of file yac.c.

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

◆ yac_cdef_field_metadata()

void yac_cdef_field_metadata ( const char * comp_name,
const char * grid_name,
const char * field_name,
const char * metadata )

Define metadata for a field

Parameters
[in]comp_name
[in]grid_name
[in]field_name
[in]metadata

Definition at line 2073 of file yac.c.

Here is the call graph for this function:

◆ yac_cdef_field_metadata_instance()

void yac_cdef_field_metadata_instance ( int yac_instance_id,
const char * comp_name,
const char * grid_name,
const char * field_name,
const char * metadata )

Define metadata for a field

Parameters
[in]yac_instance_id
[in]comp_name
[in]grid_name
[in]field_name
[in]metadata

Definition at line 2064 of file yac.c.

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

◆ yac_cdef_grid_cloud()

void yac_cdef_grid_cloud ( const char * grid_name,
int nbr_points,
double * x_points,
double * y_points,
int * grid_id )

Definition of grid consisting of a cloud of points

Parameters
[in]grid_namename of the grid
[in]nbr_pointsnumber of points
[in]x_pointsarray of point longitudes, in radians
[in]y_pointsarray of point latitudes, in radians
[out]grid_idid of generated grid

Definition at line 5730 of file yac.c.

Here is the call graph for this function:

◆ yac_cdef_grid_curve2d()

void yac_cdef_grid_curve2d ( const char * grid_name,
int nbr_vertices[2],
int cyclic[2],
double * x_vertices,
double * y_vertices,
int * grid_id )

Definition of a 2d curvilinear grid

Parameters
[in]grid_namename of the grid
[in]nbr_vertices2d array containing the number of vertices in each dimension
[in]cyclic2d array containing information about cyclic behaviour in each dimension
[in]x_verticesarray of vertex longitudes, in radians
[in]y_verticesarray of vertex latitudes, in radians
[out]grid_idid of generated grid
Remarks
  • The array x_vertices and y_vertices are expected to be of size nbr_vertices[0] * nbr_vertices[1].
  • This call generate a grid with the following basic grid data:
    size_t internal_nbr_cells_2d[2];
    size_t internal_nbr_vertices_2d[2];
    if (cyclic[0]) {
    internal_nbr_cells_2d[0] = nbr_vertices[0];
    internal_nbr_cells_2d[1] = nbr_vertices[1] - 1;
    internal_nbr_vertices_2d[0] = nbr_vertices[0] + 1;
    internal_nbr_vertices_2d[1] = nbr_vertices[1];
    } else {
    internal_nbr_cells_2d[0] = nbr_vertices[0] - 1;
    internal_nbr_cells_2d[1] = nbr_vertices[1] - 1;
    internal_nbr_vertices_2d[0] = nbr_vertices[0];
    internal_nbr_vertices_2d[1] = nbr_vertices[1];
    }
    size_t internal_nbr_cells =
    internal_nbr_cells_2d[0] * internal_nbr_cells_2d[1];
    size_t internal_nbr_vertices =
    internal_nbr_vertices_2d[0] * internal_nbr_vertices_2d[1];
    size_t internal_nbr_edges =
    (internal_nbr_cells_2d[0] + 1) * internal_nbr_cells_2d[1] +
    internal_nbr_cells_2d[0] * (internal_nbr_cells_2d[1] + 1);
    double * internal_x_vertices =
    malloc(internal_nbr_vertices * sizeof(*internal_x_vertices));
    double * internal_y_vertices =
    malloc(internal_nbr_vertices * sizeof(*internal_y_vertices));
    for (size_t i = 0; i < internal_nbr_vertices; ++i) {
    internal_x_vertices[i] = x_vertices[i];
    internal_y_vertices[i] = y_vertices[i];
    }
    unsigned cyclic[2]
  • The edges of the grid follow great circles.
  • See Ordering of Edges

Definition at line 5626 of file yac.c.

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

◆ yac_cdef_grid_metadata()

void yac_cdef_grid_metadata ( const char * grid_name,
const char * metadata )

Define metadata for a grid for the default YAC instance

Parameters
[in]grid_name
[in]metadata

Definition at line 2059 of file yac.c.

Here is the call graph for this function:

◆ yac_cdef_grid_metadata_instance()

void yac_cdef_grid_metadata_instance ( int yac_instance_id,
const char * grid_name,
const char * metadata )

Define metadata for a grid

Parameters
[in]yac_instance_id
[in]grid_name
[in]metadata

Definition at line 2050 of file yac.c.

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

◆ yac_cdef_grid_reg2d()

void yac_cdef_grid_reg2d ( const char * grid_name,
int nbr_vertices[2],
int cyclic[2],
double * x_vertices,
double * y_vertices,
int * grid_id )

Definition of a 2d regular grid

Parameters
[in]grid_namename of the grid
[in]nbr_vertices2d array containing the number of vertices in each dimension
[in]cyclic2d array containing information about cyclic behaviour in each dimension
[in]x_verticesarray of vertex longitudes, in radians
[in]y_verticesarray of vertex latitudes, in radians
[out]grid_idid of generated grid
Remarks
  • This call generate a grid with the following basic grid data:
    size_t internal_nbr_cells_2d[2];
    size_t internal_nbr_vertices_2d[2];
    if (cyclic[0]) {
    internal_nbr_cells_2d[0] = nbr_vertices[0];
    internal_nbr_cells_2d[1] = nbr_vertices[1] - 1;
    internal_nbr_vertices_2d[0] = nbr_vertices[0];
    internal_nbr_vertices_2d[1] = nbr_vertices[1];
    } else {
    internal_nbr_cells_2d[0] = nbr_vertices[0] - 1;
    internal_nbr_cells_2d[1] = nbr_vertices[1] - 1;
    internal_nbr_vertices_2d[0] = nbr_vertices[0];
    internal_nbr_vertices_2d[1] = nbr_vertices[1];
    }
    size_t internal_nbr_cells =
    internal_nbr_cells_2d[0] * internal_nbr_cells_2d[1];
    size_t internal_nbr_vertices =
    internal_nbr_vertices_2d[0] * internal_nbr_vertices_2d[1];
    size_t internal_nbr_edges =
    internal_nbr_cells_2d[1] * internal_nbr_vertices_2d[0] +
    internal_nbr_cells_2d[0] * internal_nbr_vertices_2d[1];
    double * internal_x_vertices =
    malloc(internal_nbr_vertices * sizeof(*internal_x_vertices));
    double * internal_y_vertices =
    malloc(internal_nbr_vertices * sizeof(*internal_y_vertices));
    for (size_t i = 0, k = 0; i < nbr_vertices[1]; ++i) {
    for (size_t j = 0; j < nbr_vertices[0]; ++j, ++k) {
    internal_x_vertices[k] = x_vertices[j];
    internal_y_vertices[k] = y_vertices[i];
    }
    }
  • The edges of the grid either follow circles of longitude or latitude.
  • See Ordering of Edges

Definition at line 5608 of file yac.c.

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

◆ yac_cdef_grid_reg2d_rot()

void yac_cdef_grid_reg2d_rot ( const char * grid_name,
int nbr_vertices[2],
int cyclic[2],
double * x_vertices,
double * y_vertices,
double x_north_pole,
double y_north_pole,
int * grid_id )

Definition of a rotated 2d regular grid

Parameters
[in]grid_namename of the grid
[in]nbr_vertices2d array containing the number of vertices in each dimension
[in]cyclic2d array containing information about cyclic behaviour in each dimension
[in]x_verticesarray of vertex longitudes, in radians
[in]y_verticesarray of vertex latitudes, in radians
[in]x_north_polelongitude of the rotated north pole, in radians
[in]y_north_polelongitude of the rotated north pole, in radians
[out]grid_idid of generated grid
Remarks
  • This call generate a grid with the following basic grid data:
    size_t internal_nbr_cells_2d[2];
    size_t internal_nbr_vertices_2d[2];
    if (cyclic[0]) {
    internal_nbr_cells_2d[0] = nbr_vertices[0];
    internal_nbr_cells_2d[1] = nbr_vertices[1] - 1;
    internal_nbr_vertices_2d[0] = nbr_vertices[0];
    internal_nbr_vertices_2d[1] = nbr_vertices[1];
    } else {
    internal_nbr_cells_2d[0] = nbr_vertices[0] - 1;
    internal_nbr_cells_2d[1] = nbr_vertices[1] - 1;
    internal_nbr_vertices_2d[0] = nbr_vertices[0];
    internal_nbr_vertices_2d[1] = nbr_vertices[1];
    }
    size_t internal_nbr_cells =
    internal_nbr_cells_2d[0] * internal_nbr_cells_2d[1];
    size_t internal_nbr_vertices =
    internal_nbr_vertices_2d[0] * internal_nbr_vertices_2d[1];
    size_t internal_nbr_edges =
    internal_nbr_cells_2d[1] * internal_nbr_vertices_2d[0] +
    internal_nbr_cells_2d[0] * internal_nbr_vertices_2d[1];
    double * internal_x_vertices =
    malloc(internal_nbr_vertices * sizeof(*internal_x_vertices));
    double * internal_y_vertices =
    malloc(internal_nbr_vertices * sizeof(*internal_y_vertices));
    for (size_t i = 0, k = 0; i < nbr_vertices[1]; ++i) {
    for (size_t j = 0; j < nbr_vertices[0]; ++j, ++k) {
    double x_vertex_rot, y_vertex_rot;
    rotate(
    x_vertices[j], y_vertices[i], &x_vertex_rot, &y_vertex_rot);
    internal_x_vertices[k] = x_vertex_rot;
    internal_y_vertices[k] = y_vertex_rot;
    }
    }
  • The edges of the grid follow great circles.
  • See Ordering of Edges

Definition at line 5746 of file yac.c.

Here is the call graph for this function:

◆ yac_cdef_grid_unstruct()

void yac_cdef_grid_unstruct ( const char * grid_name,
int nbr_vertices,
int nbr_cells,
int * num_vertices_per_cell,
double * x_vertices,
double * y_vertices,
int * cell_to_vertex,
int * grid_id )

Definition of an unstructured grid

Parameters
[in]grid_namename of the grid
[in]nbr_verticesnumber of vertices
[in]nbr_cellsnumber of cells
[in]num_vertices_per_cellarray containing the number of vertices for each cell
[in]x_verticesarray of vertex longitudes, in radians
[in]y_verticesarray of vertex latitudes, in radians
[in]cell_to_vertexconnectivity of vertices belonging to cells
(the vertex indices per cell have to be in clockwise or counterclockwise ordering)
[out]grid_idid of generated grid
Remarks
Examples
dummy_atmosphere_c.c, dummy_io_c.c, and dummy_ocean_c.c.

Definition at line 5644 of file yac.c.

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

◆ yac_cdef_grid_unstruct_edge()

void yac_cdef_grid_unstruct_edge ( const char * grid_name,
int nbr_vertices,
int nbr_cells,
int nbr_edges,
int * num_edges_per_cell,
double * x_vertices,
double * y_vertices,
int * cell_to_edge,
int * edge_to_vertex,
int * grid_id )

Definition of an unstructured grid with explicit edge definition

Parameters
[in]grid_namename of the grid
[in]nbr_verticesnumber of vertices
[in]nbr_cellsnumber of cells
[in]nbr_edgesnumber of edges
[in]num_edges_per_cellarray containing the number of edges for each cell
[in]x_verticesarray of vertex longitudes, in radians
[in]y_verticesarray of vertex latitudes, in radians
[in]cell_to_edgeconnectivity of edges belonging to cells
(the edge indices per cell have to be in clockwise or counterclockwise ordering)
[in]edge_to_vertexconnectivity of vertices belonging to edges
[out]grid_idid of generated grid
Remarks
  • The edges of the grid follow great circles.

Definition at line 5686 of file yac.c.

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

◆ yac_cdef_grid_unstruct_edge_ll()

void yac_cdef_grid_unstruct_edge_ll ( const char * grid_name,
int nbr_vertices,
int nbr_cells,
int nbr_edges,
int * num_edges_per_cell,
double * x_vertices,
double * y_vertices,
int * cell_to_edge,
int * edge_to_vertex,
int * grid_id )

Definition of an unstructured grid with lon-lat edges with explicit edge definition

Parameters
[in]grid_namename of the grid
[in]nbr_verticesnumber of vertices
[in]nbr_cellsnumber of cells
[in]nbr_edgesnumber of edges
[in]num_edges_per_cellarray containing the number of edges for each cell
[in]x_verticesarray of vertex longitudes, in radians
[in]y_verticesarray of vertex latitudes, in radians
[in]cell_to_edgeconnectivity of edges belonging to cells
(the edge indices per cell have to be in clockwise or counterclockwise ordering)
[in]edge_to_vertexconnectivity of vertices belonging to edges
[out]grid_idid of generated grid
Remarks
YAC will check all edges of the grid and determine whether they are on circles of longitudes (same x coordinate) or latitudes (same y coordinate). An edge that does not fulfill this condition will cause an error.

Definition at line 5708 of file yac.c.

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

◆ yac_cdef_grid_unstruct_ll()

void yac_cdef_grid_unstruct_ll ( const char * grid_name,
int nbr_vertices,
int nbr_cells,
int * num_vertices_per_cell,
double * x_vertices,
double * y_vertices,
int * cell_to_vertex,
int * grid_id )

Definition of an unstructured grid with lon-lat edges

Parameters
[in]grid_namename of the grid
[in]nbr_verticesnumber of vertices
[in]nbr_cellsnumber of cells
[in]num_vertices_per_cellarray containing the number of vertices for each cell
[in]x_verticesarray of vertex longitudes, in radians
[in]y_verticesarray of vertex latitudes, in radians
[in]cell_to_vertexconnectivity of vertices belonging to cells
(the vertex indices per cell have to be in clockwise or counterclockwise ordering)
[out]grid_idid of generated grid
Remarks
See Ordering of Edges
YAC will check all edges of the grid and determine whether they are on circles of longitudes (same x coordinate) or latitudes (same y coordinate). An edge that does not fulfill this condition will cause an error.

Definition at line 5665 of file yac.c.

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

◆ yac_cdef_mask()

void yac_cdef_mask ( int const grid_id,
int const nbr_points,
int const location,
int const * is_valid,
int * mask_id )

define a mask for a grid

Parameters
[in]grid_idgrid ID
[in]nbr_pointsnumber of points
[in]locationcell/vertex/edge
[in]is_valid0 for points that are masked out, 1 for valid points
[out]mask_idreturned handle to the mask struct

Definition at line 1870 of file yac.c.

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

◆ yac_cdef_mask_named()

void yac_cdef_mask_named ( int const grid_id,
int const nbr_points,
int const location,
int const * is_valid,
char const * name,
int * mask_id )

define a named mask for a grid

Parameters
[in]grid_idgrid ID
[in]nbr_pointsnumber of points
[in]locationcell/vertex/edge
[in]is_valid0 for points that are masked out, 1 for valid points
[in]namename of the mask
[out]mask_idreturned handle to the mask struct

Definition at line 1847 of file yac.c.

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

◆ yac_cdef_points_curve2d()

void yac_cdef_points_curve2d ( int const grid_id,
int const * nbr_points,
int const location,
double const * x_points,
double const * y_points,
int * point_id )

Definition of a set of points for 2D curvilinear grids.

Parameters
[in]grid_idhandle to the grid struct
[in]nbr_pointsnumber of points
[in]locationlocation of points
[in]x_pointsarray of point longitudes, in radians
[in]y_pointsarray of point latitudes, in radians
[out]point_idreturned handle to the points struct
Remarks
  • This routine supports points defined on cells or vertices. For edges use yac_cdef_points_unstruct instead.
  • The array x_points and y_points are expected to be of size nbr_points[0] * nbr_points[1].
  • See yac_cdef_grid_curve2d on how the coordinates are being interpreted.

Definition at line 1638 of file yac.c.

Here is the call graph for this function:

◆ yac_cdef_points_curve2d_named()

void yac_cdef_points_curve2d_named ( int const grid_id,
int const * nbr_points,
int const location,
double const * x_points,
double const * y_points,
char const * name,
int * point_id )

Definition of a set of named points for 2D curvilinear grids.

Parameters
[in]grid_idhandle to the grid struct
[in]nbr_pointsnumber of points
[in]locationlocation of points
[in]x_pointsarray of point longitudes, in radians
[in]y_pointsarray of point latitudes, in radians
[in]namename of the points
[out]point_idreturned handle to the points struct
Remarks
  • This routine supports points defined on cells or vertices. For edges use yac_cdef_points_unstruct instead.
  • The array x_points and y_points are expected to be of size nbr_points[0] * nbr_points[1].
  • See yac_cdef_grid_curve2d on how the coordinates are being interpreted.

Definition at line 1596 of file yac.c.

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

◆ yac_cdef_points_reg2d()

void yac_cdef_points_reg2d ( int const grid_id,
int const * nbr_points,
int const location,
double const * x_points,
double const * y_points,
int * point_id )

Definition of a set of points for 2D regular grids.

Parameters
[in]grid_idhandle to the grid struct
[in]nbr_pointsnumber of points
[in]locationlocation of points
[in]x_pointsarray of point longitudes, in radians
[in]y_pointsarray of point latitudes, in radians
[out]point_idreturned handle to the points struct
Remarks
  • This routine supports points defined on cells or vertices. For edges use yac_cdef_points_unstruct instead.
  • The array x_points and y_points are expected to be of size nbr_points[0] and nbr_points[1] respectively.
  • See yac_cdef_grid_reg2d on how the coordinates are being interpreted.

Definition at line 1583 of file yac.c.

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

◆ yac_cdef_points_reg2d_named()

void yac_cdef_points_reg2d_named ( int const grid_id,
int const * nbr_points,
int const location,
double const * x_points,
double const * y_points,
char const * name,
int * point_id )

Definition of a set of named points for 2D regular grids.

Parameters
[in]grid_idhandle to the grid struct
[in]nbr_pointsnumber of points
[in]locationlocation of points
[in]x_pointsarray of point longitudes, in radians
[in]y_pointsarray of point latitudes, in radians
[in]namename of the points
[out]point_idreturned handle to the points struct
Remarks
  • This routine supports points defined on cells or vertices. For edges use yac_cdef_points_unstruct instead.
  • The array x_points and y_points are expected to be of size nbr_points[0] and nbr_points[1] respectively.
  • See yac_cdef_grid_reg2d on how the coordinates are being interpreted.

Definition at line 1541 of file yac.c.

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

◆ yac_cdef_points_reg2d_rot()

void yac_cdef_points_reg2d_rot ( int const grid_id,
int const * nbr_points,
int const location,
double const * x_points,
double const * y_points,
double x_north_pole,
double y_north_pole,
int * point_id )

Definition of a set of points for 2D regular rotated grid.

Parameters
[in]grid_idhandle to the grid struct
[in]nbr_pointsnumber of points
[in]locationlocation of points
[in]x_pointsarray of point longitudes, in radians
[in]y_pointsarray of point latitudes, in radians
[in]x_north_polelongitude of the north pole, in radians
[in]y_north_polelatitude of the north pole, in radians
[out]point_idreturned handle to the points struct
Remarks
  • This routine supports points defined on cells or vertices. For edges use yac_cdef_points_unstruct instead.
  • The array x_points and y_points are expected to be of size nbr_points[0] and nbr_points[1] respectively.
  • See yac_cdef_grid_reg2d_rot on how the coordinates are being interpreted.

Definition at line 1745 of file yac.c.

Here is the call graph for this function:

◆ yac_cdef_points_reg2d_rot_named()

void yac_cdef_points_reg2d_rot_named ( int const grid_id,
int const * nbr_points,
int const location,
double const * x_points,
double const * y_points,
double x_north_pole,
double y_north_pole,
char const * name,
int * point_id )

Definition of a set of named points for 2D regular rotated grid.

Parameters
[in]grid_idhandle to the grid struct
[in]nbr_pointsnumber of points
[in]locationlocation of points
[in]x_pointsarray of point longitudes, in radians
[in]y_pointsarray of point latitudes, in radians
[in]x_north_polelongitude of the north pole, in radians
[in]y_north_polelatitude of the north pole, in radians
[in]namename of the points
[out]point_idreturned handle to the points struct
Remarks
  • This routine supports points defined on cells or vertices. For edges use yac_cdef_points_unstruct instead.
  • The array x_points and y_points are expected to be of size nbr_points[0] and nbr_points[1] respectively.
  • See yac_cdef_grid_reg2d_rot on how the coordinates are being interpreted.

Definition at line 1696 of file yac.c.

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

◆ yac_cdef_points_unstruct()

void yac_cdef_points_unstruct ( int const grid_id,
int const nbr_points,
int const location,
double const * x_points,
double const * y_points,
int * point_id )

Definition of a set of points for 2D unstructured grids.

Parameters
[in]grid_idhandle to the grid struct
[in]nbr_pointsnumber of points
[in]locationlocation of points
[in]x_pointsarray of point longitudes, in radians
[in]y_pointsarray of point latitudes, in radians
[out]point_idreturned handle to the points struct
Remarks
The array x_points and y_points are expected to be of size nbr_points.
See also
yac_cdef_grid_unstruct
Examples
dummy_atmosphere_c.c, dummy_io_c.c, and dummy_ocean_c.c.

Definition at line 1683 of file yac.c.

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

◆ yac_cdef_points_unstruct_named()

void yac_cdef_points_unstruct_named ( int const grid_id,
int const nbr_points,
int const location,
double const * x_points,
double const * y_points,
char const * name,
int * point_id )

Definition of a set of named points for 2D unstructured grids.

Parameters
[in]grid_idhandle to the grid struct
[in]nbr_pointsnumber of points
[in]locationlocation of points
[in]x_pointsarray of point longitudes, in radians
[in]y_pointsarray of point latitudes, in radians
[in]namename of the points
[out]point_idreturned handle to the points struct
Remarks
The array x_points and y_points are expected to be of size nbr_points.
See also
yac_cdef_grid_unstruct

Definition at line 1651 of file yac.c.

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

◆ yac_cdefault_instance_defined()

int yac_cdefault_instance_defined ( void )

Check if the default instance is defined

Returns
1 if the default instance is defined,
0 otherwise

Definition at line 718 of file yac.c.

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

◆ yac_cenable_field_frac_mask()

void yac_cenable_field_frac_mask ( const char * comp_name,
const char * grid_name,
const char * field_name,
double frac_mask_fallback_value )

Enables fractional masking for a coupling field and sets the fallback value

Parameters
[in]comp_name
[in]grid_name
[in]field_name
[in]frac_mask_fallback_valuefractional mask fallback value
Remarks
If this field is used as a source in couple, the user will have to provide a fractional mask for all source points along with the source field values in all put/exchange operations of this field. (see Dynamic fractional masking)

Definition at line 2028 of file yac.c.

Here is the call graph for this function:

◆ yac_cenable_field_frac_mask_instance()

void yac_cenable_field_frac_mask_instance ( int yac_instance_id,
const char * comp_name,
const char * grid_name,
const char * field_name,
double frac_mask_fallback_value )

Enables fractional masking for a coupling field and sets the fallback value

Parameters
[in]yac_instance_id
[in]comp_name
[in]grid_name
[in]field_name
[in]frac_mask_fallback_valuefractional mask fallback value
Remarks
If this field is used as a source in couple, the user will have to provide a fractional mask for all source points along with the source field values in all put/exchange operations of this field. (see Dynamic fractional masking)

Definition at line 2016 of file yac.c.

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

◆ yac_cenddef()

void yac_cenddef ( void )

End of the definition phase for the default YAC instance and setup of internal data structures for coupling (communication matrices and interpolation weights)

Examples
dummy_atmosphere_c.c, dummy_io_c.c, and dummy_ocean_c.c.

Definition at line 5091 of file yac.c.

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

◆ yac_cenddef_and_emit_config()

void yac_cenddef_and_emit_config ( int emit_flags,
char ** config )

End of the definition phase for the default YAC instance, invocation of the search and setup of internal data structures for coupling (communication matrices and interpolation weights). In addition, the collected coupling configuration from all processes is emitted.

Parameters
[in]emit_flagsflags for configuring the generated coupling configuration output (YAC_YAML_EMITTER_DEFAULT or YAC_YAML_EMITTER_JSON)
[out]configcoupling configuration
Remarks
the user is responsible for freeing the returned coupling configuration

Definition at line 5121 of file yac.c.

Here is the call graph for this function:

◆ yac_cenddef_and_emit_config_instance()

void yac_cenddef_and_emit_config_instance ( int yac_instance_id,
int emit_flags,
char ** config )

End of the definition phase, invocation of the search and setup of internal data structures for coupling (communication matrices and interpolation weights). In addition, the collected coupling configuration from all processes is emitted.

Parameters
[in]yac_instance_idid of the YAC instance
[in]emit_flagsflags for configuring the generated coupling configuration output (YAC_YAML_EMITTER_DEFAULT or YAC_YAML_EMITTER_JSON)
[out]configcoupling configuration
Remarks
the user is responsible for freeing the returned coupling configuration

Definition at line 5097 of file yac.c.

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

◆ yac_cenddef_instance()

void yac_cenddef_instance ( int yac_instance_id)

End of the definition phase, invocation of the search and setup of internal data structures for coupling (communication matrices and interpolation weights)

Parameters
[in]yac_instance_idid of the YAC instance

Definition at line 5065 of file yac.c.

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

◆ yac_cexchange()

void yac_cexchange ( int const send_field_id,
int const recv_field_id,
int const collection_size,
double ***const send_field,
double ** recv_field,
int * send_info,
int * recv_info,
int * ierror )

Exchange of the coupling fields

Parameters
[in]send_field_id-
[in]recv_field_id-
[in]collection_size-
[in]send_field- send buffer dimensions send_field[collection_size] [nbr_pointsets] [nbr_points]
[in]recv_field- receive buffer dimensions: recv_field[collection_size][nbr_points]
[out]send_info- returned send info
[out]recv_info- returned recv info
[out]ierror- returned error

Definition at line 4957 of file yac.c.

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

◆ yac_cexchange_()

void yac_cexchange_ ( int const send_field_id,
int const recv_field_id,
int const collection_size,
double * send_field,
double * recv_field,
int * send_info,
int * recv_info,
int * ierror )

Exchange of the coupling fields

Parameters
[in]send_field_id-
[in]recv_field_id-
[in]collection_size-
[in]send_field- send buffer (all data is stored in one contiguous part of the memory) dimensions send_field[collection_size] [nbr_pointsets] [nbr_points]
[in]recv_field- receive buffer (all data is stored in one contiguous part of the memory) dimensions: recv_field[collection_size][nbr_points]
[out]send_info- returned send info
[out]recv_info- returned recv info
[out]ierror- returned error

Definition at line 4347 of file yac.c.

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

◆ yac_cexchange_frac()

void yac_cexchange_frac ( int const send_field_id,
int const recv_field_id,
int const collection_size,
double ***const send_field,
double ***const send_frac_mask,
double ** recv_field,
int * send_info,
int * recv_info,
int * ierror )

Exchange of the coupling fields

Parameters
[in]send_field_id-
[in]recv_field_id-
[in]collection_size-
[in]send_field- send buffer dimensions send_field[collection_size] [nbr_pointsets] [nbr_points]
[in]send_frac_mask- send fractional mask dimensions send_frac_mask[collection_size] [nbr_pointsets] [nbr_points]
[in]recv_field- receive buffer dimensions: recv_field[collection_size][nbr_points]
[out]send_info- returned send info
[out]recv_info- returned recv info
[out]ierror- returned error

Definition at line 4645 of file yac.c.

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

◆ yac_cexchange_frac_()

void yac_cexchange_frac_ ( int const send_field_id,
int const recv_field_id,
int const collection_size,
double * send_field,
double * send_frac_mask,
double * recv_field,
int * send_info,
int * recv_info,
int * ierror )

Exchange of the coupling fields

Parameters
[in]send_field_id-
[in]recv_field_id-
[in]collection_size-
[in]send_field- send buffer (all data is stored in one contiguous part of the memory) dimensions send_field[collection_size] [nbr_pointsets] [nbr_points]
[in]send_frac_mask- send fractional mask (all data is stored in one contiguous part of the memory) dimensions send_frac_mask[collection_size] [nbr_pointsets] [nbr_points]
[in]recv_field- receive buffer (all data is stored in one contiguous part of the memory) dimensions: recv_field[collection_size][nbr_points]
[out]send_info- returned send info
[out]recv_info- returned recv info
[out]ierror- returned error

Definition at line 4458 of file yac.c.

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

◆ yac_cexchange_frac_ptr_()

void yac_cexchange_frac_ptr_ ( int const send_field_id,
int const recv_field_id,
int const collection_size,
double ** send_field,
double ** send_frac_mask,
double ** recv_field,
int * send_info,
int * recv_info,
int * ierror )

Sending of the coupling fields

Parameters
[in]send_field_id
[in]recv_field_id
[in]collection_size
[in]send_fieldsend buffer dimensions send_field[collection_size * nbr_pointsets] [nbr_points]
[in]send_frac_masksend buffer dimensions send_frac_mask[collection_size * nbr_pointsets] [nbr_points]
[in]recv_fieldreceive buffer dimensions: recv_field[collection_size] [nbr_points]
[out]send_inforeturned send info
[out]recv_inforeturned recv info
[out]ierrorreturned error

Definition at line 4562 of file yac.c.

Here is the call graph for this function:

◆ yac_cexchange_ptr_()

void yac_cexchange_ptr_ ( int const send_field_id,
int const recv_field_id,
int const collection_size,
double ** send_field,
double ** recv_field,
int * send_info,
int * recv_info,
int * ierror )

Sending of the coupling fields

Parameters
[in]send_field_id-
[in]recv_field_id-
[in]collection_size-
[in]send_field- send buffer dimensions send_field[collection_size * nbr_pointsets] [nbr_points]
[in]recv_field- receive buffer dimensions: recv_field[collection_size] [nbr_points]
[out]send_info- returned send info
[out]recv_info- returned recv info
[out]ierror- returned error

Definition at line 4497 of file yac.c.

Here is the call graph for this function:

◆ yac_cexchange_raw()

void yac_cexchange_raw ( int const send_field_id,
int const recv_field_id,
int const collection_size,
double ***const send_field,
double *** src_field_buffer,
int * send_info,
int * recv_info,
int * ierror )

Exchange of the source points required for the interpolation of the local target field

Parameters
[in]send_field_id
[in]recv_field_id
[in]collection_size
[in]send_fieldsend buffer (all data is stored in one contiguous part of the memory) dimensions send_field[collection_size] [nbr_pointsets] [nbr_points]
[in]src_field_buffersource field buffer (dimensions: src_field_buffer [collection_size] [nbr_pointsets] [src_field_buffer_sizes[pointset_idx]])
[out]send_inforeturned send info
[out]recv_inforeturned recv info
[out]ierrorreturned error

Definition at line 4972 of file yac.c.

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

◆ yac_cexchange_raw_()

void yac_cexchange_raw_ ( int const send_field_id,
int const recv_field_id,
int const collection_size,
double * send_field,
double * src_field_buffer,
int * send_info,
int * recv_info,
int * ierror )

Exchange of the source points required for the interpolation of the local target field

Parameters
[in]send_field_id
[in]recv_field_id
[in]collection_size
[in]send_fieldsend buffer (all data is stored in one contiguous part of the memory) dimensions send_field[collection_size] [nbr_pointsets] [nbr_points]
[in]src_field_buffersource field buffer (dimensions: src_field_buffer [collection_size] [nbr_pointsets] [src_field_buffer_sizes[pointset_idx]])
[out]send_inforeturned send info
[out]recv_inforeturned recv info
[out]ierrorreturned error

Definition at line 4437 of file yac.c.

Here is the call graph for this function:

◆ yac_cexchange_raw_frac()

void yac_cexchange_raw_frac ( int const send_field_id,
int const recv_field_id,
int const collection_size,
double ***const send_field,
double ***const send_frac_mask,
double *** src_field_buffer,
double *** src_frac_mask_buffer,
int * send_info,
int * recv_info,
int * ierror )

Exchange of the source points required for the interpolation of the local target field

Parameters
[in]send_field_id
[in]recv_field_id
[in]collection_size
[in]send_fieldsend buffer dimensions send_field[collection_size] [nbr_pointsets] [nbr_points]
[in]send_frac_masksend fractional mask dimensions send_frac_mask[collection_size] [nbr_pointsets] [nbr_points]
[in]src_field_buffersource field buffer (dimensions: src_field_buffer [collection_size] [nbr_pointsets] [src_field_buffer_sizes[pointset_idx]])
[in]src_frac_mask_buffersource fractional mask buffer (dimensions: src_frac_mask_buffer [collection_size] [nbr_pointsets] [src_field_buffer_sizes[pointset_idx]])
[out]send_inforeturned send info
[out]recv_inforeturned recv info
[out]ierrorreturned error
Remarks
source field values in the src_field_buffer have already been weighted, by the fractional mask

Definition at line 4761 of file yac.c.

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

◆ yac_cexchange_raw_frac_()

void yac_cexchange_raw_frac_ ( int const send_field_id,
int const recv_field_id,
int const collection_size,
double * send_field,
double * send_frac_mask,
double * src_field_buffer,
double * src_frac_mask_buffer,
int * send_info,
int * recv_info,
int * ierror )

Exchange of the source points required for the interpolation of the local target field

Parameters
[in]send_field_id
[in]recv_field_id
[in]collection_size
[in]send_fieldsend buffer (all data is stored in one contiguous part of the memory) dimensions send_field[collection_size] [nbr_pointsets] [nbr_points]
[in]send_frac_masksend fractional mask (all data is stored in one contiguous part of the memory) dimensions send_frac_mask[collection_size] [nbr_pointsets] [nbr_points]
[in]src_field_buffersource field buffer (all data is stored in one contiguous part of the memory) (dimensions: src_field_buffer [collection_size] [nbr_pointsets] [src_field_buffer_sizes[pointset_idx]])
[in]src_frac_mask_buffersource fractional mask buffer (all data is stored in one contiguous part of the memory) (dimensions: src_field_buffer [collection_size] [nbr_pointsets] [src_field_buffer_sizes[pointset_idx]])
[out]send_inforeturned send info
[out]recv_inforeturned recv info
[out]ierrorreturned error
Remarks
source field values in the src_field_buffer have already been weighted, by the fractional mask

Definition at line 4379 of file yac.c.

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

◆ yac_cexchange_raw_frac_ptr_()

void yac_cexchange_raw_frac_ptr_ ( int const send_field_id,
int const recv_field_id,
int const collection_size,
double ** send_field,
double ** send_frac_mask,
double ** src_field_buffer,
double ** src_frac_mask_buffer,
int * send_info,
int * recv_info,
int * ierror )

Sending of the coupling fields

Parameters
[in]send_field_id
[in]recv_field_id
[in]collection_size
[in]send_fieldsend buffer dimensions send_field[collection_size * nbr_pointsets] [nbr_points]
[in]send_frac_masksend buffer dimensions send_frac_mask[collection_size * nbr_pointsets] [nbr_points]
[in]src_field_buffersource field buffer (all data is stored in one contiguous part of the memory) (dimensions: src_field_buffer [collection_size * nbr_pointsets] [src_field_buffer_sizes[pointset_idx]])
[in]src_frac_mask_buffersource fractional mask buffer (all data is stored in one contiguous part of the memory) (dimensions: src_field_buffer [collection_size * nbr_pointsets] [src_field_buffer_sizes[pointset_idx]])
[out]send_inforeturned send info
[out]recv_inforeturned recv info
[out]ierrorreturned error

Definition at line 4595 of file yac.c.

Here is the call graph for this function:

◆ yac_cexchange_raw_ptr_()

void yac_cexchange_raw_ptr_ ( int const send_field_id,
int const recv_field_id,
int const collection_size,
double ** send_field,
double ** src_field_buffer,
int * send_info,
int * recv_info,
int * ierror )

Sending of the coupling fields

Parameters
[in]send_field_id
[in]recv_field_id
[in]collection_size
[in]send_fieldsend buffer dimensions send_field[collection_size * nbr_pointsets] [nbr_points]
[in]src_field_buffersource field buffer (all data is stored in one contiguous part of the memory) (dimensions: src_field_buffer [collection_size * nbr_pointsets] [src_field_buffer_sizes[pointset_idx]])
[out]send_inforeturned send info
[out]recv_inforeturned recv info
[out]ierrorreturned error

Definition at line 4525 of file yac.c.

Here is the call graph for this function:

◆ yac_cfinalize()

void yac_cfinalize ( )

Finalises YAC.

First cleans up the default YAC instance, if it was initialised and not yet cleaned up by a call to yac_ccleanup. If there are no remaining YAC instances, MPI and yaxt will be finalised (if initialised by YAC) and instance independed memory allocated by YAC will be freed.

Examples
dummy_atmosphere_c.c, dummy_io_c.c, and dummy_ocean_c.c.

Definition at line 1030 of file yac.c.

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

◆ yac_cfinalize_instance()

void yac_cfinalize_instance ( int yac_instance_id)

Finalises YAC.

First cleans up the provided YAC instance, if it was initialised and not yet cleaned up by a call to yac_ccleanup_instance. If there are no remaining YAC instances, MPI and yaxt will be finalised (if initialised by YAC) and instance independed memory allocated by YAC will be freed.

Parameters
[in]yac_instance_idid of the YAC instance to be finalised

Definition at line 1018 of file yac.c.

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

◆ yac_cfree_ext_couple_config()

void yac_cfree_ext_couple_config ( int ext_couple_config_id)

Frees an extended coupling configuration

Parameters
[in]ext_couple_config_id

Definition at line 2159 of file yac.c.

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

◆ yac_cfree_ext_couple_config_()

static void yac_cfree_ext_couple_config_ ( struct yac_ext_couple_config ext_couple_config)
static

Definition at line 2146 of file yac.c.

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

◆ yac_cfree_ext_spmap_config()

void yac_cfree_ext_spmap_config ( int ext_spmap_config_id)

Frees an extended source point mapping interpolation configuration

Parameters
[in]ext_spmap_config_id
See also
Extended configuration

Definition at line 6101 of file yac.c.

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

◆ yac_cfree_interp_stack_config()

void yac_cfree_interp_stack_config ( int interp_stack_config_id)

frees a stack trace

Parameters
[in]interp_stack_config_idinterpolation stack

Definition at line 5938 of file yac.c.

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

◆ yac_cfree_spmap_overwrite_config()

void yac_cfree_spmap_overwrite_config ( int spmap_overwrite_config_id)

Frees an source point mapping interpolation overwrite configuration

Parameters
[in]spmap_overwrite_config_idsource point mapping interpolation overwrite configuration
See also
Extended configuration

Definition at line 6299 of file yac.c.

Here is the call graph for this function:

◆ yac_cget()

void yac_cget ( int const field_id,
int const collection_size,
double ** recv_field,
int * info,
int * ierror )

Receiving of the coupling fields

Parameters
[in]field_id-
[in]collection_size-
[in]recv_field- receive buffer dimensions: recv_field[collection_size][nbr_points]
[out]info- returned info argument indicating the action performed
[out]ierror- returned error
Examples
dummy_atmosphere_c.c, and dummy_ocean_c.c.

Definition at line 3364 of file yac.c.

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

◆ yac_cget_()

void yac_cget_ ( int const field_id,
int const collection_size,
double * recv_field,
int * info,
int * ierror )

Receiving of the coupling fields

Parameters
[in]field_id-
[in]collection_size-
[in]recv_field- receive buffer (all data is stored in one contiguous part of the memory) dimensions: recv_field[collection_size][nbr_points]
[in]info- returned info argument indicating the action performed
[out]ierror- returned error

Definition at line 3342 of file yac.c.

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

◆ yac_cget_action()

void yac_cget_action ( int field_id,
int * action )

Returns the action a put/get would return for the current timestep

Parameters
[in]field_idfield id returned by yac_cdef_field
[out]actionaction for the current timestep (YAC_ACTION_NONE, YAC_ACTION_REDUCTION, YAC_ACTION_COUPLING, YAC_ACTION_GET_FOR_RESTART, YAC_ACTION_PUT_FOR_RESTART, or YAC_ACTION_OUT_OF_BOUND)
Remarks
If the exchange type of the field is YAC_EXCHANGE_TYPE_NONE, this routine will return YAC_ACTION_NONE.
If this routine is called before yac_cenddef, the behaviour is undefined.

Definition at line 2970 of file yac.c.

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

◆ yac_cget_async()

void yac_cget_async ( int const field_id,
int const collection_size,
double ** recv_field,
int * info,
int * ierror )

Receiving of the coupling fields

Parameters
[in]field_id-
[in]collection_size-
[in]recv_field- receive buffer dimensions: recv_field[collection_size][nbr_points]
[out]info- returned info argument indicating the action performed
[out]ierror- returned error
Remarks
This routine returns immediately without waiting for the receive operation to be completed. The user should not access the memory associated with recv_field until this is the case. This can be achieved by calling yac_cwait.

Definition at line 3375 of file yac.c.

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

◆ yac_cget_async_()

void yac_cget_async_ ( int const field_id,
int const collection_size,
double * recv_field,
int * info,
int * ierror )

Receiving of the coupling fields

Parameters
[in]field_id-
[in]collection_size-
[in]recv_field- receive buffer (all data is stored in one contiguous part of the memory) dimensions: recv_field[collection_size][nbr_points]
[in]info- returned info argument indicating the action performed
[out]ierror- returned error
Remarks
This routine returns immediately without waiting for the receive operation to be completed. The user should not access the memory associated with recv_field until this is the case. This can be achieved by calling yac_cwait.

Definition at line 3353 of file yac.c.

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

◆ yac_cget_calendar()

int yac_cget_calendar ( )

Gets the calendar of the default instance

Definition at line 1068 of file yac.c.

Here is the caller graph for this function:

◆ yac_cget_collection_size_from_field_id()

int yac_cget_collection_size_from_field_id ( int field_id)

query routine to get the collection_size of a field for a given ID

Parameters
[in]field_idID as provided by yac_cdef_field
Returns
collection_size

Definition at line 5480 of file yac.c.

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

◆ yac_cget_comp_comm()

void yac_cget_comp_comm ( int comp_id,
MPI_Comm * comp_comm )

Providing the component MPI communicator

Parameters
[in]comp_idlocal component ID (from yac_cdef_comp), handle to the component struct
[out]comp_commcomponent communicator
Remarks
The user is responsible for free the MPI communicator returned by this routine.
Examples
dummy_atmosphere_c.c, dummy_io_c.c, and dummy_ocean_c.c.

Definition at line 1159 of file yac.c.

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

◆ yac_cget_comp_grid_names()

void yac_cget_comp_grid_names ( const char * comp_name,
int nbr_grids,
const char ** grid_names )

query routine to get the list of grid names of a given component that are referenced by at least one defined field or have metadata assigned to it

Parameters
[in]comp_namename of the component
[in]nbr_gridsnumber of grids
[out]grid_nameslist of grid names

Definition at line 5398 of file yac.c.

Here is the call graph for this function:

◆ yac_cget_comp_grid_names_instance()

void yac_cget_comp_grid_names_instance ( int yac_instance_id,
const char * comp_name,
int nbr_grids,
const char ** grid_names )

query routine to get the list of grid names of a given component that are referenced by at least one defined field or have metadata assigned to it

Parameters
[in]yac_instance_idid of the YAC instance
[in]comp_namename of the component
[in]nbr_gridsnumber of grids
[out]grid_nameslist of grid names

Definition at line 5356 of file yac.c.

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

◆ yac_cget_comp_id()

int yac_cget_comp_id ( const char * comp_name)

query routine to get the component id from the component name

Parameters
[in]comp_namecomponent name
Returns
component id
Remarks
If no matching component has already been defined, a preliminary one will be created.
A later definition of the component will return the same id.
All preliminary components have to be defined before yac_cenddef / yac_cenddef_instance is called, otherwise an error will be raised.

Definition at line 5145 of file yac.c.

Here is the call graph for this function:

◆ yac_cget_comp_id_instance()

int yac_cget_comp_id_instance ( int yac_instance_id,
const char * comp_name )

query routine to get the component id from the component name

Parameters
[in]yac_instance_id
[in]comp_namecomponent name
Returns
component id
Remarks
If no matching component has already been defined, a preliminary one will be created.
A later definition of the component will return the same id.
All preliminary components have to be defined before yac_cenddef / yac_cenddef_instance is called, otherwise an error will be raised.

Definition at line 5132 of file yac.c.

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

◆ yac_cget_comp_names()

void yac_cget_comp_names ( int nbr_comps,
const char ** comp_names )

query routine to get the list of component names for defined the default YAC instance.

Parameters
[in]nbr_compsnumber of components
[out]comp_nameslist of component names

Definition at line 5325 of file yac.c.

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

◆ yac_cget_comp_names_instance()

void yac_cget_comp_names_instance ( int yac_instance_id,
int nbr_comps,
const char ** comp_names )

query routine to get the list of component names for defined

Parameters
[in]yac_instance_idid of the YAC instance
[in]nbr_compsnumber of components
[out]comp_nameslist of component names

Definition at line 5305 of file yac.c.

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

◆ yac_cget_comp_nbr_grids()

int yac_cget_comp_nbr_grids ( const char * comp_name)

query routine for number of grids defined in the default YAC instance for a given components that is referenced by at least one defined field.

Parameters
[in]comp_name
Returns
number of components

Definition at line 5275 of file yac.c.

Here is the call graph for this function:

◆ yac_cget_comp_nbr_grids_instance()

int yac_cget_comp_nbr_grids_instance ( int yac_instance_id,
const char * comp_name )

query routine for number of grids defined for a given components that is referenced by at least one defined field.

Parameters
[in]yac_instance_idid of the YAC instance
[in]comp_name
Returns
number of components

Definition at line 5252 of file yac.c.

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

◆ yac_cget_comp_rank_c2py()

void yac_cget_comp_rank_c2py ( int comp_id,
int * rank )

Definition at line 1188 of file yac.c.

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

◆ yac_cget_comp_size_c2py()

void yac_cget_comp_size_c2py ( int comp_id,
int * size )

Definition at line 1181 of file yac.c.

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

◆ yac_cget_component_metadata()

const char * yac_cget_component_metadata ( const char * comp_name)

Get metadata for a component

Parameters
[in]comp_name
Returns
metadata (NULL if no metadata is defined)

Definition at line 2088 of file yac.c.

Here is the call graph for this function:

◆ yac_cget_component_metadata_instance()

const char * yac_cget_component_metadata_instance ( int yac_instance_id,
const char * comp_name )

Get metadata for a component

Parameters
[in]yac_instance_id
[in]comp_name
Returns
metadata (NULL if no metadata is defined)

Definition at line 2080 of file yac.c.

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

◆ yac_cget_component_name_from_field_id()

const char * yac_cget_component_name_from_field_id ( int field_id)

query routine to get the component name for a given ID

Parameters
[in]field_idID as provided by yac_cdef_field
Returns
comp_name component name of the fields component. (array of length YAC_MAX_CHARLEN)

Definition at line 5451 of file yac.c.

Here is the call graph for this function:

◆ yac_cget_comps_comm()

void yac_cget_comps_comm ( const char ** comp_names,
int num_comps,
MPI_Comm * comps_comm )

Generates an MPI communicator that contains all processes of the provided components

Parameters
[in]comp_namesname of components
[in]num_compsnumber of components
[out]comps_commgenerated communicator
Remarks
the components have to defined in the default YAC instance
the local process has to be in at least one of the provided components
this call is collective for all processes in the provided components
The user is responsible for free the MPI communicator returned by this routine.

Definition at line 1209 of file yac.c.

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

◆ yac_cget_comps_comm_f2c()

void yac_cget_comps_comm_f2c ( char const ** comp_names,
int num_comps,
MPI_Fint * comps_comm_f )

Definition at line 1229 of file yac.c.

Here is the call graph for this function:

◆ yac_cget_comps_comm_instance()

void yac_cget_comps_comm_instance ( int yac_instance_id,
const char ** comp_names,
int num_comps,
MPI_Comm * comps_comm )

Generates an MPI communicator that contains all processes of the provided components

Parameters
[in]yac_instance_idid of the YAC instance
[in]comp_namesname of components
[in]num_compsnumber of components
[out]comps_commgenerated communicator
Remarks
the local process has to be in at least one of the provided components
this call is collective for all processes in the provided components
The user is responsible for free the MPI communicator returned by this routine.

Definition at line 1199 of file yac.c.

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

◆ yac_cget_comps_comm_instance_f2c()

void yac_cget_comps_comm_instance_f2c ( int yac_instance_id,
char const ** comp_names,
int num_comps,
MPI_Fint * comps_comm_f )

Definition at line 1219 of file yac.c.

Here is the call graph for this function:

◆ yac_cget_default_instance_id()

int yac_cget_default_instance_id ( )

Getter function for the default instance

Returns the instance id of the default instance.

Remarks
The default instance needs to be initialised before calling this function.
Returns
The instance id of the default instance

Definition at line 713 of file yac.c.

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

◆ yac_cget_end_datetime()

char * yac_cget_end_datetime ( void )

query routine for the end datetime of the job of the default YAC instance

Definition at line 1097 of file yac.c.

Here is the call graph for this function:

◆ yac_cget_end_datetime_instance()

char * yac_cget_end_datetime_instance ( int yac_instance_id)

query routine for the end datetime of the job

Parameters
[in]yac_instance_idid of the YAC instance

Definition at line 1090 of file yac.c.

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

◆ yac_cget_ext_couple_config()

void yac_cget_ext_couple_config ( int * ext_couple_config_id)

Get an extended coupling configuration (all parameters are set to the default values)

Parameters
[out]ext_couple_config_idextended coupling configuration

Definition at line 2138 of file yac.c.

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

◆ yac_cget_ext_couple_config_collection_selection()

void yac_cget_ext_couple_config_collection_selection ( int ext_couple_config_id,
int * collection_size,
int ** collection_indices )

Gets the collection selection

Parameters
[in]ext_couple_config_idextended coupling configuration
[out]collection_sizenumber of selected collections
[out]collection_indicespointer to array of selected collection indices (may be NULL if contiguous)
Remarks
If collection_indices is NULL, the selection is the contiguous range [0, collection_size-1].
The returned array is managed internally and must not be freed or modified by the caller.
The caller is responsible for freeing the memory pointed to by collection_indices.

Definition at line 2429 of file yac.c.

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

◆ yac_cget_ext_couple_config_mapping_side()

void yac_cget_ext_couple_config_mapping_side ( int ext_couple_config_id,
int * mapping_side )

Gets the mapping side

Parameters
[in]ext_couple_config_idextended coupling configuration
[out]mapping_sidemapping side

Definition at line 2239 of file yac.c.

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

◆ yac_cget_ext_couple_config_scale_factor()

void yac_cget_ext_couple_config_scale_factor ( int ext_couple_config_id,
double * scale_factor )

Gets the scale factor

Parameters
[in]ext_couple_config_idextended coupling configuration
[out]scale_factorscale_factor

Definition at line 2262 of file yac.c.

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

◆ yac_cget_ext_couple_config_scale_summand()

void yac_cget_ext_couple_config_scale_summand ( int ext_couple_config_id,
double * scale_summand )

Gets the scale summand

Parameters
[in]ext_couple_config_idextended coupling configuration
[out]scale_summandscale_summand

Definition at line 2285 of file yac.c.

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

◆ yac_cget_ext_couple_config_src_mask_names()

void yac_cget_ext_couple_config_src_mask_names ( int ext_couple_config_id,
size_t * num_src_mask_names,
char const *const ** src_mask_names )

Gets source mask names

Parameters
[in]ext_couple_config_idextended coupling configuration
[out]num_src_mask_namesnumber of source mask names
[out]src_mask_namessource mask names

Definition at line 2316 of file yac.c.

Here is the call graph for this function:

◆ yac_cget_ext_couple_config_tgt_mask_name()

void yac_cget_ext_couple_config_tgt_mask_name ( int ext_couple_config_id,
char const ** tgt_mask_name )

Gets target mask name

Parameters
[in]ext_couple_config_idextended coupling configuration
[out]tgt_mask_nametarget mask name

Definition at line 2340 of file yac.c.

Here is the call graph for this function:

◆ yac_cget_ext_couple_config_use_raw_exchange()

void yac_cget_ext_couple_config_use_raw_exchange ( int ext_couple_config_id,
int * use_raw_exchange )

Gets use of raw exchange

Parameters
[in]ext_couple_config_idextended coupling configuration
[out]use_raw_exchangeuse raw exchange

Definition at line 2382 of file yac.c.

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

◆ yac_cget_ext_couple_config_weight_file()

void yac_cget_ext_couple_config_weight_file ( int ext_couple_config_id,
char const ** weight_file )

Gets the weight file name

Parameters
[in]ext_couple_config_idextended coupling configuration
[out]weight_filename of the weight file, if it is set; NULL otherwise

Definition at line 2182 of file yac.c.

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

◆ yac_cget_ext_couple_config_weight_file_on_existing()

void yac_cget_ext_couple_config_weight_file_on_existing ( int ext_couple_config_id,
int * weight_file_on_existing )

Gets how already existing weight files are handled

Parameters
[in]ext_couple_config_idextended coupling configuration
[in]weight_file_on_existinghandling of existing weight files

Definition at line 2213 of file yac.c.

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

◆ yac_cget_ext_couple_config_yaxt_exchanger_name()

void yac_cget_ext_couple_config_yaxt_exchanger_name ( int ext_couple_config_id,
char const ** yaxt_exchanger_name )

Gets yaxt exchanger name

Parameters
[in]ext_couple_config_idextended coupling configuration
[out]yaxt_exchanger_nameyaxt exchanger name

Definition at line 2362 of file yac.c.

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

◆ yac_cget_ext_spmap_config()

void yac_cget_ext_spmap_config ( int * ext_spmap_config_id)

Get an extended source point mapping interpolation configuration

Parameters
[out]ext_spmap_config_idextended source point mapping interpolation configuration
See also
Extended configuration

Definition at line 6075 of file yac.c.

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

◆ yac_cget_field_collection_size()

int yac_cget_field_collection_size ( const char * comp_name,
const char * grid_name,
const char * field_name )

query routine to get the collection_size of a field

Parameters
[in]comp_name
[in]grid_name
[in]field_name
Returns
if collection size is defined for this field, then the collection size, otherwise -1

Definition at line 5555 of file yac.c.

Here is the call graph for this function:

◆ yac_cget_field_collection_size_instance()

int yac_cget_field_collection_size_instance ( int yac_instance_id,
const char * comp_name,
const char * grid_name,
const char * field_name )

query routine to get the collection_size of a field

Parameters
[in]yac_instance_id
[in]comp_name
[in]grid_name
[in]field_name
Returns
if collection size is defined for this field, then the collection size, otherwise -1

Definition at line 5526 of file yac.c.

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

◆ yac_cget_field_datetime()

const char * yac_cget_field_datetime ( int field_id)

Returns the current datetime of the field

Parameters
[in]field_id
Returns
current datetime of the field

Definition at line 3013 of file yac.c.

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

◆ yac_cget_field_frac_mask_fallback_value()

double yac_cget_field_frac_mask_fallback_value ( const char * comp_name,
const char * grid_name,
const char * field_name )

query routine to get the fractional mask fallback value of a field

Parameters
[in]comp_name
[in]grid_name
[in]field_name
Returns
frac_mask_fallback_value
Remarks
if YAC_FRAC_MASK_NO_VALUE is returned, then no fractional mask fallback value is defined for this field

Definition at line 5547 of file yac.c.

Here is the call graph for this function:

◆ yac_cget_field_frac_mask_fallback_value_instance()

double yac_cget_field_frac_mask_fallback_value_instance ( int yac_instance_id,
const char * comp_name,
const char * grid_name,
const char * field_name )

query routine to get the fractional mask fallback value of a field

Parameters
[in]yac_instance_id
[in]comp_name
[in]grid_name
[in]field_name
Returns
frac_mask_fallback_value
Remarks
if YAC_FRAC_MASK_NO_VALUE is returned, then no fractional mask fallback value is defined for this field

Definition at line 5515 of file yac.c.

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

◆ yac_cget_field_id()

int yac_cget_field_id ( const char * comp_name,
const char * grid_name,
const char * field_name )

query routine to get the field_id from component, grid and field name (if defined on this process)

Parameters
[in]comp_namecomponent name
[in]grid_namegrid name
[in]field_namefield name
Returns
field_id

Definition at line 5220 of file yac.c.

Here is the call graph for this function:

◆ yac_cget_field_id_instance()

int yac_cget_field_id_instance ( int yac_instance_id,
const char * comp_name,
const char * grid_name,
const char * field_name )

query routine to get the field_id from component, grid and field name (if defined on this process)

Parameters
[in]yac_instance_id
[in]comp_namecomponent name
[in]grid_namegrid name
[in]field_namefield name
Returns
field_id

Definition at line 5207 of file yac.c.

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

◆ yac_cget_field_is_defined()

int yac_cget_field_is_defined ( const char * comp_name,
const char * grid_name,
const char * field_name )

determines whether a field with the provided component, grid, and field name is defined on the local process

Parameters
[in]comp_namecomponent name
[in]grid_namegrid name
[in]field_namefield name
Returns
!= 0, if the local process has defined a field with the provided component, grid, and field name
0, otherwise

Definition at line 5199 of file yac.c.

Here is the call graph for this function:

◆ yac_cget_field_is_defined_instance()

int yac_cget_field_is_defined_instance ( int yac_instance_id,
const char * comp_name,
const char * grid_name,
const char * field_name )

determines whether a field with the provided component, grid, and field name is defined on the local process

Parameters
[in]yac_instance_id
[in]comp_namecomponent name
[in]grid_namegrid name
[in]field_namefield name
Returns
!= 0, if the local process has defined a field with the provided component, grid, and field name
0, otherwise

Definition at line 5190 of file yac.c.

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

◆ yac_cget_field_metadata()

const char * yac_cget_field_metadata ( const char * comp_name,
const char * grid_name,
const char * field_name )

Get metadata for a field

Parameters
[in]comp_name
[in]grid_name
[in]field_name
Returns
metadata (NULL if no metadata is defined)

Definition at line 2115 of file yac.c.

Here is the call graph for this function:

◆ yac_cget_field_metadata_instance()

const char * yac_cget_field_metadata_instance ( int yac_instance_id,
const char * comp_name,
const char * grid_name,
const char * field_name )

Get metadata for a field

Parameters
[in]yac_instance_id
[in]comp_name
[in]grid_name
[in]field_name
Returns
metadata (NULL if no metadata is defined)

Definition at line 2106 of file yac.c.

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

◆ yac_cget_field_name_from_field_id()

const char * yac_cget_field_name_from_field_id ( int field_id)

query routine to get the field name for a given ID

Parameters
[in]field_idID as provided by yac_cdef_field
Returns
field_name field name that has been given to yac_cdef_field. (array of length YAC_MAX_CHARLEN)

Definition at line 5466 of file yac.c.

Here is the call graph for this function:

◆ yac_cget_field_names()

void yac_cget_field_names ( const char * comp_name,
const char * grid_name,
int nbr_fields,
const char ** field_names )

query routine to get the list of field names defined on the given component and grid for the default YAC instance.

Parameters
[in]comp_namecomponent name
[in]grid_namegrid name
[in]nbr_fieldsnumber of fields
[out]field_nameslist of field names

Definition at line 5444 of file yac.c.

Here is the call graph for this function:

◆ yac_cget_field_names_instance()

void yac_cget_field_names_instance ( int yac_instance_id,
const char * comp_name,
const char * grid_name,
int nbr_fields,
const char ** field_names )

query routine to get the list of field names on the given component and grid

Parameters
[in]yac_instance_idid of the YAC instance
[in]comp_namecomponent name
[in]grid_namegrid name
[in]nbr_fieldsnumber of fields
[out]field_nameslist of grid names

Definition at line 5405 of file yac.c.

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

◆ yac_cget_field_role()

int yac_cget_field_role ( const char * comp_name,
const char * grid_name,
const char * field_name )

query routine to get the role of a field for a given ID

Parameters
[in]comp_name
[in]grid_name
[in]field_name
Returns
role exchange type of the field
(YAC_EXCHANGE_TYPE_NONE, YAC_EXCHANGE_TYPE_SOURCE, YAC_EXCHANGE_TYPE_TARGET, or YAC_EXCHANGE_TYPE_INVALID)
Remarks
the role is set by the call to yac_cenddef or yac_cenddef_instance

Definition at line 5574 of file yac.c.

Here is the call graph for this function:

◆ yac_cget_field_role_instance()

int yac_cget_field_role_instance ( int yac_instance_id,
const char * comp_name,
const char * grid_name,
const char * field_name )

query routine to get the role of a field for a given ID

Parameters
[in]yac_instance_id
[in]comp_name
[in]grid_name
[in]field_name
Returns
role exchange type of the field
(YAC_EXCHANGE_TYPE_NONE, YAC_EXCHANGE_TYPE_SOURCE, YAC_EXCHANGE_TYPE_TARGET, or YAC_EXCHANGE_TYPE_INVALID)
Remarks
the role is set by the call to yac_cenddef or yac_cenddef_instance

Definition at line 5563 of file yac.c.

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

◆ yac_cget_field_source()

void yac_cget_field_source ( const char * tgt_comp_name,
const char * tgt_grid_name,
const char * tgt_field_name,
const char ** src_comp_name,
const char ** src_grid_name,
const char ** src_field_name )

query routine to get the source field for a given target field

Parameters
[in]tgt_comp_name
[in]tgt_grid_name
[in]tgt_field_name
[out]src_comp_name
[out]src_grid_name
[out]src_field_name

Definition at line 5595 of file yac.c.

Here is the call graph for this function:

◆ yac_cget_field_source_instance()

void yac_cget_field_source_instance ( int yac_instance_id,
const char * tgt_comp_name,
const char * tgt_grid_name,
const char * tgt_field_name,
const char ** src_comp_name,
const char ** src_grid_name,
const char ** src_field_name )

query routine to get the source field for a given target field

Parameters
[in]yac_instance_id
[in]tgt_comp_name
[in]tgt_grid_name
[in]tgt_field_name
[out]src_comp_name
[out]src_grid_name
[out]src_field_name

Definition at line 5581 of file yac.c.

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

◆ yac_cget_field_timestep()

const char * yac_cget_field_timestep ( const char * comp_name,
const char * grid_name,
const char * field_name )

query routine to get the timestep of a field

Parameters
[in]comp_name
[in]grid_name
[in]field_name
Returns
if timestep is defined for this field, then the timestep is returned (as iso8601 string), otherwise NULL is returned

Definition at line 5508 of file yac.c.

Here is the call graph for this function:

◆ yac_cget_field_timestep_instance()

const char * yac_cget_field_timestep_instance ( int yac_instance_id,
const char * comp_name,
const char * grid_name,
const char * field_name )

query routine to get the timestep of a field

Parameters
[in]yac_instance_id
[in]comp_name
[in]grid_name
[in]field_name
Returns
if timestep is defined for this field, then the timestep is returned (as iso8601 string), otherwise NULL is returned

Definition at line 5496 of file yac.c.

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

◆ yac_cget_grid_id()

int yac_cget_grid_id ( const char * grid_name)

query routine to get the grid id from the grid name

Parameters
[in]grid_namegrid name
Returns
grid id
Remarks
If no matching grid has already been defined, a preliminary one will be created.
A later definition of the grid will return the same id.
All preliminary grids have to be defined before yac_cenddef / yac_cenddef_instance is called, otherwise an error will be raised.

Definition at line 5151 of file yac.c.

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

◆ yac_cget_grid_metadata()

const char * yac_cget_grid_metadata ( const char * grid_name)

Get metadata for a grid

Parameters
[in]grid_name
Returns
metadata (NULL if no metadata is defined)

Definition at line 2101 of file yac.c.

Here is the call graph for this function:

◆ yac_cget_grid_metadata_instance()

const char * yac_cget_grid_metadata_instance ( int yac_instance_id,
const char * grid_name )

Get metadata for a grid

Parameters
[in]yac_instance_id
[in]grid_name
Returns
metadata (NULL if no metadata is defined)

Definition at line 2093 of file yac.c.

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

◆ yac_cget_grid_name_from_field_id()

const char * yac_cget_grid_name_from_field_id ( int field_id)

query routine to get the grid name for a given ID

Parameters
[in]field_idID as provided by yac_cdef_field
Returns
grid_name grid name of the fields grid. (array of length YAC_MAX_CHARLEN)

Definition at line 5458 of file yac.c.

Here is the call graph for this function:

◆ yac_cget_grid_names()

void yac_cget_grid_names ( int nbr_grids,
const char ** grid_names )

query routine to get the list of grid names of the default YAC instance that are referenced by at least one defined field or have metadata assigned to it

Parameters
[in]nbr_gridsnumber of grids
[out]grid_nameslist of grid names

Definition at line 5351 of file yac.c.

Here is the call graph for this function:

◆ yac_cget_grid_names_instance()

void yac_cget_grid_names_instance ( int yac_instance_id,
int nbr_grids,
const char ** grid_names )

query routine to get the list of grid names that are referenced by at least one defined field or have metadata assigned to it

Parameters
[in]yac_instance_idid of the YAC instance
[in]nbr_gridsnumber of grids
[out]grid_nameslist of grid names

Definition at line 5331 of file yac.c.

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

◆ yac_cget_grid_size()

size_t yac_cget_grid_size ( int location,
int grid_id )

query routine to get the number of points in a grid

Parameters
[in]location
[in]grid_id

Definition at line 5888 of file yac.c.

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

◆ yac_cget_instance_rank_c2py()

void yac_cget_instance_rank_c2py ( int yac_instance_id,
int * rank )

Definition at line 808 of file yac.c.

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

◆ yac_cget_instance_size_c2py()

void yac_cget_instance_size_c2py ( int yac_instance_id,
int * size )

Definition at line 818 of file yac.c.

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

◆ yac_cget_interp_stack_config()

void yac_cget_interp_stack_config ( int * interp_stack_config_id)

gets an empty stack trace

Parameters
[out]interp_stack_config_idinterpolation stack

Definition at line 5922 of file yac.c.

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

◆ yac_cget_interp_stack_config_from_string()

static int yac_cget_interp_stack_config_from_string ( char const * interp_stack_config,
int parse_flags )
static

Definition at line 6695 of file yac.c.

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

◆ yac_cget_interp_stack_config_from_string_json()

void yac_cget_interp_stack_config_from_string_json ( char const * interp_stack_config,
int * interp_stack_config_id )

generate an interpolation stack from a "0" terminated string that contains a JSON formated description of the stack

Parameters
[in]interp_stack_configinterpolation stack description
[out]interp_stack_config_idinterpolation stack

Definition at line 6725 of file yac.c.

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

◆ yac_cget_interp_stack_config_from_string_yaml()

void yac_cget_interp_stack_config_from_string_yaml ( char const * interp_stack_config,
int * interp_stack_config_id )

generate an interpolation stack from a "0" terminated string that contains a YAML formated description of the stack

Parameters
[in]interp_stack_configinterpolation stack description
[out]interp_stack_config_idinterpolation stack

Definition at line 6717 of file yac.c.

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

◆ yac_cget_mask_id()

int yac_cget_mask_id ( int grid_id,
int location,
const char * mask_name )

query routine to get the mask id from grid id, location, and name

Parameters
[in]grid_idgrid id
[in]locationmask location
[in]mask_namemask name
Returns
mask id
Remarks
If no matching mask has already been defined, a preliminary one will be created.
A later definition of the mask will return the same id.
All preliminary masks have to be defined before yac_cenddef / yac_cenddef_instance is called, otherwise an error will be raised.

Definition at line 5176 of file yac.c.

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

◆ yac_cget_mpi_handshake_group_name()

const char * yac_cget_mpi_handshake_group_name ( void )

Retrieve the MPI handshake group name used by YAC.

This function returns (via an output pointer) mpi_handshake_group_name.

Returns
name of the MPI group used by YAC in MPI handshake.
Note
Returns a null-terminated string containing the group name. The string is managed internally and must not be modified or freed.

Definition at line 1114 of file yac.c.

Here is the caller graph for this function:

◆ yac_cget_nbr_comps()

int yac_cget_nbr_comps ( void )

query routine for number of components defined in the default YAC instance

Returns
number of components

Definition at line 5234 of file yac.c.

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

◆ yac_cget_nbr_comps_instance()

int yac_cget_nbr_comps_instance ( int yac_instance_id)

query routine for number of components

Parameters
[in]yac_instance_idid of the YAC instance
Returns
number of components

Definition at line 5228 of file yac.c.

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

◆ yac_cget_nbr_fields()

int yac_cget_nbr_fields ( const char * comp_name,
const char * grid_name )

query routine for number of coupling fields defined in the given component and grids of the default YAC instance

Parameters
[in]comp_namename of the component
[in]grid_namename of the grid
Returns
number of fields defined on the calling process

Definition at line 5300 of file yac.c.

Here is the call graph for this function:

◆ yac_cget_nbr_fields_instance()

int yac_cget_nbr_fields_instance ( int yac_instance_id,
const char * comp_name,
const char * grid_name )

query routine for number of coupling fields defined in the given component and grids

Parameters
[in]yac_instance_idid of the YAC instance
[in]comp_namename of the component
[in]grid_namename of the grid
Returns
number of fields defined on the calling process

Definition at line 5280 of file yac.c.

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

◆ yac_cget_nbr_grids()

int yac_cget_nbr_grids ( )

query routine for number of grids defined in the default YAC instance that are referenced by at least one defined field or have metadata assigned to it

Returns
number of fields defined on the calling process

Definition at line 5247 of file yac.c.

Here is the call graph for this function:

◆ yac_cget_nbr_grids_instance()

int yac_cget_nbr_grids_instance ( int yac_instance_id)

query routine for number of grids that are referenced by at least one defined field or have metadata assigned to it

Parameters
[in]yac_instance_idid of the YAC instance
Returns
number of fields defined on the calling process

Definition at line 5239 of file yac.c.

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

◆ yac_cget_points_id()

int yac_cget_points_id ( int grid_id,
int location,
const char * point_name )

query routine to get the points id from grid id, location, and name

Parameters
[in]grid_idgrid id
[in]locationpoint location
[in]point_namepoint-set name
Returns
points id
Remarks
If no matching point-set has already been defined, a preliminary one will be created.
A later definition of the point-set will return the same id.
All preliminary point-sets have to be defined before yac_cenddef / yac_cenddef_instance is called, otherwise an error will be raised.

Definition at line 5162 of file yac.c.

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

◆ yac_cget_points_size()

size_t yac_cget_points_size ( int points_id)

query routine to get the number of points in a pointset

Parameters
[in]points_id

Definition at line 5909 of file yac.c.

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

◆ yac_cget_pre_processing()

static void * yac_cget_pre_processing ( int const field_id,
int collection_size,
int * info,
int * ierr )
static

Definition at line 3167 of file yac.c.

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

◆ yac_cget_raw()

void yac_cget_raw ( int const field_id,
int const collection_size,
double *** src_field_buffer,
int * info,
int * ierror )

Receiving source points required for the interpolation of the local target field

Parameters
[in]field_id
[in]collection_size
[in]src_field_buffersource field buffer (dimensions: src_field_buffer [collection_size] [nnr_src_pointsets] [src_field_buffer_sizes[pointset_idx]])
[out]inforeturned info argument indicating the action performed
[out]ierrorreturned error

Definition at line 3571 of file yac.c.

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

◆ yac_cget_raw_()

void yac_cget_raw_ ( int const field_id,
int const collection_size,
double * src_field_buffer,
int * info,
int * ierror )

Receiving source points required for the interpolation of the local target field

Parameters
[in]field_id
[in]collection_size
[in]src_field_buffersource field buffer (all data is stored in one contiguous part of the memory) (dimensions: src_field_buffer [collection_size] [nbr_src_pointsets] [src_field_buffer_sizes[pointset_idx]])
[out]inforeturned info argument indicating the action performed
[out]ierrorreturned error

Definition at line 3458 of file yac.c.

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

◆ yac_cget_raw_async()

void yac_cget_raw_async ( int const field_id,
int const collection_size,
double *** src_field_buffer,
int * info,
int * ierror )

Receiving source points required for the interpolation of the local target field

Parameters
[in]field_id
[in]collection_size
[in]src_field_buffersource field buffer (dimensions: src_field_buffer [collection_size] [nbr_src_pointsets] [src_field_buffer_sizes[pointset_idx]])
[out]inforeturned info argument indicating the action performed
[out]ierrorreturned error
Remarks
This routine returns immediately without waiting for the receive operation to be completed. The user should not access the memory associated with recv_field until this is the case. This can be achieved by calling yac_cwait.

Definition at line 3584 of file yac.c.

Here is the call graph for this function:

◆ yac_cget_raw_async_()

void yac_cget_raw_async_ ( int const field_id,
int const collection_size,
double * src_field_buffer,
int * info,
int * ierror )

Receiving source points required for the interpolation of the local target field

Parameters
[in]field_id
[in]collection_size
[in]src_field_buffersource field buffer (all data is stored in one contiguous part of the memory) (dimensions: src_field_buffer [collection_size * nbr_src_pointsets * SUM(src_field_buffer_sizes(:))])
[out]inforeturned info argument indicating the action performed
[out]ierrorreturned error
Remarks
This routine returns immediately without waiting for the receive operation to be completed. The user should not access the memory associated with recv_field until this is the case. This can be achieved by calling yac_cwait.

Definition at line 3515 of file yac.c.

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

◆ yac_cget_raw_async_ptr_()

void yac_cget_raw_async_ptr_ ( int const field_id,
int const collection_size,
double ** src_field_buffer,
int * info,
int * ierr )

Definition at line 3543 of file yac.c.

Here is the call graph for this function:

◆ yac_cget_raw_frac()

void yac_cget_raw_frac ( int const field_id,
int const collection_size,
double *** src_field_buffer,
double *** src_frac_mask_buffer,
int * info,
int * ierror )

Receiving source points required for the interpolation of the local target field

Parameters
[in]field_id
[in]collection_size
[in]src_field_buffersource field buffer (dimensions: src_field_buffer [collection_size] [nbr_src_pointsets] [src_field_buffer_sizes[pointset_idx]])
[in]src_frac_mask_buffersource fractional mask buffer (dimensions: src_frac_mask_buffer [collection_size] [nbr_src_pointsets] [src_field_buffer_sizes[pointset_idx]])
[out]inforeturned info argument indicating the action performed
[out]ierrorreturned error
Remarks
source field values in the src_field_buffer have already been weighted, by the fractional mask

Definition at line 3598 of file yac.c.

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

◆ yac_cget_raw_frac_()

void yac_cget_raw_frac_ ( int const field_id,
int const collection_size,
double * src_field_buffer,
double * src_frac_mask_buffer,
int * info,
int * ierror )

Receiving source points required for the interpolation of the local target field

Parameters
[in]field_id
[in]collection_size
[in]src_field_buffersource field buffer (all data is stored in one contiguous part of the memory) (dimensions: src_field_buffer [collection_size] [nbr_src_pointsets] [src_field_buffer_sizes[pointset_idx]])
[in]src_frac_mask_buffersource fractional mask buffer (all data is stored in one contiguous part of the memory) (dimensions: src_frac_mask_buffer [collection_size] [nbr_src_pointsets] [src_field_buffer_sizes[pointset_idx]])
[out]inforeturned info argument indicating the action performed
[out]ierrorreturned error
Remarks
source field values in the src_field_buffer have already been weighted, by the fractional mask

Definition at line 3470 of file yac.c.

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

◆ yac_cget_raw_frac_async()

void yac_cget_raw_frac_async ( int const field_id,
int const collection_size,
double *** src_field_buffer,
double *** src_frac_mask_buffer,
int * info,
int * ierror )

Receiving source points required for the interpolation of the local target field

Parameters
[in]field_id
[in]collection_size
[in]src_field_buffersource field buffer (dimensions: src_field_buffer [collection_size] [nbr_src_pointsets] [src_field_buffer_sizes[pointset_idx]])
[in]src_frac_mask_buffersource fractional mask buffer (dimensions: src_frac_mask_buffer [collection_size] [nbr_src_pointsets] [src_field_buffer_sizes[pointset_idx]])
[out]inforeturned info argument indicating the action performed
[out]ierrorreturned error
Remarks
source field values in the src_field_buffer have already been weighted, by the fractional mask
This routine returns immediately without waiting for the receive operation to be completed. The user should not access the memory associated with recv_field until this is the case. This can be achieved by calling yac_cwait.

Definition at line 3616 of file yac.c.

Here is the call graph for this function:

◆ yac_cget_raw_frac_async_()

void yac_cget_raw_frac_async_ ( int const field_id,
int const collection_size,
double * src_field_buffer,
double * src_frac_mask_buffer,
int * info,
int * ierror )

Receiving source points required for the interpolation of the local target field

Parameters
[in]field_id
[in]collection_size
[in]src_field_buffersource field buffer (all data is stored in one contiguous part of the memory) (dimensions: src_field_buffer [collection_size] [nbr_src_pointsets] [src_field_buffer_sizes[pointset_idx]])
[in]src_frac_mask_buffersource fractional mask buffer (all data is stored in one contiguous part of the memory) (dimensions: src_frac_mask_buffer [collection_size] [nbr_src_pointsets] [src_field_buffer_sizes[pointset_idx]])
[out]inforeturned info argument indicating the action performed
[out]ierrorreturned error
Remarks
source field values in the src_field_buffer have already been weighted, by the fractional mask
This routine returns immediately without waiting for the receive operation to be completed. The user should not access the memory associated with recv_field until this is the case. This can be achieved by calling yac_cwait.

Definition at line 3527 of file yac.c.

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

◆ yac_cget_raw_frac_async_ptr_()

void yac_cget_raw_frac_async_ptr_ ( int const field_id,
int const collection_size,
double ** src_field_buffer,
double ** src_frac_mask_buffer,
int * info,
int * ierr )

Definition at line 3555 of file yac.c.

Here is the call graph for this function:

◆ yac_cget_raw_frac_ptr_()

void yac_cget_raw_frac_ptr_ ( int const field_id,
int const collection_size,
double ** src_field_buffer,
double ** src_frac_mask_buffer,
int * info,
int * ierr )

Definition at line 3498 of file yac.c.

Here is the call graph for this function:

◆ yac_cget_raw_interp_weights_data()

void yac_cget_raw_interp_weights_data ( int const field_id,
double * frac_mask_fallback_value,
double * scaling_factor,
double * scaling_summand,
size_t * num_fixed_values,
double ** fixed_values,
size_t ** num_tgt_per_fixed_value,
size_t ** tgt_idx_fixed,
size_t * num_wgt_tgt,
size_t ** wgt_tgt_idx,
size_t ** num_src_per_tgt,
double ** weights,
size_t ** src_pointset_idx,
size_t ** src_idx,
size_t * num_src_pointsets,
size_t ** src_field_buffer_sizes )

Get interpolation information for raw data exchange

Parameters
[in]field_id
[out]frac_mask_fallback_valuefractional masking fallback value
[out]scaling_factorscaling factor
[out]scaling_summandscaling summand
[out]num_fixed_valuesnumber of fixed values
[out]fixed_valuesarray of fixed values
[out]num_tgt_per_fixed_valuenumber of target points per fixed value
[out]tgt_idx_fixedlocal target point indices that receive a fixed value
[out]num_wgt_tgtnumber of target points receiving a weighted sum of source points
[out]wgt_tgt_idxlocal target point indices that receive weighted sum of source points
[out]num_src_per_tgtnumber of source points per target point
[out]weightsweights
[out]src_pointset_idxsource pointset indices
[out]src_idxsource field buffer indices
[out]num_src_pointsetsnumber of source pointsets
[out]src_field_buffer_sizesbuffer sizes of source field pointsets buffers
Remarks
If a coupling is configured for raw data exchange, target processes can extract once all information required to execute the interpolation by hand.
The user is responsible for freeing the memory associated with returned arrays.

Definition at line 2783 of file yac.c.

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

◆ yac_cget_raw_interp_weights_data_csr()

void yac_cget_raw_interp_weights_data_csr ( int const field_id,
double * frac_mask_fallback_value,
double * scaling_factor,
double * scaling_summand,
size_t * num_fixed_values,
double ** fixed_values,
size_t ** num_tgt_per_fixed_value,
size_t ** tgt_idx_fixed,
size_t ** src_indptr,
double ** weights,
size_t ** src_pointset_idx,
size_t ** src_idx,
size_t * num_src_pointsets,
size_t ** src_field_buffer_sizes )

Get interpolation information for raw data exchange (weight matrix is stored as a sparse matrix using CSR format)

Parameters
[in]field_id
[out]frac_mask_fallback_valuefractional masking fallback value
[out]scaling_factorscaling factor
[out]scaling_summandscaling summand
[out]num_fixed_valuesnumber of fixed values
[out]fixed_valuesarray of fixed values
[out]num_tgt_per_fixed_valuenumber of target points per fixed value
[out]tgt_idx_fixedlocal target point indices that receive a fixed value
[out]src_indptroffset to weights/src_idx/pointset_idx for each local target point
[out]weightsweights
[out]src_pointset_idxsource pointset indices
[out]src_idxsource field buffer indices
[out]num_src_pointsetsnumber of source pointsets
[out]src_field_buffer_sizesbuffer sizes of source field pointset buffers
Remarks
If a coupling is configured for raw data exchange, target processes can extract once all information required to execute the interpolation by hand.
The user is responsible for freeing the memory associated with returned arrays.
Number of weights per target is computed by "src_indptr[tgt_idx+1] - src_indptr[tgt_idx]".

Definition at line 2823 of file yac.c.

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

◆ yac_cget_raw_interp_weights_data_csr_c2f()

void yac_cget_raw_interp_weights_data_csr_c2f ( int const field_id,
double * frac_mask_fallback_value,
double * scaling_factor,
double * scaling_summand,
size_t * num_fixed_values,
double ** fixed_values,
size_t ** num_tgt_per_fixed_value,
size_t ** tgt_idx_fixed,
size_t ** src_indptr,
double ** weights,
size_t ** src_field_idx,
size_t ** src_idx,
size_t * num_src_fields,
size_t ** src_field_buffer_sizes,
size_t * tgt_field_data_size )

Definition at line 2930 of file yac.c.

Here is the call graph for this function:

◆ yac_cget_raw_ptr_()

void yac_cget_raw_ptr_ ( int const field_id,
int const collection_size,
double ** src_field_buffer,
int * info,
int * ierr )

Definition at line 3486 of file yac.c.

Here is the call graph for this function:

◆ yac_cget_role_from_field_id()

int yac_cget_role_from_field_id ( int field_id)

query routine to get the role of a field for a given ID

Parameters
[in]field_idID as provided by yac_cdef_field
Returns
role exchange type of the field
(YAC_EXCHANGE_TYPE_NONE, YAC_EXCHANGE_TYPE_SOURCE, or YAC_EXCHANGE_TYPE_TARGET)
Remarks
the role is set by the call to yac_cenddef or yac_cenddef_instance

Definition at line 5487 of file yac.c.

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

◆ yac_cget_spmap_overwrite_config()

void yac_cget_spmap_overwrite_config ( int * spmap_overwrite_config_id)

Get an source point mapping interpolation overwrite configuration

Parameters
[out]spmap_overwrite_config_idsource point mapping interpolation overwrite configuration
See also
Extended configuration

Definition at line 6281 of file yac.c.

Here is the call graph for this function:

◆ yac_cget_start_datetime()

char * yac_cget_start_datetime ( void )

query routine for the start datetime of the job of the default YAC instance

Definition at line 1082 of file yac.c.

Here is the call graph for this function:

◆ yac_cget_start_datetime_instance()

char * yac_cget_start_datetime_instance ( int yac_instance_id)

query routine for the start datetime of the job

Parameters
[in]yac_instance_idid of the YAC instance

Definition at line 1075 of file yac.c.

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

◆ yac_cget_timestep_from_field_id()

const char * yac_cget_timestep_from_field_id ( int field_id)

query routine to get the timestep of a field for a given ID

Parameters
[in]field_idID as provided by yac_cdef_field
Returns
timestep timestep that has been given to yac_cdef_field iso8601 string. (array of length YAC_MAX_CHARLEN)
Examples
dummy_atmosphere_c.c, and dummy_ocean_c.c.

Definition at line 5473 of file yac.c.

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

◆ yac_cget_version()

char * yac_cget_version ( void )

query routine for the YAC version

Examples
dummy_atmosphere_c.c, dummy_io_c.c, and dummy_ocean_c.c.

Definition at line 1108 of file yac.c.

Here is the caller graph for this function:

◆ yac_check_version()

static void yac_check_version ( MPI_Comm comm)
static

Definition at line 605 of file yac.c.

Here is the caller graph for this function:

◆ yac_check_yac_int()

static void yac_check_yac_int ( MPI_Comm comm)
static

Definition at line 640 of file yac.c.

Here is the caller graph for this function:

◆ yac_cinit()

void yac_cinit ( void )

Elementary initialisation of the whole system

Remarks
This call initialises the default YAC instance.
A call to yac_ccleanup or yac_cfinalize is required to free all memory associated with the default YAC instance.
This call executes an MPI handshake (MPI handshake algorithm) on MPI_COMM_WORLD with the group name mpi_handshake_group_name and uses the created communicator for the initialization. If you do not want to execute an MPI Handshake on MPI_COMM_WORLD, call yac_cinit_comm with MPI_COMM_WORLD directly.
Examples
dummy_atmosphere_c.c, dummy_io_c.c, and dummy_ocean_c.c.

Definition at line 768 of file yac.c.

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

◆ yac_cinit_comm()

void yac_cinit_comm ( MPI_Comm comm)

Elementary initialisation of the whole system using a user-provided MPI communicator

Parameters
[in]commMPI communicator
Remarks
This call initialises the default YAC instance.
A call to yac_ccleanup or yac_cfinalize is required to free all memory associated with the default YAC instance.
the MPI communicator provided to this routine has to contain all processes that will take part in the coupling
this call is collective for all processes in comm

Definition at line 742 of file yac.c.

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

◆ yac_cinit_comm_dummy()

void yac_cinit_comm_dummy ( MPI_Comm comm)

Dummy initialisation of the whole system using a user-provided MPI world communicator

Parameters
[in]commMPI communicator
Remarks
This routine can be called instead of yac_cinit_comm or yac_cinit_comm_instance, if the local process does not wish to initialise a YAC instance.

Definition at line 778 of file yac.c.

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

◆ yac_cinit_comm_dummy_f2c()

void yac_cinit_comm_dummy_f2c ( MPI_Fint comm_f)

Definition at line 789 of file yac.c.

Here is the call graph for this function:

◆ yac_cinit_comm_f2c()

void yac_cinit_comm_f2c ( MPI_Fint comm_f)

Definition at line 751 of file yac.c.

Here is the call graph for this function:

◆ yac_cinit_comm_instance()

void yac_cinit_comm_instance ( MPI_Comm comm,
int * yac_instance_id )

Elementary initialisation of the whole system using a user-provided MPI communicator

Parameters
[in]commMPI communicator
[out]yac_instance_idid of the YAC instance initialised by this call
Remarks
This call initialises a YAC instance.
A call to yac_ccleanup_instance or yac_cfinalize_instance is required to free all memory associated with this YAC instance.
In case the user has multiple YAC instances in parallel, he has to initialise yaxt himself.

Definition at line 722 of file yac.c.

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

◆ yac_cinit_comm_instance_f2c()

void yac_cinit_comm_instance_f2c ( MPI_Fint comm,
int * yac_instance_id )

Definition at line 736 of file yac.c.

Here is the call graph for this function:

◆ yac_cinit_dummy()

void yac_cinit_dummy ( void )

Dummy for initialisation of the whole system

Remarks
This routine can be called instead of yac_cinit or yac_cinit_instance, if the local process does not wish to initialise a YAC instance.

Definition at line 795 of file yac.c.

Here is the call graph for this function:

◆ yac_cinit_instance()

void yac_cinit_instance ( int * yac_instance_id)

Elementary initialisation of the whole system

Parameters
[out]yac_instance_idid of the YAC instance initialised by this call
Remarks
This call initialises a YAC instance.
A call to yac_ccleanup_instance or yac_cfinalize_instance is required to free all memory associated with this YAC instance.
This call executes an MPI handshake (MPI handshake algorithm) on MPI_COMM_WORLD with the group name mpi_handshake_group_name and uses the created communicator for the initialization. If you do not want to execute an MPI Handshake on MPI_COMM_WORLD, call yac_cinit_comm with MPI_COMM_WORLD directly.

Definition at line 756 of file yac.c.

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

◆ yac_cmpi_handshake()

void yac_cmpi_handshake ( MPI_Comm comm,
size_t n,
char const ** group_names,
MPI_Comm * group_comms )

MPI Handshake (MPI handshake algorithm)

Splits the provided communicator into group communicators. Each group communicator contains all processes of the provided communicator that provided the same group name. The order of the group names can be arbitrary on each process. A process can be part of multiple groups.

Parameters
[in]commMPI communicator
[in]nnumber of group communicators to be generated
[in]group_namesgroup names
[out]group_commsgroup communicators
Remarks
This call is collective for processes in comm.
yac_cinit will call this routine for MPI_COMM_WORLD and use a fixed mpi_handshake_group_name to build its internal communicator.
If a process does not wish to use YAC but is part of a communicator (e.g. MPI_COMM_WORLD) that is used by other processes that actually do use YAC, this routine can be called, while not providing mpi_handshake_group_name. This will exclude a process from later collective YAC-calls.
yac_cget_mpi_handshake_group_name allows to query the mpi_handshake_group_name internally used by YAC.
The user is responsible for free the MPI communicators returned by this routine.

Definition at line 669 of file yac.c.

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

◆ yac_cmpi_handshake_f2c()

void yac_cmpi_handshake_f2c ( MPI_Fint comm,
int n,
char const ** group_names,
MPI_Fint * group_comms )

Definition at line 675 of file yac.c.

Here is the call graph for this function:

◆ yac_cpredef_comp()

void yac_cpredef_comp ( char const * comp_name,
int * comp_id )

Non-blocking pre-definition of a component for the default YAC instance.

Parameters
[in]comp_namename of the component
[out]comp_idcomponent Id
Remarks
this call does not finish the component definition phase. I.e. the component communicators are not set up after this call.

Definition at line 1321 of file yac.c.

Here is the call graph for this function:

◆ yac_cpredef_comp_instance()

void yac_cpredef_comp_instance ( int yac_instance_id,
char const * comp_name,
int * comp_id )

Non-blocking pre-definition of a component.

Parameters
[in]yac_instance_idid of the YAC instance
[in]comp_namename of the component
[out]comp_idcomponent Id
Remarks
this call does not finish the component definition phase. I.e. the component communicators are not set up after this call.

Definition at line 1294 of file yac.c.

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

◆ yac_cput()

void yac_cput ( int const field_id,
int const collection_size,
double ***const send_field,
int * info,
int * ierror )

Sending of the coupling fields

Parameters
[in]field_id-
[in]collection_size-
[in]send_field- send buffer dimensions send_field[collection_size] [nbr_pointsets] [nbr_points]
[out]info- returned info
[out]ierror- returned error
Remarks
This operation does not wait until the data has been received.
Once this routine returns that user can access send_field.
Examples
dummy_atmosphere_c.c, and dummy_ocean_c.c.

Definition at line 4332 of file yac.c.

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

◆ yac_cput_()

void yac_cput_ ( int const field_id,
int const collection_size,
double * send_field,
int * info,
int * ierror )

Sending of the coupling fields

Parameters
[in]field_id-
[in]collection_size-
[in]send_field- send buffer (all data is stored in one contiguous part of the memory) dimensions send_field[collection_size] [nbr_pointsets] [nbr_points]
[out]info- returned info
[out]ierror- returned error
Remarks
This operation does not wait until the data has been received.
Once this routine returns that user can access send_field.

Definition at line 3671 of file yac.c.

Here is the call graph for this function:

◆ yac_cput_frac()

void yac_cput_frac ( int const field_id,
int const collection_size,
double ***const send_field,
double ***const send_frac_mask,
int * info,
int * ierror )

Sending of the coupling fields

Parameters
[in]field_id-
[in]collection_size-
[in]send_field- send buffer dimensions send_field[collection_size] [nbr_pointsets] [nbr_points]
[in]send_frac_mask- send fractional mask dimensions send_frac_mask[collection_size] [nbr_pointsets] [nbr_points]
[out]info- returned info
[out]ierror- returned error
Remarks
This operation does not wait until the data has been received.
Once this routine returns that user can access send_field and send_frac_mask.

Definition at line 4209 of file yac.c.

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

◆ yac_cput_frac_()

void yac_cput_frac_ ( int const field_id,
int const collection_size,
double * send_field,
double * send_frac_mask,
int * info,
int * ierror )

Sending of the coupling fields

Parameters
[in]field_id-
[in]collection_size-
[in]send_field- send buffer (all data is stored in one contiguous part of the memory) dimensions send_field[collection_size] [nbr_pointsets] [nbr_points]
[in]send_frac_mask- send fractional mask (all data is stored in one contiguous part of the memory) dimensions send_frac_mask[collection_size] [nbr_pointsets] [nbr_points]
[out]info- returned info
[out]ierror- returned error
Remarks
This operation does not wait until the data has been received.
Once this routine returns that user can access send_field and send_frac_mask.

Definition at line 3691 of file yac.c.

Here is the call graph for this function:

◆ yac_cput_frac_ptr_()

void yac_cput_frac_ptr_ ( int const field_id,
int const collection_size,
double ** send_field,
double ** send_frac_mask,
int * info,
int * ierror )

Sending of the coupling fields

Parameters
[in]field_id-
[in]collection_size-
[in]send_field- send buffer dimensions send_field[collection_size * nbr_pointsets] [nbr_points]
[in]send_frac_mask- send fractional mask dimensions send_frac_mask[collection_size * nbr_pointsets] [nbr_points]
[out]info- returned info
[out]ierror- returned error
Remarks
This operation does not wait until the data has been received.
Once this routine returns that user can access send_field and send_frac_mask.

Definition at line 3789 of file yac.c.

Here is the call graph for this function:

◆ yac_cput_pre_processing()

static void * yac_cput_pre_processing ( struct coupling_field * cpl_field,
unsigned put_idx,
int const collection_size,
double *** send_field,
double **** send_field_acc_,
double *** send_frac_mask,
double **** send_frac_mask_acc_,
int * with_frac_mask_,
int * use_raw_exchange_,
int * info,
int * ierr )
static

Definition at line 3896 of file yac.c.

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

◆ yac_cput_ptr_()

void yac_cput_ptr_ ( int const field_id,
int const collection_size,
double ** send_field,
int * info,
int * ierror )

Sending of the coupling fields

Parameters
[in]field_id-
[in]collection_size-
[in]send_field- send buffer dimensions send_field[collection_size * nbr_pointsets] [nbr_points]
[out]info- returned info
[out]ierror- returned error
Remarks
This operation does not wait until the data has been received.
Once this routine returns that user can access send_field.

Definition at line 3768 of file yac.c.

Here is the call graph for this function:

◆ yac_cread_config_json()

void yac_cread_config_json ( const char * json_file)

Function for reading configuration from JSON configuration file

Parameters
[in]json_fileJSON configuration file

Definition at line 863 of file yac.c.

Here is the call graph for this function:

◆ yac_cread_config_json_instance()

void yac_cread_config_json_instance ( int yac_instance_id,
const char * json_file )

Function for reading configuration from JSON configuration file for a specific YAC instance

Parameters
[in]yac_instance_idYAC instance id
[in]json_fileJSON configuration file

Definition at line 854 of file yac.c.

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

◆ yac_cread_config_yaml()

void yac_cread_config_yaml ( const char * yaml_file)

Function for reading configuration from YAML configuration file

Parameters
[in]yaml_fileYAML configuration file
Examples
dummy_atmosphere_c.c, dummy_io_c.c, and dummy_ocean_c.c.

Definition at line 849 of file yac.c.

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

◆ yac_cread_config_yaml_instance()

void yac_cread_config_yaml_instance ( int yac_instance_id,
const char * yaml_file )

Function for reading configuration from YAML configuration file for a specific YAC instance

Parameters
[in]yac_instance_idYAC instance id
[in]yaml_fileYAML configuration file

Definition at line 840 of file yac.c.

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

◆ yac_cset_config_output_file()

void yac_cset_config_output_file ( const char * filename,
int fileformat,
int sync_location,
int include_definitions )

Activates writing out of the coupling configuration

Parameters
[in]filenamename of the file to be written
[in]fileformatfile format (YAC_CONFIG_OUTPUT_FORMAT_YAML or YAC_CONFIG_OUTPUT_FORMAT_JSON)
[in]sync_locationsynchronisation point after which the file is to be written (YAC_CONFIG_OUTPUT_SYNC_LOC_DEF_COMP, YAC_CONFIG_OUTPUT_SYNC_LOC_SYNC_DEF, or YAC_CONFIG_OUTPUT_SYNC_LOC_ENDDEF)
[in]include_definitionsinclude debug definitions (components, grids, and fields)

Definition at line 901 of file yac.c.

Here is the call graph for this function:

◆ yac_cset_config_output_file_instance()

void yac_cset_config_output_file_instance ( int yac_instance_id,
const char * filename,
int fileformat,
int sync_location,
int include_definitions )

Activates writing out of the coupling configuration

Parameters
[in]yac_instance_idYAC instance_id
[in]filenamename of the file to be written
[in]fileformatfile format (YAC_CONFIG_OUTPUT_FORMAT_YAML or YAC_CONFIG_OUTPUT_FORMAT_JSON)
[in]sync_locationsynchronisation point after which the file is to be written (YAC_CONFIG_OUTPUT_SYNC_LOC_DEF_COMP, YAC_CONFIG_OUTPUT_SYNC_LOC_SYNC_DEF, or YAC_CONFIG_OUTPUT_SYNC_LOC_ENDDEF)
[in]include_definitionsinclude debug definitions (components, grids, and fields)

Definition at line 870 of file yac.c.

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

◆ yac_cset_coordinates_check()

void yac_cset_coordinates_check ( int apply_check)

Enables or disables the coordinate consistency check at enddef (default YAC instance)

Parameters
[in]apply_checknon-zero to enable, zero to disable

Definition at line 945 of file yac.c.

Here is the call graph for this function:

◆ yac_cset_coordinates_check_instance()

void yac_cset_coordinates_check_instance ( int yac_instance_id,
int apply_check )

Enables or disables the coordinate consistency check at enddef

Parameters
[in]yac_instance_idYAC instance_id
[in]apply_checknon-zero to enable, zero to disable

Definition at line 936 of file yac.c.

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

◆ yac_cset_coordinates_mismatch_is_fatal()

void yac_cset_coordinates_mismatch_is_fatal ( int is_fatal)

Sets whether a coordinate mismatch is fatal (abort) or a warning (default YAC instance)

Parameters
[in]is_fatalnon-zero for fatal error, zero for warning

Definition at line 960 of file yac.c.

Here is the call graph for this function:

◆ yac_cset_coordinates_mismatch_is_fatal_instance()

void yac_cset_coordinates_mismatch_is_fatal_instance ( int yac_instance_id,
int is_fatal )

Sets whether a coordinate mismatch is fatal (abort) or a warning

Parameters
[in]yac_instance_idYAC instance_id
[in]is_fatalnon-zero for fatal error, zero for warning

Definition at line 951 of file yac.c.

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

◆ yac_cset_core_mask()

void yac_cset_core_mask ( int const * is_core,
int location,
int grid_id )

Set core mask for a grid

Parameters
[in]is_core0 for cells/vertices/edges that are halos, 1 for cells/vertices/edges that are core
[in]locationcell/vertex/edge
[in]grid_idgrid id
Remarks
cells/vertices/edges who are halos are not used or set in a put or get operation
core mask values are to be provided in the local order of their respective cells/vertices/edges
Examples
dummy_atmosphere_c.c, dummy_io_c.c, and dummy_ocean_c.c.

Definition at line 5845 of file yac.c.

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

◆ yac_cset_ext_couple_config_collection_selection()

void yac_cset_ext_couple_config_collection_selection ( int ext_couple_config_id,
int collection_size,
int const * collection_indices )

Sets the collection selection

Parameters
[in]ext_couple_config_idextended coupling configuration
[in]collection_sizenumber of selected collections
[in]collection_indicesarray of selected collection indices (may be NULL if indices are contiguous)
Remarks
If collection_indices is NULL, the selection is assumed to be the contiguous range [0, collection_size-1].

Definition at line 2421 of file yac.c.

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

◆ yac_cset_ext_couple_config_collection_selection_()

void yac_cset_ext_couple_config_collection_selection_ ( struct yac_ext_couple_config * ext_couple_config,
int collection_size,
int const * collection_indices )

Definition at line 2389 of file yac.c.

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

◆ yac_cset_ext_couple_config_mapping_side()

void yac_cset_ext_couple_config_mapping_side ( int ext_couple_config_id,
int mapping_side )

Sets the mapping side

Parameters
[in]ext_couple_config_idextended coupling configuration
[in]mapping_sidemapping side
Remarks
Valid values are: source = 1 and target = 0

Definition at line 2232 of file yac.c.

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

◆ yac_cset_ext_couple_config_mapping_side_()

void yac_cset_ext_couple_config_mapping_side_ ( struct yac_ext_couple_config * ext_couple_config,
int mapping_side )

Definition at line 2220 of file yac.c.

Here is the caller graph for this function:

◆ yac_cset_ext_couple_config_scale_factor()

void yac_cset_ext_couple_config_scale_factor ( int ext_couple_config_id,
double scale_factor )

Sets the scale factor

Parameters
[in]ext_couple_config_idextended coupling configuration
[in]scale_factorscale factor

Definition at line 2255 of file yac.c.

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

◆ yac_cset_ext_couple_config_scale_factor_()

void yac_cset_ext_couple_config_scale_factor_ ( struct yac_ext_couple_config * ext_couple_config,
double scale_factor )

Definition at line 2246 of file yac.c.

Here is the caller graph for this function:

◆ yac_cset_ext_couple_config_scale_summand()

void yac_cset_ext_couple_config_scale_summand ( int ext_couple_config_id,
double scale_summand )

Sets the scale summand

Parameters
[in]ext_couple_config_idextended coupling configuration
[in]scale_summandscale summand

Definition at line 2278 of file yac.c.

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

◆ yac_cset_ext_couple_config_scale_summand_()

void yac_cset_ext_couple_config_scale_summand_ ( struct yac_ext_couple_config * ext_couple_config,
double scale_summand )

Definition at line 2269 of file yac.c.

Here is the caller graph for this function:

◆ yac_cset_ext_couple_config_src_mask_names()

void yac_cset_ext_couple_config_src_mask_names ( int ext_couple_config_id,
size_t num_src_mask_names,
char const *const * src_mask_names )

Sets source mask names

Parameters
[in]ext_couple_config_idextended coupling configuration
[in]num_src_mask_namesnumber of source mask names
[in]src_mask_namessource mask names

Definition at line 2308 of file yac.c.

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

◆ yac_cset_ext_couple_config_src_mask_names_()

void yac_cset_ext_couple_config_src_mask_names_ ( struct yac_ext_couple_config * ext_couple_config,
size_t num_src_mask_names,
char const *const * src_mask_names )

Definition at line 2292 of file yac.c.

Here is the caller graph for this function:

◆ yac_cset_ext_couple_config_tgt_mask_name()

void yac_cset_ext_couple_config_tgt_mask_name ( int ext_couple_config_id,
char const * tgt_mask_name )

Sets target mask name

Parameters
[in]ext_couple_config_idextended coupling configuration
[in]tgt_mask_nametarget mask name

Definition at line 2333 of file yac.c.

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

◆ yac_cset_ext_couple_config_tgt_mask_name_()

void yac_cset_ext_couple_config_tgt_mask_name_ ( struct yac_ext_couple_config * ext_couple_config,
char const * tgt_mask_name )

Definition at line 2325 of file yac.c.

Here is the caller graph for this function:

◆ yac_cset_ext_couple_config_use_raw_exchange()

void yac_cset_ext_couple_config_use_raw_exchange ( int ext_couple_config_id,
int use_raw_exchange )

Sets use of raw exchange

Parameters
[in]ext_couple_config_idextended coupling configuration
[in]use_raw_exchangeuse raw exchange

Definition at line 2375 of file yac.c.

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

◆ yac_cset_ext_couple_config_use_raw_exchange_()

void yac_cset_ext_couple_config_use_raw_exchange_ ( struct yac_ext_couple_config * ext_couple_config,
int use_raw_exchange )

Definition at line 2369 of file yac.c.

Here is the caller graph for this function:

◆ yac_cset_ext_couple_config_weight_file()

void yac_cset_ext_couple_config_weight_file ( int ext_couple_config_id,
char const * weight_file )

Sets the weight file name

Parameters
[in]ext_couple_config_idextended coupling configuration
[in]weight_filename of a weight file
Remarks
if (weight_file == NULL) no weight file will be written
YAC will write out the weight file in parallel. This parallel output can be configured as described here: Configuration of parallel IO in YAC

Definition at line 2175 of file yac.c.

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

◆ yac_cset_ext_couple_config_weight_file_()

void yac_cset_ext_couple_config_weight_file_ ( struct yac_ext_couple_config * ext_couple_config,
char const * weight_file )

Definition at line 2167 of file yac.c.

Here is the caller graph for this function:

◆ yac_cset_ext_couple_config_weight_file_on_existing()

void yac_cset_ext_couple_config_weight_file_on_existing ( int ext_couple_config_id,
int weight_file_on_existing )

Specify handling of already existing weight files

Parameters
[in]ext_couple_config_idextended coupling configuration
[in]weight_file_on_existinghandling of existing weight files
Remarks
this only applies, if a weight file name was specified
Avaiable options:
See also
yac_cset_ext_couple_config_weight_file

Definition at line 2206 of file yac.c.

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

◆ yac_cset_ext_couple_config_weight_file_on_existing_()

void yac_cset_ext_couple_config_weight_file_on_existing_ ( struct yac_ext_couple_config * ext_couple_config,
int weight_file_on_existing )

Definition at line 2189 of file yac.c.

Here is the caller graph for this function:

◆ yac_cset_ext_couple_config_yaxt_exchanger_name()

void yac_cset_ext_couple_config_yaxt_exchanger_name ( int ext_couple_config_id,
char const * yaxt_exchanger_name )

Sets yaxt exchanger name

Parameters
[in]ext_couple_config_idextended coupling configuration
[in]yaxt_exchanger_nameyaxt exchange name

Definition at line 2355 of file yac.c.

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

◆ yac_cset_ext_couple_config_yaxt_exchanger_name_()

void yac_cset_ext_couple_config_yaxt_exchanger_name_ ( struct yac_ext_couple_config * ext_couple_config,
char const * yaxt_exchanger_name )

Definition at line 2347 of file yac.c.

Here is the caller graph for this function:

◆ yac_cset_ext_spmap_config_max_search_distance()

void yac_cset_ext_spmap_config_max_search_distance ( int ext_spmap_config_id,
double max_search_distance )

Sets the maximum search distance

Parameters
[out]ext_spmap_config_idextended source point mapping interpolation configuration
[in]max_search_distancemaximum search distance
See also
Extended configuration

Definition at line 6132 of file yac.c.

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

◆ yac_cset_ext_spmap_config_scale_type()

void yac_cset_ext_spmap_config_scale_type ( int ext_spmap_config_id,
int scale_type )

Sets the scaling type

Parameters
[out]ext_spmap_config_idextended source point mapping interpolation configuration
[in]scale_typescaling type
See also
Extended configuration

Definition at line 6158 of file yac.c.

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

◆ yac_cset_ext_spmap_config_spread_distance()

void yac_cset_ext_spmap_config_spread_distance ( int ext_spmap_config_id,
double spread_distance )

Sets the spread distance

Parameters
[out]ext_spmap_config_idextended source point mapping interpolation configuration
[in]spread_distancespread distance
See also
Extended configuration

Definition at line 6122 of file yac.c.

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

◆ yac_cset_ext_spmap_config_src_cell_area_config_file()

void yac_cset_ext_spmap_config_src_cell_area_config_file ( int ext_spmap_config_id,
char const * filename,
char const * varname,
int min_global_id )

enables the reading of the source cell areas for the scaling

Parameters
[out]ext_spmap_config_idextended source point mapping interpolation configuration
[in]filenamenetCDF file contain the cell areas
[in]varnamevariable name of cell areas
[in]min_global_idminimum global id
See also
Extended configuration

Definition at line 6257 of file yac.c.

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

◆ yac_cset_ext_spmap_config_src_cell_area_config_yac()

void yac_cset_ext_spmap_config_src_cell_area_config_yac ( int ext_spmap_config_id,
double sphere_radius )

enables the computation of the source cell areas by yac for the scaling

Parameters
[out]ext_spmap_config_idextended source point mapping interpolation configuration
[in]sphere_radiussphere radius
See also
Extended configuration

Definition at line 6176 of file yac.c.

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

◆ yac_cset_ext_spmap_config_tgt_cell_area_config_file()

void yac_cset_ext_spmap_config_tgt_cell_area_config_file ( int ext_spmap_config_id,
char const * filename,
char const * varname,
int min_global_id )

enables the reading of the target cell areas for the scaling

Parameters
[out]ext_spmap_config_idextended source point mapping interpolation configuration
[in]filenamenetCDF file contain the cell areas
[in]varnamevariable name of cell areas
[in]min_global_idminimum global id
See also
Extended configuration

Definition at line 6269 of file yac.c.

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

◆ yac_cset_ext_spmap_config_tgt_cell_area_config_yac()

void yac_cset_ext_spmap_config_tgt_cell_area_config_yac ( int ext_spmap_config_id,
double sphere_radius )

enables the computation of the target cell areas by yac

Parameters
[out]ext_spmap_config_idextended source point mapping interpolation configuration
[in]sphere_radiussphere radius
See also
Extended configuration

Definition at line 6194 of file yac.c.

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

◆ yac_cset_ext_spmap_config_weight_type()

void yac_cset_ext_spmap_config_weight_type ( int ext_spmap_config_id,
int weight_type )

Sets the weightening type

Parameters
[out]ext_spmap_config_idextended source point mapping interpolation configuration
[in]weight_typeweightening type
See also
Extended configuration

Definition at line 6142 of file yac.c.

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

◆ yac_cset_global_index()

void yac_cset_global_index ( int const * global_index,
int location,
int grid_id )

Set global ids for a grid

Parameters
[in]global_indexarray of global indices
[in]locationcell/vertex/edge
[in]grid_idgrid id
Remarks
global indices are to be provided in the local order of their respective cells/vertices/edges
Examples
dummy_atmosphere_c.c, dummy_io_c.c, and dummy_ocean_c.c.

Definition at line 5829 of file yac.c.

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

◆ yac_cset_global_index_yac_int()

void yac_cset_global_index_yac_int ( yac_int const * global_index,
int location,
int grid_id )

Set global ids for a grid

Parameters
[in]global_indexarray of global indices
[in]locationcell/vertex/edge
[in]grid_idgrid id
Remarks
global indices are to be provided in the local order of their respective cells/vertices/edges
Internally global ids are stored using the integer type yac_int, which depending on the configuration can have different sizes (e.g. int or long).
It is prefered to use this interface over yac_cset_global_index.

Definition at line 5816 of file yac.c.

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

◆ yac_cset_grid_output_file()

void yac_cset_grid_output_file ( const char * gridname,
const char * filename )

Activates writing out of the grid data

Parameters
[in]gridnamename of the grid to be written
[in]filenamename of the file to be written
Remarks
the writing is done in parallel (see Configuration of parallel IO in YAC)

Definition at line 930 of file yac.c.

Here is the call graph for this function:

◆ yac_cset_grid_output_file_instance()

void yac_cset_grid_output_file_instance ( int yac_instance_id,
const char * gridname,
const char * filename )

Activates writing out of the grid data

Parameters
[in]yac_instance_idYAC instance_id
[in]gridnamename of the grid to be written
[in]filenamename of the file to be written
Remarks
the writing is done in parallel (see Configuration of parallel IO in YAC)

Definition at line 913 of file yac.c.

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

◆ yac_cset_mask()

void yac_cset_mask ( int const * is_valid,
int points_id )

Set the default mask for points

Parameters
[in]is_valid0 for points that are masked out, 1 for valid points
[in]points_idid of points/cells
Examples
dummy_atmosphere_c.c, dummy_io_c.c, and dummy_ocean_c.c.

Definition at line 1879 of file yac.c.

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

◆ yac_cset_spmap_overwrite_config_max_search_distance()

void yac_cset_spmap_overwrite_config_max_search_distance ( int spmap_overwrite_config_id,
double max_search_distance )

Sets the maximum search distance

Parameters
[out]spmap_overwrite_config_idsource point mapping interpolation overwrite configuration
[in]max_search_distancemaximum search distance
See also
Extended configuration

Definition at line 6337 of file yac.c.

Here is the call graph for this function:

◆ yac_cset_spmap_overwrite_config_spread_distance()

void yac_cset_spmap_overwrite_config_spread_distance ( int spmap_overwrite_config_id,
double spread_distance )

Sets the spread distance

Parameters
[out]spmap_overwrite_config_idsource point mapping interpolation overwrite configuration
[in]spread_distancespread distance
See also
Extended configuration

Definition at line 6327 of file yac.c.

Here is the call graph for this function:

◆ yac_cset_spmap_overwrite_config_src_point_selection_bnd_circle()

void yac_cset_spmap_overwrite_config_src_point_selection_bnd_circle ( int spmap_overwrite_config_id,
double center_lon,
double center_lat,
double inc_angle )

Sets the source point selection method to a bounding circle

Parameters
[out]spmap_overwrite_config_idsource point mapping interpolation overwrite configuration
[in]center_lonlongitude coordinate of the center of the bounding circle (in radians)
[in]center_latlatitude coordinate of the center of the bounding circle (in radians)
[in]inc_anglethe angle between center vector and a vector pointing to any point on the bounding circle (in radians)
See also
Extended configuration

Definition at line 6309 of file yac.c.

Here is the call graph for this function:

◆ yac_cset_spmap_overwrite_config_weight_type()

void yac_cset_spmap_overwrite_config_weight_type ( int spmap_overwrite_config_id,
int weight_type )

Sets the weightening type

Parameters
[out]spmap_overwrite_config_idsource point mapping interpolation overwrite configuration
[in]weight_typeweightening type
See also
Extended configuration

Definition at line 6347 of file yac.c.

Here is the call graph for this function:

◆ yac_csync_def()

void yac_csync_def ( void )

synchronize grids and fields of the default instance

Definition at line 5000 of file yac.c.

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

◆ yac_csync_def_comps()

void yac_csync_def_comps ( char const ** comp_names,
int num_comp_names )

synchronize definitions between components of the default instance

Parameters
[in]comp_namescomponent names
[in]num_comp_namesnumber of entries in comp_names
Remarks
This call is collective of all processes that defined of the defined processes.
All processes involved in this call have to provide the same list of component names.
In contrast to yac_csync_def, this routine can be called an arbitrary number of times.

Definition at line 5012 of file yac.c.

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

◆ yac_csync_def_comps_instance()

void yac_csync_def_comps_instance ( int yac_instance_id,
char const ** comp_names,
int num_comp_names )

synchronize definitions between provided components

Parameters
[in]yac_instance_idid of the YAC instance
[in]comp_namescomponent names
[in]num_comp_namesnumber of entries in comp_names
Remarks
This call is collective of all processes that defined of the defined processes.
All processes involved in this call have to provide the same list of component names.
In contrast to yac_csync_def_instance, this routine can be called an arbitrary number of times.

Definition at line 5005 of file yac.c.

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

◆ yac_csync_def_instance()

void yac_csync_def_instance ( int yac_instance_id)

synchronize grids and fields

Parameters
[in]yac_instance_idid of the YAC instance

Definition at line 4992 of file yac.c.

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

◆ yac_ctest()

void yac_ctest ( int field_id,
int * flag )

Determines whether there is an asynchronous communication associated with a field, which is not yet completed (for example by a previous put)

Parameters
[in]field_id
[out]flag"0" if there is an uncompleted asynchronous communication associated with the field, "1" otherwise

Definition at line 3822 of file yac.c.

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

◆ yac_cupdate()

void yac_cupdate ( int field_id)

If the action for the current timestep is YAC_ACTION_NONE, this routine will advance the internal clock to next timestep.

Parameters
[in]field_idfield id returned by yac_cdef_field
Remarks
If this routine is called before yac_cenddef, the behaviour is undefined.
This routine can be called instead of yac_cput or yac_cget, if these routines would not have taken any action for the current timestep, in order to advance the internal clock.

Definition at line 3040 of file yac.c.

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

◆ yac_cupdate_()

static void yac_cupdate_ ( struct coupling_field * cpl_field,
struct event * event,
int is_source )
inlinestatic

Definition at line 3021 of file yac.c.

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

◆ yac_cwait()

void yac_cwait ( int field_id)

Waits until all previous asynchronous communication associated with a field is completed (for example by a previous put)

Parameters
[in]field_id

Definition at line 3846 of file yac.c.

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

◆ yac_cyaml_get_emitter_flag_default_c2f()

int yac_cyaml_get_emitter_flag_default_c2f ( )

Definition at line 829 of file yac.c.

◆ yac_cyaml_get_emitter_flag_json_c2f()

int yac_cyaml_get_emitter_flag_json_c2f ( )

Definition at line 833 of file yac.c.

◆ yac_free_global_components()

static void yac_free_global_components ( )
static

Definition at line 568 of file yac.c.

Here is the caller graph for this function:

◆ yac_free_global_grids()

static void yac_free_global_grids ( )
static

Definition at line 527 of file yac.c.

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

◆ yac_free_global_interp_stack_configs()

static void yac_free_global_interp_stack_configs ( )
static

Definition at line 581 of file yac.c.

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

◆ yac_free_global_masks()

static void yac_free_global_masks ( )
static

Definition at line 555 of file yac.c.

Here is the caller graph for this function:

◆ yac_free_global_points()

static void yac_free_global_points ( )
static

Definition at line 542 of file yac.c.

Here is the caller graph for this function:

◆ yac_free_pointer_unique_lookup()

static void yac_free_pointer_unique_lookup ( )
static

frees all memory used for the pointer/unique_id conversion

Remarks
this should only be called after the last call to yac_pointer_to_unique_id and yac_unique_id_to_pointer, because afterwards yac_unique_id_to_pointer will not be able to return the respective pointers for previously valid unique ids

Definition at line 315 of file yac.c.

Here is the caller graph for this function:

◆ yac_get()

static void yac_get ( int const field_id,
int collection_size,
double ** recv_field,
int is_async,
int * info,
int * ierr )
static

Definition at line 3231 of file yac.c.

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

◆ yac_get_()

void yac_get_ ( int const field_id,
int const collection_size,
double * recv_field,
int is_async,
int * info,
int * ierr )

Definition at line 3324 of file yac.c.

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

◆ yac_get_comp_comm_f2c()

void yac_get_comp_comm_f2c ( int comp_id,
MPI_Fint * comp_comm_f )

Definition at line 1171 of file yac.c.

Here is the call graph for this function:

◆ yac_get_field_get_mask_c2f()

void * yac_get_field_get_mask_c2f ( int field_id)

Definition at line 3886 of file yac.c.

Here is the call graph for this function:

◆ yac_get_field_put_mask_c2f()

void * yac_get_field_put_mask_c2f ( int field_id)

Definition at line 3878 of file yac.c.

Here is the call graph for this function:

◆ yac_get_raw_frac()

void yac_get_raw_frac ( int const field_id,
int const collection_size,
double *** src_field_buffer,
double *** src_frac_mask_buffer,
int is_async,
int * info,
int * ierror )

Definition at line 3252 of file yac.c.

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

◆ yac_get_raw_frac_()

void yac_get_raw_frac_ ( int const field_id,
int const collection_size,
double * src_field_buffer,
double * src_frac_mask_buffer,
int is_async,
int * info,
int * ierr )

Definition at line 3388 of file yac.c.

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

◆ yac_get_raw_frac_ptr_()

static void yac_get_raw_frac_ptr_ ( int const field_id,
int const collection_size,
double ** src_field_buffer,
double ** src_frac_mask_buffer,
int is_async,
int * info,
int * ierr )
static

Definition at line 3423 of file yac.c.

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

◆ yac_init()

static int yac_init ( MPI_Comm comm)
static

Definition at line 685 of file yac.c.

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

◆ yac_invalidate_unique_id()

static void yac_invalidate_unique_id ( int id)
static

marks the given id as invalid by pointing its table entry to a sentinel, so that a future allocation at the same address is not confused with the already freed object

Parameters
[in]idid previously returned by yac_pointer_to_unique_id

Definition at line 328 of file yac.c.

Here is the caller graph for this function:

◆ yac_lookup_pointer()

static int yac_lookup_pointer ( void const * pointer)
static

gives the unique index associated with pointer

Parameters
[in]pointer
Returns
unique value associated to pointer
Remarks
the pointer has to have been registers using yac_pointer_to_unique_id, otherwise this routine returns INT_MAX

Definition at line 300 of file yac.c.

Here is the caller graph for this function:

◆ yac_pointer_to_unique_id()

static int yac_pointer_to_unique_id ( void * pointer)
static

gives a unique index for a given pointer

Parameters
[in]pointer
Returns
unique value associated to pointer
See also
unique_id_to_pointer

Definition at line 261 of file yac.c.

Here is the caller graph for this function:

◆ yac_unique_id_to_pointer()

static void * yac_unique_id_to_pointer ( int id,
char const * id_name )
static

gives the pointer that is associated to the given id

Parameters
[in]idunique index previously returned by pointer_to_unique_id
[in]id_namename of the id
Returns
pointer the is associated to the given id
NULL if the id is invalid

Definition at line 280 of file yac.c.

Here is the caller graph for this function:

Variable Documentation

◆ default_instance_id

int default_instance_id = INT_MAX
static

Definition at line 171 of file yac.c.

◆ global_components

struct user_input_data_component** global_components = NULL
static

Definition at line 181 of file yac.c.

◆ global_grids

struct user_input_data_grid** global_grids = NULL
static

Definition at line 178 of file yac.c.

◆ global_interp_stack_configs

struct yac_interp_stack_config** global_interp_stack_configs = NULL
static

Definition at line 190 of file yac.c.

◆ global_masks

struct user_input_data_masks** global_masks = NULL
static

Definition at line 187 of file yac.c.

◆ global_points

struct user_input_data_points** global_points = NULL
static

Definition at line 184 of file yac.c.

◆ mpi_handshake_group_name

const char* mpi_handshake_group_name = "yac"
static

Name of the MPI group used by YAC in MPI handshake.

Definition at line 169 of file yac.c.

◆ num_global_components

size_t num_global_components = 0
static

Definition at line 182 of file yac.c.

◆ num_global_grids

size_t num_global_grids = 0
static

Definition at line 179 of file yac.c.

◆ num_global_interp_stack_configs

size_t num_global_interp_stack_configs = 0
static

Definition at line 191 of file yac.c.

◆ num_global_masks

size_t num_global_masks = 0
static

Definition at line 188 of file yac.c.

◆ num_global_points

size_t num_global_points = 0
static

Definition at line 185 of file yac.c.

◆ pointer_lookup_table

void** pointer_lookup_table = NULL
static

Definition at line 175 of file yac.c.

◆ pointer_lookup_table_size

int pointer_lookup_table_size = 0
static

Definition at line 176 of file yac.c.

◆ YAC_ACTION_COUPLING

int const YAC_ACTION_COUPLING = COUPLING

data exchange

Definition at line 48 of file yac.c.

◆ YAC_ACTION_GET_FOR_CHECKPOINT

int const YAC_ACTION_GET_FOR_CHECKPOINT = GET_FOR_CHECKPOINT

Definition at line 52 of file yac.c.

◆ YAC_ACTION_GET_FOR_RESTART

int const YAC_ACTION_GET_FOR_RESTART = GET_FOR_RESTART

last valid get

Definition at line 50 of file yac.c.

◆ YAC_ACTION_NONE

int const YAC_ACTION_NONE = NONE

no data exchanges

Definition at line 46 of file yac.c.

◆ YAC_ACTION_OUT_OF_BOUND

int const YAC_ACTION_OUT_OF_BOUND = OUT_OF_BOUND

put/get is outside of the valid range

Definition at line 54 of file yac.c.

◆ YAC_ACTION_PUT_FOR_CHECKPOINT

int const YAC_ACTION_PUT_FOR_CHECKPOINT = PUT_FOR_CHECKPOINT

Definition at line 53 of file yac.c.

◆ YAC_ACTION_PUT_FOR_RESTART

int const YAC_ACTION_PUT_FOR_RESTART = PUT_FOR_RESTART

last valid put

Definition at line 51 of file yac.c.

◆ YAC_ACTION_REDUCTION

int const YAC_ACTION_REDUCTION = REDUCTION

data reduction, but data exchange

Definition at line 47 of file yac.c.

◆ YAC_ACTION_RESTART

int const YAC_ACTION_RESTART = RESTART

Definition at line 49 of file yac.c.

◆ YAC_AVG_ARITHMETIC

int const YAC_AVG_ARITHMETIC = YAC_INTERP_AVG_ARITHMETIC

Definition at line 76 of file yac.c.

◆ YAC_AVG_BARY

int const YAC_AVG_BARY = YAC_INTERP_AVG_BARY

Definition at line 78 of file yac.c.

◆ YAC_AVG_DIST

int const YAC_AVG_DIST = YAC_INTERP_AVG_DIST

Definition at line 77 of file yac.c.

◆ YAC_CALENDAR_NOT_SET

int const YAC_CALENDAR_NOT_SET = CALENDAR_NOT_SET

Definition at line 71 of file yac.c.

◆ YAC_CONFIG_OUTPUT_FORMAT_JSON

int const YAC_CONFIG_OUTPUT_FORMAT_JSON = YAC_TEXT_FILETYPE_JSON

Definition at line 117 of file yac.c.

◆ YAC_CONFIG_OUTPUT_FORMAT_YAML

int const YAC_CONFIG_OUTPUT_FORMAT_YAML = YAC_TEXT_FILETYPE_YAML

Definition at line 116 of file yac.c.

◆ YAC_CONFIG_OUTPUT_SYNC_LOC_DEF_COMP

int const YAC_CONFIG_OUTPUT_SYNC_LOC_DEF_COMP
Initial value:

after component definition

Definition at line 129 of file yac.c.

◆ YAC_CONFIG_OUTPUT_SYNC_LOC_ENDDEF

int const YAC_CONFIG_OUTPUT_SYNC_LOC_ENDDEF
Initial value:

after end of definitions

Definition at line 133 of file yac.c.

◆ YAC_CONFIG_OUTPUT_SYNC_LOC_SYNC_DEF

int const YAC_CONFIG_OUTPUT_SYNC_LOC_SYNC_DEF
Initial value:

after synchronization of definition

Definition at line 131 of file yac.c.

◆ YAC_CONSERV_DESTAREA

int const YAC_CONSERV_DESTAREA = YAC_INTERP_CONSERV_DESTAREA

Definition at line 97 of file yac.c.

◆ YAC_CONSERV_FRACAREA

int const YAC_CONSERV_FRACAREA = YAC_INTERP_CONSERV_FRACAREA

Definition at line 98 of file yac.c.

◆ YAC_DNN_AVG

int const YAC_DNN_AVG = YAC_INTERP_DNN_WEIGHT_AVG

Definition at line 89 of file yac.c.

◆ YAC_DNN_DIST

int const YAC_DNN_DIST = YAC_INTERP_DNN_WEIGHT_DIST

Definition at line 90 of file yac.c.

◆ YAC_DNN_GAUSS

int const YAC_DNN_GAUSS = YAC_INTERP_DNN_WEIGHT_GAUSS

Definition at line 91 of file yac.c.

◆ YAC_DNN_RBF

int const YAC_DNN_RBF = YAC_INTERP_DNN_WEIGHT_RBF

Definition at line 92 of file yac.c.

◆ YAC_DNN_SEARCH_DISTANCE_CELL_AREA

int const YAC_DNN_SEARCH_DISTANCE_CELL_AREA = YAC_INTERP_DNN_SEARCH_DISTANCE_CELL_AREA

Definition at line 95 of file yac.c.

◆ YAC_DNN_SEARCH_DISTANCE_FIXED

int const YAC_DNN_SEARCH_DISTANCE_FIXED = YAC_INTERP_DNN_SEARCH_DISTANCE_FIXED

Definition at line 94 of file yac.c.

◆ YAC_EXCHANGE_TYPE_INVALID

int const YAC_EXCHANGE_TYPE_INVALID = INVALID

Definition at line 41 of file yac.c.

◆ YAC_EXCHANGE_TYPE_NONE

int const YAC_EXCHANGE_TYPE_NONE = NOTHING

Definition at line 42 of file yac.c.

◆ YAC_EXCHANGE_TYPE_SOURCE

int const YAC_EXCHANGE_TYPE_SOURCE = SOURCE

Definition at line 43 of file yac.c.

◆ YAC_EXCHANGE_TYPE_TARGET

int const YAC_EXCHANGE_TYPE_TARGET = TARGET

Definition at line 44 of file yac.c.

◆ YAC_FILE_MISSING_CONT

int const YAC_FILE_MISSING_CONT = YAC_INTERP_FILE_MISSING_CONT

continue on missing file

Definition at line 109 of file yac.c.

◆ YAC_FILE_MISSING_ERROR

int const YAC_FILE_MISSING_ERROR = YAC_INTERP_FILE_MISSING_ERROR

abort on missing file

Definition at line 108 of file yac.c.

◆ YAC_FILE_SUCCESS_CONT

int const YAC_FILE_SUCCESS_CONT = YAC_INTERP_FILE_SUCCESS_CONT

continue weight computation with following interpolation methods

Definition at line 113 of file yac.c.

◆ YAC_FILE_SUCCESS_STOP

int const YAC_FILE_SUCCESS_STOP = YAC_INTERP_FILE_SUCCESS_STOP

prevents following interpolation method from computating further weights

Definition at line 111 of file yac.c.

◆ yac_instance_count

int yac_instance_count = 0
static

Definition at line 173 of file yac.c.

◆ yac_invalid_pointer_sentinel

int yac_invalid_pointer_sentinel
static

sentinel value used by yac_invalidate_unique_id to mark an id as invalid; its address can never be returned by malloc, so it will never be confused with a live registered pointer

Definition at line 253 of file yac.c.

◆ YAC_LOCATION_CELL

int const YAC_LOCATION_CELL = YAC_LOC_CELL
Examples
dummy_atmosphere_c.c, dummy_io_c.c, and dummy_ocean_c.c.

Definition at line 37 of file yac.c.

◆ YAC_LOCATION_CORNER

int const YAC_LOCATION_CORNER = YAC_LOC_CORNER

Definition at line 38 of file yac.c.

◆ YAC_LOCATION_EDGE

int const YAC_LOCATION_EDGE = YAC_LOC_EDGE

Definition at line 39 of file yac.c.

◆ YAC_NCC_AVG

int const YAC_NCC_AVG = YAC_INTERP_NCC_AVG

Definition at line 80 of file yac.c.

◆ YAC_NCC_DIST

int const YAC_NCC_DIST = YAC_INTERP_NCC_DIST

Definition at line 81 of file yac.c.

◆ YAC_NNN_AVG

int const YAC_NNN_AVG = YAC_INTERP_NNN_AVG

Definition at line 83 of file yac.c.

◆ YAC_NNN_DIST

int const YAC_NNN_DIST = YAC_INTERP_NNN_DIST

Definition at line 84 of file yac.c.

◆ YAC_NNN_GAUSS

int const YAC_NNN_GAUSS = YAC_INTERP_NNN_GAUSS

Definition at line 85 of file yac.c.

◆ YAC_NNN_RBF

int const YAC_NNN_RBF = YAC_INTERP_NNN_RBF

Definition at line 86 of file yac.c.

◆ YAC_NNN_ZERO

int const YAC_NNN_ZERO = YAC_INTERP_NNN_ZERO

Definition at line 87 of file yac.c.

◆ YAC_PROLEPTIC_GREGORIAN

int const YAC_PROLEPTIC_GREGORIAN = PROLEPTIC_GREGORIAN

Definition at line 72 of file yac.c.

◆ YAC_REDUCTION_TIME_ACCUMULATE

int const YAC_REDUCTION_TIME_ACCUMULATE = TIME_ACCUMULATE

Definition at line 57 of file yac.c.

◆ YAC_REDUCTION_TIME_AVERAGE

int const YAC_REDUCTION_TIME_AVERAGE = TIME_AVERAGE

Definition at line 58 of file yac.c.

◆ YAC_REDUCTION_TIME_MAXIMUM

int const YAC_REDUCTION_TIME_MAXIMUM = TIME_MAXIMUM

Definition at line 60 of file yac.c.

◆ YAC_REDUCTION_TIME_MINIMUM

int const YAC_REDUCTION_TIME_MINIMUM = TIME_MINIMUM

Definition at line 59 of file yac.c.

◆ YAC_REDUCTION_TIME_NONE

int const YAC_REDUCTION_TIME_NONE = TIME_NONE

Definition at line 56 of file yac.c.

◆ YAC_SPMAP_AVG

int const YAC_SPMAP_AVG = YAC_INTERP_SPMAP_AVG

Definition at line 100 of file yac.c.

◆ YAC_SPMAP_DIST

int const YAC_SPMAP_DIST = YAC_INTERP_SPMAP_DIST

Definition at line 101 of file yac.c.

◆ YAC_SPMAP_FRACAREA

int const YAC_SPMAP_FRACAREA = YAC_INTERP_SPMAP_FRACAREA

Definition at line 106 of file yac.c.

◆ YAC_SPMAP_INVTGTAREA

int const YAC_SPMAP_INVTGTAREA = YAC_INTERP_SPMAP_INVTGTAREA

Definition at line 105 of file yac.c.

◆ YAC_SPMAP_NONE

int const YAC_SPMAP_NONE = YAC_INTERP_SPMAP_NONE

Definition at line 103 of file yac.c.

◆ YAC_SPMAP_SRCAREA

int const YAC_SPMAP_SRCAREA = YAC_INTERP_SPMAP_SRCAREA

Definition at line 104 of file yac.c.

◆ YAC_TIME_UNIT_DAY

int const YAC_TIME_UNIT_DAY = C_DAY

Definition at line 66 of file yac.c.

◆ YAC_TIME_UNIT_HOUR

int const YAC_TIME_UNIT_HOUR = C_HOUR

Definition at line 65 of file yac.c.

◆ YAC_TIME_UNIT_ISO_FORMAT

int const YAC_TIME_UNIT_ISO_FORMAT = C_ISO_FORMAT

Definition at line 69 of file yac.c.

◆ YAC_TIME_UNIT_MILLISECOND

int const YAC_TIME_UNIT_MILLISECOND = C_MILLISECOND

Definition at line 62 of file yac.c.

◆ YAC_TIME_UNIT_MINUTE

int const YAC_TIME_UNIT_MINUTE = C_MINUTE

Definition at line 64 of file yac.c.

◆ YAC_TIME_UNIT_MONTH

int const YAC_TIME_UNIT_MONTH = C_MONTH

Definition at line 67 of file yac.c.

◆ YAC_TIME_UNIT_SECOND

int const YAC_TIME_UNIT_SECOND = C_SECOND
Examples
dummy_atmosphere_c.c, dummy_io_c.c, and dummy_ocean_c.c.

Definition at line 63 of file yac.c.

◆ YAC_TIME_UNIT_YEAR

int const YAC_TIME_UNIT_YEAR = C_YEAR

Definition at line 68 of file yac.c.

◆ YAC_WGT_ON_EXISTING_ERROR

int const YAC_WGT_ON_EXISTING_ERROR = YAC_WEIGHT_FILE_ERROR

generate error and abort, if file with the same name already existis

Definition at line 119 of file yac.c.

◆ YAC_WGT_ON_EXISTING_KEEP

int const YAC_WGT_ON_EXISTING_KEEP = YAC_WEIGHT_FILE_KEEP

keep existing weight file

Definition at line 120 of file yac.c.

◆ YAC_WGT_ON_EXISTING_OVERWRITE

int const YAC_WGT_ON_EXISTING_OVERWRITE = YAC_WEIGHT_FILE_OVERWRITE

overwrite existing weight file

Definition at line 121 of file yac.c.

◆ YAC_YEAR_OF_360_DAYS

int const YAC_YEAR_OF_360_DAYS = YEAR_OF_360_DAYS

Definition at line 74 of file yac.c.

◆ YAC_YEAR_OF_365_DAYS

int const YAC_YEAR_OF_365_DAYS = YEAR_OF_365_DAYS

Definition at line 73 of file yac.c.