00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019 #ifndef _CONTOUR_PDATA_H_
00020 #define _CONTOUR_PDATA_H_
00021
00022 #include "fmatvec/fmatvec.h"
00023 #include "mbsim/frame.h"
00024 #include <vector>
00025
00026 namespace MBSim {
00027
00028 class Point;
00029
00038 class ContourPointData {
00039 public:
00040
00041 enum ContourParameterType { node, staggeredNode, continuum, extInterpol, ffrorigin, fixedrelativeframe };
00042
00046 ContourPointData() :
00047 type(continuum), ID(0), alpha(fmatvec::Vec2()), alphap(fmatvec::Vec2()) {
00048 }
00049 ContourPointData(const double &alpha_) :
00050 type(continuum), ID(0), alpha(fmatvec::Vec2()), alphap(fmatvec::Vec2()) {
00051 alpha(0) = alpha_;
00052 }
00053 ContourPointData(const fmatvec::Vec2 &alpha_) :
00054 type(continuum), ID(0), alpha(alpha_), alphap(fmatvec::Vec2()) {
00055 }
00056 ContourPointData(const int &id_, const ContourParameterType type_ = node) :
00057 type(type_), ID(id_), alpha(fmatvec::Vec2()), alphap(fmatvec::Vec2()) {
00058 }
00059
00063 virtual ~ContourPointData() {
00064 }
00065
00066
00067 ContourParameterType& getContourParameterType() {
00068 return type;
00069 }
00070 const ContourParameterType& getContourParameterType() const {
00071 return type;
00072 }
00073 int& getNodeNumber() {
00074 return ID;
00075 }
00076 const int& getNodeNumber() const {
00077 return ID;
00078 }
00079 fmatvec::Vec2& getLagrangeParameterPosition() {
00080 return alpha;
00081 }
00082 const fmatvec::Vec2& getLagrangeParameterPosition() const {
00083 return alpha;
00084 }
00085 fmatvec::Vec2& getLagrangeParameterVelocity() {
00086 return alphap;
00087 }
00088 const fmatvec::Vec2& getLagrangeParameterVelocity() const {
00089 return alphap;
00090 }
00091 fmatvec::VecV& getInterpolationWeights() {
00092 return iWeights;
00093 }
00094 const fmatvec::VecV& getInterpolationWeights() const {
00095 return iWeights;
00096 }
00097 Frame& getFrameOfReference() {
00098 return cosy;
00099 }
00100 const Frame& getFrameOfReference() const {
00101 return cosy;
00102 }
00103
00104
00105 private:
00109 ContourParameterType type;
00110
00114 int ID;
00115
00119 fmatvec::Vec2 alpha;
00120
00124 fmatvec::Vec2 alphap;
00125
00129 fmatvec::VecV iWeights;
00130
00136 std::vector<Point*> iPoints;
00137
00141 Frame cosy;
00142 };
00143
00144 }
00145
00146 #endif
00147