SheafSystem  0.0.0.0
fiber_bundles_namespace.cc
Go to the documentation of this file.
1 
2 //
3 // Copyright (c) 2014 Limit Point Systems, Inc.
4 //
5 // Licensed under the Apache License, Version 2.0 (the "License");
6 // you may not use this file except in compliance with the License.
7 // You may obtain a copy of the License at
8 //
9 // http://www.apache.org/licenses/LICENSE-2.0
10 //
11 // Unless required by applicable law or agreed to in writing, software
12 // distributed under the License is distributed on an "AS IS" BASIS,
13 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 // See the License for the specific language governing permissions and
15 // limitations under the License.
16 //
17 
20 
21 #include "SheafSystem/arg_list.h"
22 #include "SheafSystem/assert_contract.h"
23 #include "SheafSystem/at0.h"
24 #include "SheafSystem/at0_space.h"
25 #include "SheafSystem/at1.h"
26 #include "SheafSystem/at1_space.h"
27 #include "SheafSystem/at2.h"
28 #include "SheafSystem/at2_e2.h"
29 #include "SheafSystem/at2_e3.h"
30 #include "SheafSystem/at3.h"
31 #include "SheafSystem/at3_e3.h"
32 #include "SheafSystem/atp.h"
33 #include "SheafSystem/atp_space.h"
34 #include "SheafSystem/array_index_space_handle.h"
35 #include "SheafSystem/array_index_space_state.h"
36 #include "SheafSystem/base_space_member.h"
37 #include "SheafSystem/base_space_poset.h"
38 #include "SheafSystem/biorder_iterator.h"
39 #include "SheafSystem/block.impl.h"
40 #include "SheafSystem/e1.h"
41 #include "SheafSystem/e2.h"
42 #include "SheafSystem/e3.h"
43 #include "SheafSystem/e4.h"
44 #include "SheafSystem/ed.h"
45 #include "SheafSystem/fiber_bundles_namespace.h"
46 #include "SheafSystem/gl2.h"
47 #include "SheafSystem/gl3.h"
48 #include "SheafSystem/gln.h"
49 #include "SheafSystem/gln_space.h"
50 #include "SheafSystem/homogeneous_block.h"
51 #include "SheafSystem/i_adjacency_index_space_interval.h" // for initialize_prototypes
52 #include "SheafSystem/i_connectivity_index_space_interval.h" // for initialize_prototypes
53 #include "SheafSystem/ij_adjacency_index_space_interval.h" // for initialize_prototypes
54 #include "SheafSystem/ij_connectivity_index_space_interval.h" // for initialize_prototypes
55 #include "SheafSystem/ijk_adjacency_index_space_interval.h" // for initialize_prototypes
56 #include "SheafSystem/ijk_connectivity_index_space_interval.h" // for initialize_prototypes
57 #include "SheafSystem/index_iterator.h"
58 #include "SheafSystem/index_space_iterator.h"
59 #include "SheafSystem/jcb.h"
60 #include "SheafSystem/jcb_space.h"
61 #include "SheafSystem/jcb_e13.h"
62 #include "SheafSystem/jcb_e23.h"
63 #include "SheafSystem/jcb_e33.h"
64 #include "SheafSystem/jcb_ed.h"
65 #include "SheafSystem/met.h"
66 #include "SheafSystem/met_e1.h"
67 #include "SheafSystem/met_e2.h"
68 #include "SheafSystem/met_e3.h"
69 #include "SheafSystem/met_ed.h"
70 #include "SheafSystem/namespace_poset.h"
71 #include "SheafSystem/namespace_poset_member.h"
72 #include "SheafSystem/point_block_1d.h"
73 #include "SheafSystem/point_block_2d.h"
74 #include "SheafSystem/point_block_3d.h"
75 #include "SheafSystem/point_block_crg_interval.h" // For initialize_prototypes.
76 #include "SheafSystem/poset.h"
77 #include "SheafSystem/poset_handle_factory.h"
78 #include "SheafSystem/poset_member_iterator.h"
79 #include "SheafSystem/postorder_iterator.h"
80 #include "SheafSystem/primitives_poset.h"
81 #include "SheafSystem/primitives_poset_schema.h"
82 #include "SheafSystem/binary_section_space_schema_member.h"
83 #include "SheafSystem/binary_section_space_schema_poset.h"
84 #include "SheafSystem/schema_poset_member.h"
85 #include "SheafSystem/sec_at0_space.h" // For initialize_prototypes.
86 #include "SheafSystem/sec_at1_space.h" // For initialize_prototypes.
87 #include "SheafSystem/sec_atp_space.h" // For initialize_prototypes.
88 #include "SheafSystem/sec_jcb_space.h" // For initialize_prototypes.
89 #include "SheafSystem/sec_rep_descriptor.h"
90 #include "SheafSystem/sec_rep_descriptor_poset.h"
91 #include "SheafSystem/sec_rep_space.h"
92 #include "SheafSystem/sec_stp_space.h" // For initialize_prototypes.
93 #include "SheafSystem/sec_tp_space.h" // For initialize_prototypes.
94 #include "SheafSystem/sec_vd_space.h" // For initialize_prototypes.
95 #include "SheafSystem/section_space_schema_jims_index_space_state.h" // For initialize_prototypes
96 #include "SheafSystem/st2.h"
97 #include "SheafSystem/st2_e2.h"
98 #include "SheafSystem/st2_e3.h"
99 #include "SheafSystem/st3.h"
100 #include "SheafSystem/st3_e3.h"
101 #include "SheafSystem/st4.h"
102 #include "SheafSystem/st4_e2.h"
103 #include "SheafSystem/st4_e3.h"
104 #include "SheafSystem/std_cstring.h"
105 #include "SheafSystem/std_iostream.h"
106 #include "SheafSystem/std_string.h"
107 #include "SheafSystem/stp.h"
108 #include "SheafSystem/stp_space.h"
109 #include "SheafSystem/structured_block_1d.h"
110 #include "SheafSystem/structured_block_2d.h"
111 #include "SheafSystem/structured_block_3d.h"
112 #include "SheafSystem/structured_block_1d_crg_interval.h" // For initialize_prototypes.
113 #include "SheafSystem/structured_block_2d_crg_interval.h" // For initialize_prototypes.
114 #include "SheafSystem/structured_block_3d_crg_interval.h" // For initialize_prototypes.
115 #include "SheafSystem/t2.h"
116 #include "SheafSystem/t2_e2.h"
117 #include "SheafSystem/t2_e3.h"
118 #include "SheafSystem/t3.h"
119 #include "SheafSystem/t3_e3.h"
120 #include "SheafSystem/t4.h"
121 #include "SheafSystem/t4_e2.h"
122 #include "SheafSystem/t4_e3.h"
123 #include "SheafSystem/tp.h"
124 #include "SheafSystem/tp_space.h"
125 #include "SheafSystem/tern.h"
126 #include "SheafSystem/tuple.h"
127 #include "SheafSystem/unstructured_block.h"
128 #include "SheafSystem/vd.h"
129 #include "SheafSystem/vd_space.h"
130 #include "SheafSystem/zone_nodes_block.h"
131 #include "SheafSystem/zone_nodes_block_crg_interval.h" // For initialize_prototypes.
132 
134 
135 #include "SheafSystem/array_section_dof_map.h"
136 #include "SheafSystem/sparse_section_dof_map.h"
137 
138 using namespace std;
139 using namespace fiber_bundle; // Workaround for MS C++ bug.
140 
141 // ===========================================================
142 // FIBER_BUNDLES_NAMESPACE FACET
143 // ===========================================================
144 
145 // PUBLIC MEMBER FUNCTIONS
146 
148 fiber_bundles_namespace(const std::string& xname)
149 {
150  // Preconditions:
151 
152  require(precondition_of(new_state(xname)));
153 
154  // Body:
155 
156  // Create the state.
157 
158  new_state(xname);
159 
160  // Postconditions:
161 
162  ensure(postcondition_of(new_state(xname)));
163 
164  // Exit:
165 
166  return;
167 }
168 
171 {
172  // Preconditions:
173 
174  require(is_attached() ? state_is_read_write_accessible() : true);
175 
176  // Body:
177 
178  // Nothing to do.
179 
180  // Postconditions:
181 
182  // Exit:
183 
184  return;
185 }
186 
187 // PROTECTED MEMBER FUNCTIONS
188 
189 
192 {
193  // Preconditions:
194 
195  // Body:
196 
197  // Postconditions:
198 
199  ensure(!is_attached());
200 
201  // Exit:
202 
203  return;
204 }
205 
208  : sheaves_namespace(xtop, xbottom)
209 {
210  // Preconditions:
211 
212  require(precondition_of(sheaves_namespace(xtop, xbottom)));
213 
214  // Body:
215 
216  // Nothing to do.
217 
218  // Postconditions:
219 
220  ensure(postcondition_of(sheaves_namespace(xtop, xbottom)));
221 
222  // Exit:
223 
224  return;
225 }
226 
227 // PRIVATE MEMBER FUNCTIONS
228 
229 
230 // ===========================================================
231 // BASE SPACE DEFINITIONS FACET
232 // ===========================================================
233 
234 // PUBLIC MEMBER FUNCTIONS
235 
236 // PROTECTED MEMBER FUNCTIONS
237 
238 void
241 {
242  // Preconditions:
243 
247 
248  // Body:
249 
250  // Create the base space member schema.
251 
253 
254  // Create base space member prototypes.
255 
257 
258  // Postconditions:
259 
261 
262  // Exit:
263 
264  return;
265 }
266 
267 void
270 {
271  // cout << "Entering fiber_bundles_namespace::make_base_space_schema_poset" << endl;
272 
273  // Preconditions:
274 
277 
278  // Body:
279 
280  // Create the schema poset.
281 
283  poset_path lschema_path = primitives().schema().path(false);
284 
285  poset& lbase_space_schema_poset = poset::new_table(const_cast<fiber_bundles_namespace&>(*this), lname, lschema_path, false);
286 
287  lbase_space_schema_poset.get_read_write_access();
288 
289  subposet table_dofs(&lbase_space_schema_poset, 0, false);
290  table_dofs.put_name(schema_poset_member::table_dof_subposet_name("top"), true, false);
291 
292  subposet row_dofs(&lbase_space_schema_poset, 0, false);
293  row_dofs.put_name(schema_poset_member::row_dof_subposet_name("top"), true, false);
294 
295  // Make the various schema members
296 
298 
299  // Schematize the poset and all its members
300 
301  lbase_space_schema_poset.schematize(&table_dofs, &row_dofs, true);
302 
303  // Clean up.
304 
305  table_dofs.detach_from_state();
306  row_dofs.detach_from_state();
307  lbase_space_schema_poset.release_access();
308 
309  // Postconditions:
310 
312 
313  // Exit:
314 
315  // cout << "Leaving fiber_bundles_namespace::make_base_space_schema_poset" << endl;
316  return;
317 }
318 
319 
320 void
323 {
324  // Preconditions:
325 
329 
330  // Body:
331 
333 // homogeneous_block::make_standard_schema(*this);
334 // unstructured_block::make_standard_schema(*this);
335 // structured_block::make_standard_schema(*this);
336 // structured_block_3d::make_standard_schema(*this);
337 // structured_block_2d::make_standard_schema(*this);
338 // structured_block_1d::make_standard_schema(*this);
339 // point_block_3d::make_standard_schema(*this);
340 // point_block_2d::make_standard_schema(*this);
341 // point_block_1d::make_standard_schema(*this);
342 
343 // // Schema for prototypes is join of allother schema,
344 // // so it hase to be constructed last.
345 
346 // base_space_member_prototype::make_standard_schema(*this);
347 
348 
349 // // Construct the standard base space schema member
350 // // (the join of the down set of the standard base space schema poset top).
351 
352 // base_space_member lmember(_base_space_schema_poset->top(), true, false);
353 // lmember.put_name(base_space_member::standard_schema_path().member_name(), true, false);
354 // lmember.detach_from_state();
355 
356  // Postconditions:
357 
358  // Exit:
359 
360  return;
361 }
362 
363 void
366 {
367  // Preconditions:
368 
372 
373  // Body:
374 
375  // Create the prototypes poset.
376 
377  base_space_poset& lprototypes_poset =
379 
380  lprototypes_poset.begin_jim_edit_mode(true);
381 
382  // Create the id space for cell types.
383 
384  array_index_space_state::new_space(lprototypes_poset.member_id_spaces(false),
385  "cell_types",
386  true, 0);
387 
388  // Create the prototypes:
389 
390  make_base_space_member_prototypes(&lprototypes_poset);
391 
392  // Clean up.
393 
394  lprototypes_poset.end_jim_edit_mode(true, true);
395 
396  // Postconditions:
397 
399 
400  // Exit:
401 
402  return;
403 }
404 
405 
406 void
409 {
410  // Preconditions:
411 
412  require(xspace != 0);
413  require(xspace->in_jim_edit_mode());
414 
415  // Body:
416 
423 
424  // 0-cell prototypes.
425 
426  make_point_prototype(xspace);
427 
428  // 1-cell prototypes
429 
430  make_segment_prototype(xspace);
432 
433  // 2-cell prototypes
434 
435  make_triangle_prototype(xspace);
438 
439  make_quad_prototype(xspace);
442 
444 
445  // 3-cell prototypes.
446 
447  make_tetra_prototype(xspace);
450 
451  make_hex_prototype(xspace);
452  make_hex_nodes_prototype(xspace);
455 
457 
458  // Homogeneous blocks.
459 
468 
469  // Other
470 
471  make_part_prototype(xspace);
472 
473 
474  // Postconditions:
475 
476 
477  // Exit:
478 
479  return;
480 }
481 
482 
483 
484 void
487 {
488  // Preconditions:
489 
490  require(xspace != 0);
491  require(xspace->in_jim_edit_mode());
492 
493  // Body:
494 
495  base_space_member lpt(xspace, "point", 0, "", false);
496 
497  lpt.detach_from_state();
498 
499  // Postconditions:
500 
501  ensure(xspace->contains_member("point"));
502 
503  // Exit:
504 
505  return;
506 }
507 
508 
509 void
512 {
513  // Preconditions:
514 
515  require(xspace != 0);
516  require(xspace->in_jim_edit_mode());
517 
518  // Body:
519 
520  base_space_member lseg(xspace, "segment", 1, "", false);
521 
522  lseg.detach_from_state();
523 
524  // Postconditions:
525 
526  ensure(xspace->contains_member("segment"));
527 
528  // Exit:
529 
530  return;
531 }
532 
533 void
536 {
537  // Preconditions:
538 
539  require(xspace != 0);
540  require(xspace->in_jim_edit_mode());
541 
542  // Body:
543 
544  // Create the vertices.
545 
546  base_space_member lpt(xspace, "point");
547 
548  base_space_member v0(xspace, "point", false, false);
549  v0.put_name("segment_complex_vertex_0", true, false);
550 
551  base_space_member v1(xspace, "point", false, false);
552  v1.put_name("segment_complex_vertex_1", true, false);
553 
554  // Create the segment and link it to the vertices.
555 
556  base_space_member lseg(xspace, "segment_complex", 1, "", false);
557 
558  lseg.create_cover_link(&v0);
559  lseg.create_cover_link(&v1);
560 
561  // Clean up.
562 
563  lseg.detach_from_state();
564  v1.detach_from_state();
565  v0.detach_from_state();
566  lpt.detach_from_state();
567 
568  // Postconditions:
569 
570  ensure(xspace->contains_member("segment_complex"));
571 
572  // Exit:
573 
574  return;
575 }
576 
577 
578 void
581 {
582  // Preconditions:
583 
584  require(xspace != 0);
585  require(xspace->in_jim_edit_mode());
586 
587  // Body:
588 
589  base_space_member ltriangle(xspace, "triangle", 2, "", false);
590  ltriangle.detach_from_state();
591 
592  // Postconditions:
593 
594  ensure(xspace->contains_member("triangle"));
595 
596  // Exit:
597 
598  return;
599 }
600 
601 void
604 {
605  // Preconditions:
606 
607  require(xspace != 0);
608  require(xspace->in_jim_edit_mode());
609 
610  // Body:
611 
612  // Create the vertices.
613 
614  base_space_member lpt(xspace, "point");
615 
616  base_space_member v0(xspace, "point", false, false);
617  v0.put_name("triangle_nodes_vertex_0", true, false);
618 
619  base_space_member v1(xspace, "point", false, false);
620  v1.put_name("triangle_nodes_vertex_1", true, false);
621 
622  base_space_member v2(xspace, "point", false, false);
623  v2.put_name("triangle_nodes_vertex_2", true, false);
624 
625  // Create the triangle and link it to the vertices.
626 
627  base_space_member ltriangle(xspace, "triangle_nodes", 2, "", false);
628 
629  ltriangle.create_cover_link(&v0);
630  ltriangle.create_cover_link(&v1);
631  ltriangle.create_cover_link(&v2);
632 
633  // Clean up.
634 
635  lpt.detach_from_state();
636 
637  v0.detach_from_state();
638  v1.detach_from_state();
639  v2.detach_from_state();
640 
641  ltriangle.detach_from_state();
642 
643  // Postconditions:
644 
645  ensure(xspace->contains_member("triangle_nodes"));
646 
647  // Exit:
648 
649  return;
650 }
651 
652 
653 void
656 {
657  // Preconditions:
658 
659  require(xspace != 0);
660  require(xspace->in_jim_edit_mode());
661 
662  // Body:
663 
664  // Create the vertices.
665 
666  base_space_member lpt(xspace, "point");
667 
668  base_space_member v0(xspace, "point", false, false);
669  v0.put_name("triangle_complex_vertex_0", true, false);
670 
671  base_space_member v1(xspace, "point", false, false);
672  v1.put_name("triangle_complex_vertex_1", true, false);
673 
674  base_space_member v2(xspace, "point", false, false);
675  v2.put_name("triangle_complex_vertex_2", true, false);
676 
677  // Create the edges and link them to the vertices.
678 
679  base_space_member lseg(xspace, "segment");
680 
681  base_space_member e0(xspace, "segment", false, false);
682  e0.put_name("triangle_complex_edge_0", true, false);
683  e0.create_cover_link(&v0);
684  e0.create_cover_link(&v1);
685 
686  base_space_member e1(xspace, "segment", false, false);
687  e1.put_name("triangle_complex_edge_1", true, false);
688  e1.create_cover_link(&v1);
689  e1.create_cover_link(&v2);
690 
691  base_space_member e2(xspace, "segment", false, false);
692  e2.put_name("triangle_complex_edge_2", true, false);
693  e2.create_cover_link(&v2);
694  e2.create_cover_link(&v0);
695 
696  // Create the triangle and link it to the edges.
697 
698  base_space_member ltriangle(xspace, "triangle_complex", 2, "", false);
699 
700  ltriangle.create_cover_link(&e0);
701  ltriangle.create_cover_link(&e1);
702  ltriangle.create_cover_link(&e2);
703 
704  // Clean up.
705 
706  lpt.detach_from_state();
707  v0.detach_from_state();
708  v1.detach_from_state();
709  v2.detach_from_state();
710 
711  lseg.detach_from_state();
712  e0.detach_from_state();
713  e1.detach_from_state();
714  e2.detach_from_state();
715 
716  ltriangle.detach_from_state();
717 
718  // Postconditions:
719 
720  ensure(xspace->contains_member("triangle_nodes"));
721 
722  // Exit:
723 
724  return;
725 }
726 
727 void
730 {
731  // Preconditions:
732 
733  require(xspace != 0);
734  require(xspace->in_jim_edit_mode());
735 
736  // Body:
737 
738  base_space_member lquad(xspace, "quad", 2, "", false);
739 
740  lquad.detach_from_state();
741 
742  // Postconditions:
743 
744  ensure(xspace->contains_member("quad"));
745 
746  // Exit:
747 
748  return;
749 }
750 
751 
752 
753 void
756 {
757  // Preconditions:
758 
759  require(xspace != 0);
760  require(xspace->in_jim_edit_mode());
761 
762  // Body:
763 
764  // Create the vertices.
765 
766  base_space_member lpt(xspace, "point");
767 
768  base_space_member v0(xspace, "point", false, false);
769  v0.put_name("quad_nodes_vertex_0", true, false);
770 
771  base_space_member v1(xspace, "point", false, false);
772  v1.put_name("quad_nodes_vertex_1", true, false);
773 
774  base_space_member v2(xspace, "point", false, false);
775  v2.put_name("quad_nodes_vertex_2", true, false);
776 
777  base_space_member v3(xspace, "point", false, false);
778  v3.put_name("quad_nodes_vertex_3", true, false);
779 
780  // Create the quad and link it to the vertices.
781 
782  base_space_member lquad(xspace, "quad_nodes", 2, "", false);
783 
784  lquad.create_cover_link(&v0);
785  lquad.create_cover_link(&v1);
786  lquad.create_cover_link(&v2);
787  lquad.create_cover_link(&v3);
788 
789  // Clean up.
790 
791 
792  lpt.detach_from_state();
793  v0.detach_from_state();
794  v1.detach_from_state();
795  v2.detach_from_state();
796  v3.detach_from_state();
797 
798  lquad.detach_from_state();
799 
800  // Postconditions:
801 
802  ensure(xspace->contains_member("quad_nodes"));
803 
804  // Exit:
805 
806  return;
807 }
808 
809 void
812 {
813  // Preconditions:
814 
815  require(xspace != 0);
816  require(xspace->in_jim_edit_mode());
817 
818  // Body:
819 
820  // Create the vertices.
821 
822  base_space_member lpt(xspace, "point");
823 
824  base_space_member v0(xspace, "point", false, false);
825  v0.put_name("quad_complex_vertex_0", true, false);
826 
827  base_space_member v1(xspace, "point", false, false);
828  v1.put_name("quad_complex_vertex_1", true, false);
829 
830  base_space_member v2(xspace, "point", false, false);
831  v2.put_name("quad_complex_vertex_2", true, false);
832 
833  base_space_member v3(xspace, "point", false, false);
834  v3.put_name("quad_complex_vertex_3", true, false);
835 
836  // Create the edges and link them to the vertices.
837 
838  base_space_member lseg(xspace, "segment");
839 
840  base_space_member e0(xspace, "segment", false, false);
841  e0.put_name("quad_complex_edge_0", true, false);
842  e0.create_cover_link(&v0);
843  e0.create_cover_link(&v1);
844 
845  base_space_member e1(xspace, "segment", false, false);
846  e1.put_name("quad_complex_edge_1", true, false);
847  e1.create_cover_link(&v1);
848  e1.create_cover_link(&v2);
849 
850  base_space_member e2(xspace, "segment", false, false);
851  e2.put_name("quad_complex_edge_2", true, false);
852  e2.create_cover_link(&v2);
853  e2.create_cover_link(&v3);
854 
855  base_space_member e3(xspace, "segment", false, false);
856  e3.put_name("quad_complex_edge_3", true, false);
857  e3.create_cover_link(&v3);
858  e3.create_cover_link(&v0);
859 
860  // Create the quad and link it to the edges.
861 
862  base_space_member lquad(xspace, "quad_complex", 2, "", false);
863 
864  lquad.create_cover_link(&e0);
865  lquad.create_cover_link(&e1);
866  lquad.create_cover_link(&e2);
867  lquad.create_cover_link(&e3);
868 
869  // Clean up.
870 
871  lpt.detach_from_state();
872  v0.detach_from_state();
873  v1.detach_from_state();
874  v2.detach_from_state();
875  v3.detach_from_state();
876 
877  lseg.detach_from_state();
878  e0.detach_from_state();
879  e1.detach_from_state();
880  e2.detach_from_state();
881  e3.detach_from_state();
882 
883  lquad.detach_from_state();
884 
885 
886  // Postconditions:
887 
888  ensure(xspace->contains_member("quad_complex"));
889 
890  // Exit:
891 
892  return;
893 }
894 
895 
896 void
899 {
900  // Preconditions:
901 
902  require(xspace != 0);
903  require(xspace->in_jim_edit_mode());
904 
905  // Body:
906 
907  base_space_member lpoly(xspace, "general_polygon", 2, "", false);
908  lpoly.detach_from_state();
909 
910  // Postconditions:
911 
912  ensure(xspace->contains_member("general_polygon"));
913 
914  // Exit:
915 
916  return;
917 }
918 
919 
920 void
923 {
924  // Preconditions:
925 
926  require(xspace != 0);
927  require(xspace->in_jim_edit_mode());
928 
929  // Body:
930 
931  base_space_member ltetra(xspace, "tetra", 3, "", false);
932  ltetra.detach_from_state();
933 
934  // Postconditions:
935 
936  ensure(xspace->contains_member("tetra"));
937 
938  // Exit:
939 
940  return;
941 }
942 
943 void
946 {
947  // Preconditions:
948 
949  require(xspace != 0);
950  require(xspace->in_jim_edit_mode());
951 
952  // Body:
953 
954  // Create the vertices.
955 
956  base_space_member lpt(xspace, "point");
957 
958  base_space_member v0(xspace, "point", false, false);
959  v0.put_name("tetra_nodes_vertex_0", true, false);
960 
961  base_space_member v1(xspace, "point", false, false);
962  v1.put_name("tetra_nodes_vertex_1", true, false);
963 
964  base_space_member v2(xspace, "point", false, false);
965  v2.put_name("tetra_nodes_vertex_2", true, false);
966 
967  base_space_member v3(xspace, "point", false, false);
968  v3.put_name("tetra_nodes_vertex_3", true, false);
969 
970  // Create the tet and link it to the vertices.
971 
972  base_space_member ltetra(xspace, "tetra_nodes", 3, "", false);
973 
974  ltetra.create_cover_link(&v0);
975  ltetra.create_cover_link(&v1);
976  ltetra.create_cover_link(&v2);
977  ltetra.create_cover_link(&v3);
978 
979  // Clean up.
980 
981  lpt.detach_from_state();
982  v0.detach_from_state();
983  v1.detach_from_state();
984  v2.detach_from_state();
985  v3.detach_from_state();
986 
987  ltetra.detach_from_state();
988 
989  // Postconditions:
990 
991  ensure(xspace->contains_member("tetra_nodes"));
992 
993  // Exit:
994 
995  return;
996 }
997 
998 
999 void
1002 {
1003  // Preconditions:
1004 
1005  require(xspace != 0);
1006  require(xspace->in_jim_edit_mode());
1007 
1008  // Body:
1009 
1010  // Create the vertices.
1011 
1012  base_space_member lpt(xspace, "point");
1013 
1014  base_space_member v0(xspace, "point", false, false);
1015  v0.put_name("tetra_complex_vertex_0", true, false);
1016 
1017  base_space_member v1(xspace, "point", false, false);
1018  v1.put_name("tetra_complex_vertex_1", true, false);
1019 
1020  base_space_member v2(xspace, "point", false, false);
1021  v2.put_name("tetra_complex_vertex_2", true, false);
1022 
1023  base_space_member v3(xspace, "point", false, false);
1024  v3.put_name("tetra_complex_vertex_3", true, false);
1025 
1026  // Create the edges and link thm to the vertices.
1027 
1028  base_space_member lseg(xspace, "segment");
1029 
1030  base_space_member e0(xspace, "segment", false, false);
1031  e0.put_name("tetra_complex_edge_0", true, false);
1032  e0.create_cover_link(&v0);
1033  e0.create_cover_link(&v1);
1034 
1035  base_space_member e1(xspace, "segment", false, false);
1036  e1.put_name("tetra_complex_edge_1", true, false);
1037  e1.create_cover_link(&v1);
1038  e1.create_cover_link(&v2);
1039 
1040  base_space_member e2(xspace, "segment", false, false);
1041  e2.put_name("tetra_complex_edge_2", true, false);
1042  e2.create_cover_link(&v2);
1043  e2.create_cover_link(&v0);
1044 
1045  base_space_member e3(xspace, "segment", false, false);
1046  e3.put_name("tetra_complex_edge_3", true, false);
1047  e3.create_cover_link(&v2);
1048  e3.create_cover_link(&v3);
1049 
1050  base_space_member e4(xspace, "segment", false, false);
1051  e4.put_name("tetra_complex_edge_4", true, false);
1052  e4.create_cover_link(&v3);
1053  e4.create_cover_link(&v1);
1054 
1055  base_space_member e5(xspace, "segment", false, false);
1056  e5.put_name("tetra_complex_edge_5", true, false);
1057  e5.create_cover_link(&v3);
1058  e5.create_cover_link(&v0);
1059 
1060  // Create the faces and link them to the edges.
1061 
1062  base_space_member lface(xspace, "triangle");
1063 
1064  base_space_member f0(xspace, "triangle", false, false);
1065  f0.put_name("tetra_complex_face_0", true, false);
1066  f0.create_cover_link(&e0);
1067  f0.create_cover_link(&e1);
1068  f0.create_cover_link(&e2);
1069 
1070  base_space_member f1(xspace, "triangle", false, false);
1071  f1.put_name("tetra_complex_face_1", true, false);
1072  f1.create_cover_link(&e2);
1073  f1.create_cover_link(&e3);
1074  f1.create_cover_link(&e5);
1075 
1076  base_space_member f2(xspace, "triangle", false, false);
1077  f2.put_name("tetra_complex_face_2", true, false);
1078  f2.create_cover_link(&e5);
1079  f2.create_cover_link(&e4);
1080  f2.create_cover_link(&e0);
1081 
1082  base_space_member f3(xspace, "triangle", false, false);
1083  f3.put_name("tetra_complex_face_3", true, false);
1084  f3.create_cover_link(&e1);
1085  f3.create_cover_link(&e3);
1086  f3.create_cover_link(&e4);
1087 
1088  // Create the tet and link it to the faces.
1089 
1090  base_space_member ltetra(xspace, "tetra_complex", 3, "", false);
1091 
1092  ltetra.create_cover_link(&f0);
1093  ltetra.create_cover_link(&f1);
1094  ltetra.create_cover_link(&f2);
1095  ltetra.create_cover_link(&f3);
1096 
1097  // Clean up.
1098 
1099  lpt.detach_from_state();
1100  v0.detach_from_state();
1101  v1.detach_from_state();
1102  v2.detach_from_state();
1103  v3.detach_from_state();
1104 
1105  lseg.detach_from_state();
1106  e0.detach_from_state();
1107  e1.detach_from_state();
1108  e2.detach_from_state();
1109  e3.detach_from_state();
1110  e4.detach_from_state();
1111  e5.detach_from_state();
1112 
1113  lface.detach_from_state();
1114  f0.detach_from_state();
1115  f1.detach_from_state();
1116  f2.detach_from_state();
1117  f3.detach_from_state();
1118 
1119  ltetra.detach_from_state();
1120 
1121  // Postconditions:
1122 
1123  ensure(xspace->contains_member("tetra_complex"));
1124 
1125  // Exit:
1126 
1127  return;
1128 }
1129 
1130 
1131 void
1134 {
1135  // Preconditions:
1136 
1137  require(xspace != 0);
1138  require(xspace->in_jim_edit_mode());
1139 
1140  // Body:
1141 
1142  base_space_member lhex(xspace, "hex", 3, "", false);
1143  lhex.detach_from_state();
1144 
1145  // Postconditions:
1146 
1147  ensure(xspace->contains_member("hex"));
1148 
1149  // Exit:
1150 
1151  return;
1152 }
1153 
1154 void
1157 {
1158  // Preconditions:
1159 
1160  require(xspace != 0);
1161  require(xspace->in_jim_edit_mode());
1162 
1163  // Body:
1164 
1165  // Create the vertices.
1166 
1167  base_space_member lpt(xspace, "point");
1168 
1169  base_space_member v0(xspace, "point", false, false);
1170  v0.put_name("hex_nodes_vertex_0", true, false);
1171 
1172  base_space_member v1(xspace, "point", false, false);
1173  v1.put_name("hex_nodes_vertex_1", true, false);
1174 
1175  base_space_member v2(xspace, "point", false, false);
1176  v2.put_name("hex_nodes_vertex_2", true, false);
1177 
1178  base_space_member v3(xspace, "point", false, false);
1179  v3.put_name("hex_nodes_vertex_3", true, false);
1180 
1181  base_space_member v4(xspace, "point", false, false);
1182  v4.put_name("hex_nodes_vertex_4", true, false);
1183 
1184  base_space_member v5(xspace, "point", false, false);
1185  v5.put_name("hex_nodes_vertex_5", true, false);
1186 
1187  base_space_member v6(xspace, "point", false, false);
1188  v6.put_name("hex_nodes_vertex_6", true, false);
1189 
1190  base_space_member v7(xspace, "point", false, false);
1191  v7.put_name("hex_nodes_vertex_7", true, false);
1192 
1193  // Create the hex and link it to the vertices
1194 
1195  base_space_member lhex(xspace, "hex_nodes", 3, "", false);
1196 
1197  lhex.create_cover_link(&v0);
1198  lhex.create_cover_link(&v1);
1199  lhex.create_cover_link(&v2);
1200  lhex.create_cover_link(&v3);
1201  lhex.create_cover_link(&v4);
1202  lhex.create_cover_link(&v5);
1203  lhex.create_cover_link(&v6);
1204  lhex.create_cover_link(&v7);
1205 
1206  // Clean up.
1207 
1208  lpt.detach_from_state();
1209  v0.detach_from_state();
1210  v1.detach_from_state();
1211  v2.detach_from_state();
1212  v3.detach_from_state();
1213  v4.detach_from_state();
1214  v5.detach_from_state();
1215  v6.detach_from_state();
1216  v7.detach_from_state();
1217 
1218  lhex.detach_from_state();
1219 
1220  // Postconditions:
1221 
1222  ensure(xspace->contains_member("hex_nodes"));
1223 
1224  // Exit:
1225 
1226  return;
1227 }
1228 
1229 
1230 void
1233 {
1234  // Preconditions:
1235 
1236  require(xspace != 0);
1237  require(xspace->in_jim_edit_mode());
1238 
1239  // Body:
1240 
1241  // Create the vertices.
1242 
1243  base_space_member lpt(xspace, "point");
1244 
1245  base_space_member v0(xspace, "point", false, false);
1246  v0.put_name("hex_faces_nodes_vertex_0", true, false);
1247 
1248  base_space_member v1(xspace, "point", false, false);
1249  v1.put_name("hex_faces_nodes_vertex_1", true, false);
1250 
1251  base_space_member v2(xspace, "point", false, false);
1252  v2.put_name("hex_faces_nodes_vertex_2", true, false);
1253 
1254  base_space_member v3(xspace, "point", false, false);
1255  v3.put_name("hex_faces_nodes_vertex_3", true, false);
1256 
1257  base_space_member v4(xspace, "point", false, false);
1258  v4.put_name("hex_faces_nodes_vertex_4", true, false);
1259 
1260  base_space_member v5(xspace, "point", false, false);
1261  v5.put_name("hex_faces_nodes_vertex_5", true, false);
1262 
1263  base_space_member v6(xspace, "point", false, false);
1264  v6.put_name("hex_faces_nodes_vertex_6", true, false);
1265 
1266  base_space_member v7(xspace, "point", false, false);
1267  v7.put_name("hex_faces_nodes_vertex_7", true, false);
1268 
1269  // Create the faces and link them to the vertices.
1270 
1271  base_space_member lface(xspace, "quad");
1272 
1273  base_space_member f0(xspace, "quad", false, false);
1274  f0.put_name("hex_faces_nodes_face_0", true, false);
1275 
1276  f0.create_cover_link(&v0);
1277  f0.create_cover_link(&v1);
1278  f0.create_cover_link(&v2);
1279  f0.create_cover_link(&v3);
1280 
1281 
1282  base_space_member f1(xspace, "quad", false, false);
1283  f1.put_name("hex_faces_nodes_face_1", true, false);
1284 
1285  f1.create_cover_link(&v4);
1286  f1.create_cover_link(&v5);
1287  f1.create_cover_link(&v6);
1288  f1.create_cover_link(&v7);
1289 
1290  base_space_member f2(xspace, "quad", false, false);
1291  f2.put_name("hex_faces_nodes_face_2", true, false);
1292 
1293  f2.create_cover_link(&v1);
1294  f2.create_cover_link(&v5);
1295  f2.create_cover_link(&v6);
1296  f2.create_cover_link(&v2);
1297 
1298  base_space_member f3(xspace, "quad", false, false);
1299  f3.put_name("hex_faces_nodes_face_3", true, false);
1300 
1301  f3.create_cover_link(&v0);
1302  f3.create_cover_link(&v4);
1303  f3.create_cover_link(&v7);
1304  f3.create_cover_link(&v3);
1305 
1306  base_space_member f4(xspace, "quad", false, false);
1307  f4.put_name("hex_faces_nodes_face_4", true, false);
1308 
1309  f4.create_cover_link(&v0);
1310  f4.create_cover_link(&v1);
1311  f4.create_cover_link(&v5);
1312  f4.create_cover_link(&v4);
1313 
1314  base_space_member f5(xspace, "quad", false, false);
1315  f5.put_name("hex_faces_nodes_face_5", true, false);
1316 
1317  f5.create_cover_link(&v3);
1318  f5.create_cover_link(&v2);
1319  f5.create_cover_link(&v6);
1320  f5.create_cover_link(&v7);
1321 
1322  // Create the hex and link it to the faces.
1323 
1324  base_space_member lhex(xspace, "hex_faces_nodes", 3, "", false);
1325 
1326  lhex.create_cover_link(&f0);
1327  lhex.create_cover_link(&f1);
1328  lhex.create_cover_link(&f2);
1329  lhex.create_cover_link(&f3);
1330  lhex.create_cover_link(&f4);
1331  lhex.create_cover_link(&f5);
1332 
1333 
1334  // Clean up.
1335 
1336  lpt.detach_from_state();
1337  v0.detach_from_state();
1338  v1.detach_from_state();
1339  v2.detach_from_state();
1340  v3.detach_from_state();
1341  v4.detach_from_state();
1342  v5.detach_from_state();
1343  v6.detach_from_state();
1344  v7.detach_from_state();
1345 
1346  lface.detach_from_state();
1347  f0.detach_from_state();
1348  f1.detach_from_state();
1349  f2.detach_from_state();
1350  f3.detach_from_state();
1351  f4.detach_from_state();
1352  f5.detach_from_state();
1353 
1354  lhex.detach_from_state();
1355 
1356  // Postconditions:
1357 
1358  ensure(xspace->contains_member("hex_faces_nodes"));
1359 
1360  // Exit:
1361 
1362  return;
1363 }
1364 
1365 
1366 void
1369 {
1370  // Preconditions:
1371 
1372  require(xspace != 0);
1373  require(xspace->in_jim_edit_mode());
1374 
1375  // Body:
1376 
1377  // Create the vertices.
1378 
1379  base_space_member lpt(xspace, "point");
1380 
1381  base_space_member v0(xspace, "point", false, false);
1382  v0.put_name("hex_complex_vertex_0", true, false);
1383 
1384  base_space_member v1(xspace, "point", false, false);
1385  v1.put_name("hex_complex_vertex_1", true, false);
1386 
1387  base_space_member v2(xspace, "point", false, false);
1388  v2.put_name("hex_complex_vertex_2", true, false);
1389 
1390  base_space_member v3(xspace, "point", false, false);
1391  v3.put_name("hex_complex_vertex_3", true, false);
1392 
1393  base_space_member v4(xspace, "point", false, false);
1394  v4.put_name("hex_complex_vertex_4", true, false);
1395 
1396  base_space_member v5(xspace, "point", false, false);
1397  v5.put_name("hex_complex_vertex_5", true, false);
1398 
1399  base_space_member v6(xspace, "point", false, false);
1400  v6.put_name("hex_complex_vertex_6", true, false);
1401 
1402  base_space_member v7(xspace, "point", false, false);
1403  v7.put_name("hex_complex_vertex_7", true, false);
1404 
1405  // Create the edges and link them to the vertices.
1406 
1407  base_space_member lseg(xspace, "segment");
1408 
1409  base_space_member e0(xspace, "segment", false, false);
1410  e0.put_name("hex_complex_edge_0", true, false);
1411  e0.create_cover_link(&v0);
1412  e0.create_cover_link(&v1);
1413 
1414  base_space_member e1(xspace, "segment", false, false);
1415  e1.put_name("hex_complex_edge_1", true, false);
1416  e1.create_cover_link(&v1);
1417  e1.create_cover_link(&v2);
1418 
1419  base_space_member e2(xspace, "segment", false, false);
1420  e2.put_name("hex_complex_edge_2", true, false);
1421  e2.create_cover_link(&v2);
1422  e2.create_cover_link(&v3);
1423 
1424  base_space_member e3(xspace, "segment", false, false);
1425  e3.put_name("hex_complex_edge_3", true, false);
1426  e3.create_cover_link(&v3);
1427  e3.create_cover_link(&v0);
1428 
1429  base_space_member e4(xspace, "segment", false, false);
1430  e4.put_name("hex_complex_edge_4", true, false);
1431  e4.create_cover_link(&v4);
1432  e4.create_cover_link(&v5);
1433 
1434  base_space_member e5(xspace, "segment", false, false);
1435  e5.put_name("hex_complex_edge_5", true, false);
1436  e5.create_cover_link(&v5);
1437  e5.create_cover_link(&v6);
1438 
1439  base_space_member e6(xspace, "segment", false, false);
1440  e6.put_name("hex_complex_edge_6", true, false);
1441  e6.create_cover_link(&v6);
1442  e6.create_cover_link(&v7);
1443 
1444  base_space_member e7(xspace, "segment", false, false);
1445  e7.put_name("hex_complex_edge_7", true, false);
1446  e7.create_cover_link(&v7);
1447  e7.create_cover_link(&v4);
1448 
1449  base_space_member e8(xspace, "segment", false, false);
1450  e8.put_name("hex_complex_edge_8", true, false);
1451  e8.create_cover_link(&v3);
1452  e8.create_cover_link(&v7);
1453 
1454  base_space_member e9(xspace, "segment", false, false);
1455  e9.put_name("hex_complex_edge_9", true, false);
1456  e9.create_cover_link(&v2);
1457  e9.create_cover_link(&v6);
1458 
1459  base_space_member e10(xspace, "segment", false, false);
1460  e10.put_name("hex_complex_edge_10", true, false);
1461  e10.create_cover_link(&v1);
1462  e10.create_cover_link(&v5);
1463 
1464  base_space_member e11(xspace, "segment", false, false);
1465  e11.put_name("hex_complex_edge_11", true, false);
1466  e11.create_cover_link(&v0);
1467  e11.create_cover_link(&v4);
1468 
1469  // Create the faces and link them to the edges.
1470 
1471  base_space_member lface(xspace, "quad_complex");
1472 
1473  base_space_member f0(xspace, "quad_complex", false, false);
1474  f0.put_name("hex_complex_face_0", true, false);
1475  f0.create_cover_link(&e0);
1476  f0.create_cover_link(&e1);
1477  f0.create_cover_link(&e2);
1478  f0.create_cover_link(&e3);
1479 
1480  base_space_member f1(xspace, "quad_complex", false, false);
1481  f1.put_name("hex_complex_face_1", true, false);
1482  f1.create_cover_link(&e4);
1483  f1.create_cover_link(&e5);
1484  f1.create_cover_link(&e6);
1485  f1.create_cover_link(&e7);
1486 
1487  base_space_member f2(xspace, "quad_complex", false, false);
1488  f2.put_name("hex_complex_face_2", true, false);
1489  f2.create_cover_link(&e10);
1490  f2.create_cover_link(&e5);
1491  f2.create_cover_link(&e9);
1492  f2.create_cover_link(&e1);
1493 
1494  base_space_member f3(xspace, "quad_complex", false, false);
1495  f3.put_name("hex_complex_face_3", true, false);
1496  f3.create_cover_link(&e11);
1497  f3.create_cover_link(&e7);
1498  f3.create_cover_link(&e8);
1499  f3.create_cover_link(&e3);
1500 
1501  base_space_member f4(xspace, "quad_complex", false, false);
1502  f4.put_name("hex_complex_face_4", true, false);
1503  f4.create_cover_link(&e0);
1504  f4.create_cover_link(&e10);
1505  f4.create_cover_link(&e4);
1506  f4.create_cover_link(&e11);
1507 
1508  base_space_member f5(xspace, "quad_complex", false, false);
1509  f5.put_name("hex_complex_face_5", true, false);
1510  f5.create_cover_link(&e2);
1511  f5.create_cover_link(&e9);
1512  f5.create_cover_link(&e6);
1513  f5.create_cover_link(&e8);
1514 
1515  // Create the hex and link it to the faces.
1516 
1517  base_space_member lhex(xspace, "hex_complex", 3, "", false);
1518 
1519  lhex.create_cover_link(&f0);
1520  lhex.create_cover_link(&f1);
1521  lhex.create_cover_link(&f2);
1522  lhex.create_cover_link(&f3);
1523  lhex.create_cover_link(&f4);
1524  lhex.create_cover_link(&f5);
1525 
1526 
1527  // Clean up.
1528 
1529  lpt.detach_from_state();
1530  v0.detach_from_state();
1531  v1.detach_from_state();
1532  v2.detach_from_state();
1533  v3.detach_from_state();
1534  v4.detach_from_state();
1535  v5.detach_from_state();
1536  v6.detach_from_state();
1537  v7.detach_from_state();
1538 
1539  lseg.detach_from_state();
1540  e0.detach_from_state();
1541  e1.detach_from_state();
1542  e2.detach_from_state();
1543  e3.detach_from_state();
1544  e4.detach_from_state();
1545  e5.detach_from_state();
1546  e6.detach_from_state();
1547  e7.detach_from_state();
1548  e8.detach_from_state();
1549  e9.detach_from_state();
1550  e10.detach_from_state();
1551  e11.detach_from_state();
1552 
1553  lface.detach_from_state();
1554  f0.detach_from_state();
1555  f1.detach_from_state();
1556  f2.detach_from_state();
1557  f3.detach_from_state();
1558  f4.detach_from_state();
1559  f5.detach_from_state();
1560 
1561  lhex.detach_from_state();
1562 
1563  // Postconditions:
1564 
1565  ensure(xspace->contains_member("hex_complex"));
1566 
1567  // Exit:
1568 
1569  return;
1570 }
1571 
1572 
1573 void
1576 {
1577  // Preconditions:
1578 
1579  require(xspace != 0);
1580  require(xspace->in_jim_edit_mode());
1581 
1582  // Body:
1583 
1584  base_space_member lpoly(xspace, "general_polyhedron", 3, "", false);
1585  lpoly.detach_from_state();
1586 
1587  // Postconditions:
1588 
1589  ensure(xspace->contains_member("general_polyhedron"));
1590 
1591  // Exit:
1592 
1593  return;
1594 }
1595 
1596 void
1599 {
1600  // Preconditions:
1601 
1602  require(xspace != 0);
1603  require(xspace->in_jim_edit_mode());
1604 
1605  // Body:
1606 
1607  string lproto_name(zone_nodes_block::static_prototype_path().member_name());
1608 
1609  base_space_member lblk(xspace, lproto_name, 0, "", false);
1610  lblk.detach_from_state();
1611 
1612  // Postconditions:
1613 
1615 
1616  // Exit:
1617 
1618  return;
1619 }
1620 
1621 void
1624 {
1625  // Preconditions:
1626 
1627  require(xspace != 0);
1628  require(xspace->in_jim_edit_mode());
1629 
1630  // Body:
1631 
1633 
1634  base_space_member lblk(xspace, lproto_name, 0, "", false);
1635  lblk.detach_from_state();
1636 
1637  // Postconditions:
1638 
1640 
1641  // Exit:
1642 
1643  return;
1644 }
1645 
1646 
1647 void
1650 {
1651  // Preconditions:
1652 
1653  require(xspace != 0);
1654  require(xspace->in_jim_edit_mode());
1655 
1656  // Body:
1657 
1660 
1661  base_space_member lblk(xspace, lproto_name, 1, lcell_name, false);
1662  lblk.detach_from_state();
1663 
1664  // Postconditions:
1665 
1667 
1668  // Exit:
1669 
1670  return;
1671 }
1672 
1673 
1674 void
1677 {
1678  // Preconditions:
1679 
1680  require(xspace != 0);
1681  require(xspace->in_jim_edit_mode());
1682 
1683  // Body:
1684 
1687 
1688  base_space_member lblk(xspace, lproto_name, 2, lcell_name, false);
1689  lblk.detach_from_state();
1690 
1691  // Postconditions:
1692 
1694 
1695  // Exit:
1696 
1697  return;
1698 }
1699 
1700 void
1703 {
1704  // Preconditions:
1705 
1706  require(xspace != 0);
1707  require(xspace->in_jim_edit_mode());
1708 
1709  // Body:
1710 
1713 
1714  base_space_member lblk(xspace, lproto_name, 3, lcell_name, false);
1715  lblk.detach_from_state();
1716 
1717  // Postconditions:
1718 
1720 
1721  // Exit:
1722 
1723  return;
1724 }
1725 
1726 
1727 
1728 void
1731 {
1732  // Preconditions:
1733 
1734  require(xspace != 0);
1735  require(xspace->in_jim_edit_mode());
1736 
1737  // Body:
1738 
1739  string lproto_name(point_block_1d::static_prototype_path().member_name());
1741 
1742  base_space_member lblk(xspace, lproto_name, 0, lcell_name, false);
1743  lblk.detach_from_state();
1744 
1745  // Postconditions:
1746 
1748 
1749  // Exit:
1750 
1751  return;
1752 }
1753 
1754 
1755 
1756 void
1759 {
1760  // Preconditions:
1761 
1762  require(xspace != 0);
1763  require(xspace->in_jim_edit_mode());
1764 
1765  // Body:
1766 
1767  string lproto_name(point_block_2d::static_prototype_path().member_name());
1769 
1770  base_space_member lblk(xspace, lproto_name, 0, lcell_name, false);
1771  lblk.detach_from_state();
1772 
1773  // Postconditions:
1774 
1776 
1777  // Exit:
1778 
1779  return;
1780 }
1781 
1782 
1783 
1784 void
1787 {
1788  // Preconditions:
1789 
1790  require(xspace != 0);
1791  require(xspace->in_jim_edit_mode());
1792 
1793  // Body:
1794 
1795  string lproto_name(point_block_3d::static_prototype_path().member_name());
1797 
1798  base_space_member lblk(xspace, lproto_name, 0, lcell_name, false);
1799  lblk.detach_from_state();
1800 
1801  // Postconditions:
1802 
1804 
1805  // Exit:
1806 
1807  return;
1808 }
1809 
1810 void
1813 {
1814  // Preconditions:
1815 
1816  require(xspace != 0);
1817  require(xspace->in_jim_edit_mode());
1818 
1819  // Body:
1820 
1821  base_space_member lblk(xspace, "part", 0, "", false);
1822  lblk.detach_from_state();
1823 
1824  // Postconditions:
1825 
1826  ensure(xspace->contains_member("part"));
1827 
1828  // Exit:
1829 
1830  return;
1831 }
1832 
1833 // PRIVATE MEMBER FUNCTIONS
1834 
1835 
1836 // ===========================================================
1837 // FIBER SPACE DEFINITIONS FACET
1838 // ===========================================================
1839 
1840 // PUBLIC MEMBER FUNCTIONS
1841 
1842 // PROTECTED MEMBER FUNCTIONS
1843 
1844 void
1847 {
1848  // Preconditions:
1849 
1850  require(state_is_read_write_accessible());
1851  require(!contains_poset(tuple::standard_schema_path(), false));
1852 
1853  // Body:
1854 
1857 
1858  // Postconditions:
1859 
1860  ensure(contains_poset(tuple::standard_schema_path(), false));
1861 
1862  // Exit:
1863 
1864  return;
1865 }
1866 void
1869 {
1870  // Preconditions:
1871 
1872  require(state_is_read_write_accessible());
1873  require(!contains_poset(tuple::standard_schema_path(), false));
1874 
1875  // Body:
1876 
1877  string lname = tuple::standard_schema_path().poset_name();
1878  poset_path lschema_path = primitives().schema().path(false);
1879 
1880  poset* lfiber_space_schema_poset = &poset::new_table(const_cast<fiber_bundles_namespace&>(*this), lname, lschema_path, false);
1881  lfiber_space_schema_poset->get_read_write_access();
1882 
1883  subposet table_dofs(lfiber_space_schema_poset);
1884  table_dofs.put_name(schema_poset_member::table_dof_subposet_name("top"), true, false);
1885 
1886  subposet row_dofs(lfiber_space_schema_poset);
1887  row_dofs.put_name(schema_poset_member::row_dof_subposet_name("top"), true, false);
1888 
1889  // Make the various schema members.
1890 
1892 
1893  // Schematize the poset and all its members
1894 
1895  lfiber_space_schema_poset->schematize(&table_dofs, &row_dofs, true);
1896 
1897  table_dofs.detach_from_state();
1898  row_dofs.detach_from_state();
1899 
1900  // Make some useful groupings:
1901  // First, make a block and the id of the base type for each group.
1902  // Put pointers to the type blocks into a block indexed by mbr id.
1903 
1905  ltype_blocks(lfiber_space_schema_poset->member_index_ub().pod());
1906 
1907  ltype_blocks.set_ct(ltype_blocks.ub());
1908  ltype_blocks.assign(0);
1909 
1910  // Scalar types.
1911 
1912  block<scoped_index> lat0_types(32);
1913 
1914  pod_index_type lat0_id =
1915  lfiber_space_schema_poset->member_id(at0::standard_schema_path().member_name(), false);
1916 
1917  ltype_blocks[lat0_id] = &lat0_types;
1918 
1919  // Vector types.
1920 
1921  block<scoped_index> lat1_types(32);
1922 
1923  pod_index_type lat1_id =
1924  lfiber_space_schema_poset->member_id(at1::standard_schema_path().member_name(), false);
1925 
1926  ltype_blocks[lat1_id] = &lat1_types;
1927 
1928  // Metric tensor types.
1929 
1930  block<scoped_index> lmet_types(32);
1931 
1932  pod_index_type lmet_id =
1933  lfiber_space_schema_poset->member_id(met::standard_schema_path().member_name(), false);
1934 
1935  ltype_blocks[lmet_id] = &lmet_types;
1936 
1937  // Symmetric tensor types.
1938 
1939  block<scoped_index> lstp_types(32);
1940 
1941  pod_index_type lstp_id =
1942  lfiber_space_schema_poset->member_id(stp::standard_schema_path().member_name(), false);
1943 
1944  ltype_blocks[lstp_id] = &lstp_types;
1945 
1946  // Antisymmetric tensor types.
1947 
1948  block<scoped_index> latp_types(32);
1949 
1950  pod_index_type latp_id =
1951  lfiber_space_schema_poset->member_id(atp::standard_schema_path().member_name(), false);
1952 
1953  ltype_blocks[latp_id] = &latp_types;
1954 
1955  // General tensor types.
1956 
1957  block<scoped_index> ltp_types(32);
1958 
1959  pod_index_type ltp_id =
1960  lfiber_space_schema_poset->member_id(tp::standard_schema_path().member_name(), false);
1961 
1962  ltype_blocks[ltp_id] = &ltp_types;
1963 
1964  // Linear transformation types.
1965 
1966  block<scoped_index> lgln_types(32);
1967 
1968  pod_index_type lgln_id =
1969  lfiber_space_schema_poset->member_id(gln::standard_schema_path().member_name(), false);
1970 
1971  ltype_blocks[lgln_id] = &lgln_types;
1972 
1973  // Jacobian types.
1974 
1975  block<scoped_index> ljcb_types(32);
1976 
1977  pod_index_type ljcb_id =
1978  lfiber_space_schema_poset->member_id(jcb::standard_schema_path().member_name(), false);
1979 
1980  ltype_blocks[ljcb_id] = &ljcb_types;
1981 
1982  // Other types.
1983 
1984  block<scoped_index> lbot_types(32);
1985 
1986  pod_index_type lbot_id = BOTTOM_INDEX;
1987  ltype_blocks[lbot_id] = &lbot_types;
1988 
1989  stack<block<scoped_index>*> ltype_block_stack;
1990  ltype_block_stack.push(&lbot_types);
1991 
1992  // Iterate up from the bottom in postorder, sorting the members
1993  // into groups. This places each member in the group of its
1994  // greatest lower bound within the set of base types. (Note that
1995  // inheritance points down the CRG.)
1996 
1997  biorder_iterator lmbr_itr(lfiber_space_schema_poset->bottom(), "jims", UP, NOT_STRICT);
1998  while(!lmbr_itr.is_done())
1999  {
2000  const scoped_index& lmbr_id = lmbr_itr.index();
2001 
2002  switch(lmbr_itr.action())
2003  {
2004  case biorder_iterator::PREVISIT_ACTION:
2005  if(ltype_blocks[lmbr_id.pod()] != 0)
2006  {
2007  // This member is the base type of a group.
2008  // Push its block onto the stack so we begin
2009  // collecting the members of the group.
2010 
2011  ltype_block_stack.push(ltype_blocks[lmbr_id.pod()]);
2012  }
2013  break;
2014  case biorder_iterator::POSTVISIT_ACTION:
2015 
2016  if(!lfiber_space_schema_poset->is_atom(lmbr_id))
2017  {
2018  // Put the current member in the current group.
2019 
2020  ltype_block_stack.top()->push_back(lmbr_id);
2021  }
2022 
2023 
2024  if(ltype_blocks[lmbr_id.pod()] == ltype_block_stack.top())
2025  {
2026  // This member is the base type of a group
2027  // and we are about to leave its scope.
2028  // Pop the stack and return to collecting members
2029  // of the next most inclusive group.
2030 
2031  ltype_block_stack.pop();
2032  }
2033  break;
2034  }
2035  lmbr_itr.next();
2036  }
2037 
2038  // Now create the groups as members (jrms) and subposets.
2039  // This organization is mostly for display in the SheafScope.
2040  // The jrms organize the row graph while the subposets provide
2041  // useful filters for displaying a "flat" view in the table.
2042 
2043  // Scalar types.
2044 
2045  schema_poset_member lscalar_group(lfiber_space_schema_poset,
2046  lat0_types.base(),
2047  lat0_types.ct(),
2048  tern::TRUE,
2049  false);
2050  lscalar_group.put_name("scalars", true, false);
2051  lscalar_group.detach_from_state();
2052 
2053  subposet lat0_sp(lfiber_space_schema_poset, lat0_types, false);
2054  lat0_sp.put_name("scalars", true, false);
2055  lat0_sp.detach_from_state();
2056 
2057  // Vector types.
2058 
2059  schema_poset_member lvector_group(lfiber_space_schema_poset,
2060  lat1_types.base(),
2061  lat1_types.ct(),
2062  tern::TRUE,
2063  false);
2064  lvector_group.put_name("vectors", true, false);
2065  lvector_group.detach_from_state();
2066 
2067  subposet lat1_sp(lfiber_space_schema_poset, lat1_types, false);
2068  lat1_sp.put_name("vectors", true, false);
2069  lat1_sp.detach_from_state();
2070 
2071  // General tensor types
2072 
2073  schema_poset_member ltensor_group(lfiber_space_schema_poset,
2074  ltp_types.base(),
2075  ltp_types.ct(),
2076  tern::TRUE,
2077  false);
2078  ltensor_group.put_name("general_tensors", true, false);
2079  ltensor_group.detach_from_state();
2080 
2081  subposet ltp_sp(lfiber_space_schema_poset, ltp_types, false);
2082  ltp_sp.put_name("general_tensors", true, false);
2083  ltp_sp.detach_from_state();
2084 
2085  // Metric types
2086 
2087  schema_poset_member lmetric_group(lfiber_space_schema_poset,
2088  lmet_types.base(),
2089  lmet_types.ct(),
2090  tern::TRUE,
2091  false);
2092  lmetric_group.put_name("metric_tensors", true, false);
2093  lstp_types.push_back(lmetric_group.index());
2094  lmetric_group.detach_from_state();
2095 
2096  subposet lmet_sp(lfiber_space_schema_poset, lmet_types, false);
2097  lmet_sp.put_name("metric_tensors", true, false);
2098  lmet_sp.detach_from_state();
2099 
2100  // Symmetric tensor types
2101 
2102  schema_poset_member lsym_group(lfiber_space_schema_poset,
2103  lstp_types.base(),
2104  lstp_types.ct(),
2105  tern::TRUE,
2106  false);
2107  lsym_group.put_name("symmetric_tensors", true, false);
2108  lsym_group.detach_from_state();
2109 
2110  subposet lstp_sp(lfiber_space_schema_poset, lstp_types, false);
2111  lstp_sp.put_name("symmetric_tensors", true, false);
2112  lstp_sp.detach_from_state();
2113 
2114  // Antisymmetric tensor types
2115 
2116  schema_poset_member lantisym_group(lfiber_space_schema_poset,
2117  latp_types.base(),
2118  latp_types.ct(),
2119  tern::TRUE,
2120  false);
2121  lantisym_group.put_name("antisymmetric_tensors", true, false);
2122  lantisym_group.detach_from_state();
2123 
2124  subposet latp_sp(lfiber_space_schema_poset, latp_types, false);
2125  latp_sp.put_name("antisymmetric_tensors", true, false);
2126  latp_sp.detach_from_state();
2127 
2128  // Jacobian types
2129 
2130  schema_poset_member ljcb_group(lfiber_space_schema_poset,
2131  ljcb_types.base(),
2132  ljcb_types.ct(),
2133  tern::TRUE,
2134  false);
2135  ljcb_group.put_name("Jacobians", true, false);
2136 
2137  lgln_types.push_back(ljcb_group.index());
2138  ljcb_group.detach_from_state();
2139 
2140  subposet ljcb_sp(lfiber_space_schema_poset, ljcb_types, false);
2141  ljcb_sp.put_name("Jacobians", true, false);
2142  ljcb_sp.detach_from_state();
2143 
2144  // Linear transformation types
2145 
2146  schema_poset_member lgln_group(lfiber_space_schema_poset,
2147  lgln_types.base(),
2148  lgln_types.ct(),
2149  tern::TRUE,
2150  false);
2151  lgln_group.put_name("linear_transformations", true, false);
2152  lgln_group.detach_from_state();
2153 
2154  subposet lgln_sp(lfiber_space_schema_poset, lgln_types, false);
2155  lgln_sp.put_name("linear_transformations", true, false);
2156  lgln_sp.detach_from_state();
2157 
2158  // Other types
2159 
2160  schema_poset_member lother_group(lfiber_space_schema_poset,
2161  lbot_types.base(),
2162  lbot_types.ct(),
2163  tern::TRUE,
2164  false);
2165  lother_group.put_name("other_types", true, false);
2166  lother_group.detach_from_state();
2167 
2168  subposet lbot_sp(lfiber_space_schema_poset, lbot_types, false);
2169  lbot_sp.put_name("other_types", true, false);
2170  lbot_sp.detach_from_state();
2171 
2172 
2173  // Now identify the concrete types and put them in a subposet.
2176 
2177  subposet lconcrete_sp(lfiber_space_schema_poset);
2178  lconcrete_sp.put_name("concrete_types", true, false);
2179 
2180  subposet lrow_dof_sp(lfiber_space_schema_poset,
2182  stack<int> lrow_dof_ct;
2183  lrow_dof_ct.push(0); // So the stack is never empty.
2184 
2185  biorder_iterator lc_itr(lfiber_space_schema_poset->top(), "jims", DOWN, NOT_STRICT);
2186  while(!lc_itr.is_done())
2187  {
2188  const scoped_index& lmbr_id = lc_itr.index();
2189 
2190  switch(lc_itr.action())
2191  {
2192  case biorder_iterator::PREVISIT_ACTION:
2193  if(!lrow_dof_sp.contains_member(lmbr_id))
2194  {
2195  // This member is not a rof dof;
2196  // start a counter.
2197 
2198  lrow_dof_ct.push(0);
2199  }
2200  break;
2201  case biorder_iterator::POSTVISIT_ACTION:
2202 
2203  if(lrow_dof_sp.contains_member(lmbr_id))
2204  {
2205  // This member is a row dof;
2206  // increment the row dof counter.
2207 
2208  ++lrow_dof_ct.top();
2209 
2210  // We want to be able to visit this dof again,
2211  // if it appears in the down set of another type.
2212  // So unmark it.
2213 
2214  lc_itr.put_has_visited(lmbr_id, false);
2215  }
2216  else
2217  {
2218  // This member is not a row dof.
2219 
2220  int lct = lrow_dof_ct.top();
2221  if(lct > 0)
2222  {
2223  // This member is a concrete type.
2224 
2225  lconcrete_sp.insert_member(lmbr_id);
2226  }
2227 
2228  // Any row dofs of this member accumulate to
2229  // its superiors.
2230 
2231  lrow_dof_ct.pop();
2232  lrow_dof_ct.top() += lct;
2233  }
2234  break;
2235  }
2236  lc_itr.next();
2237  }
2238 
2239  lrow_dof_sp.detach_from_state();
2240  lconcrete_sp.detach_from_state();
2241 
2242  // Finished.
2243 
2244  lfiber_space_schema_poset->release_access();
2245 
2246  // Postconditions:
2247 
2248  ensure(contains_poset(tuple::standard_schema_path(), false));
2249 
2250  // Exit:
2251 
2252  return;
2253 }
2254 
2255 void
2258 {
2259  // Preconditions:
2260 
2261  require(contains_poset(tuple::standard_schema_path(), false));
2262  require(state_is_read_write_accessible());
2263 
2264  // Body:
2265 
2267  vd::make_standard_schema(*this);
2268  tp::make_standard_schema(*this);
2269  t2::make_standard_schema(*this);
2272  t3::make_standard_schema(*this);
2274  t4::make_standard_schema(*this);
2280  ed::make_standard_schema(*this);
2281  e4::make_standard_schema(*this);
2282  e3::make_standard_schema(*this);
2283  e2::make_standard_schema(*this);
2284  e1::make_standard_schema(*this);
2312 
2313  // Postconditions:
2314 
2315  // Exit:
2316 
2317  return;
2318 }
2319 
2320 void
2323 {
2324  // Preconditions:
2325 
2326  require(state_is_read_write_accessible());
2327 
2328  // Body:
2329 
2330  // Nothing to do in this classes;
2331  // intended for redefinition in descendants.
2332 
2333  // Postconditions:
2334 
2335 
2336  // Exit:
2337 
2338  return;
2339 }
2340 
2341 // PRIVATE MEMBER FUNCTIONS
2342 
2343 
2344 // ===========================================================
2345 // SECTION SPACE DEFINITIONS FACET
2346 // ===========================================================
2347 
2348 // PUBLIC MEMBER FUNCTIONS
2349 
2350 // PROTECTED MEMBER FUNCTIONS
2351 
2352 void
2355 {
2356 
2357  // Preconditions:
2358 
2359  require(state_is_read_write_accessible());
2363 
2364  // Body:
2365 
2368 
2370 
2371  // Postconditions:
2372 
2376 
2377  // Exit
2378 
2379  return;
2380 }
2381 
2382 void
2385 {
2386  // Preconditions:
2387 
2388  require(state_is_read_write_accessible());
2390 
2391  // Body:
2392 
2394  poset_path lschema_path = primitives().schema().path(false);
2395 
2396  poset* lschema_host = &poset::new_table(const_cast<fiber_bundles_namespace&>(*this), lname, lschema_path, false);
2397  lschema_host->get_read_write_access();
2398 
2399  subposet table_dofs(lschema_host);
2400  table_dofs.put_name(schema_poset_member::table_dof_subposet_name("top"), true, false);
2401 
2402  subposet row_dofs(lschema_host);
2403  row_dofs.put_name(schema_poset_member::row_dof_subposet_name("top"), true, false);
2404 
2405  // Make the schema members.
2406 
2408 
2409  // Schematize the schema poset and all its members
2410 
2411  lschema_host->schematize(&table_dofs, &row_dofs, true);
2412 
2413  // Detach all the handles allocated on the stack
2414 
2415  table_dofs.detach_from_state();
2416  row_dofs.detach_from_state();
2417 
2418  lschema_host->release_access();
2419 
2421 
2422  // Postconditions:
2423 
2425 
2426  // Exit:
2427 
2428  return;
2429 }
2430 
2431 void
2434 {
2435  // Preconditions:
2436 
2437  require(state_is_read_write_accessible());
2440 
2441  // Body:
2442 
2444 
2445  // Postconditions:
2446 
2447 
2448  // Exit:
2449 
2450  return;
2451 }
2452 
2453 void
2456 {
2457  // Preconditions:
2458 
2459  require(state_is_read_write_accessible());
2461 
2462 
2463  // Body:
2464 
2465  // Create the poset.
2466 
2468 
2469  // Create the members.
2470 
2471  lhost.begin_jim_edit_mode(true);
2472 
2473  make_sec_rep_descriptors(&lhost);
2474 
2475  lhost.end_jim_edit_mode(true, true);
2476 
2478 
2479  // Postconditions:
2480 
2482 
2483  // Exit:
2484 
2485  return;
2486 }
2487 
2488 void
2491 {
2492  // Preconditions:
2493 
2494  require(xhost->in_jim_edit_mode());
2495 
2496  // Body:
2497 
2498  sec_rep_descriptor lsrd;
2499 
2500  lsrd.new_jim_state(xhost,
2501  "__vertices",
2502  "",
2503  "__elements",
2504  "dlinear",
2505  "www.lpsweb.com/fiber_bundles/fiber_bundles_namespace.html",
2506  1,
2507  true,
2508  false);
2509  lsrd.put_name("vertex_element_dlinear", true, false);
2510 
2511  // $$SCRIBBLE eval-sp: make vertex_cells_dlinear rep.
2512 
2513  lsrd.new_jim_state(xhost,
2514  "__vertices",
2515  "",
2516  "__cells",
2517  "dlinear",
2518  "www.lpsweb.com/fiber_bundles/fiber_bundles_namespace.html",
2519  1,
2520  true,
2521  false);
2522  lsrd.put_name("vertex_cells_dlinear", true, false);
2523 
2524  lsrd.new_jim_state(xhost,
2525  "__elements",
2526  "",
2527  "__elements",
2528  "constant",
2529  "www.lpsweb.com/fiber_bundles/fiber_bundles_namespace.html",
2530  1,
2531  false,
2532  false);
2533  lsrd.put_name("element_element_constant", true, false);
2534 
2535  lsrd.new_jim_state(xhost,
2536  "__block_vertices",
2537  "",
2538  "__blocks",
2539  "dlinear",
2540  "www.lpsweb.com/fiber_bundles/fiber_bundles_namespace.html",
2541  1,
2542  true,
2543  false);
2544  lsrd.put_name("vertex_block_dlinear", true, false);
2545 
2546  lsrd.new_jim_state(xhost,
2547  "__block_vertices",
2548  "",
2549  "__blocks",
2550  "uniform",
2551  "www.lpsweb.com/fiber_bundles/fiber_bundles_namespace.html",
2552  1,
2553  true,
2554  false);
2555  lsrd.put_name("vertex_block_uniform", true, false);
2556 
2557  lsrd.new_jim_state(xhost,
2558  "__1_cells",
2559  "",
2560  "__1_cells",
2561  "constant",
2562  "www.lpsweb.com/fiber_bundles/fiber_bundles_namespace.html",
2563  1,
2564  false,
2565  false);
2566  lsrd.put_name("face_face_const_2D", true, false);
2567 
2568  lsrd.new_jim_state(xhost,
2569  "__2_cells",
2570  "",
2571  "__2_cells",
2572  "constant",
2573  "www.lpsweb.com/fiber_bundles/fiber_bundles_namespace.html",
2574  1,
2575  false,
2576  false);
2577  lsrd.put_name("face_face_const_3D", true, false);
2578 
2579  lsrd.new_jim_state(xhost,
2580  "__neumann_face_vertices",
2581  "",
2582  "__1_cells",
2583  "dlinear",
2584  "www.lpsweb.com/fiber_bundles/fiber_bundles_namespace.html",
2585  1,
2586  true,
2587  false);
2588  lsrd.put_name("neumann_vertex_face_dlinear_2D", true, false);
2589 
2590  lsrd.new_jim_state(xhost,
2591  "__neumann_face_vertices",
2592  "",
2593  "__2_cells",
2594  "dlinear",
2595  "www.lpsweb.com/fiber_bundles/fiber_bundles_namespace.html",
2596  1,
2597  true,
2598  false);
2599  lsrd.put_name("neumann_vertex_face_dlinear_3D", true, false);
2600 
2601  lsrd.new_jim_state(xhost,
2602  "__dirichlet_face_vertices",
2603  "",
2604  "__1_cells",
2605  "dlinear",
2606  "www.lpsweb.com/fiber_bundles/fiber_bundles_namespace.html",
2607  1,
2608  true,
2609  false);
2610  lsrd.put_name("dirichlet_vertex_face_dlinear_2D", true, false);
2611 
2612  lsrd.new_jim_state(xhost,
2613  "__dirichlet_face_vertices",
2614  "",
2615  "__2_cells",
2616  "dlinear",
2617  "www.lpsweb.com/fiber_bundles/fiber_bundles_namespace.html",
2618  1,
2619  true,
2620  false);
2621  lsrd.put_name("dirichlet_vertex_face_dlinear_3D", true, false);
2622 
2623  lsrd.new_jim_state(xhost,
2624  "__neumann_face_vertices",
2625  "",
2626  "__vertices",
2627  "dlinear",
2628  "www.lpsweb.com/fiber_bundles/fiber_bundles_namespace.html",
2629  1,
2630  false,
2631  false);
2632  lsrd.put_name("neumann_vertex_face_dlinear_1D", true, false);
2633 
2634  lsrd.new_jim_state(xhost,
2635  "__dirichlet_face_vertices",
2636  "",
2637  "__vertices",
2638  "dlinear",
2639  "www.lpsweb.com/fiber_bundles/fiber_bundles_namespace.html",
2640  1,
2641  false,
2642  false);
2643  lsrd.put_name("dirichlet_vertex_face_dlinear_1D", true, false);
2644 
2645  lsrd.new_jim_state(xhost,
2646  "__vertices",
2647  "",
2648  "__vertices",
2649  "constant",
2650  "www.lpsweb.com/fiber_bundles/fiber_bundles_namespace.html",
2651  1,
2652  false,
2653  false);
2654  lsrd.put_name("vertex_vertex_constant", true, false);
2655 
2656  lsrd.new_jim_state(xhost,
2657  "__cells",
2658  "",
2659  "__cells",
2660  "constant",
2661  "www.lpsweb.com/fiber_bundles/fiber_bundles_namespace.html",
2662  1,
2663  false,
2664  false);
2665  lsrd.put_name("cells_cells_constant", true, false);
2666 
2667  lsrd.detach_from_state();
2668 
2669  // Postconditions:
2670 
2671  // Exit:
2672 
2673  return;
2674 }
2675 
2676 void
2679 {
2680  // Preconditions:
2681 
2682  require(state_is_read_write_accessible());
2684 
2685 
2686  // Body:
2687 
2688  // Create the poset.
2689 
2691  poset_path lschema_path = primitives().schema().path(false);
2692 
2693  poset* lschema_host = &poset::new_table(const_cast<fiber_bundles_namespace&>(*this), lname, lschema_path, false);
2694  lschema_host->get_read_write_access();
2695 
2696  subposet table_dofs(lschema_host);
2697  table_dofs.put_name(schema_poset_member::table_dof_subposet_name("top"), true, false);
2698 
2699  subposet row_dofs(lschema_host);
2700  row_dofs.put_name(schema_poset_member::row_dof_subposet_name("top"), true, false);
2701 
2702  // Create the members.
2703 
2705 
2706  // Schematize the schema poset and all its members
2707 
2708  lschema_host->schematize(&table_dofs, &row_dofs, true);
2709 
2710  // Detach all the handles allocated on the stack
2711 
2712  table_dofs.detach_from_state();
2713  row_dofs.detach_from_state();
2714 
2715  lschema_host->release_access();
2716 
2718 
2719  // Postconditions:
2720 
2722 
2723  // Exit:
2724 
2725  return;
2726 }
2727 
2728 void
2731 {
2732  // Preconditions:
2733 
2734  require(state_is_read_write_accessible());
2737 
2738  // Body:
2739 
2742 
2743  // Postconditions:
2744 
2745 
2746  // Exit:
2747 
2748  return;
2749 }
2750 
2751 // PRIVATE MEMBER FUNCTIONS
2752 
2753 // ===========================================================
2754 // MEMBER POSET FACET
2755 // ===========================================================
2756 
2757 // PUBLIC MEMBER FUNCTIONS
2758 
2759 // PROTECTED MEMBER FUNCTIONS
2760 
2761 void
2764 {
2765  // Preconditions:
2766 
2767  require(contains_member(&xmbr));
2768  require(in_jim_edit_mode());
2769 
2770  // Body:
2771 
2772  pod_index_type lmbr_schema_id = xmbr.poset_prereq_id(0);
2773 
2774  if((lmbr_schema_id == PRIMITIVES_SCHEMA_INDEX) ||
2775  (lmbr_schema_id == member_id("section_space_schema_schema", false)))
2776  {
2777  // This is a schema poset; link it under the schema defintions group.
2778 
2779  new_link(SCHEMA_DEFINITIONS_INDEX, xmbr.index().pod());
2780 
2781  new_link(xmbr.index().pod(), BOTTOM_INDEX);
2782  }
2783  else if(lmbr_schema_id == member_id(base_space_member::standard_schema_path().poset_name(), false))
2784  {
2785  // This is a base space poset; link it under the base space group.
2786 
2787  pod_index_type lbase_spaces_id = member_id("base_spaces", false);
2788 
2789  if(!is_valid(lbase_spaces_id))
2790  {
2791  // base spaces member not created yet; create it now.
2792 
2793  lbase_spaces_id = new_member(false, 0, false);
2794  put_member_name(lbase_spaces_id, "base_spaces", true, false);
2795 
2796  new_link(TOP_INDEX, lbase_spaces_id);
2797  }
2798  new_link(lbase_spaces_id, xmbr.index().pod());
2799 
2800  new_link(xmbr.index().pod(), BOTTOM_INDEX);
2801  }
2802  else if(lmbr_schema_id == member_id(tuple::standard_schema_path().poset_name(), false))
2803  {
2804  pod_index_type lfiber_spaces_id = member_id("fiber_spaces", false);
2805 
2806  if(!is_valid(lfiber_spaces_id))
2807  {
2808  // fiber spaces member not created yet; create it now.
2809 
2810  lfiber_spaces_id = new_member(false, 0, false);
2811  put_member_name(lfiber_spaces_id, "fiber_spaces", true, false);
2812 
2813  new_link(TOP_INDEX, lfiber_spaces_id);
2814  }
2815 
2816  // Test to see if this member comforms to tp.
2817 
2818  // poset_path lpath(tp::standard_schema_path());
2819  bool lconforms = xmbr.poset_pointer()->schema().conforms_to(tp::standard_schema_path());
2820 
2821  // If it conforms, create the tensor space family if necessary
2822  // and link this member to that group.
2823 
2824  if(lconforms)
2825  {
2826  pod_index_type ltensor_family_id = member_id("tensor_space_family", false);
2827 
2828  if(!is_valid(ltensor_family_id))
2829  {
2830  // tensor space family member not created yet; create it now.
2831 
2832  ltensor_family_id = new_member(false, 0, false);
2833  put_member_name(ltensor_family_id, "tensor_space_family", true, false);
2834 
2835  new_link(lfiber_spaces_id, ltensor_family_id);
2836  }
2837 
2838  // This is a tensor space; link it under the tensor space family group.
2839 
2840  new_link(ltensor_family_id, xmbr.index().pod());
2841  }
2842  else
2843  {
2844  // This is a fiber space but not in the tensor space family;
2845  // so, link it under the fiber spaces group.
2846 
2847  new_link(lfiber_spaces_id, xmbr.index().pod());
2848  }
2849 
2850  new_link(xmbr.index().pod(), BOTTOM_INDEX);
2851  }
2852  else if(dynamic_cast<sec_rep_space*>(xmbr.poset_pointer()) != 0)
2853  {
2854  // This is a section space, link it under the section spaces group.
2855 
2856  pod_index_type lsection_spaces_id = member_id("section_spaces", false);
2857 
2858  if(!is_valid(lsection_spaces_id))
2859  {
2860  // Section spaces member not created yet; create it now.
2861 
2862  lsection_spaces_id = new_member(false, 0, false);
2863  put_member_name(lsection_spaces_id, "section_spaces", true, false);
2864 
2865  new_link(TOP_INDEX, lsection_spaces_id);
2866  }
2867  else if(is_jem(lsection_spaces_id, BOTTOM_INDEX))
2868  {
2869  // This group exists but is empty;
2870  // delete its link to bottom.
2871 
2872  delete_link(lsection_spaces_id, BOTTOM_INDEX);
2873  }
2874  new_link(lsection_spaces_id, xmbr.index().pod());
2875 
2876  new_link(xmbr.index().pod(), BOTTOM_INDEX);
2877  }
2878  else
2879  {
2880  // Default is xmbr is in general spaces group.
2881 
2882  pod_index_type lgeneral_sets_id = member_id("general_sets", false);
2883 
2884  if(!is_valid(lgeneral_sets_id))
2885  {
2886  // general sets member not created yet; create it now.
2887 
2888  lgeneral_sets_id = new_member(false, 0, false);
2889  put_member_name(lgeneral_sets_id, "general_sets", true, false);
2890 
2891  new_link(TOP_INDEX, lgeneral_sets_id);
2892  }
2893  new_link(lgeneral_sets_id, xmbr.index().pod());
2894 
2895  new_link(xmbr.index().pod(), BOTTOM_INDEX);
2896  }
2897 
2898  // Postconditions:
2899 
2900 
2901  // Exit:
2902 
2903  return;
2904 }
2905 
2906 // PRIVATE MEMBER FUNCTIONS
2907 
2908 // ===========================================================
2909 // FACTORY INITIALIZATION FACET
2910 // ===========================================================
2911 
2912 // PUBLIC MEMBER FUNCTIONS
2913 
2914 void
2917 {
2918  // Preconditions:
2919 
2920  // Body:
2921 
2926 
2927  // Postconditions:
2928 
2929  // Exit:
2930 
2931  return;
2932 }
2933 
2934 void
2937 {
2938  // Preconditions:
2939 
2940  // Body:
2941 
2942  static bool lposet_prototypes_initialized = false;
2943 
2944  if(!lposet_prototypes_initialized)
2945  {
2947 
2948  // Initialize the prototypes
2949 
2950  base_space_poset::make_prototype();
2951 
2953  sec_at0_space::make_prototype();
2954  sec_at1_space::make_prototype();
2955  sec_atp_space::make_prototype();
2956  sec_jcb_space::make_prototype();
2957  sec_rep_space::make_prototype();
2959  sec_stp_space::make_prototype();
2960  sec_tp_space::make_prototype();
2961  sec_tuple_space::make_prototype();
2962  sec_vd_space::make_prototype();
2963 
2964  at0_space::make_prototype();
2965  at1_space::make_prototype();
2966  atp_space::make_prototype();
2967  gln_space::make_prototype();
2968  jcb_space::make_prototype();
2969  stp_space::make_prototype();
2970  tp_space::make_prototype();
2971  tuple_space::make_prototype();
2972  vd_space::make_prototype();
2973 
2974  // Done with prototype initializations.
2975 
2976  lposet_prototypes_initialized = true;
2977 
2978 #ifdef DIAGNOSTIC_OUTPUT
2979  cout << "Initialized fiber bundles poset prototypes" << endl;
2980 #endif
2981 
2982  }
2983 
2984  // Postconditions:
2985 
2986  // Exit:
2987 
2988  return;
2989 }
2990 
2991 void
2994 {
2995  // Preconditions:
2996 
2997  // Body:
2998 
2999  static bool lcrg_interval_prototypes_initialized = false;
3000 
3001  if(!lcrg_interval_prototypes_initialized)
3002  {
3004 
3005  // Initialize the prototypes
3006 
3007  point_block_crg_interval::make_prototype();
3008  structured_block_1d_crg_interval::make_prototype();
3009  structured_block_2d_crg_interval::make_prototype();
3010  structured_block_3d_crg_interval::make_prototype();
3011  zone_nodes_block_crg_interval::make_prototype();
3012 
3013  // Done with prototype initializations.
3014 
3015  lcrg_interval_prototypes_initialized = true;
3016 
3017 #ifdef DIAGNOSTIC_OUTPUT
3018  cout << "Initialized fiber bundles crg interval prototypes" << endl;
3019 #endif
3020  }
3021 
3022  // Postconditions:
3023 
3024  // Exit:
3025 
3026  return;
3027 }
3028 
3029 void
3032 {
3033  // Preconditions:
3034 
3035  // Body:
3036 
3037  static bool ldof_map_prototypes_initialized = false;
3038 
3039  if(!ldof_map_prototypes_initialized)
3040  {
3042 
3043  // Initialize the prototypes
3044 
3045  array_section_dof_map::make_prototype();
3046  sparse_section_dof_map::make_prototype();
3047 
3048  // Done with prototype initializations.
3049 
3050  ldof_map_prototypes_initialized = true;
3051 
3052 #ifdef DIAGNOSTIC_OUTPUT
3053  cout << "Initialized fiber bundles dof map prototypes" << endl;
3054 #endif
3055  }
3056 
3057  // Postconditions:
3058 
3059  // Exit:
3060 
3061  return;
3062 }
3063 
3064 void
3067 {
3068  // Preconditions:
3069 
3070  // Body:
3071 
3072  static bool lid_space_prototypes_initialized = false;
3073 
3074  if(!lid_space_prototypes_initialized)
3075  {
3077 
3078  // Initialize the prototypes
3079 
3080  section_space_schema_jims_index_space_state::make_prototype();
3081 
3082  i_adjacency_index_space_interval::make_prototype();
3083  i_connectivity_index_space_interval::make_prototype();
3084  ij_adjacency_index_space_interval::make_prototype();
3085  ij_connectivity_index_space_interval::make_prototype();
3086  ijk_adjacency_index_space_interval::make_prototype();
3087  ijk_connectivity_index_space_interval::make_prototype();
3088 
3089  // Done with prototype initializations.
3090 
3091  lid_space_prototypes_initialized = true;
3092 
3093 #ifdef DIAGNOSTIC_OUTPUT
3094  cout << "Initialized fiber bundles id space prototypes" << endl;
3095 #endif
3096  }
3097 
3098  // Postconditions:
3099 
3100  // Exit:
3101 
3102  return;
3103 }
3104 
3105 // PROTECTED MEMBER FUNCTIONS
3106 
3107 void
3110 {
3111  // cout << endl << "Entering namespace_poset::virutal_initialize_prototypes." << endl;
3112 
3113  // Preconditions:
3114 
3115 
3116  // Body:
3117 
3118  // Call static version defined in this class.
3119 
3121 
3122  // Postconditions:
3123 
3124 
3125  // Exit:
3126 
3127  // cout << "Leaving namespace_poset::virutal_initialize_prototypes." << endl;
3128  return;
3129 }
3130 
3131 // PRIVATE MEMBER FUNCTIONS
3132 
3133 // ===========================================================
3134 // STATE FACET
3135 // ===========================================================
3136 
3137 // PUBLIC MEMBER FUNCTIONS
3138 
3141 type_id() const
3142 {
3143  return FIBER_BUNDLES_NAMESPACE_ID;
3144 }
3145 
3146 const char*
3148 class_name() const
3149 {
3150  // Preconditions:
3151 
3152 
3153  // Body:
3154 
3155  static const char* result = "fiber_bundles_namespace";
3156 
3157  // Postconditions:
3158 
3159  // Exit:
3160 
3161  return result;
3162 }
3163 
3164 // PROTECTED MEMBER FUNCTIONS
3165 
3166 // PRIVATE MEMBER FUNCTIONS
3167 
3168 // ===========================================================
3169 // MEMBERSHIP FACET
3170 // ===========================================================
3171 
3172 // PUBLIC MEMBER FUNCTIONS
3173 
3174 // PROTECTED MEMBER FUNCTIONS
3175 
3176 void
3179 {
3180  // Preconditions:
3181 
3182  require(state_is_read_write_accessible());
3183 
3184  define_old_variable(int old_access_request_depth = access_request_depth());
3185 
3186 
3187  // Body:
3188 
3192 
3193  // Postconditions:
3194 
3195  ensure(access_request_depth() == old_access_request_depth);
3196 
3197 
3198  // Exit:
3199 
3200  return;
3201 }
3202 
3203 // PRIVATE MEMBER FUNCTIONS
static const poset_path & standard_schema_path()
The path to the standard schema for this class.
Definition: gln.cc:551
virtual void get_read_write_access(bool xrelease_read_only_access=false)
Get read write access to the state associated with this. If release_read_only_access is requested...
static void make_standard_schema(namespace_poset &xns)
Creates the standard schema for this class in namespace xns.
Definition: st4_e3.cc:529
static void make_standard_schema(namespace_poset &xns)
Creates the standard schema for this class in namespace xns.
Definition: st3.cc:448
virtual void delete_link(pod_index_type xgreater, pod_index_type xlesser)
Delete the cover link between hub id xgreater and hub id xlesser.
A client handle for a subposet.
Definition: subposet.h:86
static void make_standard_schema(namespace_poset &xns)
Creates the standard schema for this class in namespace xns.
Definition: gl2.cc:742
static const poset_path & standard_schema_path()
The path of the schema required by this class.
Definition: tuple.cc:270
static void make_standard_schema(namespace_poset &xns)
Creates the standard schema for this class in namespace xns.
Definition: st2_e3.cc:611
static const poset_path & static_local_cell_prototype_path()
The path of the local cell prototype required by this class.
void make_hex_nodes_prototype(base_space_poset *xspace)
Create prototype for a hex with nodes in poset xspace.
static const poset_path & static_prototype_path()
The path of the prototype required by this class.
static void make_standard_schema(namespace_poset &xns)
Creates the standard schema for this class in namespace xns.
Definition: st2.cc:450
void make_structured_block_1d_prototype(base_space_poset *xspace)
Create prototype for a 1D structured block in poset xspace.
virtual void schematize(subposet *xtable_dof_subposet, subposet *xrow_dof_subposet, bool xall_members=false)
Prepare this poset and its top member for use as a schema. If xall_members = true, schematize all other members as well.
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)...
virtual void create_cover_link(abstract_poset_member *xlesser)
Insert a link from this to lesser; make lesser <= this.
static void make_standard_schema(namespace_poset &xns)
Creates the standard schema for this class in namespace xns.
Definition: e2.cc:720
static void initialize_crg_interval_prototypes()
Initialize the prototypes needed by crg interval factory method,.
static void make_standard_schema(namespace_poset &xns)
Creates the standard schema for this class in namespace xns.
Definition: t2_e3.cc:711
abstract_poset_member & top()
The top member of the poset (mutable version)
size_type ct() const
The number of items currently in use.
static const poset_path & static_local_cell_prototype_path()
The path of the local cell prototype required by this class.
static const poset_path & standard_schema_path()
The path to the standard schema for this class.
Definition: at0.cc:681
const pod_type & pod() const
The "plain old data" storage of this; the value in the external id space.
Definition: scoped_index.h:672
static void make_standard_schema(namespace_poset &xns)
Creates the standard schema for this class in namespace xns.
Definition: at2_e2.cc:578
Euclidean vector space of dimension 4 (persistent version).
Definition: e4.h:410
static void make_standard_schema(namespace_poset &xns)
Creates the standard schema for this class in namespace xns.
Definition: ed.cc:364
sheaves_namespace()
Default constructor; creates an unattached handle.
void make_unstructured_block_prototype(base_space_poset *xspace)
Create prototype for an unstructured block in poset xspace.
Euclidean vector space of dimension 2 (persistent version).
Definition: e2.h:405
static poset & new_table(namespace_type &xhost, const poset_path &xpath, const poset_path &xschema_path, bool xauto_access)
Creates a new poset in namespace xns with path xpath and schema specified by xschema_path.
Definition: poset.cc:42
virtual poset_type type_id() const
Identifier for the type of this poset.
static void make_standard_schema(namespace_poset &xns)
Creates the standard schema for this class in namespace xns.
Definition: e3.cc:1118
static void make_standard_schema(namespace_poset &xns)
Creates the standard schema for this class in namespace xns.
Definition: met_ed.cc:366
void make_triangle_prototype(base_space_poset *xspace)
Create prototype for a triangle in poset xspace.
void make_hex_complex_prototype(base_space_poset *xspace)
Create prototype for a hex with faces, edges, and nodes in poset xspace.
poset_path path(bool xauto_access=true) const
A path to this component.
bool conforms_to(const schema_poset_member &xother) const
True if the dofs defined by this agree in type and in order with the dofs defined by xother...
static const poset_path & standard_host_path()
The standard path for host spaces for this class.
static void make_standard_schema(namespace_poset &xns)
Creates the standard schema for this class in namespace xns.
Definition: t2_e2.cc:683
static void make_standard_schema(namespace_poset &xns)
Creates the standard schema for this class in namespace xns.
Definition: jcb_e23.cc:572
poset_type
Identifiers for poset types.
Definition: poset_type.h:41
static void make_standard_schema(namespace_poset &xns)
Creates the standard schema for this class in namespace xns.
Definition: at3_e3.cc:527
bool contains_poset_member(pod_index_type xposet_hub_id, pod_index_type xmember_hub_id, bool xauto_access=true) const
True if this contains a poset with hub id xposet_hub_id which contains a member with hub id xmember_h...
static void make_standard_schema(namespace_poset &xns)
Creates the standard schema for this class in namespace xns.
Definition: tuple.cc:291
static void make_standard_schema(namespace_poset &xns)
Creates the standard schema for this class in namespace xns.
Definition: at2_e3.cc:601
virtual void make_sec_rep_descriptors(sec_rep_descriptor_poset *xhost)
Create standard section representation descriptors in poset xhost.
primitives_poset & primitives()
The poset of primitives for this namespace (mutable version)
static const poset_path & static_prototype_path()
The path of the prototype required by this class.
void make_point_block_3d_prototype(base_space_poset *xspace)
Create prototype for a 3D point block in poset xspace.
void make_sec_rep_descriptor_schema_poset()
Create schema poset for standard sec_rep_descritpors.
void make_quad_nodes_prototype(base_space_poset *xspace)
Create prototype for a quad with nodes in poset xspace.
A path defined by a poset name and a member name separated by a forward slash (&#39;/&#39;). For example: "cell_definitions/triangle".
Definition: poset_path.h:48
const index_space_family & member_id_spaces(bool xauto_access) const
Collection of member id spaces for this (const version).
virtual bool is_atom(pod_index_type xmbr_hub_id) const
True if the member with hub id xmbr_hub_id covers the bottom.
virtual bool contains_member(pod_index_type xmbr_hub_id) const
True if this poset contains poset member with hub id xmbr_hub_id.
Definition: subposet.cc:955
static void make_standard_schema(namespace_poset &xns)
Creates the standard schema for this class in namespace xns.
Definition: st2_e2.cc:604
STL namespace.
static const poset_path & static_prototype_path()
The path of the prototype required by this class.
static const poset_path & standard_schema_path()
The path of the schema required by this class.
static void make_standard_schema(namespace_poset &xns)
Creates the standard schema for this class in namespace xns.
Definition: t4.cc:457
std::string row_dof_subposet_name() const
The standard name for the row dof subposet associated with this schema member. Synonym for dof_subpos...
static void make_standard_schema(namespace_poset &xns)
Creates the standard schema for this class in namespace xns.
Definition: t4_e3.cc:489
The standard sheaves name space.
static void make_standard_schema(namespace_poset &xns)
Creates the standard schema for this class in namespace xns.
Definition: at2.cc:486
poset_state_handle & member_poset(pod_index_type xhub_id, bool xauto_access=true) const
The poset_state_handle object referred to by hub id xhub_id.
static const poset_path & static_local_cell_prototype_path()
The path of the local cell prototype required by this class.
const scoped_index & index() const
The index of the component state this handle is attached to.
The poset for sec_rep_descriptors.
abstract_poset_member & bottom()
The bottom member of the poset (mutable version)
virtual void put_member_name(pod_index_type xmbr_hub_id, const std::string &xname, bool xunique, bool xauto_access=false)
Make xname a name for the member with hub id xmbr_hub_id. if xunique, make xname the only name...
static const std::string & prototypes_poset_name()
The name of the prototypes poset.
Euclidean vector space of dimension 3 (persistent version).
Definition: e3.h:467
T::row_dofs_type & row_dofs(T &x0)
The row dofs pod type for x0 (mutable version).
void make_segment_prototype(base_space_poset *xspace)
Create prototype for a line segement (i.e. an edge) in poset xspace.
static void make_standard_schema(namespace_poset &xns)
Creates the standard schema for this class in namespace xns.
Definition: gl3.cc:879
virtual pod_index_type new_member(bool xis_jim, pod_index_type xtuple_hub_id)
Create a disconnected member with is_jim == xis_jim and the dof tuple identified by hub id xtuple_hub...
Euclidean vector space of dimension 1 (persistent version).
Definition: e1.h:400
static void initialize_dof_map_prototypes()
Initialize the prototypes needed by dof map factory method,.
A client handle for a member of a base space poset.
static void initialize_dof_map_prototypes()
Initialize the prototypes needed by dof map factory method,.
static void make_standard_schema(namespace_poset &xns)
Creates the standard schema for this class in namespace xns.
Definition: jcb.cc:507
virtual bool is_jem(pod_index_type xmbr_hub_id, pod_index_type xother_hub_id) const
True if hub id xother_hub_id is join equivalent to hub id xmbr_hub_id.
static void initialize_poset_prototypes()
Initialize the prototypes needed by poset factory method,.
void make_general_polyhedron_prototype(base_space_poset *xspace)
Create prototype for a general polyhedron in poset xspace.
virtual void make_base_space_member_prototypes(base_space_poset *xspace)
Create standard base space member prototypes.
A client handle for a member of a namespace poset.
static void initialize_poset_prototypes()
Initialize the prototypes needed by poset factory method,.
static void make_standard_schema(namespace_poset &xns)
Creates the standard schema for this class in namespace xns.
Definition: jcb_ed.cc:338
void make_hex_prototype(base_space_poset *xspace)
Create prototype for a hex in poset xspace.
static const poset_path & standard_schema_path()
The path to the standard schema for this class.
Definition: tp.cc:435
virtual void link_poset(const namespace_poset_member &xmbr)
Links xmbr into the appropriate group.
The lattice of closed cells of a cellular space; a lattice representation of a computational mesh...
void make_point_block_1d_prototype(base_space_poset *xspace)
Create prototype for a 1D point block in poset xspace.
virtual void put_name(const std::string &xname, bool xunique, bool xauto_access)
Make xname a name for this; if xunique, make xname the only name.
Definition: subposet.cc:2782
const bool NOT_STRICT
Iteration strictness control.
Definition: sheaf.h:102
const bool DOWN
Iteration directions.
Definition: sheaf.h:77
virtual void make_fiber_spaces()
Create standard fiber spaces.
virtual schema_poset_member & schema()
The schema for this poset (mutable version).
virtual void make_sec_rep_descriptor_schema_members()
Create schema members for standard sec_rep_descriptors.
void push_back(const_reference_type item)
Insert item at the end of the items in the auto_block.
static const poset_path & static_prototype_path()
The path of the prototype required by this class.
void make_fiber_space_definitions()
Create standard fiber schema and fiber spaces.
static void make_standard_schema(namespace_poset &xns)
Creates the standard schema for this class in namespace xns.
Definition: tp.cc:456
pod_index_type poset_prereq_id(int xi) const
The id of the xi-th prerequisite poset for the poset associated with this namespace member...
void make_point_block_2d_prototype(base_space_poset *xspace)
Create prototype for a 2D point block in poset xspace.
fiber_bundles_namespace()
Default constructor; creates an unattached handle.
static const poset_path & static_prototype_path()
The path of the prototype required by this class.
A client handle for a mutable partially ordered set.
Definition: poset.h:40
bool state_is_read_write_accessible() const
True if this is attached and if the state is accessible for read and write or access control is disab...
static void initialize_crg_interval_prototypes()
Initialize the prototypes needed by crg interval factory method,.
pointer_type base() const
The underlying storage array.
static const poset_path & standard_schema_path()
The path to the standard schema for this class.
Definition: met.cc:344
static const poset_path & static_local_cell_prototype_path()
The path of the local cell prototype required by this class.
void * table_dofs()
The table dofs for this instance (mutable version).
void set_ct(size_type xct)
Sets ct() == xct.
An index within the external ("client") scope of a given id space.
Definition: scoped_index.h:116
static const poset_path & static_prototype_path()
The path of the prototype required by this class.
static void make_standard_schema(namespace_poset &xns)
Creates the standard schema for this class in namespace xns.
Definition: st3_e3.cc:529
poset_state_handle * poset_pointer() const
The pointer to the poset associated with this namespace member.
void make_tetra_nodes_prototype(base_space_poset *xspace)
Create prototype for a tetrahedron with nodes in poset xspace.
Specialization of the filtered depth-first iterator which exposes the PREVISIT_ACTION and the POSTVIS...
virtual const char * class_name() const
The name of this class.
std::string poset_name() const
The poset name part of the path.
Definition: poset_path.cc:473
static void make_standard_schema(namespace_poset &xns)
Creates the standard schema for this class in namespace xns.
Definition: st4_e2.cc:529
virtual void insert_member(pod_index_type xmbr_hub_id)
Inserts the member of host() with hub id xmbr_hub_id.
Definition: subposet.cc:1091
static void make_standard_schema(namespace_poset &xns)
Creates the standard schema for this class in namespace xns.
Definition: at3.cc:468
virtual void make_section_space_schema_schema_members()
Create schema members for standard section space schema.
static void make_standard_schema(namespace_poset &xns)
Creates the standard schema for this class in namespace xns.
Definition: at0.cc:699
static void make_standard_schema(namespace_poset &xns)
Creates the standard schema for this class in namespace xns.
Definition: e4.cc:684
virtual bool contains_member(pod_index_type xmbr_hub_id, bool xauto_access=true) const
True if some version of this poset contains poset member with hub id xmbr_hub_id. ...
static void make_standard_schema(namespace_poset &xns)
Creates the standard schema for this class in namespace xns.
Definition: met_e1.cc:574
void make_tetra_prototype(base_space_poset *xspace)
Create prototype for a tetrahedron in poset xspace.
virtual std::string member_name(pod_index_type xmbr_hub_id, bool xauto_access=false) const
A name for the member with hub id xmbr_hub_id.
virtual void initialize_additional_members()
Creates additional members for this namespace.
virtual void put_name(const std::string &xname, bool xunique, bool xauto_access)
Make xname a name for this; if xunique, make xname the only name.
static void make_standard_schema(namespace_poset &xns)
Creates the standard schema for this class in namespace xns.
Definition: stp.cc:375
static void make_standard_schema(namespace_poset &xns)
Creates the standard schema for this class in namespace xns.
Definition: met.cc:362
void make_section_space_schema_schema_poset()
Create schema poset for standard section space schema.
virtual void release_access(bool xall=false) const
Release access. If xall is true, release all levels of access. Otherwise, release one level of access...
const bool UP
Iteration directions.
Definition: sheaf.h:82
static void make_standard_schema(namespace_poset &xns)
Creates the standard schema for this class in namespace xns.
Definition: vd.cc:746
void make_triangle_nodes_prototype(base_space_poset *xspace)
Create prototype for a triangle with nodes in poset xspace.
void make_triangle_complex_prototype(base_space_poset *xspace)
Create prototype for a triangle with edges and nodes in poset xspace.
void make_segment_complex_prototype(base_space_poset *xspace)
Create prototype for a line segement complex, i.e. an edge and the veritices it contains, in poset xspace.
static void make_standard_schema(namespace_poset &xns)
Creates the standard schema for this class in namespace xns.
Definition: t4_e2.cc:539
bool contains_poset(pod_index_type xhub_id, bool xauto_access=true) const
True if this contains a poset with hub id xhub_id..
static void initialize_prototypes()
Initialize all the prototypes needed by various factory methods,.
static void initialize_id_space_prototypes()
Initialize the prototypes needed by id space factory method,.
virtual void make_base_space_schema_members()
Create schema members for standard base space member types.
static host_type & standard_host(namespace_type &xns, const poset_path &xhost_path, int xmax_db, bool xauto_access)
The host with path xhost_path. Returns the host if it already exists, otherwise, creates it in namesp...
void make_sec_rep_descriptor_poset()
Create the standard sec_rep_descriptor poset.
static const poset_path & standard_schema_path()
The path of the schema required by this class.
void make_structured_block_3d_prototype(base_space_poset *xspace)
Create prototype for a 3D structured block in poset xspace.
virtual void detach_from_state()
Detach this handle from its state, if any.
static void initialize_id_space_prototypes()
Initialize the prototypes needed by id space factory method,.
void make_quad_prototype(base_space_poset *xspace)
Create prototype for a quad in poset xspace.
static void make_standard_schema(namespace_poset &xns)
Creates the standard schema for this class in namespace xns.
Definition: t3_e3.cc:573
int access_request_depth() const
The number of times access has been requested and granted without being released. ...
virtual void make_fiber_space_schema_members()
Create schema members for standard fiber space types.
static bool make_prototype()
Creates prototype for this class and enters in in factory.
static void make_standard_schema(namespace_poset &xns)
Creates the standard schema for this class in namespace xns.
Definition: st4.cc:476
static void make_standard_schema(namespace_poset &xns)
Creates the standard schema for this class in namespace xns.
void make_general_polygon_prototype(base_space_poset *xspace)
Create prototype for a general polygon in poset xspace.
void make_structured_block_2d_prototype(base_space_poset *xspace)
Create prototype for a 2D structured block in poset xspace.
static void make_standard_schema(namespace_poset &xns)
Creates the standard schema for this class in namespace xns.
Definition: jcb_e33.cc:588
void make_tetra_complex_prototype(base_space_poset *xspace)
Create prototype for a tetrahedron with faces, edges, and nodes in poset xspace.
static const poset_path & standard_schema_path()
The path to the standard schema for this class.
Definition: stp.cc:354
static const poset_path & static_local_cell_prototype_path()
The path of the local cell prototype required by this class.
static bool make_prototype()
Creates prototype for this class and enters in in factory.
int_type pod_index_type
The plain old data index type.
Definition: pod_types.h:49
std::string member_name() const
The member name part of the path.
Definition: poset_path.cc:511
static const poset_path & standard_schema_path()
The path to the standard schema for this class.
Definition: jcb.cc:486
virtual scoped_index member_index_ub() const
The upper bound on the member_index;.
static void make_standard_schema(namespace_poset &xns)
Creates the standard schema for this class in namespace xns.
void make_point_prototype(base_space_poset *xspace)
Create prototype for a single point (i.e. a vertex) in poset xspace.
static void make_standard_schema(namespace_poset &xns)
Creates the standard schema for this class in namespace xns.
Definition: met_e2.cc:627
static void make_standard_schema(namespace_poset &xns)
Creates the standard schema for this class in namespace xns.
Definition: e1.cc:694
void make_base_space_schema_poset()
Create schema poset for standard base space member types.
static array_index_space_handle new_space(index_space_family &xid_spaces, const std::string &xname, bool xis_persistent, size_type xcapacity)
Create a new array id space in the id space family xid_spaces at the next available id space index wi...
static const poset_path & static_prototype_path()
The path of the prototype required by this class.
void make_part_prototype(base_space_poset *xspace)
Create prototype for a part in poset xspace.
static host_type & standard_host(namespace_type &xns, bool xauto_access)
The host with path standard_host_path(). Returns the host if it already exists, otherwise, creates it in namespace xns with schema specified by standard_schema_path() and standard paths for prerequisites, which are also created if needed.
static const poset_path & static_prototype_path()
The path of the prototype required by this class.
virtual void end_jim_edit_mode(bool xensure_lattice_invariant=true, bool xauto_access=true)
Prevent editing of jims and jim order relation.
Definition: poset.cc:253
static void make_standard_schema(namespace_poset &xns)
Creates standard schema for this class in namespace xns.
void make_fiber_space_schema_poset()
Create schema poset for standard fiber space types.
static void make_standard_schema(namespace_poset &xns)
Creates the standard schema for this class in namespace xns.
Definition: jcb_e13.cc:566
virtual void new_jim_state(poset_dof_map *xdof_map=0, bool xcopy_dof_map=false, bool xauto_access=true)
Creates a new jim (join-irreducible member) state in host() and attaches this to it. If xdof_map == 0 a new dof map is created. If xdof_map != 0 and xcopy_dof_map == false, xdof_map is used as the dof map. If xdof_map != 0 and xcopy_dof_map is true, a copy of xdof_map is used.
static void make_standard_schema(namespace_poset &xns)
Creates the standard schema for this class in namespace xns.
Definition: atp.cc:227
static void make_standard_schema(namespace_poset &xns)
Creates the standard schema for this class in namespace xns.
Definition: t3.cc:468
bool in_jim_edit_mode() const
True if editing jims and jim order relation is allowed.
static const poset_path & standard_schema_path()
The path to the standard schema for this class.
Definition: at1.cc:353
static void make_standard_schema(namespace_poset &xns)
Creates the standard schema for this class in namespace xns.
Definition: at1.cc:371
SHEAF_DLL_SPEC bool is_valid(pod_index_type xpod_index)
True if an only if xpod_index is valid.
Definition: pod_types.cc:37
An auto_block with a no-initialization initialization policy.
void make_hex_faces_nodes_prototype(base_space_poset *xspace)
Create prototype for a hex with faces and nodes in poset xspace.
Namespace for the fiber_bundles component of the sheaf system.
static const poset_path & standard_schema_path()
The path of the schema required by this class.
std::string table_dof_subposet_name() const
The standard name for the table dof subposet associated with this schema member. Synonym for dof_subp...
void make_zone_nodes_block_prototype(base_space_poset *xspace)
Create prototype for an zone_nodes block in poset xspace.
static void make_standard_schema(namespace_poset &xns)
Creates the standard schema for this class in namespace xns.
Definition: met_e3.cc:655
static void make_standard_schema(namespace_poset &xns)
Creates the standard schema for this class in namespace xns.
Definition: t2.cc:446
A client handle for a poset member which has been prepared for use as a schema.
static const poset_path & static_local_cell_prototype_path()
The path of the local cell prototype required by this class.
void make_base_space_definitions()
Create schema and prototypes for standard base space member types.
void make_section_space_definitions()
Create standard section representations and section schema.
virtual void virtual_initialize_prototypes()
Initialize all the prototypes needed by various factory methods; virtual version. ...
static const poset_path & standard_schema_path()
The path to the standard schema for this class.
Definition: atp.cc:206
void make_quad_complex_prototype(base_space_poset *xspace)
Create prototype for a quad with edges and nodes in poset xspace.
static void make_standard_schema(namespace_poset &xns)
Creates the standard schema for this class in namespace xns.
A description for a section representation scheme.
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...
void make_base_space_member_prototypes_poset()
Create standard base space member prototypes poset.
virtual void begin_jim_edit_mode(bool xauto_access=true)
Allow editing of jims and jim order relation.
Definition: poset.cc:230
static void make_standard_schema(namespace_poset &xns)
Creates the standard schema for this class in namespace xns.
Definition: gln.cc:572