TurbineData Struct Reference
Kynema API
A flexible multibody structural dynamics code for wind turbines
|
Struct to hold and manage turbine-specific data. More...
#include <aerodyn_inflow.hpp>
Public Member Functions | |
TurbineData (const TurbineConfig &tc) | |
Constructor for TurbineData based on a TurbineConfig object. | |
void | Validate () const |
size_t | NumberOfBlades () const |
Returns the number of blades as size_t. | |
void | SetBladeNodeMotion (size_t blade_number, size_t node_number, const std::array< double, 7 > &position, const std::array< double, 6 > &velocity, const std::array< double, 6 > &acceleration) |
Sets the blade node values based on blade number and node number. | |
void | SetBladeRootMotion (size_t blade_number, const std::array< double, 7 > &position, const std::array< double, 6 > &velocity, const std::array< double, 6 > &acceleration) |
Sets the blade root values based on blade number. | |
void | SetHubMotion (const std::array< double, 7 > &position, const std::array< double, 6 > &velocity, const std::array< double, 6 > &acceleration) |
Sets the hub motion values. | |
void | SetNacelleMotion (const std::array< double, 7 > &position, const std::array< double, 6 > &velocity, const std::array< double, 6 > &acceleration) |
Sets the nacelle motion values. | |
std::array< double, 6 > | GetBladeNodeLoad (size_t blade_number, size_t node_number) const |
Gets the blade node loads based on blade number and node number. | |
Public Attributes | |
int32_t | n_blades |
MeshData | hub |
MeshData | nacelle |
MeshData | blade_roots |
MeshData | blade_nodes |
std::array< float, 3 > | hh_vel |
std::vector< int32_t > | blade_nodes_to_blade_num_mapping |
Mapping of blade nodes to blade numbers (1D array) | |
std::vector< std::vector< size_t > > | node_indices_by_blade |
Unique indices of nodes for each blade (2D array) | |
Detailed Description
Struct to hold and manage turbine-specific data.
This struct contains data for a single turbine, including the number of blades, mesh data for various components (hub, nacelle, blade roots, blade nodes), and blade node mappings.
Constructor & Destructor Documentation
◆ TurbineData()
|
inline |
Constructor for TurbineData based on a TurbineConfig object.
This constructor initializes the turbine data in AeroDyn/InflowWind compatible format based on the provided TurbineConfig object in 7x1 arrays i.e. Kynema format.
- Parameters
-
tc The TurbineConfig object containing the initial state of the turbine
Member Function Documentation
◆ GetBladeNodeLoad()
|
inline |
Gets the blade node loads based on blade number and node number.
This method returns the blade node loads based on the provided blade number and node number. It simplifies the process by abstracting away the indexing logic.
- Parameters
-
blade_number The number of the blade to update. node_number The number of the node to update within the specified blade.
◆ NumberOfBlades()
|
inline |
Returns the number of blades as size_t.
◆ SetBladeNodeMotion()
|
inline |
Sets the blade node values based on blade number and node number.
This method updates the blade node values in the mesh based on the provided blade number and node number. It simplifies the process of updating blade node values by abstracting away the indexing logic.
- Parameters
-
blade_number The number of the blade to update. node_number The number of the node to update within the specified blade. position The new position of the node [x, y, z, qw, qx, qy, qz] velocity The new velocity of the node [u, v, w, p, q, r] acceleration The new acceleration of the node [u_dot, v_dot, w_dot, p_dot, q_dot, r_dot]
◆ SetBladeRootMotion()
|
inline |
Sets the blade root values based on blade number.
This method updates the blade root values in the mesh based on the provided blade number and node number. It handles orientation conversion so Z is along blade axis.
- Parameters
-
blade_number The number of the blade to update. position The new position of the node [x, y, z, qw, qx, qy, qz] velocity The new velocity of the node [u, v, w, p, q, r] acceleration The new acceleration of the node [u_dot, v_dot, w_dot, p_dot, q_dot, r_dot]
◆ SetHubMotion()
|
inline |
Sets the hub motion values.
This method updates the hub motion values.
- Parameters
-
position The new position of the node [x, y, z, qw, qx, qy, qz] velocity The new velocity of the node [u, v, w, p, q, r] acceleration The new acceleration of the node [u_dot, v_dot, w_dot, p_dot, q_dot, r_dot]
◆ SetNacelleMotion()
|
inline |
Sets the nacelle motion values.
This method sets the nacelle motion values.
- Parameters
-
position The new position of the node [x, y, z, qw, qx, qy, qz] velocity The new velocity of the node [u, v, w, p, q, r] acceleration The new acceleration of the node [u_dot, v_dot, w_dot, p_dot, q_dot, r_dot]
◆ Validate()
|
inline |
Member Data Documentation
◆ blade_nodes
MeshData kynema::util::TurbineData::blade_nodes |
◆ blade_nodes_to_blade_num_mapping
std::vector<int32_t> kynema::util::TurbineData::blade_nodes_to_blade_num_mapping |
Mapping of blade nodes to blade numbers (1D array)
This vector stores the blade number (1-based index) for each blade node. It allows quick lookup of which blade a particular node belongs to. The size of this vector is equal to the total number of blade nodes across all blades.
◆ blade_roots
MeshData kynema::util::TurbineData::blade_roots |
◆ hh_vel
std::array<float, 3> kynema::util::TurbineData::hh_vel |
◆ hub
MeshData kynema::util::TurbineData::hub |
◆ n_blades
int32_t kynema::util::TurbineData::n_blades |
◆ nacelle
MeshData kynema::util::TurbineData::nacelle |
◆ node_indices_by_blade
std::vector<std::vector<size_t> > kynema::util::TurbineData::node_indices_by_blade |
Unique indices of nodes for each blade (2D array)
This is a vector of vectors where each inner vector contains the unique indices of nodes belonging to a specific blade. The outer vector's size is equal to the number of blades, and each inner vector's size is equal to the number of nodes on that blade. This structure allows quick access to all nodes of a particular blade.
The documentation for this struct was generated from the following file:
- /home/runner/work/kynema/kynema/kynema/src/utilities/aerodynamics/aerodyn_inflow.hpp
Generated by