RectangleMesh_create

dolfin.cpp.mesh.RectangleMesh_create()
// Mesh with 8 cells in each direction on the
// set [-1,2] x [-1,2]
Point p0(-1, -1);
Point p1(2, 2);
auto mesh = RectangleMesh::create(MPI_COMM_WORLD, {p0, p1}, {8, 8});
Parameters:
  • comm (MPI_Comm) – (MPI_Comm) MPI communicator
  • std::array< Point, 2 > & p (const) – (std::array<Point , 2>) Vertex points.
  • std::size_t, 2 > n (std::array<) – (std::array<std::size_t, 2>) Number of cells in each direction
  • cell_type (CellType::Type) – (dolfin::CellType::Type ) Cell type
  • diagonal (std::string) – (string) Direction of diagonals: “left”, “right”, “left/right”, “crossed”
Return type:

Mesh