LCS::ContinuousVelocity< T, Func, Dim > Class Template Reference
Velocity field with continuous velocity function. More...
#include <field.hpp>
Public Types | |
using | vec = LCS::Vector< T, Dim > |
![]() | |
using | vec = LCS::Vector< T, Dim > |
Public Member Functions | |
ContinuousVelocity (unsigned nx, unsigned ny, Position< T, Dim > &pos, T time=0) | |
ContinuousVelocity (unsigned nx, unsigned ny, Position< T, Dim > &pos, std::vector< T > ¶meters, T time=0) | |
void | SetAll () |
Func & | Function () |
![]() | |
Velocity (unsigned nx, unsigned ny, Position< T, Dim > &pos) | |
auto | Get (const unsigned i, const unsigned j) const |
auto & | GetPosition () |
void | InterpolateFrom (Velocity< T, Dim > &ref_vel) |
![]() | |
Field (unsigned nx, unsigned ny) | |
auto & | GetAll () const |
auto | GetTime () const |
void | ReadFromFile (const std::string &file_name) |
void | SetAll (Tensor< Vector< T, Size >, Dim > &data) |
void | UpdateTime (const T time) |
void | WriteToFile (const std::string &file_name) const |
Additional Inherited Members | |
![]() | |
Position< T, Dim > & | pos_ |
![]() | |
const unsigned | nx_ |
const unsigned | ny_ |
Tensor< Vector< T, Size >, Dim > | data_ |
T | time_ |
Detailed Description
template<typename T, typename Func, unsigned Dim>
class LCS::ContinuousVelocity< T, Func, Dim >
Velocity field with continuous velocity function.
This class represents velocity fields that are defined by known continuous velocity function. It is a subclass of Velocity.
- Template Parameters
-
T Numeric data type of the field. Func Continous velocity function for this field. Dim Dimension of the field (2 or 3).
Inheritance diagram for LCS::ContinuousVelocity< T, Func, Dim >:

Constructor & Destructor Documentation
template<typename T , typename Func , unsigned Dim>
|
inline |
Constructor for initializating the continous velocity field.
- Parameters
-
nx The number of points in -direction.
ny The number of points in -direction.
pos The Position field that associated with the ContinuousVelocity field. time Initial time, default value is 0.
template<typename T , typename Func , unsigned Dim>
|
inline |
Constructor for initializating the continous velocity field that the velocity function has parameters.
- Parameters
-
nx The number of points in -direction.
ny The number of points in -direction.
pos The Position field that associated with the ContinuousVelocity field. parameters A vector that contains all the parameters of the velocity function. time Initial time, default value is 0.
Member Function Documentation
template<typename T , typename Func , unsigned Dim>
|
inline |
Get the velocity function of this field.
- Returns
- Continuous velocity function of this field.
template<typename T , typename Func , unsigned Dim>
|
inline |
Use continuous function to set all velocity values.
The documentation for this class was generated from the following file:
- src/field.hpp