25 #ifndef WDATASETDIPOLES_H
26 #define WDATASETDIPOLES_H
30 #include <boost/shared_ptr.hpp>
56 size_t firstTimeStep,
size_t lastTimeStep );
82 size_t firstTimeStep,
size_t lastTimeStep );
115 float getEndTime(
size_t dipoleId = 0u )
const;
123 std::vector<float>
getTimes(
size_t dipoleId = 0u )
const;
131 std::vector<float>
getMagnitudes(
size_t dipoleId = 0u )
const;
171 #endif // WDATASETDIPOLES_H
float getEndTime(size_t dipoleId=0u) const
Return last time where the magnitude is not 0.
Base class for all data set types.
size_t addDipole(WPosition dipPos, std::vector< float > mags, std::vector< float > times, size_t firstTimeStep, size_t lastTimeStep)
Adds a new dipole with given information and checks consistency of the information.
WDataSetDipoles()
Creates a new dipole dataset.
std::vector< Dipole > m_dipoles
List of dipoles representeing this dipoles dataset.
std::vector< float > m_times
Times for the different magnitudes.
std::vector< float > m_magnitudes
The magnitude of the dipole.
float getMagnitude(float time, size_t dipoleId=0)
Return magnitude of dipole for a given time.
WPosition getPosition(size_t dipoleId=0)
Return position of dipole.
This only is a 3d double vector.
size_t getNumberOfDipoles()
Return number of dipoles in this dataset.
float getStartTime(size_t dipoleId=0u) const
Return first time where the magnitude is not 0.
float m_maxMagnitude
Biggest magnitude of all dipoles.
size_t m_firstTimeStep
First time where the magnitude is not 0.
WPosition m_dipolePosition
The location of the dipole.
static boost::shared_ptr< WPrototyped > m_prototype
The prototype as singleton.
std::vector< float > getTimes(size_t dipoleId=0u) const
Return the times where the magnitude is not 0.
size_t m_lastTimeStep
Last time where the magnitude is not 0.
~WDataSetDipoles()
Destructs this dataset.
std::vector< float > getMagnitudes(size_t dipoleId=0u) const
Return the magnitudes where the magnitude is not 0.
float getMaxMagnitude() const
Return the biggest magnitude of all dipoles.
Internal class representing one dipole.
Represents a dipole dataset.
static boost::shared_ptr< WPrototyped > getPrototype()
Returns a prototype instantiated with the true type of the deriving class.