Virtual Testbed
Ship dynamics simulator for extreme conditions
|
Base class for all wave pressure solvers. More...
#include <wave_pressure.hh>
Public Types | |
using | panel_type = Ship_hull_panel< T, 3 > |
using | panel_array = std::vector< panel_type > |
using | grid3 = Grid< T, 3 > |
using | grid4 = Grid< T, 4 > |
using | array3 = Array< T, 3 > |
using | array4 = Array< T, 4 > |
using | vec3 = Vector3< T > |
Public Member Functions | |
virtual void | solve (const Grid< T, 3 > &wavy_surface_grid, Array< T, 3 > wavy_surface, const Grid< T, 4 > &velocity_potential_grid, Array< T, 4 > velocity_potential, panel_array &panels)=0 |
Compute pressure force applied to the centre of each ship hull panel. More... | |
T | density () const noexcept |
Fluid density. | |
void | density (T rhs) noexcept |
T | g () const noexcept |
Gravitational acceleration. | |
void | g (T rhs) noexcept |
void | clip (bool b) |
bool | clip () const |
Clamp grid to panels? | |
Base class for all wave pressure solvers.
Calculates wave pressure using Bernoulli equation.
Definition at line 23 of file wave_pressure.hh.
|
pure virtual |
Compute pressure force applied to the centre of each ship hull panel.
[in] | wavy_surface_grid | Three-dimensional \((t,x,y)\) grid for each point of which wavy surface elevation is given. |
[in] | velocity_potential_grid | Four-dimensional \((t,z,x,y)\) grid for each point of which velocity potential is calculated. |
[in,out] | panels | Triangular panels comprising wetted part of the ship hull. |
\[ p(x,y,z,t) = -\rho \left( \phi_t + \frac{1}{2}\left( \phi_x^2 + \phi_y^2 + \phi_z^2 \right) + g z \right), \]
where \(\rho\) — fluid density, \(g\) — gravitational acceleration, \(\phi\) — velocity potential.\[ \vec{F} = \vec{x} \vec{n} S, \]
where \(S\) — panel area, \(\vec{x}\) — radius vector of the panel centre relative to the ship hull centre of mass, \(\vec{n}\) — normal vector of the panel facing outside the hull. Multiplication is pointwise.