DOLFIN User Manual - FEniCS Project

DOLFIN User Manual - FEniCS Project DOLFIN User Manual - FEniCS Project

fenicsproject.org
from fenicsproject.org More from this publisher
12.07.2015 Views

DOLFIN User ManualHoffman, Jansson, Logg, Wells// Mark cells for refinementfor (CellIterator cell(mesh); !cell.end(); ++cell)if ( ... )cell->mark();// Refine meshmesh.refine();It is also possible to directly mark all Cells for refinement to refine the Meshuniformly:// Refine all cellsmesh.refineUniformly();32

Chapter 5Functions◮ Developer’s note: Since this chapter was written, the Function class hasseen a number of improvements which are not covered here. Chapter needsto be updated.The central concept of a function on a domain Ω ⊂ R d is modeled by the classFunction, which is used in DOLFIN to represent coefficients or solutions ofpartial differential equations.5.1 Basic propertiesThe following basic properties hold for all Functions:• A Function can be scalar or vector-valued;• A Function can be evaluated at each Vertex of a Mesh;• A Function can be restricted to each local Cell of a Mesh;• The underlying representation of a Function may vary.33

<strong>DOLFIN</strong> <strong>User</strong> <strong>Manual</strong>Hoffman, Jansson, Logg, Wells// Mark cells for refinementfor (CellIterator cell(mesh); !cell.end(); ++cell)if ( ... )cell->mark();// Refine meshmesh.refine();It is also possible to directly mark all Cells for refinement to refine the Meshuniformly:// Refine all cellsmesh.refineUniformly();32

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!