programmer's documentation
Macros | Typedefs | Enumerations | Functions
cs_restart.h File Reference
#include "cs_defs.h"
#include "cs_time_step.h"
Include dependency graph for cs_restart.h:

Go to the source code of this file.

Macros

#define CS_RESTART_SUCCESS   0 /* Success */
 
#define CS_RESTART_ERR_FILE_NUM   -1 /* No restart file for the given number */
 
#define CS_RESTART_ERR_LOCATION   -2 /* Undefined location / incorrect size */
 
#define CS_RESTART_ERR_VAL_TYPE   -3 /* Unknown or unexpected value type */
 
#define CS_RESTART_ERR_N_VALS   -4 /* Number of values does not match */
 
#define CS_RESTART_ERR_MODE   -5 /* Incompatible access mode */
 
#define CS_RESTART_ERR_EXISTS   -6 /* Section not available */
 

Typedefs

typedef struct _cs_restart_t cs_restart_t
 

Enumerations

enum  cs_restart_mode_t { CS_RESTART_MODE_READ, CS_RESTART_MODE_WRITE }
 
enum  cs_restart_val_type_t { CS_TYPE_char, CS_TYPE_cs_int_t, CS_TYPE_cs_gnum_t, CS_TYPE_cs_real_t }
 

Functions

void dflsui (cs_int_t *ntsuit, cs_real_t *ttsuit, cs_real_t *wtsuit)
 
void reqsui (cs_int_t *iisuit)
 
void stusui (void)
 
void indsui (cs_int_t *isuite)
 
void cs_restart_checkpoint_set_defaults (int nt_interval, double t_interval, double wt_interval)
 
void cs_restart_checkpoint_set_next_ts (int nt_next)
 
void cs_restart_checkpoint_set_next_tv (double t_next)
 
void cs_restart_checkpoint_set_next_wt (double wt_next)
 
bool cs_restart_checkpoint_required (const cs_time_step_t *ts)
 
void cs_restart_checkpoint_done (const cs_time_step_t *ts)
 
int cs_restart_present (void)
 
cs_restart_tcs_restart_create (const char *name, const char *path, cs_restart_mode_t mode)
 
void cs_restart_destroy (cs_restart_t **restart)
 
void cs_restart_check_base_location (const cs_restart_t *restart, bool *match_cell, bool *match_i_face, bool *match_b_face, bool *match_vertex)
 
int cs_restart_add_location (cs_restart_t *restart, const char *location_name, cs_gnum_t n_glob_ents, cs_lnum_t n_ents, const cs_gnum_t *ent_global_num)
 
const char * cs_restart_get_name (const cs_restart_t *restart)
 
void cs_restart_dump_index (const cs_restart_t *restart)
 
int cs_restart_check_section (cs_restart_t *restart, const char *sec_name, int location_id, int n_location_vals, cs_restart_val_type_t val_type)
 
int cs_restart_read_section (cs_restart_t *restart, const char *sec_name, int location_id, int n_location_vals, cs_restart_val_type_t val_type, void *val)
 
void cs_restart_write_section (cs_restart_t *restart, const char *sec_name, int location_id, int n_location_vals, cs_restart_val_type_t val_type, const void *val)
 
int cs_restart_read_particles_info (cs_restart_t *restart, const char *name, cs_lnum_t *n_particles)
 
int cs_restart_read_particles (cs_restart_t *restart, int particles_location_id, cs_lnum_t *particle_cell_id, cs_real_t *particle_coords)
 
int cs_restart_write_particles (cs_restart_t *restart, const char *name, bool number_by_coords, cs_lnum_t n_particles, const cs_lnum_t *particle_cell_num, const cs_real_t *particle_coords)
 
int cs_restart_read_ids (cs_restart_t *restart, const char *sec_name, int location_id, int ref_location_id, cs_lnum_t ref_id_base, cs_lnum_t *ref_id)
 
void cs_restart_write_ids (cs_restart_t *restart, const char *sec_name, int location_id, int ref_location_id, cs_lnum_t ref_id_base, const cs_lnum_t *ref_id)
 
int cs_restart_read_section_compat (cs_restart_t *restart, const char *sec_name, const char *old_name, int location_id, int n_location_vals, cs_restart_val_type_t val_type, void *val)
 
int cs_restart_read_real_t_compat (cs_restart_t *restart, const char *sec_name, const char *old_name, int location_id, int n_location_vals, cs_real_t *val)
 
int cs_restart_read_real_3_t_compat (cs_restart_t *restart, const char *sec_name, const char *old_name_x, const char *old_name_y, const char *old_name_z, int location_id, cs_real_3_t *val)
 
int cs_restart_read_real_6_t_compat (cs_restart_t *restart, const char *sec_name, const char *old_name_xx, const char *old_name_yy, const char *old_name_zz, const char *old_name_xy, const char *old_name_yz, const char *old_name_xz, int location_id, cs_real_6_t *val)
 
int cs_restart_read_real_66_t_compat (cs_restart_t *restart, const char *sec_name, const char *old_name_xx, const char *old_name_yy, const char *old_name_zz, const char *old_name_xy, const char *old_name_yz, const char *old_name_xz, int location_id, cs_real_66_t *val)
 
void cs_restart_print_stats (void)
 

Macro Definition Documentation

#define CS_RESTART_ERR_EXISTS   -6 /* Section not available */
#define CS_RESTART_ERR_FILE_NUM   -1 /* No restart file for the given number */
#define CS_RESTART_ERR_LOCATION   -2 /* Undefined location / incorrect size */
#define CS_RESTART_ERR_MODE   -5 /* Incompatible access mode */
#define CS_RESTART_ERR_N_VALS   -4 /* Number of values does not match */
#define CS_RESTART_ERR_VAL_TYPE   -3 /* Unknown or unexpected value type */
#define CS_RESTART_SUCCESS   0 /* Success */

Typedef Documentation

typedef struct _cs_restart_t cs_restart_t

Enumeration Type Documentation

Enumerator
CS_RESTART_MODE_READ 
CS_RESTART_MODE_WRITE 
Enumerator
CS_TYPE_char 
CS_TYPE_cs_int_t 
CS_TYPE_cs_gnum_t 
CS_TYPE_cs_real_t 

Function Documentation

int cs_restart_add_location ( cs_restart_t restart,
const char *  location_name,
cs_gnum_t  n_glob_ents,
cs_lnum_t  n_ents,
const cs_gnum_t ent_global_num 
)
void cs_restart_check_base_location ( const cs_restart_t restart,
bool *  match_cell,
bool *  match_i_face,
bool *  match_b_face,
bool *  match_vertex 
)
int cs_restart_check_section ( cs_restart_t restart,
const char *  sec_name,
int  location_id,
int  n_location_vals,
cs_restart_val_type_t  val_type 
)
void cs_restart_checkpoint_done ( const cs_time_step_t ts)
bool cs_restart_checkpoint_required ( const cs_time_step_t ts)
void cs_restart_checkpoint_set_defaults ( int  nt_interval,
double  t_interval,
double  wt_interval 
)
void cs_restart_checkpoint_set_next_ts ( int  nt_next)
void cs_restart_checkpoint_set_next_tv ( double  t_next)
void cs_restart_checkpoint_set_next_wt ( double  wt_next)
cs_restart_t* cs_restart_create ( const char *  name,
const char *  path,
cs_restart_mode_t  mode 
)
void cs_restart_destroy ( cs_restart_t **  restart)
void cs_restart_dump_index ( const cs_restart_t restart)
const char* cs_restart_get_name ( const cs_restart_t restart)
int cs_restart_present ( void  )
void cs_restart_print_stats ( void  )
int cs_restart_read_ids ( cs_restart_t restart,
const char *  sec_name,
int  location_id,
int  ref_location_id,
cs_lnum_t  ref_id_base,
cs_lnum_t ref_id 
)
int cs_restart_read_particles ( cs_restart_t restart,
int  particles_location_id,
cs_lnum_t particle_cell_id,
cs_real_t particle_coords 
)
int cs_restart_read_particles_info ( cs_restart_t restart,
const char *  name,
cs_lnum_t n_particles 
)
int cs_restart_read_real_3_t_compat ( cs_restart_t restart,
const char *  sec_name,
const char *  old_name_x,
const char *  old_name_y,
const char *  old_name_z,
int  location_id,
cs_real_3_t val 
)
int cs_restart_read_real_66_t_compat ( cs_restart_t restart,
const char *  sec_name,
const char *  old_name_xx,
const char *  old_name_yy,
const char *  old_name_zz,
const char *  old_name_xy,
const char *  old_name_yz,
const char *  old_name_xz,
int  location_id,
cs_real_66_t val 
)
int cs_restart_read_real_6_t_compat ( cs_restart_t restart,
const char *  sec_name,
const char *  old_name_xx,
const char *  old_name_yy,
const char *  old_name_zz,
const char *  old_name_xy,
const char *  old_name_yz,
const char *  old_name_xz,
int  location_id,
cs_real_6_t val 
)
int cs_restart_read_real_t_compat ( cs_restart_t restart,
const char *  sec_name,
const char *  old_name,
int  location_id,
int  n_location_vals,
cs_real_t val 
)
int cs_restart_read_section ( cs_restart_t restart,
const char *  sec_name,
int  location_id,
int  n_location_vals,
cs_restart_val_type_t  val_type,
void *  val 
)
int cs_restart_read_section_compat ( cs_restart_t restart,
const char *  sec_name,
const char *  old_name,
int  location_id,
int  n_location_vals,
cs_restart_val_type_t  val_type,
void *  val 
)
void cs_restart_write_ids ( cs_restart_t restart,
const char *  sec_name,
int  location_id,
int  ref_location_id,
cs_lnum_t  ref_id_base,
const cs_lnum_t ref_id 
)
int cs_restart_write_particles ( cs_restart_t restart,
const char *  name,
bool  number_by_coords,
cs_lnum_t  n_particles,
const cs_lnum_t particle_cell_num,
const cs_real_t particle_coords 
)
void cs_restart_write_section ( cs_restart_t restart,
const char *  sec_name,
int  location_id,
int  n_location_vals,
cs_restart_val_type_t  val_type,
const void *  val 
)
void dflsui ( cs_int_t ntsuit,
cs_real_t ttsuit,
cs_real_t wtsuit 
)
void indsui ( cs_int_t isuite)
void reqsui ( cs_int_t iisuit)
void stusui ( void  )