ASL  0.1.7
Advanced Simulation Library
aslPositionFunction.h
Go to the documentation of this file.
1 /*
2  * Advanced Simulation Library <http://asl.org.il>
3  *
4  * Copyright 2015 Avtech Scientific <http://avtechscientific.com>
5  *
6  *
7  * This file is part of Advanced Simulation Library (ASL).
8  *
9  * ASL is free software: you can redistribute it and/or modify it
10  * under the terms of the GNU Affero General Public License as
11  * published by the Free Software Foundation, version 3 of the License.
12  *
13  * ASL is distributed in the hope that it will be useful,
14  * but WITHOUT ANY WARRANTY; without even the implied warranty of
15  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16  * GNU Affero General Public License for more details.
17  *
18  * You should have received a copy of the GNU Affero General Public License
19  * along with ASL. If not, see <http://www.gnu.org/licenses/>.
20  *
21  */
22 
23 
24 #ifndef ASLPOSITIONFUNCTION_H
25 #define ASLPOSITIONFUNCTION_H
26 
28 #include "utilities/aslUValue.h"
29 
30 namespace acl
31 {
32  class KernelConfiguration;
33 }
34 
35 namespace asl {
36 
37  template <typename T> class AVec;
38  class Block;
39 
40  class AbstractDataWithGhostNodes;
41  typedef std::shared_ptr<AbstractDataWithGhostNodes> SPAbstractDataWithGhostNodes;
42 
45 
49  {
50  protected:
52  public:
53  virtual ~PositionFunction();
55  };
56 
58  typedef std::shared_ptr<PositionFunction> SPPositionFunction;
59 
62  {
63  protected:
66  public:
68  };
69 
72  {
73  protected:
75  public:
77  };
78 
81  {
82  public:
85  };
86 
89  {
90  public:
93  };
94 
97  {
98  public:
101  };
102 
105  {
106  public:
109  };
110 
113  {
114  private:
116  public:
119  };
120 
123  {
124  private:
125  acl::VectorOfElements gradient;
127  public:
130  };
131 
134  {
135  private:
138  public:
143  acl::VectorOfElements center);
145  };
146 
148  class PFSign: public PFUnaryOperation
149  {
150  public:
153  };
154 
156  SPPositionFunction generatePFLinear(const AVec<double> & g, double p0);
158  template <typename T>
160 
167  const AVec<double> & c);
168 
169 
180 
183  SPPositionFunction df,
184  unsigned int gN,
185  acl::TypeID t);
186 
187 
194  const acl::KernelConfiguration & k);
195 
196 
197 //---------------------------- Implementation --------------------------------
198 
199 
201  {
202  return SPPositionFunction(new PFOperationPlus(a,b));
203  }
204 
206  {
207  return SPPositionFunction(new PFOperationMinus(a,b));
208  }
209 
211  {
213  }
214 
216  {
217  return SPPositionFunction(new PFOperationProduct(a,b));
218  }
219 
221  {
222  return SPPositionFunction(new PFSign(a));
223  }
224 
225 }// asl
226 
227 #endif // ASLPositionFunction
std::shared_ptr< PositionFunction > SPPositionFunction
virtual ~PositionFunction()
PFOperationInversion(SPPositionFunction a)
PFOperationProduct(SPPositionFunction a, SPPositionFunction b)
SPPositionFunction e1
Advanced Simulation Library.
Definition: aslDataInc.h:30
Advanced Computational Language.
Definition: acl.h:40
virtual acl::VectorOfElements value(acl::VectorOfElements &pos)
PFRotationField(acl::VectorOfElements rotationAxis, acl::VectorOfElements center)
virtual acl::VectorOfElements value(acl::VectorOfElements &pos)
SPPositionFunction generatePFLinear(const AVec< double > &g, double p0)
SPDataWrapperACL generateDataContainer_SP(const Block &b, const acl::VectorOfElements &a)
PFConstant(acl::VectorOfElements v)
virtual acl::VectorOfElements value(acl::VectorOfElements &pos)
PFSign(SPPositionFunction a)
creates function corresponding to a velocity field
PFBinaryOperation(SPPositionFunction a, SPPositionFunction b)
virtual acl::VectorOfElements value(acl::VectorOfElements &pos)=0
Updatable value. This class stores value and its TimeStamp.
Definition: aslBasicBC.h:41
The class represents several Element.
void initData(SPAbstractData d, double a)
PFUnaryOperation(SPPositionFunction a)
ACL Kernel configuration class.
PFLinear(acl::VectorOfElements g, acl::VectorOfElements p0)
SPPositionFunction operator*(SPPositionFunction a, SPPositionFunction b)
SPPositionFunction sign(SPPositionFunction a)
const AMatr< T > operator+(const AMatr< T > &a, const AMatr< T > &b)
Definition: aslMatrices.h:252
virtual acl::VectorOfElements value(acl::VectorOfElements &pos)
virtual acl::VectorOfElements value(acl::VectorOfElements &pos)
SPDistanceFunction operator-(SPDistanceFunction a)
SPPositionFunction generatePFRotationField(const AVec< double > &axis, const AVec< double > &c)
PFOperationMinus(SPPositionFunction a, SPPositionFunction b)
TypeID
Definition: aclTypes.h:38
std::shared_ptr< AbstractDataWithGhostNodes > SPAbstractDataWithGhostNodes
Definition: aslGenerators.h:50
virtual acl::VectorOfElements value(acl::VectorOfElements &pos)
PFOperationPlus(SPPositionFunction a, SPPositionFunction b)
SPPositionFunction generatePFConstant(const AVec< double > &a)
virtual acl::VectorOfElements value(acl::VectorOfElements &pos)
virtual acl::VectorOfElements value(acl::VectorOfElements &pos)