Module ppm_module_impose_part_bc

This module includes the source code user callable ppm_impose_part_bc routine to map the particles back inside the computational domain for periodic BC.

Defined Types

name description

no types

Defined Module Interfaces

name description

ppm_impose_part_bc

Defined Module Subroutines

name description

no subroutines

Interface ppm_impose_part_bc

Subroutines contained in this interface:

name description

ppm_impose_part_bc_s

This routine imposes periodic boundary conditions for

ppm_impose_part_bc_d

This routine imposes periodic boundary conditions for

Subroutine ppm_impose_part_bc_d

This routine imposes periodic boundary conditions for the particles. That is it moves/wraps any particles outside the computational box into the box. The routine assumes that the particles are located within the size of one computational box.

[Note]Note

This routine is a user callable routine.

[Caution]Caution

(This concerns only PPM developers) The routine is sensitive the round off errors! So be careful not to change the order of the IF statements (see code comments) and make sure the compiler is not doing something wrong as well! Originally when particles would be close/at the boundary, the routine would fail to map all particles, but succed if called a 2nd time. The changed in the order of the IF statements removed this double calling sequence.

Arguments

name type dimension intent optional description

topoid

integer

(IN)

Topology ID

xp

real array

(:,:)

(INOUT)

Particle coordinates

npart

integer

(IN)

Number of particles

info

integer

(OUT)

Returns status, 0 upon success

topoid

integer, , (IN)

Topology ID

xp

real array, (:,:), (INOUT)

Particle coordinates

npart

integer, , (IN)

Number of particles

info

integer, , (OUT)

Returns status, 0 upon success

Used Modules

ppm_module_data, ppm_module_error, ppm_module_check_id, ppm_module_substop, ppm_module_substart

Subroutine ppm_impose_part_bc_s

This routine imposes periodic boundary conditions for the particles. That is it moves/wraps any particles outside the computational box into the box. The routine assumes that the particles are located within the size of one computational box.

[Note]Note

This routine is a user callable routine.

[Caution]Caution

(This concerns only PPM developers) The routine is sensitive the round off errors! So be careful not to change the order of the IF statements (see code comments) and make sure the compiler is not doing something wrong as well! Originally when particles would be close/at the boundary, the routine would fail to map all particles, but succed if called a 2nd time. The changed in the order of the IF statements removed this double calling sequence.

Arguments

name type dimension intent optional description

topoid

integer

(IN)

Topology ID

xp

real array

(:,:)

(INOUT)

Particle coordinates

npart

integer

(IN)

Number of particles

info

integer

(OUT)

Returns status, 0 upon success

topoid

integer, , (IN)

Topology ID

xp

real array, (:,:), (INOUT)

Particle coordinates

npart

integer, , (IN)

Number of particles

info

integer, , (OUT)

Returns status, 0 upon success

Used Modules

ppm_module_data, ppm_module_error, ppm_module_check_id, ppm_module_substop, ppm_module_substart

Defined Module Variables

name type dimension description

no variables

Used Modules

has no uses