Class documentation of Concepts

Loading...
Searching...
No Matches
elementMaps.hh
Go to the documentation of this file.
1
7#ifndef elementMaps_hh
8#define elementMaps_hh
9
11#include "basics/typedefs.hh"
13#include "basics/cloneable.hh"
14#include "toolbox/sequence.hh"
15#include "toolbox/arrayOp.hh"
16
17namespace concepts {
18
19 // ***************************************************************** Map1d **
20
24 class Map1d : public OutputOperator {
25 public:
26 std::ostream& info(std::ostream& os) const {return os << concepts::typeOf(*this)<<"()";};
27 };
28
29 // ***************************************************************** Map2d **
30
34 class Map2d : public OutputOperator {
35 public:
36 std::ostream& info(std::ostream& os) const {return os << concepts::typeOf(*this)<<"()";};
37 virtual bool straight() const {return false;};
38 };
39
40 // ************************************************************* MapEdge1d **
41
47 class MapEdge1d : public Map1d {
48 public:
53 inline MapEdge1d(const Real vtx0, const Real vtx1) :
54 vtx0_(vtx0), vtx1_(vtx1) {}
55
59 inline Real operator()(const Real x) const {
60 return vtx0_*(1.0-x) + vtx1_*x; }
61
63 inline Real jacobian(const Real) const { return vtx1_-vtx0_; }
64
66 inline MapEdge1d* clone() const {return new MapEdge1d(vtx0_, vtx1_);};
67 protected:
68 virtual std::ostream& info(std::ostream& os) const;
69 private:
71 Real vtx0_, vtx1_;
72 };
73
74 // ********************************************************* MappingEdge2d **
75
84 class MappingEdge2d : public Cloneable, public Map1d {
85 public:
94 virtual MappingEdge2d* clone() const = 0;
96 virtual MappingEdge2d* inverse() const;
100 virtual Real2d operator()(const Real t) const = 0;
102 virtual Real2d derivative(const Real t, const uint n = 1) const = 0;
103
105 virtual Real2d normal(const Real t) const;
107 inline Real2d n0(const Real t) const {
108 return UnitNd<2>(normal(t));
109 }
116 virtual Real curvature(const Real t, uint n = 0) const;
117
121 virtual MappingEdge2d* part(const Real t0, const Real t1) const;
122
124 inline const Real2d& vtx(uint i) const {return vtx_[i];}
125 protected:
126 virtual std::ostream& info(std::ostream& os) const;
129 };
130
131 // ***************************************************** PartMappingEdge2d **
132
138 public:
145 const Real t0, const Real t1);
149 virtual PartMappingEdge2d* clone() const;
151 virtual PartMappingEdge2d* inverse() const;
155 virtual Real2d operator()(const Real t) const;
157 virtual Real2d derivative(const Real t, const uint n = 1) const;
158 protected:
159 virtual std::ostream& info(std::ostream& os) const;
160 private:
162 std::unique_ptr<const MappingEdge2d> edgemap_;
164 const Real t0_, t1_;
165
167 inline const Real t_(const Real t) const {
168 return t0_*(1. - t) + t1_*t;
169 }
170 };
171
172 // ************************************************** InverseMappingEdge2d **
173
180 public:
186
187 virtual InverseMappingEdge2d* clone() const;
188 virtual MappingEdge2d* inverse() const {
189 return edgemap_->clone();
190 }
194 virtual Real2d operator()(const Real t) const;
196 virtual Real2d derivative(const Real t, const uint n = 1) const;
203 virtual Real curvature(const Real t, uint n = 0) const;
204 PartMappingEdge2d* part(const Real t0, const Real t1) const;
205 protected:
206 virtual std::ostream& info(std::ostream& os) const;
209 };
210
211 // ************************************************* MappingStraightEdge2d **
212
219 public:
228 virtual MappingStraightEdge2d* clone() const;
230 return new MappingStraightEdge2d(vtx(1), vtx(0));
231 }
235 virtual Real2d operator()(const Real t) const;
237 virtual Real2d derivative(const Real t, const uint n = 1) const;
238 virtual Real curvature(const Real t, uint n = 0) const;
239 MappingStraightEdge2d* part(const Real t0, const Real t1) const;
240 protected:
241 virtual std::ostream& info(std::ostream& os) const;
244 };
245
246 // ************************************************** CircleMappingEdge2d **
247
260 public:
284 CircleMappingEdge2d(const Real2d center, const Real r,
285 const Real angle0, const Real angle1);
301 virtual CircleMappingEdge2d* clone() const;
302 virtual MappingEdge2d* inverse() const;
303
305 bool straight() const;
306
307 virtual Real2d operator()(const Real t) const;
308 virtual Real2d derivative(const Real t, const uint n = 1) const;
309 virtual Real curvature(const Real t, const uint n = 0) const;
310 MappingEdge2d* part(const Real t0, const Real t1) const;
311 protected:
312 virtual std::ostream& info(std::ostream& os) const;
313 private:
315 Real r_;
317 Real2d m_;
319 Real angle0_, angle1_;
320
321 inline Real phi_(const Real t) const {
322 return angle0_ * (1.-t) + angle1_ * t;
323 }
324 };
325
326 // ************************************************** EllipseMappingEdge2d **
327
339 public:
346 EllipseMappingEdge2d(const Real2d center, const Real a, const Real b,
347 const Real2d vtx0, const Real2d vtx1);
351 virtual EllipseMappingEdge2d* clone() const;
353
354 virtual Real2d operator()(const Real t) const;
355 virtual Real2d derivative(const Real t, const uint n = 1) const;
356 EllipseMappingEdge2d* part(const Real t0, const Real t1) const;
357 protected:
358 virtual std::ostream& info(std::ostream& os) const;
359 private:
361 Real2d m_;
363 Real a_, b_;
365 Real angle0_, angle1_;
366
367 EllipseMappingEdge2d(const Real2d center, const Real a, const Real b,
368 const Real angle0, const Real angle1);
369 };
370
371 // ************************************************** ParabelMappingEdge2d **
372
381 public:
389 const Real2d cusp, const Real2d ap);
393 virtual ParabelMappingEdge2d* clone() const;
394
395 virtual Real2d operator()(const Real t) const;
396 virtual Real2d derivative(const Real t, const uint n = 1) const;
397 ParabelMappingEdge2d* part(const Real t0, const Real t1) const;
398 protected:
399 virtual std::ostream& info(std::ostream& os) const;
400 private:
402 const UnitNd<2> v_, vrot_;
404 const Real2d cusp_;
406 const Real s0_, deltas_;
408 Real p_;
410 const Real s_(const Real t) const;
411 };
412
413 // ************************************************ MappingParallelEdge2d **
414
422 public:
436 virtual MappingParallelEdge2d* clone() const;
437
438 virtual Real2d operator()(const Real t) const;
439 virtual Real2d derivative(const Real t, const uint n = 1) const;
440 virtual Real curvature(const Real t, const uint n = 0) const;
441 virtual Real2d n0(const Real t) const;
442
444 inline const MappingEdge2d& map() const { return *edgemap_; }
446 inline const Real d() const { return d_; }
447 MappingParallelEdge2d* part(const Real t0, const Real t1) const;
448 protected:
449 virtual std::ostream& info(std::ostream& os) const;
450 private:
452 std::unique_ptr<const MappingEdge2d> edgemap_;
454 Real d_;
455 };
456
457 class MappingQuad2d;
458
459 // ***************************************************** MappingQuadEdge2d **
460
466 public:
476 MappingQuadEdge2d(const MappingQuad2d& map, const uint edge);
484 const Real2d xi0, const Real2d xi1);
488 virtual MappingQuadEdge2d* clone() const;
489
490 virtual Real2d operator()(const Real t) const;
491 virtual Real2d derivative(const Real t, const uint n = 1) const;
492 virtual MappingQuadEdge2d* inverse() const {
493 return new MappingQuadEdge2d(*map_, xi_ + xidiff_, xi_);
494 }
495 protected:
496 virtual std::ostream& info(std::ostream& os) const;
497 private:
499 std::unique_ptr<MappingQuad2d> map_;
501 Real2d xi_, xidiff_;
502
503 // Local coordinate of an point on the edge
504 inline const Real2d lcoord_(const Real t) const {
505 return xi_ + xidiff_*t;
506 }
507 // Derivative of the local mapping
508 inline const Real2d lderiv_(const Real t) const {
509 return xidiff_;
510 }
511 };
512
513 // ***************************************************** MappingTriangle2d **
514
520 class MappingTriangle2d : public Map2d {
521 public:
526 virtual Real2d operator()(const Real x, const Real y) const = 0;
527
531 virtual MappingTriangle2d* clone() const = 0;
532
538 //virtual bool curved() const = 0;
539
541 virtual Real jacobianDeterminant(const Real x, const Real y) const;
542
544 virtual MapReal2d jacobian(const Real x, const Real y) const = 0;
545
547 virtual MapReal2d jacobianInverse(const Real x, const Real y) const;
548 };
549
550 // ****************************************************** VertexTriangle2d **
551
558 public:
566
569
570 virtual ~VertexTriangle2d();
571 virtual VertexTriangle2d* clone() const;
572 //virtual bool curved() const;
573
578 virtual bool straight() const {return true;};
579
580 virtual MapReal2d jacobian(const Real x, const Real y) const {
581 return jacobian_;
582 }
583
584 Real2d operator()(const Real x, const Real y) const {
585 conceptsAssert(0.0 <= y, Assertion());
586 conceptsAssert(0.0 <= x, Assertion());
587 conceptsAssert(y <= x, Assertion());
588 conceptsAssert(x <= 1.0, Assertion());
589
590 Real2d res(vtx1_); res -= vtx0_; res *= x;
591 Real2d res2(vtx2_); res2 -= vtx1_; res2 *= y;
592 res += res2;
593
594 res += vtx0_;
595 return res;
596 }
597 protected:
598 virtual std::ostream& info(std::ostream& os) const;
599 private:
601 Real2d vtx0_, vtx1_, vtx2_;
603 MapReal2d jacobian_;
604 };
605
606 // ******************************************************* MapTriangle2d **
607
616 public:
627 MapTriangle2d(char* map, const Real scX, const Real scY);
628
631
632 virtual ~MapTriangle2d();
633 virtual MapTriangle2d* clone() const;
634 //virtual bool curved() const;
635 virtual MapReal2d jacobian(const Real x, const Real y) const;
636
637 Real2d operator()(const Real x, const Real y) const {
638 conceptsAssert(0.0 <= y, Assertion());
639 conceptsAssert(0.0 <= x, Assertion());
640 conceptsAssert(y <= x, Assertion());
641 conceptsAssert(x <= 1.0, Assertion());
642 return Real2d(map_, scx_ * x, scy_ * (x == 0 ? 0 : y/x));
643 }
644 protected:
645 virtual std::ostream& info(std::ostream& os) const;
646 private:
648 uchar* map_;
649
651 uint sz_;
652
654 const Real scx_;
655
657 const Real scy_;
658 };
659
660
661 // ********************************************************* MappingQuad2d **
662
667 class MappingQuad2d : public Map2d {
668 public:
673 virtual Real2d operator()(Real x, Real y) const = 0;
674
676 virtual Real jacobianDeterminant(const Real x, const Real y) const;
677
679 virtual MapReal2d jacobian(const Real x, const Real y) const = 0;
680
682 virtual MapReal2d jacobianInverse(const Real x, const Real y) const;
683
688 virtual MapReal2d hessian(uint i, const Real x, const Real y) const = 0;
689
702 virtual MapReal2d inverseLaplace(const Real x, const Real y) const;
703
704
722 virtual Real lineElement(const Real x, const uint edge) const;
723
731 virtual MappingEdge2d* edge(const uint edge) const {
732 return new MappingQuadEdge2d(*this, edge);
733 }
734
738 virtual MappingQuad2d* part(const Real2d x0, const Real2d y0) const;
739
741 virtual MappingQuad2d* clone() const = 0;
742 protected:
743 virtual std::ostream& info(std::ostream& os) const;
744 };
745
746 // ************************************************************* MapQuad2d **
747
756 class MapQuad2d : public MappingQuad2d {
757 public:
770 MapQuad2d(const char* map, Real scX, Real scY,
771 Real2d org = Real2d(0.0, 0.0), Real stretch = 1.0);
772 MapQuad2d(const char* map, Real scX, Real scY, Real2d org,
774
776 MapQuad2d(const MapQuad2d &map);
777 virtual ~MapQuad2d();
778
779 virtual Real2d operator()(Real x, Real y) const {
780 Real2d v(map_, scx_ * x, scy_ * y);
781 return Real2d(v[0]*scaling_[0] + org_[0], v[1]*scaling_[1] + org_[0]);
782 }
783
784 virtual MapReal2d jacobian(const Real x, const Real y) const;
785
786 virtual MapReal2d hessian(uint i, const Real x, const Real y) const;
787
788 virtual MapQuad2d* clone() const { return new MapQuad2d(*this); }
789 protected:
790 virtual std::ostream& info(std::ostream& os) const;
791 private:
793 uchar* map_;
794
796 uint sz_;
797
799 Real scx_;
800
802 Real scy_;
803
804 Real2d org_;
805 Real2d scaling_;
806
808 void operator=(const MapQuad2d &);
809 };
810
811 // ********************************************************** VertexQuad2d **
812
819 public:
825 virtual ~VertexQuad2d();
826 virtual Real2d operator()(Real x, Real y) const;
827
832 virtual MapReal2d jacobian(const Real x, const Real y) const;
833
834 virtual MapReal2d hessian(uint i, const Real x, const Real y) const;
835
840 virtual Real lineElement(const Real x, const uint edge) const;
841
842 virtual MappingStraightEdge2d* edge(const uint edge) const;
843
844 virtual VertexQuad2d* part(const Real2d x0, const Real2d y0) const;
845
846 virtual VertexQuad2d* clone() const;
847
848 virtual bool straight() const {return true;};
849 protected:
850 virtual std::ostream& info(std::ostream& os) const;
851 private:
853 Real2d vtx_[4];
855 mutable Real len_[4];
857 bool hasLength_;
858 };
859
860 // ********************************************************* BlendingQuad2d **
861
873 public:
904 const MappingEdge2d* edgemap1,
905 const MappingEdge2d* edgemap2,
906 const MappingEdge2d* edgemap3 = 0,
907 const Real2d* vtx0 = 0, const Real2d* vtx1 = 0,
908 const Real2d* vtx2 = 0, const Real2d* vtx3 = 0);
912 virtual Real2d operator()(Real x, Real y) const;
913 virtual MapReal2d jacobian(const Real x, const Real y) const;
914 virtual MapReal2d hessian(uint i, const Real x, const Real y) const;
915 virtual Real lineElement(const Real x, const uint edge) const;
916 virtual MappingEdge2d* edge(const uint edge) const {
918 return edgemap_[edge]->clone();
919 }
920 virtual BlendingQuad2d* clone() const { return new BlendingQuad2d(*this); }
921 protected:
922 virtual std::ostream& info(std::ostream& os) const;
923 private:
925 Real2d vtx_[4];
927 const MappingEdge2d* edgemap_[4];
929 void testJacobian_() const;
930 };
931
932 // ***************************************************** PartMappingQuad2d **
933
939 public:
947 const Real2d xi0, const Real2d xi1);
951 virtual PartMappingQuad2d* clone() const;
955 virtual Real2d operator()(Real x, Real y) const;
956 virtual MapReal2d jacobian(const Real x, const Real y) const;
957 virtual MapReal2d hessian(uint i, const Real x, const Real y) const;
958 virtual MappingEdge2d* edge(const uint edge) const;
959 protected:
960 virtual std::ostream& info(std::ostream& os) const;
961 private:
963 std::unique_ptr<const MappingQuad2d> map_;
967 const Real2d x0_;
971 const Real2d d_;
972
974 inline const Real2d xi_(const Real x, const Real y) const {
975 return x0_ + Real2d(x * d_[0], y * d_[1]);
976 }
977 };
978
979 // ********************************************* InverseVertexQuadSector2d **
980
988 public:
992 const Real2d vtx2, const Real2d vtx3);
997 // Copy constructor
1000 virtual Real2d operator()(const Real2d x) const;
1001 virtual MapReal2d jacobian(const Real2d x) const;
1002 virtual bool is_inregion(const Real2d x) const;
1003 virtual bool is_inpatch(const Real2d x) const;
1004 virtual InverseVertexQuadSector2d* clone() const;
1005
1006 protected:
1007 virtual std::ostream& info(std::ostream& os) const;
1008
1009 private:
1011 void construct_(const Real2d vtx0, const Real2d vtx1,
1012 const Real2d vtx2, const Real2d vtx3);
1014 Real2d sector_p_[4];
1016 Real2d vtx_[4];
1017 };
1018
1019 // ********************************************************* MapTriangle3d **
1020
1023 class MapTriangle3d : public Map2d {
1024 public:
1035 MapTriangle3d(const char* map, Real scX, Real scY);
1036
1044
1047 ~MapTriangle3d() { delete[] map_; };
1048
1057 if (map_)
1058 return Real3d(map_, scx_ * x, scy_ * y);
1059 else {
1060 Real3d res;
1061 res.lincomb(B1_, B2_, x, x*y);
1062 res += b_;
1063 return res;
1064 }
1065 }
1066
1068 inline MapTriangle3d* clone() const {return new MapTriangle3d(*this);};
1069 private:
1071 uchar* map_;
1072
1074 uint sz_;
1075
1077 Real scx_;
1078
1080 Real scy_;
1081
1083 Real3d B1_, B2_, b_;
1084
1086 void operator=(const MapTriangle3d &);
1087 };
1088
1089} // namespace concepts
1090
1091#endif // elementMaps_hh
virtual MapReal2d jacobian(const Real x, const Real y) const
Returns the Jacobian in a 2D linear map.
BlendingQuad2d(const BlendingQuad2d &v)
Copy constructor.
virtual Real2d operator()(Real x, Real y) const
virtual MappingEdge2d * edge(const uint edge) const
virtual std::ostream & info(std::ostream &os) const
Returns information in an output stream.
virtual MapReal2d hessian(uint i, const Real x, const Real y) const
virtual Real lineElement(const Real x, const uint edge) const
virtual BlendingQuad2d * clone() const
Returns a copy of the map.
BlendingQuad2d(const MappingEdge2d *edgemap0, const MappingEdge2d *edgemap1, const MappingEdge2d *edgemap2, const MappingEdge2d *edgemap3=0, const Real2d *vtx0=0, const Real2d *vtx1=0, const Real2d *vtx2=0, const Real2d *vtx3=0)
MappingEdge2d * part(const Real t0, const Real t1) const
virtual MappingEdge2d * inverse() const
Returns the mapping of the edge in inverse direction.
bool straight() const
returns true if the mapping is straight, i.e. the radius equals zero.
virtual Real2d derivative(const Real t, const uint n=1) const
Returns the n-th derivative.
virtual std::ostream & info(std::ostream &os) const
Returns information in an output stream.
virtual Real curvature(const Real t, const uint n=0) const
virtual Real2d operator()(const Real t) const
CircleMappingEdge2d(const Real2d vtx0, const Real2d vtxm, const Real2d vtx1)
virtual CircleMappingEdge2d * clone() const
Virtual copy constructor.
CircleMappingEdge2d(const Real2d center, const Real r, const Real angle0, const Real angle1)
CircleMappingEdge2d(const Real r, const Real2d vtx0, const Real2d vtx1)
CircleMappingEdge2d(const CircleMappingEdge2d &edgemap)
Copy Constructor.
EllipseMappingEdge2d(const EllipseMappingEdge2d &edgemap)
Copy Constructor.
virtual Real2d operator()(const Real t) const
EllipseMappingEdge2d * part(const Real t0, const Real t1) const
virtual EllipseMappingEdge2d * clone() const
Virtual copy constructor.
EllipseMappingEdge2d(const Real2d center, const Real a, const Real b, const Real2d vtx0, const Real2d vtx1)
virtual EllipseMappingEdge2d * inverse() const
Returns the mapping of the edge in inverse direction.
virtual std::ostream & info(std::ostream &os) const
Returns information in an output stream.
virtual Real2d derivative(const Real t, const uint n=1) const
Returns the n-th derivative.
InverseMappingEdge2d(const MappingEdge2d &edgemap)
PartMappingEdge2d * part(const Real t0, const Real t1) const
virtual Real2d derivative(const Real t, const uint n=1) const
Returns the n-th derivative.
const MappingEdge2d * edgemap_
Original edge map.
virtual std::ostream & info(std::ostream &os) const
Returns information in an output stream.
virtual InverseMappingEdge2d * clone() const
Virtual copy constructor.
virtual MappingEdge2d * inverse() const
Returns the mapping of the edge in inverse direction.
virtual Real curvature(const Real t, uint n=0) const
virtual Real2d operator()(const Real t) const
InverseVertexQuadSector2d(const Real2d vtx0, const Real2d vtx1, const Real2d vtx2, const Real2d vtx3)
virtual std::ostream & info(std::ostream &os) const
Returns information in an output stream.
InverseVertexQuadSector2d(const Sequence< Real2d > x)
std::ostream & info(std::ostream &os) const
Returns information in an output stream.
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.
Real operator()(const Real x) const
MapEdge1d * clone() const
Returns a copy of the map.
MapEdge1d(const Real vtx0, const Real vtx1)
Real jacobian(const Real) const
Returns the jacobian.
virtual std::ostream & info(std::ostream &os) const
Returns information in an output stream.
MapQuad2d(const char *map, Real scX, Real scY, Real2d org=Real2d(0.0, 0.0), Real stretch=1.0)
virtual MapReal2d hessian(uint i, const Real x, const Real y) const
virtual MapQuad2d * clone() const
Returns a copy of the map.
virtual MapReal2d jacobian(const Real x, const Real y) const
Returns the Jacobian in a 2D linear map.
MapQuad2d(const MapQuad2d &map)
Copy constructor.
virtual Real2d operator()(Real x, Real y) const
virtual MapTriangle2d * clone() const
virtual MapReal2d jacobian(const Real x, const Real y) const
Returns the Jacobian in a 2D linear map.
Real2d operator()(const Real x, const Real y) const
MapTriangle2d(char *map, const Real scX, const Real scY)
MapTriangle2d(const MapTriangle2d &map)
Copy constructor.
virtual std::ostream & info(std::ostream &os) const
Returns information in an output stream.
MapTriangle3d(const char *map, Real scX, Real scY)
MapTriangle3d * clone() const
Returns a copy of the map.
Real3d operator()(Real x, Real y) const
MapTriangle3d(Real3d vtx0, Real3d vtx1, Real3d vtx2)
MapTriangle3d(const MapTriangle3d &map)
Copy constructor.
Real2d vtx_[2]
Coordinates of the vertices at either end of the edge.
MappingEdge2d(const Real2d vtx0, const Real2d vtx1)
virtual MappingEdge2d * part(const Real t0, const Real t1) const
virtual Real2d derivative(const Real t, const uint n=1) const =0
Returns the n-th derivative.
virtual Real2d normal(const Real t) const
Returns the right normal vector, length is that of the derivative.
virtual std::ostream & info(std::ostream &os) const
Returns information in an output stream.
virtual MappingEdge2d * inverse() const
Returns the mapping of the edge in inverse direction.
const Real2d & vtx(uint i) const
Spit out one vertex of the edge.
virtual Real2d operator()(const Real t) const =0
Real2d n0(const Real t) const
Returns the normalised right normal vector.
MappingEdge2d(const MappingEdge2d &edgemap)
Copy Constructor.
virtual MappingEdge2d * clone() const =0
Virtual copy constructor.
virtual Real curvature(const Real t, uint n=0) const
virtual Real curvature(const Real t, const uint n=0) const
virtual Real2d derivative(const Real t, const uint n=1) const
Returns the n-th derivative.
virtual Real2d operator()(const Real t) const
const MappingEdge2d & map() const
Returns the edge to which this edge is parallel.
virtual std::ostream & info(std::ostream &os) const
Returns information in an output stream.
const Real d() const
Returns the distance.
MappingParallelEdge2d(const MappingEdge2d &edgemap, const Real d)
MappingParallelEdge2d * part(const Real t0, const Real t1) const
virtual MappingParallelEdge2d * clone() const
Virtual copy constructor.
MappingParallelEdge2d(const MappingParallelEdge2d &edgemap)
Copy Constructor.
virtual Real2d operator()(Real x, Real y) const =0
virtual Real lineElement(const Real x, const uint edge) const
virtual Real jacobianDeterminant(const Real x, const Real y) const
Returns determinant of the Jacobian.
virtual MapReal2d jacobianInverse(const Real x, const Real y) const
Returns the inverse of the Jacobian in a 2D linear map.
virtual MapReal2d inverseLaplace(const Real x, const Real y) const
virtual MapReal2d jacobian(const Real x, const Real y) const =0
Returns the Jacobian in a 2D linear map.
virtual std::ostream & info(std::ostream &os) const
Returns information in an output stream.
virtual MapReal2d hessian(uint i, const Real x, const Real y) const =0
virtual MappingQuad2d * part(const Real2d x0, const Real2d y0) const
virtual MappingEdge2d * edge(const uint edge) const
virtual MappingQuad2d * clone() const =0
Returns a copy of the map.
MappingQuadEdge2d(const MappingQuad2d &map, const Real2d xi0, const Real2d xi1)
MappingQuadEdge2d(const MappingQuad2d &map, const uint edge)
virtual MappingQuadEdge2d * clone() const
Virtual copy constructor.
MappingQuadEdge2d(const MappingQuadEdge2d &edgemap)
Copy Constructor.
virtual std::ostream & info(std::ostream &os) const
Returns information in an output stream.
virtual MappingQuadEdge2d * inverse() const
Returns the mapping of the edge in inverse direction.
virtual Real2d operator()(const Real t) const
virtual Real2d derivative(const Real t, const uint n=1) const
Returns the n-th derivative.
virtual std::ostream & info(std::ostream &os) const
Returns information in an output stream.
MappingStraightEdge2d(const Real2d vtx0, const Real2d vtx1)
MappingStraightEdge2d(const MappingStraightEdge2d &edgemap)
Copy Constructor.
virtual MappingStraightEdge2d * clone() const
Virtual copy constructor.
virtual Real curvature(const Real t, uint n=0) const
virtual Real2d operator()(const Real t) const
virtual MappingStraightEdge2d * inverse() const
Returns the mapping of the edge in inverse direction.
MappingStraightEdge2d * part(const Real t0, const Real t1) const
virtual Real2d derivative(const Real t, const uint n=1) const
Returns the n-th derivative.
Real2d delta_
Vector from first to second vertex.
virtual MapReal2d jacobian(const Real x, const Real y) const =0
Returns the Jacobian in a 2D linear map.
virtual MappingTriangle2d * clone() const =0
virtual Real jacobianDeterminant(const Real x, const Real y) const
Returns determinant of the Jacobian.
virtual MapReal2d jacobianInverse(const Real x, const Real y) const
Returns the inverse of the Jacobian in a 2D linear map.
virtual Real2d operator()(const Real x, const Real y) const =0
ParabelMappingEdge2d(const ParabelMappingEdge2d &edgemap)
Copy Constructor.
virtual Real2d derivative(const Real t, const uint n=1) const
Returns the n-th derivative.
ParabelMappingEdge2d(const Real2d vtx0, const Real2d vtx1, const Real2d cusp, const Real2d ap)
ParabelMappingEdge2d * part(const Real t0, const Real t1) const
virtual std::ostream & info(std::ostream &os) const
Returns information in an output stream.
virtual Real2d operator()(const Real t) const
virtual ParabelMappingEdge2d * clone() const
Virtual copy constructor.
virtual PartMappingEdge2d * inverse() const
Returns the mapping of the edge in inverse direction.
virtual Real2d derivative(const Real t, const uint n=1) const
Returns the n-th derivative.
PartMappingEdge2d(const PartMappingEdge2d &edgemap)
Copy Constructor.
virtual PartMappingEdge2d * clone() const
Virtual copy constructor.
virtual Real2d operator()(const Real t) const
virtual std::ostream & info(std::ostream &os) const
Returns information in an output stream.
PartMappingEdge2d(const MappingEdge2d &edgemap, const Real t0, const Real t1)
virtual PartMappingQuad2d * clone() const
Virtual copy constructor.
virtual MapReal2d jacobian(const Real x, const Real y) const
Returns the Jacobian in a 2D linear map.
virtual MapReal2d hessian(uint i, const Real x, const Real y) const
virtual Real2d operator()(Real x, Real y) const
virtual MappingEdge2d * edge(const uint edge) const
PartMappingQuad2d(const PartMappingQuad2d &map)
Copy Constructor.
PartMappingQuad2d(const MappingQuad2d &map, const Real2d xi0, const Real2d xi1)
virtual std::ostream & info(std::ostream &os) const
Returns information in an output stream.
void lincomb(const Point< F, dim > &a, const Point< F, dim > &b, const F ca=1.0, const F cb=1.0)
Assign the vector the linear combination of a and b.
virtual VertexQuad2d * clone() const
Returns a copy of the map.
VertexQuad2d(const VertexQuad2d &v)
Copy constructor.
virtual Real2d operator()(Real x, Real y) const
virtual VertexQuad2d * part(const Real2d x0, const Real2d y0) const
VertexQuad2d(Real2d vtx0, Real2d vtx1, Real2d vtx2, Real2d vtx3)
virtual Real lineElement(const Real x, const uint edge) const
virtual MappingStraightEdge2d * edge(const uint edge) const
virtual MapReal2d jacobian(const Real x, const Real y) const
virtual MapReal2d hessian(uint i, const Real x, const Real y) const
virtual std::ostream & info(std::ostream &os) const
Returns information in an output stream.
VertexTriangle2d(const VertexTriangle2d &map)
Copy constructor.
virtual std::ostream & info(std::ostream &os) const
Returns information in an output stream.
VertexTriangle2d(Real2d vtx0, Real2d vtx1, Real2d vtx2)
virtual bool straight() const
Real2d operator()(const Real x, const Real y) const
virtual VertexTriangle2d * clone() const
virtual MapReal2d jacobian(const Real x, const Real y) const
Returns the Jacobian in a 2D linear map.
#define conceptsAssert(cond, exc)
std::string typeOf(const T &t)
Definition output.hh:43
double Real
Definition typedefs.hh:39
Set< F > makeSet(uint n, const F &first,...)
Definition set.hh:320
unsigned char uchar
Abbreviation for unsigned char.
Definition typedefs.hh:48