formulafrmEformula.hh

Go to the documentation of this file.
1 
8 #ifndef formulatfrmEformula_hh
9 #define formulatfrmEformula_hh
10 
11 #include "geometry.hh"
12 #include "formula.hh"
13 #include "toolbox/sharedPointer.hh"
14 
15 #include <algorithm>
16 
17 #if __GNUC__ == 2
18 # include <float.h>
19 # define EPS DBL_EPSILON
20 #else
21 # include <limits>
22 # define EPS std::numeric_limits<double>::epsilon()
23 #endif
24 
25 namespace concepts{
26 
27  // ************************************************************* JacobianCell *
28 
35  template<uint dimC> class JacobianCell;
36 
37  template<> class JacobianCell<1>{
38  public:
40  };
41 
42  template<> class JacobianCell<2>{
43  public:
45  };
46 
47  template<> class JacobianCell<3>{
48  public:
50  };
51 
52 
53  // ********************************************************** TensorVertexMap *
54 
61  template<uint dimC> class TensorVertexMap;
62 
63  template<> class TensorVertexMap<1>{
64  public:
66  };
67 
68  template<> class TensorVertexMap<2>{
69  public:
71  };
72 
73  template<> class TensorVertexMap<3>{
74  public:
76  };
77 
78 
79 
85  template<uint dimC>
87 
89  : cell(cell), key(cell.connector().key()){};
90 
91  virtual bool operator<(const CellStripeElement<dimC>& sb) const{
92  return this->key < sb.key;
93  }
94 
95  virtual bool operator==(const CellStripeElement<dimC>& sb) const{
96  return key == sb.key;
97  }
98 
99  const typename JacobianCell<dimC>::cell& cell;
100  const uint key;
101 
102 
103  protected:
104  virtual std::ostream& info(std::ostream& os) const{
105  return os<< concepts::typeOf(*this)<<"[ "<< key << " ] ";
106  }
107  };
108 
109 
110 
125  template<uint dimC>
126  class CellBox : public OutputOperator{
127  public:
129  cell(cell), isDummy(false), key(cell.connector().key().key()){
130 
131  for(uint j = 0; j < dimC; ++j)
132  minX[j] = maxX[j] = cell.vertex(0)[j];
133 
134  for(uint i = 1; i < pow(2,dimC); ++i){
135 
136  for(uint j = 0; j < dimC; ++j){
137  maxX[j] = std::max(maxX[j], cell.vertex(i)[j] );
138  minX[j] = std::min(minX[j], cell.vertex(i)[j] );
139  }
140  }//for i
141  }
142 
143 
144  // //dummy constructor
145  CellBox(const typename JacobianCell<dimC>::cell& cell, Real xMax):
146  cell(cell), isDummy(true), key(cell.connector().key().key()){
147 
148  minX[0] = - std::numeric_limits<double>::max();
149  maxX[0] = xMax;
150 
151  for(uint i = 1 ; i < dimC; ++i){
152  minX[i] = maxX[i] = - std::numeric_limits<double>::max();
153  }
154 
155  }
156 
163  virtual bool operator<(const CellBox<dimC>& box) const;
164 
165 
166  virtual bool operator==(const CellBox<dimC>& box) const{
167  //safety hold ask for isDummy
168  return this->key == box.key && isDummy == box.isDummy;
169  }
170 
171  Real minX[dimC];
172  Real maxX[dimC];
173 
175  bool isDummy;
176  uint key;
177 
178  protected:
179  virtual std::ostream& info(std::ostream& os) const{
180  os<< concepts::typeOf(*this)<<"[key = "<< key<<"] << box frame = ";
181  for(uint i = 0 ; i < dimC-1; ++i)
182  os << "["<<minX[i] << " , "<< maxX[i] << "] x ";
183  os << "["<<minX[dimC-1] << " , "<< maxX[dimC-1] << "]";
184  return os;
185  }
186  };
187 
188 
195  template<uint dimC>
196  struct CCell_F : public OutputOperator{
197 
198  CCell_F(const typename JacobianCell<dimC>::cell& cell, const uint cardF=2):
199  cell(cell), key(cell.connector().key()), cardF(cardF){
201  computeF();
202  }
203 
204 
205  bool operator==(CCell_F cCF) const{
206  return this->key == cCF.key;
207  }
208 
209  bool operator<(CCell_F cCF) const{
210  return this->key < cCF.key;
211  }
212 
213 
215  const uint key;
216  const uint cardF;
217 
218  //Finite set of physical points
220 
221  protected:
222  virtual std::ostream& info(std::ostream& os) const{
223  return os << concepts::typeOf(*this)<<"[ Cellkey = "<< key << " ], F = " << F;
224  }
225  void computeF();
226  };
227 
228 
234  template<uint dimC>
235  struct CCell_F_dist : public OutputOperator{
237  ccF(ccF), dist_2((ccF.F[0]-P).l2_2()) {
238 
239  for(uint i = 1; i < ccF.F.size(); ++i){
240  dist_2 = std::min(dist_2, (ccF.F[i]-P).l2_2());
241  }
242  }
243  bool operator==(CCell_F_dist ccF_d) const{
244  return this->ccF.key == ccF_d.ccF.key;
245  }
246 
247  bool operator<(CCell_F_dist ccF_d) const{
248  return this->dist_2 < ccF_d.dist_2;
249  }
251  //squared distance of P and F
253 
254  protected:
255  virtual std::ostream& info(std::ostream& os) const{
256  return os << concepts::typeOf(*this)<<"[] ";
257  }
258  };
259 
260 
261 
265  template<uint dimC,class G> class MultiVector;
266 
267 
268  // ********************************* specific MultiVector classes **
269 
270  template<> class MultiVector<0,const ElementWithCell<Real>* >{
271  public:
272  typedef const ElementWithCell<Real>* map;
273  };
274  template<> class MultiVector<0,const ElementWithCell<Cmplx>* >{
275  public:
276  typedef const ElementWithCell<Cmplx>* map;
277  };
278 
279 
280 
281  template<> class MultiVector<0,concepts::Set<CellBox<1>>>{
282  public:
283  typedef std::pair<concepts::Set<CellBox<1>>, Real> map;
284  };
285  template<> class MultiVector<0,concepts::Set<CellBox<2>>>{
286  public:
287  typedef std::pair<concepts::Set<CellBox<2>>, Real> map;
288  };
289  template<> class MultiVector<0,concepts::Set<CellBox<3>>>{
290  public:
291  typedef std::pair<concepts::Set<CellBox<3>>, Real> map;
292  };
293 
294 
296  template<uint dimC,class G> class MultiVector{
297  public:
298  typedef std::vector<typename MultiVector<dimC-1,G>::map > map;
299  };
300 
301 
302  // **************************************************** CellMap **
303 
311  template<uint dimC, class H>
312  struct CellMap: public OutputOperator{
313 
315 
317 
318  void resize(const uint (&maxlevel)[dimC]);
319 
320  //add information at given index
321  void add(const ElementWithCell<H>* elm, const uint (&idx)[dimC]);
322 
323  //@ pre idx is accessable
324  const ElementWithCell<H>* get(const uint (&idx)[dimC]);
325 
326  uint sizes[dimC];
327 
328  //a better range safe multiarray, since 2^64 cannot be holded in a ulonglong!
330 
331  protected:
332  virtual std::ostream& info(std::ostream& os) const{
333  return os << concepts::typeOf(*this)<<"["<<dimC<<"]";
334  }
335  };
336 
337 
338 
339 
340  // **************************************************** FFEF_Error **
341 
345  class FFEF_Error: public ExceptionBase {
346  public:
350  FFEF_Error(const std::string& file, const unsigned int line,
351  const std::string& function, const std::string& errorMessage) throw ();
352 
353 
354  virtual const char* what() const throw();
355 
356  virtual ~FFEF_Error() throw () {};
357  protected:
358  virtual std::ostream& info(std::ostream& os) const throw ();
359  private:
360  std::string errorMessage_;
361  mutable std::string outputMessage_ ;
362  };
363 
364 
365 
366  // ************************************************* FormulaFromElementFormula *
367 
517  template<uint dim, class F, typename G = typename Realtype<F>::type>
519 
520  private:
521  //this is the maximal refinement level allowed here, maximal practical level should be around < 32.
522  static uint max_lvl;
523 
524  public:
525 
531  enum PNF {Exc = 0, NaN, Zero};
532 
533 
553  //template<class F, class H>
556  const Set<uint>* s_attrb = 0,
557  const Set<uint>* d_attrb = 0,
558  const Point<Real, dim> scale = Point<Real, dim>(1),
559  const Point<Real, dim> shift = Point<Real, dim>(0),
560  const uint N = 10,
561  const uint cardF_2 = 2,
562  const Real tol = EPS,
563  const Real interior = 0.00000001,
564  const uint maxDoI = 3
565  );
566 
568 
569 
570  virtual F operator() (const Real p, const Real t = 0.0) const;
571  virtual F operator() (const Real2d& p, const Real t = 0.0) const;
572  virtual F operator() (const Real3d& p, const Real t = 0.0) const;
573 
574  virtual F operator() (const Connector& cntr,
575  const Real p,
576  const Real t = 0.0) const;
577 
578  virtual F operator() (const Connector& cntr,
579  const Real2d& p,
580  const Real t = 0.0) const;
581 
582  virtual F operator() (const Connector& cntr,
583  const Real3d& p,
584  const Real t = 0.0) const;
585 
586 
607 
608 
617  inline void setPNF(PNF pnf) {pnf_ = pnf;}
618 
619 
621 
622  protected:
623  virtual std::ostream& info(std::ostream& os) const {
624  return os << "u_ = " << this->u_ << ", pnf_ = " << this->pnf_ ;
625  }
626 
627 
628  private:
629 
632 
637 
642 
644  const Real tol_;
646  const uint N_;
648  const uint cardF_2_;
651 
652  //heuristic approach due to integration or graphical application
653  //often next local coordinate is in the same element as the last one
654  mutable const ElementWithCell<G>* lastElm_;
655 
657  mutable const typename JacobianCell<dim>::cell* lastCell_;
658 
660  mutable const typename JacobianCell<dim>::cell* lastCoarseCell_;
661 
663  mutable bool wasCurved_;
664 
666  mutable bool wasCurved_c_;
667 
668 
674  mutable Z2 cCellType_;
675 
678  bool allowPer_;
679 
684 
688  const uint maxDoI_;
689 
690  //Flag for Point not found behaviour of underlying search routine.
692 
693 
694 
697 
701 
702 
703 
704 
705  //maps I in IN^dim to the coressponding child cells key
706  //it holds 0<= I_i maxLevel_i
707  // where maxLevel is the highest number of levels in diretion x_i
708 
709  //example :
710  //
711  // coarsest cell href4
712  // 1_________ ________ _________
713  // | | | | | maxlevel_0 = 1 | | | maxlevel_0 = 2
714  // | | |___|___| maxlevel_1 = 1 |___|___| maxlevel_1 = 1
715  // | | | | | | | | |
716  // |_______| |___|___| |_|_|___|
717  // 0 1
718 
719  // We devide the coarsest cell into sectors along coord i
720  // 0 <= l_i / (2^maxLevel_i) <= 1 , l_i = 0,..., 2^maxLevel_i
721  //
722  // Then map(l_0, l_1, l_2) maps into a sector surjectiv.
723  //
724  // Example :
725  // _____________
726  // 1 | e | d |
727  // |_____|_____|
728  // 0 | a| b| c |
729  // |__|__|_____|
730  // 0 1 2 3
731  //
732  // then for example map(0,0) = a, map(2,0) = map(3,0) = c
733 
734  //the map is from coarse elms to its finest children
736 
737 
742 
743 
746 
751 
752 
763  void build_directMap_(const typename JacobianCell<dim>::cell* cell,
764  const concepts::HashMap<const concepts::ElementWithCell<G>* >& mapToElm);
765 
766 
767  template<uint dim1 = dim,
768  typename std::enable_if<dim1 == 1u, uint>::type = 0>
769  void setLocalMap_(const typename JacobianCell<dim>::cell* coarseCell,
770  const HashMap<const ElementWithCell<G>* >& mapToElm,
771  CellMap<dim, G>& map,
772  const std::array<uint,dim> idxL,
773  const std::array<uint,dim> idxR) const;
774 
775  template<uint dim2 = dim,
776  typename std::enable_if<dim2 == 2u, uint>::type = 0>
777  void setLocalMap_(const typename JacobianCell<dim>::cell* coarseCell,
778  const HashMap<const ElementWithCell<G>* >& mapToElm,
779  CellMap<dim, G>& map,
780  const std::array<uint,dim> idxL,
781  const std::array<uint,dim> idxR) const ;
782 
783  template<uint dim3 = dim,
784  typename std::enable_if<dim3 == 3u, uint>::type = 0>
785  void setLocalMap_(const typename JacobianCell<dim>::cell* coarseCell,
786  const HashMap<const ElementWithCell<G>* >& mapToElm,
787  CellMap<dim, G>& map,
788  const std::array<uint,dim> idxL,
789  const std::array<uint,dim> idxR) const;
790 
791 
792 
794  const concepts::RCP<const concepts::Set<uint> > s_attrb,
795  const concepts::RCP<const concepts::Set<uint> > d_attrb,
796  const Point<Real, dim> scale,
797  const Point<Real, dim> shift,
798  const uint N,
799  const uint cardF_2 ,
800  const Real tol,
801  const Real interior,
802  const concepts::Set<CellBox<dim> > cBoxes,
803  const concepts::Set<CCell_F<dim> > rCC,
804  const bool allowPer,
805  const Point<Real, dim> O,
806  const Point<Real, dim> eL,
807  const Set<uint> mapCCells,
808  const Set<const typename JacobianCell<dim>::cell* > coarsestCell,
809  const Set<const typename JacobianCell<dim>::cell* > irrCCells,
810  const concepts::HashMap<CellMap<dim,G> > mapToFinestElm,
811  const uint maxDoI,
812  const PNF pnf,
813  const HashMap<HashMap<const concepts::ElementWithCell<G>* > > coarseToElm);
814 
830  F compute_(const Point<Real,dim>& p, const Real t) const;
831 
841 
854  bool getOrigPoint_(//const concepts::ElementWithCell<G>& elm,
855  const typename JacobianCell<dim>::cell& cell,
856  const Point<Real, dim> P, Point<Real, dim>& eta, const uint N,
857  const Real interior,
858  const Point<Real, dim>& x0 = Real3d(0.49,0.51,0.49)) const;
859 
860 
861  //
862  // then applies original shift/scale to p to build P
863 
870  void shift_DBox_(const Point<Real,dim>& p, Point<Real,dim>& P) const;
871 
872 
873 
874  //a cell is called coarse iff its level of refinement is zero in each direction
875  bool isCoarse_(const typename JacobianCell<dim>::cell& cell);
876 
877 
885  void addElements_(const uint cKey,
886  const typename JacobianCell<dim>::cell& cell,
887  const HashMap<const concepts::ElementWithCell<G>* >& mapToElm,
888  HashMap<HashMap<const concepts::ElementWithCell<G>* > >& cCtE );
889 
890 
891  //@pre arrays are initialized with zero entries
892  //template<uint dim>
893  void getExtremalLevel(const typename JacobianCell<dim>::cell* cell,
894  uint (&maxL)[dim], uint (&minL)[dim]);
895 
896 
902  bool compute0_(const typename JacobianCell<dim>::cell& cCell, const Point<Real, dim>& P,
903  const Point<Real, dim>& cEta,const Real t, F& val) const;
904 
905 
911  bool compute1_(const typename JacobianCell<dim>::cell& cCell, const Point<Real, dim>& P,
912  const Point<Real, dim>& cEta,const Real t, F& val) const;
913 
918  bool checkCCells_(const std::set<typename CellType<dim>::cell *>& allCell,
919  typename std::set<typename CellType<dim>::cell *>::const_iterator iter);
920 
921 
922  F handlePNF_() const;
923 
924 
925 
926 
927 
928  };
929 
930 #ifdef __clang__
931  void getChild(const concepts::Edge1d& cCell,const Point<Real,1u>& eta,
932  const std::array<Real,std::size_t(1u)> x0,
933  const std::array<Real,std::size_t(1u)> xN,
934  const concepts::Edge1d*& cld);
935  void getChild(const concepts::Quad2d& cCell,const Point<Real,2u>& eta,
936  const std::array<Real,std::size_t(2u)> x0,
937  const std::array<Real,std::size_t(2u)> xN,
938  const concepts::Quad2d*& cld);
939  void getChild(const concepts::Hexahedron3d& cCell,const Point<Real,3u>& eta,
940  const std::array<Real,std::size_t(3u)> x0,
941  const std::array<Real,std::size_t(3u)> xN,
942  const concepts::Hexahedron3d*& cld);
943 
944 #else
945 
952  template<uint dimC>
953  void getChild(const typename JacobianCell<dimC>::cell& cCell,const Point<Real,dimC>& eta,
954  const std::array<Real,std::size_t(dimC)> x0,
955  const std::array<Real,std::size_t(dimC)> xN,
956  const typename JacobianCell<dimC>::cell*& cld);
957 #endif
958 
959 
960 
961 
962 } //namespace concepts
963 
964 #endif // formulatfrmEformula.hh
virtual std::ostream & info(std::ostream &os) const
Returns information in an output stream.
virtual std::ostream & info(std::ostream &os) const
Returns information in an output stream.
Basic template class for a tensor map vertex.
A 2D cell: quadrilateral.
Definition: cell2D.hh:378
virtual FormulaFromElementFormula< dim, F, G > * clone() const
const uint cardF_2_
Square root of amount of interior points in a curved cell for distance evaluation.
bool compute0_(const typename JacobianCell< dim >::cell &cCell, const Point< Real, dim > &P, const Point< Real, dim > &cEta, const Real t, F &val) const
Evaluates the ElementFormula in the case of coarse Cell with key cKey has a local mapping.
Basic class for a Point or a vector.
void build_directMap_(const typename JacobianCell< dim >::cell *cell, const concepts::HashMap< const concepts::ElementWithCell< G > * > &mapToElm)
Method to build the O(1) access mapping defined via maxDoI .
bool isCoarse_(const typename JacobianCell< dim >::cell &cell)
bool allowPer_
Flag defining whether the destination mesh is considered periodic for the formula projection.
Base class for exceptions.
Definition: exceptions.hh:86
void buildBoxCandidates_(const Point< Real, dim > P, concepts::Set< CellStripeElement< dim > > &box) const
Build Boxes of Vertex Cells that contain the point P.
A 2D element map for a quadrilateral given by a the four vertices.
Definition: elementMaps.hh:818
PNF
Exc = 0, by default exception is thrown NaN = 1, if point is not found return a NaN Zero = 2,...
const JacobianCell< dim >::cell * lastCoarseCell_
last coarse cell to avoid dynamic cast
A 3D cell: hexahedron.
Definition: cell3D.hh:317
Set with operations, output operator, and method of the particular element types.
Definition: traces.hh:18
Interface for a formula.
Definition: lform.hh:18
A 1D cell: edge.
Definition: cell1D.hh:83
Point< Real, dim > O_
Origin of the periodic box, in a case of a periodic formula projection.
void setPNF(PNF pnf)
Sets the behaviour of the class in the case when a requested point is not found, e....
#define conceptsAssert(cond, exc)
Assert that a certain condition is fulfilled.
Definition: exceptions.hh:394
Set< uint > mapCCells_
Keys of all coarse cells that provide local mapping.
CellStripeElement(const typename JacobianCell< dimC >::cell &cell)
const concepts::RCP< const concepts::Set< uint > > s_attrb_
Source attributes.
Projection class that allows to project an ElementFormula (i.e.
const Real tol_
Stop criterion for interior Newton scheme.
Point< Real, 3 > Real3d
virtual std::ostream & info(std::ostream &os) const
Returns information in an output stream.
Element with cell.
const concepts::ElementFormulaContainer< F, G > u_
The original projected formula.
const Point< Real, dim > shift_
Shift box, from destination mesh to source mesh.
const uint maxDoI_
Determines the internal map for resolving meshes with hanging nodes.
virtual std::ostream & info(std::ostream &os) const
CellBox(const typename JacobianCell< dimC >::cell &cell)
CellBox with a specific order relation.
Cells ordered by key numbering.
void getChild(const typename JacobianCell< dimC >::cell &cCell, const Point< Real, dimC > &eta, const std::array< Real, std::size_t(dimC)> x0, const std::array< Real, std::size_t(dimC)> xN, const typename JacobianCell< dimC >::cell *&cld)
Searches through the dichotomic tree cell hierachy to find the unique child cell that is defined via ...
const Real interior_
Interior in . Defines projection rule, meant to be very small.
std::pair< concepts::Set< CellBox< 1 > >, Real > map
void add(const ElementWithCell< H > *elm, const uint(&idx)[dimC])
Sequence< Point< Real, dimC > > F
const JacobianCell< dimC >::cell & cell
const ElementWithCell< G > * lastElm_
CellMap(const CellMap< dimC, H > &map)
Exception class for assertions.
Definition: exceptions.hh:258
A 3D element map for a hexahedron.
concepts::MapHexahedron3d vtxmap
bool operator==(CCell_F_dist ccF_d) const
A multivector in dimension dimC with const pointer entries.
void shift_DBox_(const Point< Real, dim > &p, Point< Real, dim > &P) const
shifts the physical point to the default periodic box out of the destination mesh,...
CCell_F_dist(const CCell_F< dimC > &ccF, const Point< Real, dimC > &P)
const JacobianCell< dimC >::cell & cell
bool wasCurved_c_
flag if last coarse cell was curved
const concepts::RCP< const concepts::Set< uint > > d_attrb_
Destination attributes.
Interface class for SpacesOnCells that also allow for allCells(), that i.e.
Definition: space.hh:127
A 1D element map for an edge.
Definition: elementMaps.hh:47
F compute_(const Point< Real, dim > &p, const Real t) const
Internal evaluation of local coordinate in the source space and its corresponding element.
concepts::Set< CCell_F< dim > > rCC_
Remaining coarse cells that do not provide box design, i.e. non vertex.
virtual bool operator==(const CellStripeElement< dimC > &sb) const
const CCell_F< dimC > & ccF
#define EPS
Sequence with operations, output operator, and method of the particular element types.
Definition: sequence.hh:39
F min(const concepts::Array< F > &a)
Returns the minimal value in array a.
Definition: arrayOp.hh:67
std::complex< Real > Cmplx
Type for a complex number. It also depends on the setting of Real.
Definition: typedefs.hh:39
FormulaFromElementFormula(const concepts::ElementFormulaContainer< F, G > frm, const concepts::RCP< const concepts::Set< uint > > s_attrb, const concepts::RCP< const concepts::Set< uint > > d_attrb, const Point< Real, dim > scale, const Point< Real, dim > shift, const uint N, const uint cardF_2, const Real tol, const Real interior, const concepts::Set< CellBox< dim > > cBoxes, const concepts::Set< CCell_F< dim > > rCC, const bool allowPer, const Point< Real, dim > O, const Point< Real, dim > eL, const Set< uint > mapCCells, const Set< const typename JacobianCell< dim >::cell * > coarsestCell, const Set< const typename JacobianCell< dim >::cell * > irrCCells, const concepts::HashMap< CellMap< dim, G > > mapToFinestElm, const uint maxDoI, const PNF pnf, const HashMap< HashMap< const concepts::ElementWithCell< G > * > > coarseToElm)
Reference-counting pointer.
Definition: bf_iddiv.hh:15
bool operator<(CCell_F_dist ccF_d) const
virtual bool operator<(const CellBox< dimC > &box) const
The Operator ensures that if a coordinate x > minX[0], then all following boxes in a set also have th...
const Point< Real, dim > scale_
Scaling box, from destination mesh to source mesh.
Point< Real, dim > eL_
Size of the periodic box, in a case of a periodic formula projection.
Set< const typename JacobianCell< dim >::cell * > coarsestCell_
Set of coarsest cells.
std::pair< concepts::Set< CellBox< 2 > >, Real > map
Struct that provides a CCell_F object together with a heuristic distance between given point to the ...
bool compute1_(const typename JacobianCell< dim >::cell &cCell, const Point< Real, dim > &P, const Point< Real, dim > &cEta, const Real t, F &val) const
Evaluates the ElementFormula in the case of coarse Cell using quasi-binary search in the dichotomic t...
const ElementWithCell< H > * get(const uint(&idx)[dimC])
bool wasCurved_
flag is last finecell was a curved one
CCell_F(const typename JacobianCell< dimC >::cell &cell, const uint cardF=2)
void getExtremalLevel(const typename JacobianCell< dim >::cell *cell, uint(&maxL)[dim], uint(&minL)[dim])
Z2 cCellType_
type of last Coarse Cell 0 = Coarse Cell with mapping => O(1) search 1 = Coarse cell has no boxing =>...
concepts::HashMap< CellMap< dim, G > > mapToFinestElm_
void addElements_(const uint cKey, const typename JacobianCell< dim >::cell &cell, const HashMap< const concepts::ElementWithCell< G > * > &mapToElm, HashMap< HashMap< const concepts::ElementWithCell< G > * > > &cCtE)
void allowPeriodicity(const Point< Real, dim > &O, const Point< Real, dim > &eL)
This method allows for periodic destination meshes.
bool operator<(CCell_F cCF) const
MultiVector< dimC, const ElementWithCell< H > * >::map map
const uint N_
Number of Newton steps.
const JacobianCell< dimC >::cell & cell
concepts::Hexahedron3d cell
CellBox(const typename JacobianCell< dimC >::cell &cell, Real xMax)
Class representing a map to ElementWithCells.
HashMap< HashMap< const concepts::ElementWithCell< G > * > > coarseToElm_
maps from coarse cell key to all finest element children belonging to that coarse cell; this is kind ...
virtual bool operator==(const CellBox< dimC > &box) const
void setLocalMap_(const typename JacobianCell< dim >::cell *coarseCell, const HashMap< const ElementWithCell< G > * > &mapToElm, CellMap< dim, G > &map, const std::array< uint, dim > idxL, const std::array< uint, dim > idxR) const
Exception class to handle errors in the FormulaFromElementFormula class.
Set< const typename JacobianCell< dim >::cell * > irrCCells_
Set of coarsest cells that have an irregular children refinement pattern with irregular degree bigger...
std::pair< concepts::Set< CellBox< 3 > >, Real > map
virtual std::ostream & info(std::ostream &os) const
Returns information in an output stream.
Binary group (algebraic): only the values 0 and 1 are represented.
Definition: Zm.hh:16
std::string typeOf(const T &t)
Return the typeid name of a class object.
Definition: output.hh:43
virtual const char * what() const
void resize(const uint(&maxlevel)[dimC])
virtual F operator()(const Real p, const Real t=0.0) const
Application operator.
virtual std::ostream & info(std::ostream &os) const
Returns information in an output stream.
const JacobianCell< dim >::cell * lastCell_
last cell to avoid dynamic cast
Curved Cell struct that holds a physical non-vertex cell with a finite number of setted point evaluat...
std::vector< typename MultiVector< dimC-1, const concepts::ElementWithCell< H > * >::map > map
bool getOrigPoint_(const typename JacobianCell< dim >::cell &cell, const Point< Real, dim > P, Point< Real, dim > &eta, const uint N, const Real interior, const Point< Real, dim > &x0=Real3d(0.49, 0.51, 0.49)) const
Projected Newton scheme based on the parameter interior.
Class providing an output operator.
bool operator==(CCell_F cCF) const
concepts::Set< CellBox< dim > > cBoxes_
Coarse boxes of vertex coarse cells.
bool checkCCells_(const std::set< typename CellType< dim >::cell * > &allCell, typename std::set< typename CellType< dim >::cell * >::const_iterator iter)
Method checks for the preassumed of ordered Cells, starting with coarsest cells, then finer ones etc.
An abstract class for elements of the topology.
Definition: connector.hh:85
double Real
Type normally used for a floating point number.
Definition: typedefs.hh:36
FormulaFromElementFormula(const concepts::ElementFormulaContainer< F, G > frm, const concepts::SpaceOnCoarseCells< dim, G > &sSpc, const Set< uint > *s_attrb=0, const Set< uint > *d_attrb=0, const Point< Real, dim > scale=Point< Real, dim >(1), const Point< Real, dim > shift=Point< Real, dim >(0), const uint N=10, const uint cardF_2=2, const Real tol=EPS, const Real interior=0.00000001, const uint maxDoI=3)
Constructor of the projection.
Basic template class for a Jacobian Cell.
virtual bool operator<(const CellStripeElement< dimC > &sb) const
Basic namespace for Concepts-2.
Definition: pml_formula.h:16
FFEF_Error(const std::string &file, const unsigned int line, const std::string &function, const std::string &errorMessage)
Constructor.
virtual std::ostream & info(std::ostream &os) const
Returns information in an output stream.
Page URL: http://wiki.math.ethz.ch/bin/view/Concepts/WebHome
21 August 2020
© 2020 Eidgenössische Technische Hochschule Zürich