refineable_elements.h
Go to the documentation of this file.
1 // LIC// ====================================================================
2 // LIC// This file forms part of oomph-lib, the object-oriented,
3 // LIC// multi-physics finite-element library, available
4 // LIC// at http://www.oomph-lib.org.
5 // LIC//
6 // LIC// Copyright (C) 2006-2022 Matthias Heil and Andrew Hazel
7 // LIC//
8 // LIC// This library is free software; you can redistribute it and/or
9 // LIC// modify it under the terms of the GNU Lesser General Public
10 // LIC// License as published by the Free Software Foundation; either
11 // LIC// version 2.1 of the License, or (at your option) any later version.
12 // LIC//
13 // LIC// This library is distributed in the hope that it will be useful,
14 // LIC// but WITHOUT ANY WARRANTY; without even the implied warranty of
15 // LIC// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
16 // LIC// Lesser General Public License for more details.
17 // LIC//
18 // LIC// You should have received a copy of the GNU Lesser General Public
19 // LIC// License along with this library; if not, write to the Free Software
20 // LIC// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
21 // LIC// 02110-1301 USA.
22 // LIC//
23 // LIC// The authors may be contacted at oomph-lib@maths.man.ac.uk.
24 // LIC//
25 // LIC//====================================================================
26 // Header file for classes that define refineable element objects
27 
28 // Include guard to prevent multiple inclusions of the header
29 #ifndef OOMPH_REFINEABLE_ELEMENTS_HEADER
30 #define OOMPH_REFINEABLE_ELEMENTS_HEADER
31 
32 // Config header generated by autoconfig
33 #ifdef HAVE_CONFIG_H
34 #include <oomph-lib-config.h>
35 #endif
36 
37 #include "elements.h"
38 #include "tree.h"
39 
40 namespace oomph
41 {
42  class Mesh;
43 
44  //=======================================================================
95  //======================================================================
96  class RefineableElement : public virtual FiniteElement
97  {
98  protected:
101 
103  unsigned Refine_level;
104 
107 
110 
113 
115  long Number;
116 
118  static double Max_integrity_tolerance;
119 
122  static void check_value_id(const int& n_continuously_interpolated_values,
123  const int& value_id);
124 
125 
132  const DShape& dpsids, DenseMatrix<double>& jacobian) const;
133 
140  const DShape& d2psids, DenseMatrix<double>& jacobian2) const;
141 
147  const DShape& dpsids, DenseMatrix<double>& interpolated_G) const;
148 
157  const DShape& dpsids,
158  DenseMatrix<double>& jacobian,
159  DenseMatrix<double>& inverse_jacobian) const;
160 
161  private:
167  std::map<Node*, int>* Local_hang_eqn;
168 
172  std::map<Node*, unsigned> Shape_controlling_node_lookup;
173 
174  protected:
176  void assign_hanging_local_eqn_numbers(const bool& store_local_dof_pt);
177 
183  Vector<double>& residuals, DenseMatrix<double>& jacobian);
184 
185  public:
189  : FiniteElement(),
190  Tree_pt(0),
191  Refine_level(0),
192  To_be_refined(false),
193  Refinement_is_enabled(true),
194  Sons_to_be_unrefined(false),
195  Number(-1),
196  Local_hang_eqn(0)
197  {
198  }
199 
201  // (The body is now in the cc file to keep the xlC compiler happy under AIX)
202  virtual ~RefineableElement();
203 
206 
208  void operator=(const RefineableElement&) = delete;
209 
212  {
213  return Tree_pt;
214  }
215 
217  void set_tree_pt(Tree* my_tree_pt)
218  {
219  Tree_pt = my_tree_pt;
220  }
221 
224  virtual unsigned required_nsons() const
225  {
226  return 0;
227  }
228 
229 
232  {
233  return Refinement_is_enabled;
234  }
235 
238  {
239  Refinement_is_enabled = false;
240  }
241 
244  {
245  Refinement_is_enabled = true;
246  }
247 
253  template<class ELEMENT>
254  void split(Vector<ELEMENT*>& son_pt) const
255  {
256  // Increase refinement level
257  int son_refine_level = Refine_level + 1;
258 
259  // How many sons are to be constructed
260  unsigned n_sons = required_nsons();
261  // Resize the son pointer
262  son_pt.resize(n_sons);
263 
264  // Loop over the sons and construct
265  for (unsigned i = 0; i < n_sons; i++)
266  {
267  son_pt[i] = new ELEMENT;
268  // Set the refinement level of the newly constructed son.
269  son_pt[i]->set_refinement_level(son_refine_level);
270  }
271  }
272 
273 
278  inline int local_hang_eqn(Node* const& node_pt, const unsigned& i)
279  {
280 #ifdef RANGE_CHECKING
282  {
283  std::ostringstream error_message;
284  error_message << "Range Error: Value " << i
285  << " is not in the range (0,"
286  << ncont_interpolated_values() - 1 << ")";
287  throw OomphLibError(error_message.str(),
290  }
291 #endif
292 
293  return Local_hang_eqn[i][node_pt];
294  }
295 
302  virtual void build(Mesh*& mesh_pt,
303  Vector<Node*>& new_node_pt,
304  bool& was_already_built,
305  std::ofstream& new_nodes_file) = 0;
306 
308  void set_refinement_level(const int& refine_level)
309  {
310  Refine_level = refine_level;
311  }
312 
314  unsigned refinement_level() const
315  {
316  return Refine_level;
317  }
318 
321  {
322  To_be_refined = true;
323  }
324 
327  {
328  To_be_refined = false;
329  }
330 
333  {
334  Sons_to_be_unrefined = true;
335  }
336 
340  {
341  Sons_to_be_unrefined = false;
342  }
343 
346  {
347  return To_be_refined;
348  }
349 
352  {
353  return Sons_to_be_unrefined;
354  }
355 
358  virtual void rebuild_from_sons(Mesh*& mesh_pt) = 0;
359 
362  virtual void unbuild()
363  {
364  // Get pointer to father element
365  RefineableElement* father_pt = father_element_pt();
366  // If there is no father, nothing to do
367  if (father_pt == 0)
368  {
369  return;
370  }
371 
372  // Loop over all the nodes
373  unsigned n_node = this->nnode();
374  for (unsigned n = 0; n < n_node; n++)
375  {
376  // If any node in this element is in the father, it can't be deleted
377  if (father_pt->get_node_number(this->node_pt(n)) >= 0)
378  {
380  }
381  }
382  }
383 
386  virtual void deactivate_element();
387 
389  virtual bool nodes_built()
390  {
391  return node_pt(0) != 0;
392  }
393 
395  long number() const
396  {
397  return Number;
398  }
399 
401  void set_number(const long& mynumber)
402  {
403  Number = mynumber;
404  }
405 
412  virtual unsigned ncont_interpolated_values() const = 0;
413 
418  Vector<double>& values)
419  {
420  get_interpolated_values(0, s, values);
421  }
422 
427  virtual void get_interpolated_values(const unsigned& t,
428  const Vector<double>& s,
429  Vector<double>& values) = 0;
430 
437  virtual Node* interpolating_node_pt(const unsigned& n, const int& value_id)
438 
439  {
440  return node_pt(n);
441  }
442 
448  const unsigned& n1d, const unsigned& i, const int& value_id)
449  {
450  return local_one_d_fraction_of_node(n1d, i);
451  }
452 
457  const Vector<double>& s, const int& value_id)
458 
459  {
461  }
462 
463 
466  virtual unsigned ninterpolating_node(const int& value_id)
467  {
468  return nnode();
469  }
470 
474  virtual unsigned ninterpolating_node_1d(const int& value_id)
475  {
476  return nnode_1d();
477  }
478 
481  virtual void interpolating_basis(const Vector<double>& s,
482  Shape& psi,
483  const int& value_id) const
484  {
485  shape(s, psi);
486  }
487 
492  virtual void check_integrity(double& max_error) = 0;
493 
495  static double& max_integrity_tolerance()
496  {
498  }
499 
505  std::set<std::pair<Data*, unsigned>>& paired_field_data);
506 
507 
511  inline void assign_nodal_local_eqn_numbers(const bool& store_local_dof_pt)
512  {
514  assign_hanging_local_eqn_numbers(store_local_dof_pt);
515  }
516 
525  {
526  // If there is no tree -- the element is its own root
527  if (Tree_pt == 0)
528  {
529  return this;
530  }
531  // Otherwise it's the tree's root object
532  else
533  {
534  return Tree_pt->root_pt()->object_pt();
535  }
536  }
537 
540  {
541  // If we have no tree, we have no father
542  if (Tree_pt == 0)
543  {
544  return 0;
545  }
546  else
547  {
548  // Otherwise get the father of the tree
549  Tree* father_pt = Tree_pt->father_pt();
550  // If the tree has no father then return null, no father
551  if (father_pt == 0)
552  {
553  return 0;
554  }
555  else
556  {
557  return father_pt->object_pt();
558  }
559  }
560  }
561 
565  unsigned& refinement_level, RefineableElement*& father_at_reflevel_pt)
566  {
567  // Get the father in the tree (it shouldn't try to get a null Tree...)
568  Tree* father_pt = Tree_pt->father_pt();
569  // Get the refineable element associated with this father
570  RefineableElement* father_el_pt =
571  dynamic_cast<RefineableElement*>(father_pt->object_pt());
572  // Get the refinement level
573  unsigned level = father_el_pt->refinement_level();
574  // If the level matches the required one then return, if not call again
575  if (level == refinement_level)
576  {
577  father_at_reflevel_pt = father_el_pt;
578  }
579  else
580  {
581  // Recursive call
583  father_at_reflevel_pt);
584  }
585  }
586 
590  virtual void initial_setup(Tree* const& adopted_father_pt = 0,
591  const unsigned& initial_p_order = 0)
592  {
593  }
594 
596  virtual void pre_build(Mesh*& mesh_pt, Vector<Node*>& new_node_pt) {}
597 
599  virtual void further_build() {}
600 
604  virtual void setup_hanging_nodes(Vector<std::ofstream*>& output_stream) {}
605 
609  virtual void further_setup_hanging_nodes() {}
610 
621  RankThreeTensor<double>& dresidual_dnodal_coordinates);
622 
623 
628  {
629  return Shape_controlling_node_lookup.size();
630  }
631 
636  std::map<Node*, unsigned> shape_controlling_node_lookup()
637  {
639  }
640  };
641 
642 
646 
647 
648  //======================================================================
650  //======================================================================
651  class PRefineableElement : public virtual RefineableElement
652  {
653  protected:
655  unsigned P_order;
656 
659 
662 
665 
666  public:
669  : RefineableElement(),
670  P_order(2),
671  To_be_p_refined(false),
673  To_be_p_unrefined(false)
674  {
675  }
676 
678  virtual ~PRefineableElement() {}
679 
682 
684  void operator=(const PRefineableElement&) = delete;
685 
688  {
690  }
691 
694  {
695  P_refinement_is_enabled = false;
696  }
697 
700  {
702  }
703 
705  unsigned& p_order()
706  {
707  return P_order;
708  }
709 
711  unsigned p_order() const
712  {
713  return P_order;
714  }
715 
722  virtual unsigned initial_p_order() const = 0;
723 
726  {
727  To_be_p_refined = true;
728  }
729 
732  {
733  To_be_p_refined = false;
734  }
735 
738  {
739  To_be_p_unrefined = true;
740  }
741 
744  {
745  To_be_p_unrefined = false;
746  }
747 
750  {
751  return To_be_p_refined;
752  }
753 
756  {
757  return To_be_p_unrefined;
758  }
759 
761  virtual void p_refine(const int& inc,
762  Mesh* const& mesh_pt,
763  GeneralisedElement* const& clone_pt) = 0;
764 
765  // Overload the nodes_built function to check every node
766  bool nodes_built()
767  {
768  // Must check that EVERY node exists
769  unsigned n_node = this->nnode();
770  for (unsigned n = 0; n < n_node; n++)
771  {
772  if (this->node_pt(n) == 0)
773  {
774  return false;
775  }
776  }
777  // If we get here then all the nodes are built
778  return true;
779  }
780  };
781 
782 
786 
787 
788  //=======================================================================
796  //======================================================================
798  {
799  public:
801  void build(Mesh*& mesh_pt,
802  Vector<Node*>& new_node_pt,
803  bool& was_already_built,
804  std::ofstream& new_nodes_file)
805  {
806  std::ostringstream error_message;
807  error_message << "This function is broken as it's only needed/used \n"
808  << "during \"proper\" refinement\n";
809  throw OomphLibError(
810  error_message.str(), OOMPH_CURRENT_FUNCTION, OOMPH_EXCEPTION_LOCATION);
811  }
812 
813 
816  Vector<double>& values)
817  {
818  std::ostringstream error_message;
819  error_message << "This function is broken as it's only needed/used \n"
820  << "during \"proper\" refinement\n";
821  throw OomphLibError(
822  error_message.str(), OOMPH_CURRENT_FUNCTION, OOMPH_EXCEPTION_LOCATION);
823  }
824 
826  virtual void get_interpolated_values(const unsigned& t,
827  const Vector<double>& s,
828  Vector<double>& values)
829  {
830  std::ostringstream error_message;
831  error_message << "This function is broken as it's only needed/used \n"
832  << "during \"proper\" refinement\n";
833  throw OomphLibError(
834  error_message.str(), OOMPH_CURRENT_FUNCTION, OOMPH_EXCEPTION_LOCATION);
835  }
836 
837 
840  {
841  std::ostringstream error_message;
842  error_message << "This function is broken as it's only needed/used \n"
843  << "during \"proper\" refinement\n";
844  throw OomphLibError(
845  error_message.str(), OOMPH_CURRENT_FUNCTION, OOMPH_EXCEPTION_LOCATION);
846  }
847 
849  void rebuild_from_sons(Mesh*& mesh_pt)
850  {
851  std::ostringstream error_message;
852  error_message << "This function is broken as it's only needed/used \n"
853  << "during \"proper\" refinement\n";
854  throw OomphLibError(
855  error_message.str(), OOMPH_CURRENT_FUNCTION, OOMPH_EXCEPTION_LOCATION);
856  }
857  };
858 
859 
863 
864 
865  //=======================================================================
871  //======================================================================
873  public virtual SolidFiniteElement
874  {
875  private:
880  std::map<Node*, DenseMatrix<int>> Local_position_hang_eqn;
881 
882 
885  void assign_solid_hanging_local_eqn_numbers(const bool& store_local_dof_pt);
886 
887 
888  protected:
900 
906  const DShape& dpsids, DenseMatrix<double>& jacobian) const;
907 
913  const DShape& d2psids, DenseMatrix<double>& jacobian2) const;
914 
922  const DShape& dpsids,
923  DenseMatrix<double>& jacobian,
924  DenseMatrix<double>& inverse_jacobian) const;
925 
926  public:
929  : RefineableElement(),
932  {
933  }
934 
937 
940  void assign_solid_local_eqn_numbers(const bool& store_local_dof_pt)
941  {
943  assign_solid_hanging_local_eqn_numbers(store_local_dof_pt);
944  }
945 
950  unsigned ngeom_data() const;
951 
955  Data* geom_data_pt(const unsigned& j);
956 
961  void identify_geometric_data(std::set<Data*>& geometric_data_pt);
962 
967  Vector<double>& residuals, DenseMatrix<double>& jacobian);
968 
981  {
983  }
984 
989  {
991  }
992 
997  {
999  }
1000 
1006  {
1008  }
1009 
1014  virtual void further_build()
1015  {
1017  dynamic_cast<RefineableSolidElement*>(father_element_pt())
1019 
1021  }
1022  };
1023 
1024 
1028 
1029 
1030  //=======================================================================
1038  //======================================================================
1040  : public virtual NonRefineableElementWithHangingNodes,
1041  public virtual RefineableSolidElement
1042  {
1043  };
1044 
1045 
1049 
1050 
1051 } // namespace oomph
1052 
1053 #endif
int i
Definition: BiCGSTAB_step_by_step.cpp:9
const unsigned n
Definition: CG3DPackingUnitTest.cpp:11
Definition: shape.h:278
Definition: nodes.h:86
Definition: elements.h:1313
Node *& node_pt(const unsigned &n)
Return a pointer to the local node n.
Definition: elements.h:2175
virtual void shape(const Vector< double > &s, Shape &psi) const =0
unsigned nnode() const
Return the number of nodes.
Definition: elements.h:2210
virtual void assign_nodal_local_eqn_numbers(const bool &store_local_dof_pt)
Definition: elements.cc:3544
virtual Node * get_node_at_local_coordinate(const Vector< double > &s) const
Definition: elements.cc:3882
int get_node_number(Node *const &node_pt) const
Definition: elements.cc:3814
virtual unsigned nnode_1d() const
Definition: elements.h:2218
virtual double local_one_d_fraction_of_node(const unsigned &n1d, const unsigned &i)
Definition: elements.h:1858
Definition: elements.h:73
Definition: mesh.h:67
Definition: nodes.h:906
void set_non_obsolete()
Mark node as non-obsolete.
Definition: nodes.h:1442
Definition: refineable_elements.h:798
void get_interpolated_values(const Vector< double > &s, Vector< double > &values)
Broken function – this shouldn't really be needed.
Definition: refineable_elements.h:815
void check_integrity(double &max_error)
Broken function – this shouldn't really be needed.
Definition: refineable_elements.h:839
void rebuild_from_sons(Mesh *&mesh_pt)
Broken function – this shouldn't really be needed.
Definition: refineable_elements.h:849
virtual void get_interpolated_values(const unsigned &t, const Vector< double > &s, Vector< double > &values)
Broken function – this shouldn't really be needed.
Definition: refineable_elements.h:826
void build(Mesh *&mesh_pt, Vector< Node * > &new_node_pt, bool &was_already_built, std::ofstream &new_nodes_file)
Broken build function – shouldn't really be needed.
Definition: refineable_elements.h:801
Definition: refineable_elements.h:1042
Definition: oomph_definitions.h:222
p-refineable version of RefineableElement
Definition: refineable_elements.h:652
bool to_be_p_unrefined()
Has the element been selected for p-unrefinement?
Definition: refineable_elements.h:755
bool p_refinement_is_enabled()
Flag to indicate suppression of any refinement.
Definition: refineable_elements.h:687
void enable_p_refinement()
Emnable refinement for this element.
Definition: refineable_elements.h:699
bool nodes_built()
Return true if all the nodes have been built, false if not.
Definition: refineable_elements.h:766
unsigned & p_order()
Access function to P_order.
Definition: refineable_elements.h:705
void operator=(const PRefineableElement &)=delete
Broken assignment operator.
PRefineableElement(const PRefineableElement &)=delete
Broken copy constructor.
virtual ~PRefineableElement()
Destructor, empty.
Definition: refineable_elements.h:678
virtual unsigned initial_p_order() const =0
virtual void p_refine(const int &inc, Mesh *const &mesh_pt, GeneralisedElement *const &clone_pt)=0
p-refine the element
void disable_p_refinement()
Suppress of any refinement for this element.
Definition: refineable_elements.h:693
bool To_be_p_refined
Flag for p-refinement.
Definition: refineable_elements.h:658
unsigned P_order
The polynomial expansion order of the elemental basis functions.
Definition: refineable_elements.h:655
void select_for_p_refinement()
Select the element for p-refinement.
Definition: refineable_elements.h:725
bool To_be_p_unrefined
Flag for unrefinement.
Definition: refineable_elements.h:664
void deselect_for_p_unrefinement()
Deselect the element for p-unrefinement.
Definition: refineable_elements.h:743
bool to_be_p_refined()
Has the element been selected for refinement?
Definition: refineable_elements.h:749
void select_for_p_unrefinement()
Select the element for p-unrefinement.
Definition: refineable_elements.h:737
bool P_refinement_is_enabled
Flag to indicate suppression of any refinement.
Definition: refineable_elements.h:661
unsigned p_order() const
Access function to P_order (const version)
Definition: refineable_elements.h:711
void deselect_for_p_refinement()
Deselect the element for p-refinement.
Definition: refineable_elements.h:731
PRefineableElement()
Constructor, calls the RefineableElement constructor.
Definition: refineable_elements.h:668
A Rank 3 Tensor class.
Definition: matrices.h:1370
Definition: refineable_elements.h:97
void set_number(const long &mynumber)
Set element number (for debugging/plotting)
Definition: refineable_elements.h:401
void select_sons_for_unrefinement()
Unrefinement will be performed by merging the four sons of this element.
Definition: refineable_elements.h:332
void assemble_local_to_eulerian_jacobian2(const DShape &d2psids, DenseMatrix< double > &jacobian2) const
Definition: refineable_elements.cc:133
Tree * tree_pt()
Access function: Pointer to quadtree representation of this element.
Definition: refineable_elements.h:211
virtual void build(Mesh *&mesh_pt, Vector< Node * > &new_node_pt, bool &was_already_built, std::ofstream &new_nodes_file)=0
static double Max_integrity_tolerance
Max. allowed discrepancy in element integrity check.
Definition: refineable_elements.h:118
virtual RefineableElement * root_element_pt()
Definition: refineable_elements.h:524
static double & max_integrity_tolerance()
Max. allowed discrepancy in element integrity check.
Definition: refineable_elements.h:495
virtual void further_build()
Further build: e.g. deal with interpolation of internal values.
Definition: refineable_elements.h:599
void select_for_refinement()
Select the element for refinement.
Definition: refineable_elements.h:320
virtual void rebuild_from_sons(Mesh *&mesh_pt)=0
void assign_hanging_local_eqn_numbers(const bool &store_local_dof_pt)
Assign the local equation numbers for hanging node variables.
Definition: refineable_elements.cc:312
virtual void pre_build(Mesh *&mesh_pt, Vector< Node * > &new_node_pt)
Pre-build the element.
Definition: refineable_elements.h:596
void set_refinement_level(const int &refine_level)
Set the refinement level.
Definition: refineable_elements.h:308
virtual void unbuild()
Definition: refineable_elements.h:362
Tree * Tree_pt
A pointer to a general tree object.
Definition: refineable_elements.h:100
virtual void deactivate_element()
Definition: refineable_elements.cc:293
long number() const
Element number (for debugging/plotting)
Definition: refineable_elements.h:395
double local_to_eulerian_mapping_diagonal(const DShape &dpsids, DenseMatrix< double > &jacobian, DenseMatrix< double > &inverse_jacobian) const
Definition: refineable_elements.cc:215
virtual bool nodes_built()
Return true if all the nodes have been built, false if not.
Definition: refineable_elements.h:389
virtual unsigned ncont_interpolated_values() const =0
virtual void setup_hanging_nodes(Vector< std::ofstream * > &output_stream)
Definition: refineable_elements.h:604
virtual void initial_setup(Tree *const &adopted_father_pt=0, const unsigned &initial_p_order=0)
Definition: refineable_elements.h:590
void identify_field_data_for_interactions(std::set< std::pair< Data *, unsigned >> &paired_field_data)
Definition: refineable_elements.cc:523
void get_father_at_refinement_level(unsigned &refinement_level, RefineableElement *&father_at_reflevel_pt)
Definition: refineable_elements.h:564
unsigned refinement_level() const
Return the Refinement level.
Definition: refineable_elements.h:314
static void check_value_id(const int &n_continuously_interpolated_values, const int &value_id)
Definition: refineable_elements.cc:53
unsigned Refine_level
Refinement level.
Definition: refineable_elements.h:103
void get_dresidual_dnodal_coordinates(RankThreeTensor< double > &dresidual_dnodal_coordinates)
Definition: refineable_elements.cc:597
virtual void fill_in_jacobian_from_nodal_by_fd(Vector< double > &residuals, DenseMatrix< double > &jacobian)
Definition: refineable_elements.cc:675
virtual unsigned ninterpolating_node_1d(const int &value_id)
Definition: refineable_elements.h:474
void disable_refinement()
Suppress of any refinement for this element.
Definition: refineable_elements.h:237
virtual void further_setup_hanging_nodes()
Definition: refineable_elements.h:609
long Number
Global element number – for plotting/validation purposes.
Definition: refineable_elements.h:115
virtual unsigned ninterpolating_node(const int &value_id)
Definition: refineable_elements.h:466
virtual void interpolating_basis(const Vector< double > &s, Shape &psi, const int &value_id) const
Definition: refineable_elements.h:481
bool refinement_is_enabled()
Flag to indicate suppression of any refinement.
Definition: refineable_elements.h:231
virtual unsigned required_nsons() const
Definition: refineable_elements.h:224
void deselect_for_refinement()
Deselect the element for refinement.
Definition: refineable_elements.h:326
void assemble_local_to_eulerian_jacobian(const DShape &dpsids, DenseMatrix< double > &jacobian) const
Definition: refineable_elements.cc:77
virtual RefineableElement * father_element_pt() const
Return a pointer to the father element.
Definition: refineable_elements.h:539
unsigned nshape_controlling_nodes()
Definition: refineable_elements.h:627
bool To_be_refined
Flag for refinement.
Definition: refineable_elements.h:106
std::map< Node *, int > * Local_hang_eqn
Definition: refineable_elements.h:167
std::map< Node *, unsigned > shape_controlling_node_lookup()
Definition: refineable_elements.h:636
RefineableElement()
Definition: refineable_elements.h:188
virtual Node * interpolating_node_pt(const unsigned &n, const int &value_id)
Definition: refineable_elements.h:437
void assign_nodal_local_eqn_numbers(const bool &store_local_dof_pt)
Definition: refineable_elements.h:511
void split(Vector< ELEMENT * > &son_pt) const
Definition: refineable_elements.h:254
bool to_be_refined()
Has the element been selected for refinement?
Definition: refineable_elements.h:345
void enable_refinement()
Emnable refinement for this element.
Definition: refineable_elements.h:243
int local_hang_eqn(Node *const &node_pt, const unsigned &i)
Definition: refineable_elements.h:278
void assemble_eulerian_base_vectors(const DShape &dpsids, DenseMatrix< double > &interpolated_G) const
Definition: refineable_elements.cc:177
virtual double local_one_d_fraction_of_interpolating_node(const unsigned &n1d, const unsigned &i, const int &value_id)
Definition: refineable_elements.h:447
RefineableElement(const RefineableElement &)=delete
Broken copy constructor.
void set_tree_pt(Tree *my_tree_pt)
Set pointer to quadtree representation of this element.
Definition: refineable_elements.h:217
bool Sons_to_be_unrefined
Flag for unrefinement.
Definition: refineable_elements.h:112
virtual Node * get_interpolating_node_at_local_coordinate(const Vector< double > &s, const int &value_id)
Definition: refineable_elements.h:456
virtual void get_interpolated_values(const Vector< double > &s, Vector< double > &values)
Definition: refineable_elements.h:417
std::map< Node *, unsigned > Shape_controlling_node_lookup
Definition: refineable_elements.h:172
virtual void get_interpolated_values(const unsigned &t, const Vector< double > &s, Vector< double > &values)=0
bool sons_to_be_unrefined()
Has the element been selected for unrefinement?
Definition: refineable_elements.h:351
bool Refinement_is_enabled
Flag to indicate suppression of any refinement.
Definition: refineable_elements.h:109
virtual ~RefineableElement()
Destructor, delete the allocated storage for the hanging equations.
Definition: refineable_elements.cc:38
virtual void check_integrity(double &max_error)=0
void operator=(const RefineableElement &)=delete
Broken assignment operator.
void deselect_sons_for_unrefinement()
Definition: refineable_elements.h:339
Definition: refineable_elements.h:874
virtual void further_build()
Definition: refineable_elements.h:1014
void disable_use_of_undeformed_macro_element_for_new_lagrangian_coords()
Definition: refineable_elements.h:996
bool is_undeformed_macro_element_used_for_new_lagrangian_coords() const
Definition: refineable_elements.h:980
Data * geom_data_pt(const unsigned &j)
Definition: refineable_elements.cc:1055
double local_to_lagrangian_mapping_diagonal(const DShape &dpsids, DenseMatrix< double > &jacobian, DenseMatrix< double > &inverse_jacobian) const
Definition: refineable_elements.cc:938
void assemble_local_to_lagrangian_jacobian2(const DShape &d2psids, DenseMatrix< double > &jacobian2) const
Definition: refineable_elements.cc:894
void enable_use_of_undeformed_macro_element_for_new_lagrangian_coords()
Definition: refineable_elements.h:988
unsigned ngeom_data() const
Definition: refineable_elements.cc:1003
void assign_solid_local_eqn_numbers(const bool &store_local_dof_pt)
Definition: refineable_elements.h:940
bool Use_undeformed_macro_element_for_new_lagrangian_coords
Definition: refineable_elements.h:899
virtual ~RefineableSolidElement()
Virtual Destructor, delete any allocated storage.
Definition: refineable_elements.h:936
RefineableSolidElement()
Constructor.
Definition: refineable_elements.h:928
void assign_solid_hanging_local_eqn_numbers(const bool &store_local_dof_pt)
Definition: refineable_elements.cc:1178
void fill_in_jacobian_from_solid_position_by_fd(Vector< double > &residuals, DenseMatrix< double > &jacobian)
Definition: refineable_elements.cc:1335
std::map< Node *, DenseMatrix< int > > Local_position_hang_eqn
Definition: refineable_elements.h:880
void identify_geometric_data(std::set< Data * > &geometric_data_pt)
Definition: refineable_elements.cc:1137
DenseMatrix< int > & local_position_hang_eqn(Node *const &node_pt)
Definition: refineable_elements.h:1005
void assemble_local_to_lagrangian_jacobian(const DShape &dpsids, DenseMatrix< double > &jacobian) const
Definition: refineable_elements.cc:855
Definition: shape.h:76
Definition: elements.h:3561
virtual void assign_solid_local_eqn_numbers(const bool &store_local_dof)
Assign local equation numbers for the solid equations in the element.
Definition: elements.cc:6898
Definition: tree.h:74
RefineableElement * object_pt() const
Definition: tree.h:88
Tree * father_pt() const
Return pointer to father: NULL if it's a root node.
Definition: tree.h:235
TreeRoot *& root_pt()
Return pointer to root of the tree.
Definition: tree.h:141
RealScalar s
Definition: level1_cplx_impl.h:130
double max_error
Definition: MortaringCantileverCompareToNonMortaring.cpp:188
DRAIG: Change all instances of (SPATIAL_DIM) to (DIM-1).
Definition: AnisotropicHookean.h:10
t
Definition: plotPSD.py:36
#define OOMPH_EXCEPTION_LOCATION
Definition: oomph_definitions.h:61
#define OOMPH_CURRENT_FUNCTION
Definition: oomph_definitions.h:86
void set(Container &c, Position position, const Value &value)
Definition: stdlist_overload.cpp:36
std::ptrdiff_t j
Definition: tut_arithmetic_redux_minmax.cpp:2