|
FhSim
3.1.0
Marine systems simulation
|
#include <WindField.h>
Inheritance diagram for marenv::wind::WindField:
Collaboration diagram for marenv::wind::WindField:Public Member Functions | |
| virtual | ~WindField ()=default |
| Virtual destructor. | |
| virtual Status | GetWind (double time, const double position[3], double windVelocity[3]) const =0 |
Protected Member Functions | |
| WindField ()=default | |
| The constructor is protected: WindField is an interface. | |
The interface of a wind field: the velocity of the air in a given position and time.
Conventions, for every implementation: positions and velocities are NED [m, m/s]; the height above the mean sea level is -position[2]. The velocity is the air's (the direction the wind blows towards), not the meteorological "from" direction. At and below the mean sea level a field returns zero.
Wind fields registered in an EnvironmentFacade (EnvironmentFacade::AddWindField()) are summed, as current fields are: a mean wind (ConstantWind, or a field from measurements) and gusts (GustField) are separate fields.
|
pure virtual |
Return the wind velocity in a given position and time.
| [in] | time | Time stamp in simulation time [s]. |
| [in] | position | The position to query for, NED [m]. |
| [out] | windVelocity | The velocity of the air in the given time and position, NED [m/s]. |
Threading contract, as for current::CurrentField::GetCurrent(): GetWind() may be called from several threads at once and must not change the field's state; registration happens during setup.
Implemented in marenv::wind::ConstantWind, and marenv::wind::GustField.