kwave.kWaveSimulation_helper.set_sound_speed_ref module

get_kspace_elastic_sound_speed_ref(medium)[source]

in the k-space elastic case, there are two reference sound speeds for the compressional and shear waves, so compute them seperately :param medium:

Returns:

Parameters:

medium (kWaveMedium)

get_ordinary_sound_speed_ref(medium)[source]

calculate the reference sound speed for the fluid code, using the maximum by default which ensures the model is unconditionally stable :param medium:

Returns:

get_pstd_elastic_sound_speed_ref(medium)[source]

in the pstd elastic case, the reference sound speed is only used to calculate the PML absorption, so just use the compressional wave speed :param medium:

Returns:

Parameters:

medium (kWaveMedium)

set_sound_speed_ref(medium, simulation_type)[source]

select the reference sound speed used in the k-space operator based on the heterogeneous sound speed map :param medium: kWaveMedium object :param simulation_type: Simulation type (fluid, axisymmetric, elastic, elastic with k-space correction)

Returns:

Parameters:
  • medium (kWaveMedium)

  • simulation_type (SimulationType)