12.07.2015 Views

FEniCS Course - FEniCS Project

FEniCS Course - FEniCS Project

FEniCS Course - FEniCS Project

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

Step by step: creating a meshNext, we create a mesh of our domain Ω:mesh = UnitSquare (8, 8)Defines a mesh of 8 × 8 × 2 = 128 triangles of the unit squareOther useful classes for creating meshes includeUnitIntervalMesh, UnitCubeMesh, UnitCircleMesh,UnitSphereMesh, RectangleMesh and BoxMeshComplex geometries can be built using Constructive Solid Geometry(CSG) which is built into <strong>FEniCS</strong> (operators +, -, *):r = Rectangle (0.5, 0.5, 1.5, 1.5)c = Circle (1, 1, 1)...g = (r - c)*b + amesh = Mesh (g)12 / 22

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

Saved successfully!

Ooh no, something went wrong!