wecopttool.utilities.linear_solve
- linear_solve(bem_data, pto_impedance, wave, kinematics, nsubsteps=1)[source]
Solve a linear problem in the frequency domain with optimal controller.
- Parameters:
bem_data – Linear hydrodynamic coefficients obtained using the boundary element method (BEM) code Capytaine, with sign convention corrected.
pto_impedance – Matrix representing the PTO impedance. Size 2*n_dof.
wave – 2D
xarray.DataArraycontaining the wave’s complex amplitude for a single realization as a function of wave angular frequencyomega(rad/s) and directionwave_direction(rad).kinematics – Matrix that transforms state from WEC to PTO frame.
nsubsteps – Number of steps between the default (implied) time steps. A value of
1corresponds to the default step length.
- Returns:
p_opt_average – Average power using optimal controller.
tdom – Time domain results.
fdom – Frequency domain results.
thevenin – Thevenin equivalent system.