21 #include "SheafSystem/edge_centered_triangle_refiner.h" 23 #include "SheafSystem/assert_contract.h" 24 #include "SheafSystem/base_space_poset.h" 25 #include "SheafSystem/error_message.h" 26 #include "SheafSystem/field_refinement_buffer.h" 27 #include "SheafSystem/wsv_block.h" 51 ensure(&
policy() == &xpolicy);
134 int lnew_depth = lzone_depth + 1;
141 lbase->
new_link(lzone_id, lnew_tri);
149 #ifdef DIAGNOSTIC_OUTPUT 151 cout <<
"triangle: " << setw(6) << lnew_tri;
152 cout <<
" lower cover: ";
153 cover_set_state& lnew_tri_cvr = lbase->lower_cover(lnew_tri);
154 copy(lnew_tri_cvr.begin(),
156 ostream_iterator<scoped_index>(cout,
" "));
157 cout << endl << endl;
200 result = REFINED_ZONE_CT;
263 ensure(result.
ct() > 1);
293 static const string result(
"triangle_nodes");
297 ensure(!result.empty());
330 0.5, 0.0, 0.0, 0.0, 0.5, 0.5
332 {-0.5, -0.5, 0.5, 0.5, 0.0, 0.0},
333 { 0.0, 0.5, 0.5, -0.5, -0.5, 0.5},
334 { 0.0, -0.5, 0.5, 0.5, 0.5, 0.0}
471 require(xother != 0);
double chart_point_coord_type
The type of local coordinate in the base space; the scalar type for the local coordinate vector space...
A field refiner that subdivides a triangle into 4 triangles by introducing a new vertex in the center...
virtual bool invariant() const
Class invariant.
virtual void new_link(pod_index_type xgreater, pod_index_type xlesser)
Insert a cover link from greater to lesser (that is, hub id xgreater covers hub id xlesser)...
size_type ct() const
The number of items currently in use.
virtual void modify_crg(field_refinement_buffer &xbuffer)
Modifies the cover relation graph of the base space.
virtual bool is_zone_centered_refiner() const
True if this adds a vertex at the center of the zone.
A buffer for data which is used by both a local_field_refiner object and its associated field_refinem...
Namespace for fields component of sheaf system.
int refinement_depth(pod_index_type xmbr_hub_id) const
The refinement depth of the member with hub id xmbr_hub_id.
const chart_point_coord_type * local_coordinates_map(size_type xi) const
The map from the local coordinates of refined zone xi the the local coordinates of the parent zone...
An abstract field refiner that subdivides a polygon by introducing new vertices into the centers of t...
virtual size_type unrefined_vertex_ct() const
The number of vertices with refinement depth <= unrefined zone depth.
virtual const std::string & zone_type_name() const
The name of the type of zone this creates during refinement.
void make_new_zones(field_refinement_buffer &xbuffer)
Make the new zones in the refinement.
block< scoped_index > _vertex_ids
The ids of the vertices in boundary <= new refinement depth.
virtual size_type refined_zone_ct() const
The number of refined zones created by this.
const field_refinement_policy & policy() const
The refinement policy for this refiner.
Abstract base class with useful features for all objects.
The lattice of closed cells of a cellular space; a lattice representation of a computational mesh...
virtual edge_centered_triangle_refiner * clone() const
Virtual constructor, creates a new instance of the same type as this.
virtual const block< size_type > & first_vertex_index() const
The index in _vertex_pos of the first vertex of each new zone; contains number of zones + 1 because f...
void push_back(const_reference_type item)
Insert item at the end of the items in the auto_block.
scoped_index zone_id
The id of the current zone.
edge_centered_triangle_refiner()
Default constructor; disabled.
An index within the external ("client") scope of a given id space.
unsigned long size_type
An unsigned integral type used to represent sizes and capacities.
An abstract policy that determines the conditions under which a zone should be refined.
virtual bool invariant() const
Class invariant.
virtual ~edge_centered_triangle_refiner()
Destructor.
virtual edge_centered_triangle_refiner & operator=(const local_field_refiner &xother)
Assignment operator.
void disable_invariant_check() const
Disable invariant check. Intended for preventing recursive calls to invariant and for suppressing inv...
virtual bool is_ancestor_of(const any *xother) const
Conformance test; true if other conforms to this.
An abstract refiner for a field over a local region (primitive cell) in the base space.
bool invariant_check() const
True if invariant checking is enabled.
pod_index_type create_zone(base_space_poset &xbase, int xdepth)
Creates a new quadrangle in base space xbase, with refinement depth xdepth.
void make_new_vertices(field_refinement_buffer &xbuffer)
Makes new vertices in edge centers as needed and builds the list of vertices in the boundary of the z...
base_space_poset * base_space
The current base space.
bool in_jim_edit_mode() const
True if editing jims and jim order relation is allowed.
An auto_block with a no-initialization initialization policy.
bool is_same_type(const any *other) const
True if other is the same type as this.
void enable_invariant_check() const
Enable invariant checking.
block< scoped_index > _refined_zone_ids
The member ids of the zones created by the most recent execution of refine().
Whitespace-separated-value block; A block of objects of type T that can be conveniently initialized b...
virtual const scoped_index & member_id(bool xauto_access) const
An id in the member hub id space; intended for copying to initialize ids to the member id space...