programmer's documentation
Typedefs | Functions
cs_hodge.h File Reference
#include "cs_base.h"
#include "cs_time_step.h"
#include "cs_sla.h"
#include "cs_cdo_connect.h"
#include "cs_cdo_local.h"
#include "cs_cdo_quantities.h"
#include "cs_param.h"
#include "cs_property.h"
Include dependency graph for cs_hodge.h:

Go to the source code of this file.

Typedefs

typedef struct _hodge_builder_t cs_hodge_builder_t
 

Functions

void cs_hodge_set_timer_stats (int level)
 Initialize cs_timer_stats_t structure for monitoring purpose. More...
 
cs_hodge_builder_tcs_hodge_builder_init (const cs_cdo_connect_t *connect, cs_param_hodge_t h_info)
 Allocate and initialize a cs_hodge_builder_t structure. More...
 
cs_hodge_builder_tcs_hodge_builder_free (cs_hodge_builder_t *hb)
 Free a cs_hodge_builder_t structure. More...
 
bool cs_hodge_builder_get_setting_flag (cs_hodge_builder_t *hb)
 Get the flag indicating the status of the property. More...
 
void cs_hodge_builder_unset (cs_hodge_builder_t *hb)
 Set the flag indicating the status of the property to false. More...
 
void cs_hodge_builder_set_val (cs_hodge_builder_t *hb, cs_real_t ptyval)
 Set the value of the property attached to a hodge builder. More...
 
void cs_hodge_builder_set_tensor (cs_hodge_builder_t *hb, const cs_real_33_t ptymat)
 Set the value of the property attached to a hodge builder. More...
 
void cs_hodge_build_local_stiffness (const cs_cell_mesh_t *lm, cs_hodge_builder_t *hb, cs_locmat_t *sloc)
 Build a local stiffness matrix from a local discrete Hodge H and the local discrete gradient and divergence S = Gloc^t * H * Gloc. More...
 
cs_locmat_tcs_hodge_build_cellwise (const cs_cell_mesh_t *lm, cs_hodge_builder_t *hb)
 Build a local discrete Hodge using a cell-wise view of the mesh. More...
 
cs_locmat_tcs_hodge_build_local (int c_id, const cs_cdo_connect_t *connect, const cs_cdo_quantities_t *quant, cs_hodge_builder_t *hb)
 Build a local discrete Hodge. More...
 
cs_sla_matrix_tcs_hodge_compute (const cs_cdo_connect_t *connect, const cs_cdo_quantities_t *quant, const cs_property_t *pty, const cs_param_hodge_t h_info)
 Build the full matrix related to a discrete Hodge operator. More...
 

Typedef Documentation

§ cs_hodge_builder_t

typedef struct _hodge_builder_t cs_hodge_builder_t

Function Documentation

§ cs_hodge_build_cellwise()

cs_locmat_t* cs_hodge_build_cellwise ( const cs_cell_mesh_t cm,
cs_hodge_builder_t hb 
)

Build a local discrete Hodge using a cell-wise view of the mesh.

Parameters
[in]lmpointer to a cs_cell_mesh_t structure
[in,out]hbpointer to a cs_hodge_builder_t structure
Returns
a pointer to a cs_locmat_t struct. (local dense matrix)
Parameters
[in]cmpointer to a cs_cell_mesh_t structure
[in,out]hbpointer to a cs_hodge_builder_t structure
Returns
a pointer to a cs_locmat_t struct. (local dense matrix)

§ cs_hodge_build_local()

cs_locmat_t* cs_hodge_build_local ( int  c_id,
const cs_cdo_connect_t connect,
const cs_cdo_quantities_t quant,
cs_hodge_builder_t hb 
)

Build a local discrete Hodge.

Parameters
[in]c_idcell id
[in]connectpointer to a cs_cdo_connect_t struct.
[in]quantpointer to a cs_cdo_quantities_t struct.
[in,out]hbpointer to a cs_hodge_builder_t struct.
Returns
a pointer to a cs_locmat_t struct. (local dense matrix)

§ cs_hodge_build_local_stiffness()

void cs_hodge_build_local_stiffness ( const cs_cell_mesh_t cm,
cs_hodge_builder_t hb,
cs_locmat_t sloc 
)

Build a local stiffness matrix from a local discrete Hodge H and the local discrete gradient and divergence S = Gloc^t * H * Gloc.

Parameters
[in]lmpointer to a cs_cell_mesh_t struct.
[in,out]hbpointer to a cs_hodge_builder_t struct.
[in,out]slocpointer to a local stiffness matrix struct.
[in]cmpointer to a cs_cell_mesh_t struct.
[in,out]hbpointer to a cs_hodge_builder_t struct.
[in,out]slocpointer to a local stiffness matrix struct.

§ cs_hodge_builder_free()

cs_hodge_builder_t* cs_hodge_builder_free ( cs_hodge_builder_t hb)

Free a cs_hodge_builder_t structure.

Parameters
[in]hbpointer to the cs_hodge_builder_t struct. to free
Returns
a NULL pointer

§ cs_hodge_builder_get_setting_flag()

bool cs_hodge_builder_get_setting_flag ( cs_hodge_builder_t hb)

Get the flag indicating the status of the property.

Parameters
[in,out]hbpointer to a cs_hodge_builder_t structure
Returns
true or flase

§ cs_hodge_builder_init()

cs_hodge_builder_t* cs_hodge_builder_init ( const cs_cdo_connect_t connect,
cs_param_hodge_t  h_info 
)

Allocate and initialize a cs_hodge_builder_t structure.

Parameters
[in]connectpointer to a cs_cdo_connect_t struct.
[in]time_steppointer to a time step structure
[in]h_infoalgorithm used to build the discrete Hodge op.
Returns
a new allocated cs_hodge_builder_t structure
Parameters
[in]connectpointer to a cs_cdo_connect_t struct.
[in]h_infoalgorithm used to build the discrete Hodge op.
Returns
a new allocated cs_hodge_builder_t structure

§ cs_hodge_builder_set_tensor()

void cs_hodge_builder_set_tensor ( cs_hodge_builder_t hb,
const cs_real_33_t  ptymat 
)

Set the value of the property attached to a hodge builder.

Parameters
[in,out]hbpointer to a cs_hodge_builder_t structure
[in]ptymatvalues of the tensor related to a property

§ cs_hodge_builder_set_val()

void cs_hodge_builder_set_val ( cs_hodge_builder_t hb,
cs_real_t  ptyval 
)

Set the value of the property attached to a hodge builder.

Parameters
[in,out]hbpointer to a cs_hodge_builder_t structure
[in]ptyvalvalue of the property

§ cs_hodge_builder_unset()

void cs_hodge_builder_unset ( cs_hodge_builder_t hb)

Set the flag indicating the status of the property to false.

Parameters
[in,out]hbpointer to a cs_hodge_builder_t structure

§ cs_hodge_compute()

cs_sla_matrix_t* cs_hodge_compute ( const cs_cdo_connect_t connect,
const cs_cdo_quantities_t quant,
const cs_property_t *  pty,
const cs_param_hodge_t  h_info 
)

Build the full matrix related to a discrete Hodge operator.

Parameters
[in]connectpointer to a cs_cdo_connect_t struct.
[in]quantpointer to a cs_cdo_quantities_t struct.
[in]ptypointer to a cs_property_t struct.
[in]h_infopointer to a cs_param_hodge_t struct.
Returns
a pointer to a cs_sla_matrix_t structure

§ cs_hodge_set_timer_stats()

void cs_hodge_set_timer_stats ( int  level)

Initialize cs_timer_stats_t structure for monitoring purpose.

Parameters
[in]levellevel of details requested