![]() | ![]() | ![]() | Gerris Flow Solver Reference Manual | ![]() |
---|
#include <gfs.h> #define GFS_ADAPT (obj) #define GFS_IS_ADAPT (obj) GfsAdapt; GfsEventClass* gfs_adapt_class (void);
All the adaptive refinement criteria are derived from this class. Several refinement criteria can be used at the same time.
The syntax in parameter files is as follows:
[ GfsEvent ] { minlevel = 3 maxlevel = 10 mincells = 100 maxcells = 100000 cmax = 1e-2 weight = 1 }
minlevel | The minimum number of refinement levels (default is 0). |
maxlevel | The maximum number of refinement levels. |
mincells | The minimum number of cells in the simulation (default is 0). |
maxcells | The maximum number of cells in the simulation. If this number is reached, the algorithm optimizes the distribution of the cells so that the maximum cost over all the cells is minimized. |
cmax | The maximum cell cost allowed. If the number of cells is smaller than the maximum allowed and the cost of a cell is larger than this value, the cell will be refined. |
weight | When combining several criteria, the algorithm will weight the cost of each by this value in order to compute the total cost (default is 1). |
typedef struct { GfsFunction * minlevel, * maxlevel; guint mincells, maxcells; gdouble cmax, weight; GfsVariable * c; GtsKeyFunc cost; } GfsAdapt;
<<< Adaptive mesh refinement | Vorticity-based refinement >>> |