20 #ifndef _EIGENANALYZER_H_
21 #define _EIGENANALYZER_H_
23 #include "fmatvec/fmatvec.h"
24 #include "mbsim/functions/function.h"
25 #include "mbsim/solver.h"
37 enum Task { eigenmodes, eigenmotion, unknown };
42 Eigenanalyzer() : tStart(0), tEnd(1), dtPlot(1e-2), A(1), loops(5), plotsPerLoop(100), task(eigenmodes) { }
71 void setLoops(
double loops_) { loops = loops_; }
97 void setTask(Task task_) { task = task_; }
99 const fmatvec::Vec& getInitialState()
const {
return zEq; }
125 void initializeUsingXML(xercesc::DOMElement *element);
130 double tStart, tEnd, dtPlot, A;
131 int loops, plotsPerLoop;
136 std::vector<std::pair<double,int> > f;
139 std::string fileName;
141 bool saveEigenanalyis(
const std::string &fileName);
143 void computeEigenvalues();
144 void computeEigenmodes();
145 void computeEigenmotion();
void setLoops(double loops_)
Set the number of loops for animation of each mode.
Definition: eigenanalyzer.h:71
const fmatvec::SquareMatrix< fmatvec::Ref, std::complex< double > > & getEigenvectors() const
Get the eigenvectors.
Definition: eigenanalyzer.h:111
solver-interface for dynamic systems
Definition: solver.h:38
void setOutputFileName(const std::string &fileName_)
Set the name of the output file.
Definition: eigenanalyzer.h:123
Eigenanalyzer for dynamic systems.
Definition: eigenanalyzer.h:33
void setEndTime(double tEnd_)
Set the end time for the analysis.
Definition: eigenanalyzer.h:83
fmatvec::Vec getEigenfrequencies() const
Get the eigenfrequencies.
Definition: eigenanalyzer.cc:57
void setPlotStepSize(double dtPlot_)
Set the plot step size for the analysis.
Definition: eigenanalyzer.h:89
void setInitialDeviation(const fmatvec::Vec &deltaz0_)
Set the initial deviation of the equilibrium.
Definition: eigenanalyzer.h:53
void setModeAmplitudeTable(const fmatvec::Matrix< fmatvec::General, fmatvec::Var, fmatvec::Fixed< 2 >, double > &MA_)
Set the amplitude per mode for animation.
Definition: eigenanalyzer.h:65
const fmatvec::Vector< fmatvec::Ref, std::complex< double > > & getEigenvalues() const
Get the eigenvalues.
Definition: eigenanalyzer.h:105
void setStartTime(double tStart_)
Set the start time for the analysis.
Definition: eigenanalyzer.h:77
void execute()
Perform an eigenanalysis of the system.
Definition: eigenanalyzer.cc:51
Eigenanalyzer()
Standard constructor.
Definition: eigenanalyzer.h:42
void setInitialState(const fmatvec::Vec &z0)
Set the initital state for the analysis.
Definition: eigenanalyzer.h:95
void setAmplitude(double A_)
Set the amplitude of all modes for animation.
Definition: eigenanalyzer.h:59