Virtual Testbed
Ship dynamics simulator for extreme conditions
Public Member Functions | List of all members
vtb::core::Linear_velocity_potential_solver_base< T > Class Template Reference

Base class for linear velocity potential solver. More...

#include <velocity_potential.hh>

Inheritance diagram for vtb::core::Linear_velocity_potential_solver_base< T >:
[legend]
Collaboration diagram for vtb::core::Linear_velocity_potential_solver_base< T >:
[legend]

Public Member Functions

void second_function (const Grid< T, 4 > &grid_tzxy, const Array3< T > &wavy_surface, Array3< C > &result)
 Computes second function. More...
 
- Public Member Functions inherited from vtb::core::Velocity_potential_solver< T, 3 >
depth () const noexcept
 Get water depth.
 
void depth (T rhs)
 Set water depth.
 
void wave_number_grid (const Grid< T, 2 > &rhs)
 
const Grid< T, 2 > & wave_number_grid () const
 
void assumptions (Assumptions rhs)
 
const Assumptionsassumptions () const
 
virtual void solve (const Grid< T, N+1 > &grid_tzxy, const Array< T, N > &wavy_surface, Array< T, N+1 > &velocity_potential)=0
 Calculate velocity potential for each grid point. More...
 
void operator() (const Grid< T, 4 > &grid_tzxy, const Array< T, 3 > &wavy_surface, Array< T, 4 > &velocity_potential)
 

Detailed Description

template<class T>
class vtb::core::Linear_velocity_potential_solver_base< T >

Base class for linear velocity potential solver.

Date
2019-04-07
Author
Ivan Gankevich

Definition at line 107 of file velocity_potential.hh.

Member Function Documentation

◆ second_function()

template<class T >
void vtb::core::Linear_velocity_potential_solver_base< T >::second_function ( const Grid< T, 4 > &  grid_tzxy,
const Array3< T > &  wavy_surface,
Array3< C > &  result 
)

Computes second function.

Date
2018-09-15
Author
Ivan Gankevich
  • For large-amplitude waves the second function is computed as

    \[ \mathcal{S}(x,y,t) = \frac{\zeta_t(x,y,t)}{ i \left( \left(\zeta_x + \zeta_y\right)/s - \zeta_x - \zeta_y \right) - 1/s }, \]

    where \(s=\sqrt{1 + \zeta_x^2 + \zeta_y^2}\).
  • For small-amplitude waves the second function is computed as

    \[ \mathcal{S}(x,y,t) = -\zeta_t(x,y,t). \]

Definition at line 12 of file velocity_potential.cc.

References vtb::core::Grid< T, N >::delta().