GfsRefineSolid

From Gerris

(Difference between revisions)
Jump to: navigation, search
Revision as of 23:27, 10 October 2007
Popinet (Talk | contribs)
(RefineSolid now works also with implicit surfaces)
← Previous diff
Current revision
Popinet (Talk | contribs)
(examples cross-reference)
Line 18: Line 18:
return 8; return 8;
} }
 +
 +<examples/>

Current revision

GfsRefineSolid will refine any cell intersected by an embedded solid boundary down to the specified number of levels.

The syntax in parameter files is

[ GfsRefine ]

GfsRefineSolid also creates a new derived variable SolidCurvature which contains the maximum of the mean surface curvature for the fragment of embedded surface contained in a cell. If the mean curvature in a cell cannot be computed — for example because several non-connected fragments of surface intersect the cell — the value of SolidCurvature is set to 1/(cell size).

SolidCurvature can be used to refine an embedded surface according to its mean curvature using for example

RefineSolid {
  if (SolidCurvature > 0.) {
    /* compute the level so that (radius of curvature) > 5*(cell size) */
    gint l = log(SolidCurvature/0.2)/log(2.);
    return l < 8 ? 8 : l > 12 ? 12 : l;
  }
  else
    return 8;
}

Examples

Personal tools
communication