00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020 #ifndef _COMPOUND_CONTOUR_H_
00021 #define _COMPOUND_CONTOUR_H_
00022
00023 #include "mbsim/contour.h"
00024 #include "mbsim/contours/contour_interpolation.h"
00025
00026 namespace MBSim {
00027
00033 class CompoundContour : public RigidContour {
00034 public:
00039 CompoundContour(const std::string &name);
00040
00041
00042 std::string getType() const {
00043 return "CompoundContour";
00044 }
00045 virtual void plot(double t, double dt);
00046 #ifdef HAVE_OPENMBVCPPINTERFACE
00047 OpenMBV::Group* getOpenMBVGrp() { return openMBVGroup; }
00048 #endif
00049
00050
00051
00052
00053
00054
00055
00056
00057
00058
00059
00060
00061
00062 void init(InitStage stage);
00063 Contour* getContourElement(int i) {
00064 return element[i];
00065 }
00066 Contour* getContour(int i) { return element[i]; }
00067 void addContour(RigidContour* ce);
00068 void addFrame(FixedRelativeFrame* f);
00069 unsigned int getNumberOfElements() { return element.size(); }
00070
00071 void updateKinematicsForFrame(ContourPointData &cp, FrameFeature ff);
00072 void updateJacobiansForFrame(ContourPointData &cp);
00073
00074 virtual void updateStateDependentVariables(double t);
00075 virtual void updateJacobians(double t, int j=0);
00076 virtual void updateStateDerivativeDependentVariables(const fmatvec::Vec &ud, double t);
00077
00078 protected:
00082 std::vector<RigidContour*> element;
00083
00087 std::vector<FixedRelativeFrame*> frame;
00088
00092 std::vector<fmatvec::SqrMat3> AIK;
00093
00094 #ifdef HAVE_OPENMBVCPPINTERFACE
00095 OpenMBV::Group* openMBVGroup;
00096 #endif
00097 };
00098 }
00099
00100 #endif
00101