Turbine Class Reference

Kynema API: kynema::interfaces::components::Turbine Class Reference
Kynema API
A flexible multibody structural dynamics code for wind turbines
Loading...
Searching...
No Matches
kynema::interfaces::components::Turbine Class Reference

Represents a turbine with nodes, elements, and constraints. More...

#include <turbine.hpp>

Public Types

using DeviceType = Kokkos::Device< Kokkos::DefaultExecutionSpace, Kokkos::DefaultExecutionSpace::memory_space >
 

Public Member Functions

 Turbine (const TurbineInput &input, Model &model)
 Constructs a turbine with the specified input configuration.
 
void GetMotion (const HostState< DeviceType > &host_state)
 Populate node motion from host state.
 
void SetLoads (HostState< DeviceType > &host_state) const
 Update the host state with current node forces and moments.
 
const TurbineInputGetTurbineInput () const
 Get the turbine input configuration.
 

Public Attributes

std::vector< Beamblades
 
Beam tower
 
size_t hub_mass_element_id {invalid_id}
 
size_t yaw_bearing_mass_element_id {invalid_id}
 
std::vector< NodeDataapex_nodes
 
NodeData hub_node
 
NodeData azimuth_node
 
NodeData shaft_base_node
 
NodeData yaw_bearing_node
 
ConstraintData tower_base
 
ConstraintData tower_top_to_yaw_bearing
 
ConstraintData yaw_bearing_to_shaft_base
 
ConstraintData shaft_base_to_azimuth
 
ConstraintData azimuth_to_hub
 
std::vector< ConstraintDatablade_pitch
 
std::vector< ConstraintDataapex_to_hub
 
std::vector< double > blade_pitch_control
 
double torque_control {0.}
 
double yaw_control {0.}
 

Static Public Attributes

static constexpr size_t invalid_id {9999999}
 Placeholder node ID value for uninitialized components.
 
static constexpr double kMinHubDiameter {1e-8}
 Minimum valid hub diameter.
 
static constexpr double kZeroTolerance {1e-12}
 Tolerance for near zero comparisons.
 

Detailed Description

Represents a turbine with nodes, elements, and constraints.

This class is responsible for creating and managing a turbine based on the turbine input specifications. It handles the creation of the beam elements, mass elements, nodes, and constraints within the provided model.


Node structure

The turbine assembly consists of multiple interconnected nodes that represent different physical components and their kinematic relationships.

Tower Nodes

  • Tower nodes: Beam nodes distributed along tower height (1, 2, ..., n)
  • Tower base: Fixed constraint point at tower foundation (first tower node)
  • Tower top: Connection point to nacelle assembly (last tower node)

    ┌─── Tower top node (connection to nacelle) │ ○ <- Tower node n │ ○ <- Tower node n-1 | | │ ○ <- Tower node 2 │

    ○ <- Tower node 1 (Tower base node - fixed constraint)

    / / / / / / / <– Ground / Foundation

Nacelle/Drivetrain Nodes

  • Yaw bearing node: Located at tower top, allows nacelle yaw rotation
  • Shaft base node: Base of the main shaft within nacelle
  • Azimuth node: Intermediate node for rotor azimuth positioning
  • Hub node: Center of mass of the rotating hub assembly
         Yaw bearing      Shaft base      Azimuth          Hub
            node            node           node            node
             ● -------------- ● ------------ ● ------------ ● -------------
    
    yaw control | rigid torque rigid rigid rotation | connection control connection connection about Z-axis | via revolute to blades joint Blade Assembly Nodes
  • Blade apex nodes: Connection points between hub and blade roots (one per blade)
  • Blade structural nodes: Beam nodes along each blade span
               pitch axis,
            rotation control |<----- Blade nodes ----->|
    
    ● Blade apex ----------— ● -----— ● -----— ● node root tip │ node node │ rigid connection │

    ● Hub node

Kinematic chain/constraints

The nodes are connected in a kinematic chain that represents the turbine's degrees of freedom.

  • tower base node: Fixed boundary condition
  • tower top node <-> yaw bearing node: Yaw rotation control
  • yaw bearing node <-> shaft base node: Rigid joint
  • shaft base node <-> azimuth node: Revolute joint with torque control
  • hub <-> blade apex nodes: Rigid joint
  • blade apex nodes <-> blade root nodes: Pitch rotation control

Member Typedef Documentation

◆ DeviceType

using kynema::interfaces::components::Turbine::DeviceType = Kokkos::Device<Kokkos::DefaultExecutionSpace, Kokkos::DefaultExecutionSpace::memory_space>

Constructor & Destructor Documentation

◆ Turbine()

kynema::interfaces::components::Turbine::Turbine ( const TurbineInput input,
Model model 
)

Constructs a turbine with the specified input configuration.

Creates a complete turbine structure including blades, tower, hub, nacelle components,and all associated nodes, elements, constraints, and control systems. The turbine is positioned and oriented according to the input parameters, with proper kinematic

relationships established between all components.

Construction sequence

  1. Validation: Input parameters are checked for physical consistency
  2. Node creation + positioning: All nodes are created at the origin and assembled at their correct spatial locations/orientations
  3. Mass element addition: Mass and inertia properties are assigned to relevant nodes/components, e.g. lumped mass elements at hub and nacelle
  4. Constraint creation: Kinematic relationships are established between nodes
  5. Initial conditions: Initial conditions such as displacements, velocities, and accelerations are applied as required
Parameters
inputTurbine configuration parameters
modelStructural model to add turbine components to
Exceptions
std::invalid_argumentIf input configuration is invalid

Member Function Documentation

◆ GetMotion()

void kynema::interfaces::components::Turbine::GetMotion ( const HostState< DeviceType > &  host_state)

Populate node motion from host state.

Parameters
host_stateHost state containing position, displacement, velocity, and acceleration

◆ GetTurbineInput()

const TurbineInput & kynema::interfaces::components::Turbine::GetTurbineInput ( ) const

Get the turbine input configuration.

Returns
Turbine input configuration

◆ SetLoads()

void kynema::interfaces::components::Turbine::SetLoads ( HostState< DeviceType > &  host_state) const

Update the host state with current node forces and moments.

Parameters
host_stateHost state to update

Member Data Documentation

◆ apex_nodes

std::vector<NodeData> kynema::interfaces::components::Turbine::apex_nodes

◆ apex_to_hub

std::vector<ConstraintData> kynema::interfaces::components::Turbine::apex_to_hub

◆ azimuth_node

NodeData kynema::interfaces::components::Turbine::azimuth_node

◆ azimuth_to_hub

ConstraintData kynema::interfaces::components::Turbine::azimuth_to_hub

◆ blade_pitch

std::vector<ConstraintData> kynema::interfaces::components::Turbine::blade_pitch

◆ blade_pitch_control

std::vector<double> kynema::interfaces::components::Turbine::blade_pitch_control

◆ blades

std::vector<Beam> kynema::interfaces::components::Turbine::blades

◆ hub_mass_element_id

size_t kynema::interfaces::components::Turbine::hub_mass_element_id {invalid_id}

◆ hub_node

NodeData kynema::interfaces::components::Turbine::hub_node

◆ invalid_id

constexpr size_t kynema::interfaces::components::Turbine::invalid_id {9999999}
staticconstexpr

Placeholder node ID value for uninitialized components.

◆ kMinHubDiameter

constexpr double kynema::interfaces::components::Turbine::kMinHubDiameter {1e-8}
staticconstexpr

Minimum valid hub diameter.

◆ kZeroTolerance

constexpr double kynema::interfaces::components::Turbine::kZeroTolerance {1e-12}
staticconstexpr

Tolerance for near zero comparisons.

◆ shaft_base_node

NodeData kynema::interfaces::components::Turbine::shaft_base_node

◆ shaft_base_to_azimuth

ConstraintData kynema::interfaces::components::Turbine::shaft_base_to_azimuth

◆ torque_control

double kynema::interfaces::components::Turbine::torque_control {0.}

◆ tower

Beam kynema::interfaces::components::Turbine::tower

◆ tower_base

ConstraintData kynema::interfaces::components::Turbine::tower_base

◆ tower_top_to_yaw_bearing

ConstraintData kynema::interfaces::components::Turbine::tower_top_to_yaw_bearing

◆ yaw_bearing_mass_element_id

size_t kynema::interfaces::components::Turbine::yaw_bearing_mass_element_id {invalid_id}

◆ yaw_bearing_node

NodeData kynema::interfaces::components::Turbine::yaw_bearing_node

◆ yaw_bearing_to_shaft_base

ConstraintData kynema::interfaces::components::Turbine::yaw_bearing_to_shaft_base

◆ yaw_control

double kynema::interfaces::components::Turbine::yaw_control {0.}

The documentation for this class was generated from the following files:
  • /home/runner/work/kynema/kynema/kynema/src/interfaces/components/turbine.hpp
  • /home/runner/work/kynema/kynema/kynema/src/interfaces/components/turbine.cpp