/home/runner/work/kynema/kynema/kynema/src/interfaces/blade/blade_interface.hpp Source File

Kynema API: /home/runner/work/kynema/kynema/kynema/src/interfaces/blade/blade_interface.hpp Source File
Kynema API
A flexible multibody structural dynamics code for wind turbines
Loading...
Searching...
No Matches
blade_interface.hpp
Go to the documentation of this file.
1#pragma once
2
8#include "model/model.hpp"
9
10namespace kynema::interfaces {
11
19public:
20 using DeviceType =
21 Kokkos::Device<Kokkos::DefaultExecutionSpace, Kokkos::DefaultExecutionSpace::memory_space>;
22
28 explicit BladeInterface(
29 const components::SolutionInput& solution_input, const components::BeamInput& blade_input
30 );
31
33 [[nodiscard]] components::Beam& Blade();
34
39 [[nodiscard]] bool Step();
40
42 void SaveState();
43
45 void RestoreState();
46
52 void SetRootDisplacement(const std::array<double, 7>& u) const;
53
54private:
55 Model model;
56 components::Beam blade;
57 State<DeviceType> state;
58 Elements<DeviceType> elements;
59 Constraints<DeviceType> constraints;
60 StepParameters parameters;
61 Solver<DeviceType> solver;
62 State<DeviceType> state_save;
63 HostState<DeviceType> host_state;
64 std::unique_ptr<Outputs> outputs;
65};
66
67} // namespace kynema::interfaces
Struct to define the connectivity structure of elements, nodes, and constraints defining an Kynema pr...
Definition model.hpp:74
Interface for blade simulation that manages state, solver, and components.
Definition blade_interface.hpp:18
Kokkos::Device< Kokkos::DefaultExecutionSpace, Kokkos::DefaultExecutionSpace::memory_space > DeviceType
Definition blade_interface.hpp:21
void SetRootDisplacement(const std::array< double, 7 > &u) const
Sets the displacement for the root node.
Definition blade_interface.cpp:98
bool Step()
Steps forward in time.
Definition blade_interface.cpp:54
void SaveState()
Saves the current state for potential restoration (in correction step)
Definition blade_interface.cpp:84
components::Beam & Blade()
Returns a reference to the blade model.
Definition blade_interface.cpp:50
void RestoreState()
Restores the previously saved state (in correction step)
Definition blade_interface.cpp:88
Represents a turbine blade with nodes, elements, and constraints.
Definition beam.hpp:24
Definition blade_interface.cpp:9
Container class for managing multiple constraints in a simulation.
Definition constraints.hpp:29
A container providing handle to all structural elements present in the model.
Definition elements.hpp:20
This object manages the assembly and solution of linear system arising from the generalized-alpha bas...
Definition solver.hpp:21
Container for storing the complete system state of the simulation at a given time increment.
Definition state.hpp:18
A Struct containing the paramters used to control the time stepping process.
Definition step_parameters.hpp:12
Host-side mirror of the simulation state for a given time increment.
Definition host_state.hpp:22
Complete input specification for a beam.
Definition beam_input.hpp:84
A configuration object used to create the low level StepParameters object.
Definition solution_input.hpp:13