| Gerris Flow Solver Reference Manual |
|---|
#include <gfs.h> #define GFS_BOUNDARY_CLASS (klass) #define GFS_BOUNDARY (obj) #define GFS_IS_BOUNDARY (obj) GfsBoundaryClass; GfsBoundary; enum GfsBoundaryVariableType; GfsBoundary* gfs_boundary_new (GfsBoundaryClass *klass, GfsBox *box, FttDirection d); GfsBoundaryClass* gfs_boundary_class (void);void gfs_boundary_send (GfsBoundary *boundary);void gfs_boundary_receive (GfsBoundary *boundary, FttTraverseFlags flags,gint max_depth);void gfs_boundary_synchronize (GfsBoundary *boundary);void gfs_boundary_add_bc (GfsBoundary *b,GfsBc *bc);GfsBc * gfs_boundary_lookup_bc (GfsBoundary *b, GfsVariable *v);void gfs_boundary_set_default_bc (GfsBoundary *b,GfsBc *bc);
typedef struct {
GtsObjectClass parent_class;
void (* match) (GfsBoundary * boundary);
void (* send) (GfsBoundary * boundary);
void (* receive) (GfsBoundary * boundary,
FttTraverseFlags flags,
gint max_depth);
void (* synchronize) (GfsBoundary * boundary);
} GfsBoundaryClass;typedef struct {
GfsVariable * v;
GfsBoundaryVariableType type;
GHashTable * bc;
} GfsBoundary;typedef enum {
GFS_BOUNDARY_CENTER_VARIABLE,
GFS_BOUNDARY_FACE_VARIABLE,
GFS_BOUNDARY_MATCH_VARIABLE,
GFS_BOUNDARY_VARIABLE_NUMBER
} GfsBoundaryVariableType;GfsBoundary* gfs_boundary_new (GfsBoundaryClass *klass, GfsBox *box, FttDirection d);
Creates a new boundary of type klass for box in direction d.
This function fails if box has already a boundary in direction d.
klass : | |
box : | a GfsBox. |
d : | a direction. |
| Returns : | a new GfsBoundary. |
void gfs_boundary_send (GfsBoundary *boundary);
Calls the @send()boundary.
boundary : | a GfsBoundary. |
void gfs_boundary_receive (GfsBoundary *boundary, FttTraverseFlags flags,gint max_depth);
Calls the @receive()boundary.
boundary : | a GfsBoundary. |
flags : | the traversal flags. |
max_depth : | the maximum depth of the traversal. |
void gfs_boundary_synchronize (GfsBoundary *boundary);
Calls the @synchronize()boundary.
boundary : | a GfsBoundary. |
void gfs_boundary_add_bc (GfsBoundary *b,GfsBc *bc);
Adds boundary condition bc to b.
b : | a GfsBoundary. |
bc : | a |
GfsBc * gfs_boundary_lookup_bc (GfsBoundary *b, GfsVariable *v);
b : | |
v : | |
| Returns : |
|
void gfs_boundary_set_default_bc (GfsBoundary *b,GfsBc *bc);
Sets the default boundary condition for b to bc.
b : | a GfsBoundary. |
bc : | a |
| <<< Fluid box boundaries | Constant inflow boundary >>> |