9.2
general documentation
cs_paramedmem_coupling.cxx File Reference
#include "base/cs_defs.h"
#include <stdarg.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <assert.h>
#include <math.h>
#include <mpi.h>
#include <ple_coupling.h>
#include "bft/bft_error.h"
#include "bft/bft_printf.h"
#include "base/cs_array.h"
#include "base/cs_coupling.h"
#include "base/cs_mem.h"
#include "base/cs_parall.h"
#include "base/cs_prototypes.h"
#include "base/cs_selector.h"
#include "base/cs_timer.h"
#include "mesh/cs_mesh.h"
#include "mesh/cs_mesh_connect.h"
#include "fvm/fvm_defs.h"
#include "fvm/fvm_nodal_from_desc.h"
#include "base/cs_paramedmem_coupling_utils.h"
+ Include dependency graph for cs_paramedmem_coupling.cxx:

Functions

cs_paramedmem_coupling_t * cs_paramedmem_coupling_by_id (int cpl_id)
 Retrieve coupling struct pointer by id. More...
 
cs_paramedmem_coupling_t * cs_paramedmem_coupling_by_name (const char *name)
 Retrieve coupling struct pointer by name. More...
 
cs_paramedmem_coupling_t * cs_paramedmem_coupling_create (const char *app1_name, const char *app2_name, const char *cpl_name, cs_medcpl_dec_t type_dec)
 Create a new ParaMEDMEM coupling. More...
 
cs_paramedmem_coupling_t * cs_paramedmem_coupling_create_uncoupled (const char *cpl_name)
 Create a new ParaMEDMEM handler structure with no actual coupling. More...
 
void cs_paramedmem_coupling_destroy (cs_paramedmem_coupling_t *c)
 Destroy a given ParaMEDMEM coupling structure. More...
 
void cs_paramedmem_coupling_all_finalize (void)
 Destroy all coupling structures. More...
 
int cs_paramedmem_get_number_of_couplings (void)
 Get number of defined couplings. More...
 
void cs_paramedmem_coupling_log_setup (void)
 Log ParaMEDMEM coupling setup information. More...
 
void cs_paramedmem_coupling_all_init (void)
 initialize couplings based on user functions. More...
 
void cs_paramedmem_coupling_define_mesh_fields (void)
 initialize coupled mesh and fields based on user functions. More...
 

Variables

static constexpr bool CS_PARAMEDMEM_DBG = false
 

Function Documentation

◆ cs_paramedmem_coupling_all_finalize()

void cs_paramedmem_coupling_all_finalize ( void  )

Destroy all coupling structures.

◆ cs_paramedmem_coupling_all_init()

void cs_paramedmem_coupling_all_init ( void  )

initialize couplings based on user functions.

◆ cs_paramedmem_coupling_by_id()

cs_paramedmem_coupling_t * cs_paramedmem_coupling_by_id ( int  cpl_id)

Retrieve coupling struct pointer by id.

Parameters
[in]cpl_idindex of the sought coupling
Returns
pointer to cs_paramedmem_coupling_t struct. Raise an error if the coupling does not exist.

◆ cs_paramedmem_coupling_by_name()

cs_paramedmem_coupling_t * cs_paramedmem_coupling_by_name ( const char *  name)

Retrieve coupling struct pointer by name.

Parameters
[in]namename of the coupling
Returns
pointer to cs_paramedmem_coupling_t struct or null if not found.

◆ cs_paramedmem_coupling_create()

cs_paramedmem_coupling_t * cs_paramedmem_coupling_create ( const char *  app1_name,
const char *  app2_name,
const char *  cpl_name,
cs_medcpl_dec_t  type_dec 
)

Create a new ParaMEDMEM coupling.

Parameters
[in]app1_nameName of app n°1 or null if calling app is app1
[in]app2_nameName of app n°2 or null if calling app is app2
[in]cpl_nameName of the coupling. If null an automatic name is generated.
[in]type_decType of DEC used for Data exchange
Returns
pointer to newly created cs_paramedmem_coupling_t structure.

◆ cs_paramedmem_coupling_create_uncoupled()

cs_paramedmem_coupling_t * cs_paramedmem_coupling_create_uncoupled ( const char *  cpl_name)

Create a new ParaMEDMEM handler structure with no actual coupling.

This can be useful for a "dry run" when setting up a coupling, so as to first debug local commands before actually running in coupled mode.

In this case, data "received" matches the initialized values.

Parameters
[in]cpl_nameName of the coupling. If null an automatic name is generated.
Returns
pointer to newly created cs_paramedmem_coupling_t structure.

◆ cs_paramedmem_coupling_define_mesh_fields()

void cs_paramedmem_coupling_define_mesh_fields ( void  )

initialize coupled mesh and fields based on user functions.

◆ cs_paramedmem_coupling_destroy()

void cs_paramedmem_coupling_destroy ( cs_paramedmem_coupling_t *  c)

Destroy a given ParaMEDMEM coupling structure.

Parameters
[in]cpointer to cs_paramedmem_coupling_t structure

◆ cs_paramedmem_coupling_log_setup()

void cs_paramedmem_coupling_log_setup ( void  )

Log ParaMEDMEM coupling setup information.

◆ cs_paramedmem_get_number_of_couplings()

int cs_paramedmem_get_number_of_couplings ( void  )

Get number of defined couplings.

Returns
number of defined couplings (int)

Variable Documentation

◆ CS_PARAMEDMEM_DBG

constexpr bool CS_PARAMEDMEM_DBG = false
staticconstexpr