Tsunami Project Lab
Loading...
Searching...
No Matches
tsunami_lab::setups::ShockShock1d Class Reference

#include <ShockShock1d.h>

Inheritance diagram for tsunami_lab::setups::ShockShock1d:
Collaboration diagram for tsunami_lab::setups::ShockShock1d:

Public Member Functions

 ShockShock1d (t_real i_height, t_real i_momentum, t_real i_location)
 
t_real getHeight (t_real, t_real) const
 
t_real getMomentumX (t_real i_x, t_real) const
 
t_real getMomentumY (t_real, t_real) const
 
- Public Member Functions inherited from tsunami_lab::setups::Setup
virtual ~Setup ()
 

Detailed Description

1d shock-shock setup.

Two streams of water move towards each other and collide at the discontinuity. Left state has positive momentum, right state has negative momentum of the same magnitude; the water height is identical on both sides.

Constructor & Destructor Documentation

◆ ShockShock1d()

tsunami_lab::setups::ShockShock1d::ShockShock1d ( t_real i_height,
t_real i_momentum,
t_real i_location )

Constructor.

Parameters
i_heightwater height on both sides of the discontinuity.
i_momentummagnitude of the momentum; applied positive to the left and negative to the right of the discontinuity.
i_locationx-coordinate of the discontinuity.
Author
Moritz Arnhold, Moritz Martin

DESCRIPTION

Implements the functions for a shock-shock problem, where to opposing streams of water crash into another

Member Function Documentation

◆ getHeight()

tsunami_lab::t_real tsunami_lab::setups::ShockShock1d::getHeight ( t_real ,
t_real  ) const
virtual

Gets the water height at a given point.

Returns
water height.

Implements tsunami_lab::setups::Setup.

◆ getMomentumX()

tsunami_lab::t_real tsunami_lab::setups::ShockShock1d::getMomentumX ( t_real i_x,
t_real  ) const
virtual

Gets the momentum in x-direction.

Parameters
i_xx-coordinate of the queried point.
Returns
momentum in x-direction (positive left of the discontinuity, negative right of it).

Implements tsunami_lab::setups::Setup.

◆ getMomentumY()

tsunami_lab::t_real tsunami_lab::setups::ShockShock1d::getMomentumY ( t_real ,
t_real  ) const
virtual

Gets the momentum in y-direction.

Returns
momentum in y-direction (always 0 in the 1d shock-shock setup).

Implements tsunami_lab::setups::Setup.


The documentation for this class was generated from the following files: