* is responsible to generate new points when the mesh is refined.
*
* By default, all manifold indicators of a mesh are set to
- * numbers::invalid_manifold_id. A typical piece of code that sets the
+ * numbers::flat_manifold_id. A typical piece of code that sets the
* manifold indicator on a object to something else would look like
* this, here setting the manifold indicator to 42 for all cells whose
* center has an $x$ component less than zero:
// By default (i.e., for a Triangulation created by hand or without a
// call to a GridGenerator function like GridGenerator::hyper_shell or
// GridGenerator::hyper_ball), all cells and faces of the Triangulation
- // have their manifold_id set to numbers::invalid_manifold_id, which is
+ // have their manifold_id set to numbers::flat_manifold_id, which is
// the default if you want a manifold that produces straight edges, but
// you can change this number for individual cells and faces. In that
// case, the curved manifold thus associated with number zero will not
* We assume that all valid manifold_ids lie in the range [0,
* invalid_manifold_id).
*
+ * @deprecated Use flat_manifold_id instead.
+ *
* @see
* @ref GlossManifoldIndicator "Glossary entry on manifold indicators"
*/
+ DEAL_II_DEPRECATED
const types::manifold_id invalid_manifold_id =
static_cast<types::manifold_id>(-1);
/**
* Copy boundary ids to manifold ids on faces and edges at the boundary. The
* default manifold_id for new Triangulation objects is
- * numbers::invalid_manifold_id. This function copies the boundary_ids of
+ * numbers::flat_manifold_id. This function copies the boundary_ids of
* the boundary faces and edges to the manifold_ids of the same faces and
* edges, allowing the user to change the boundary_ids and use them for
* boundary conditions regardless of the geometry, which will use
/**
* Copy material ids to manifold ids. The default manifold_id for new
- * Triangulation objects is numbers::invalid_manifold_id. When refinements
+ * Triangulation objects is numbers::flat_manifold_id. When refinements
* occurs, the Triangulation asks where to locate new points to the
* underlying manifold.
*
*
* - vertex indices to invalid values
* - boundary or material id zero (the default for boundary or material ids)
- * - manifold id to numbers::invalid_manifold_id
+ * - manifold id to numbers::flat_manifold_id
*/
CellData();
};
material_id = 0;
// And the manifold to be invalid
- manifold_id = numbers::invalid_manifold_id;
+ manifold_id = numbers::flat_manifold_id;
}
has_children() const;
/**
- * Dummy function that always returns numbers::invalid_manifold_id.
+ * Dummy function that always returns numbers::flat_manifold_id.
*/
types::manifold_id
manifold_id() const;
types::manifold_id
InvalidAccessor<structdim, dim, spacedim>::manifold_id() const
{
- return numbers::invalid_manifold_id;
+ return numbers::flat_manifold_id;
}
tria->vertex_to_manifold_id_map_1d->end())
return (*tria->vertex_to_manifold_id_map_1d)[this->vertex_index()];
else
- return numbers::invalid_manifold_id;
+ return numbers::flat_manifold_id;
}
/**
* Store manifold ids. This field stores the manifold id of each object,
- * which is a number between 0 and numbers::invalid_manifold_id-1.
+ * which is a number between 0 and numbers::flat_manifold_id-1.
*/
std::vector<types::manifold_id> manifold_id;
cell->line(line_no));
const Manifold<dim, spacedim> &manifold =
- ((line->manifold_id() == numbers::invalid_manifold_id) &&
+ ((line->manifold_id() == numbers::flat_manifold_id) &&
(dim < spacedim) ?
cell->get_manifold() :
line->get_manifold());
cell->line(line_no));
const Manifold<dim, spacedim> &manifold =
- ((line->manifold_id() == numbers::invalid_manifold_id) &&
+ ((line->manifold_id() == numbers::flat_manifold_id) &&
(dim < spacedim) ?
cell->get_manifold() :
line->get_manifold());
endf = tria.end_face();
for (; face != endf; ++face)
if ((face->at_boundary() ||
- face->manifold_id() != numbers::invalid_manifold_id) &&
+ face->manifold_id() != numbers::flat_manifold_id) &&
faces_to_remove[face->index()] == false)
{
for (unsigned int l = 0; l < GeometryInfo<dim>::lines_per_face; ++l)
manifolds;
// Set manifolds in new Triangulation
for (auto manifold_id : manifold_ids)
- if (manifold_id != numbers::invalid_manifold_id)
+ if (manifold_id != numbers::flat_manifold_id)
manifolds[manifold_id] = tria.get_manifold(manifold_id).clone();
tria.clear();
// Restore manifolds
for (auto manifold_id : manifold_ids)
- if (manifold_id != numbers::invalid_manifold_id)
+ if (manifold_id != numbers::flat_manifold_id)
tria.set_manifold(manifold_id, *manifolds[manifold_id]);
}
bool cell_is_flat = true;
for (unsigned int l = 0; l < GeometryInfo<dim>::lines_per_cell; ++l)
if (cell->line(l)->manifold_id() != cell->manifold_id() &&
- cell->line(l)->manifold_id() != numbers::invalid_manifold_id)
+ cell->line(l)->manifold_id() != numbers::flat_manifold_id)
cell_is_flat = false;
if (dim > 2)
for (unsigned int q = 0; q < GeometryInfo<dim>::quads_per_cell; ++q)
if (cell->quad(q)->manifold_id() != cell->manifold_id() &&
- cell->quad(q)->manifold_id() != numbers::invalid_manifold_id)
+ cell->quad(q)->manifold_id() != numbers::flat_manifold_id)
cell_is_flat = false;
AssertIndexRange(static_cast<unsigned int>(cell->index()),
coarse_cell_is_flat.size());
const types::manifold_id line_manifold_id =
cell.line(line)->manifold_id();
if (line_manifold_id == my_manifold_id ||
- line_manifold_id == numbers::invalid_manifold_id)
+ line_manifold_id == numbers::flat_manifold_id)
{
weights_vertices[GeometryInfo<2>::line_to_cell_vertices(line,
0)] -=
const types::manifold_id face_manifold_id =
cell.face(face)->manifold_id();
if (face_manifold_id == my_manifold_id ||
- face_manifold_id == numbers::invalid_manifold_id)
+ face_manifold_id == numbers::flat_manifold_id)
{
for (unsigned int line = 0;
line < GeometryInfo<2>::lines_per_cell;
const types::manifold_id line_manifold_id =
cell.line(line)->manifold_id();
if (line_manifold_id == my_manifold_id ||
- line_manifold_id == numbers::invalid_manifold_id)
+ line_manifold_id == numbers::flat_manifold_id)
{
weights_vertices[GeometryInfo<3>::line_to_cell_vertices(line,
0)] -=
for (unsigned int f = 0; f < GeometryInfo<dim>::faces_per_cell; ++f)
{
(*triangulation.vertex_to_manifold_id_map_1d)
- [cell->face(f)->vertex_index()] = numbers::invalid_manifold_id;
+ [cell->face(f)->vertex_index()] = numbers::flat_manifold_id;
if (cell->at_boundary(f))
(*triangulation.vertex_to_boundary_id_map_1d)
// same object of the cell (which was stored in
// line->user_index() before) unless a manifold_id
// has been set on this very line.
- if (line->manifold_id() == numbers::invalid_manifold_id)
+ if (line->manifold_id() == numbers::flat_manifold_id)
triangulation.vertices[next_unused_vertex] =
triangulation.get_manifold(line->user_index())
.get_new_point_on_line(line);
const types::manifold_id m_number,
const Manifold<dim, spacedim> &manifold_object)
{
- Assert(m_number < numbers::invalid_manifold_id,
- ExcIndexRange(m_number, 0, numbers::invalid_manifold_id));
+ Assert(m_number < numbers::flat_manifold_id,
+ ExcIndexRange(m_number, 0, numbers::flat_manifold_id));
manifold[m_number] = manifold_object.clone();
}
void
Triangulation<dim, spacedim>::reset_manifold(const types::manifold_id m_number)
{
- Assert(m_number < numbers::invalid_manifold_id,
- ExcIndexRange(m_number, 0, numbers::invalid_manifold_id));
+ Assert(m_number < numbers::flat_manifold_id,
+ ExcIndexRange(m_number, 0, numbers::flat_manifold_id));
// delete the entry located at number.
manifold.erase(m_number);
GridGenerator::hyper_cube(tria);
tria.set_all_manifold_ids_on_boundary(1);
- tria.begin_active()->face(2)->set_manifold_id(numbers::invalid_manifold_id);
+ tria.begin_active()->face(2)->set_manifold_id(numbers::flat_manifold_id);
tria.set_manifold(1, manifold);
tria.refine_global(3);
++cell)
for (unsigned int f = 0; f < GeometryInfo<dim>::faces_per_cell; ++f)
if (cell->at_boundary(f))
- cell->face(f)->set_all_manifold_ids(numbers::invalid_manifold_id);
+ cell->face(f)->set_all_manifold_ids(numbers::flat_manifold_id);
// static const SphericalManifold<dim> boundary_shell;
// tr.set_manifold (0, boundary_shell);
// tr.set_manifold (1, boundary_shell);