mus_particle_checks_module Module

mus_particle_checks_module contains a number of debugging routines to calculate the fluid and particle momentum so that the conservation of total momentum can be verified.



Variables

Type Visibility Attributes Name Initial
integer, public, save :: iMomNow = 2
integer, public, save :: iMomLast = 1

Subroutines

public subroutine compute_fluid_momentum(scheme, lev, params, totalMomentum, comm, myRank, nProcs)

compute_fluid_momentum calculates the total momentum of the fluid for all fluid elements in the global domain. The result "totalMomentum" is returned in physical units.

Arguments

Type IntentOptional Attributes Name
type(mus_scheme_type), intent(in) :: scheme

scheme for access to auxfield

integer, intent(in) :: lev

level in the octree to compute total momentum on

type(mus_param_type), intent(in) :: params

params for access to dt, dx, etc.

real(kind=rk), intent(out) :: totalMomentum(3)

output: total momentum on ENTIRE fluid domain (across all procs)

integer :: comm

MPI communicator

integer :: myRank

My MPI rank

integer :: nProcs

Number of MPI processes in communicator

public subroutine compute_particle_momentum(particleGroup, lev, params, totalMomentum, comm, myRank, nProcs)

Arguments

Type IntentOptional Attributes Name
type(mus_particle_group_type), intent(in) :: particleGroup
integer, intent(in) :: lev

Level in the octree that the particles are represented on

type(mus_param_type), intent(in) :: params

Params for access to dt, dx, etc.

real(kind=rk), intent(out) :: totalMomentum(3)

output: total momentum on ENTIRE fluid domain (across all procs)

integer, intent(in) :: comm

MPI communicator

integer, intent(in) :: myRank

My MPI rank

integer, intent(in) :: nProcs

Number of MPI processes in communicator

public subroutine swapMomNowMomLast(iMomNow, iMomLast)

Arguments

Type IntentOptional Attributes Name
integer, intent(inout) :: iMomNow
integer, intent(inout) :: iMomLast