Module ppm_module_tree_boxcut

This module provides the routine that subdivides tree boxes.

Defined Types

name description

no types

Defined Module Interfaces

name description

ppm_tree_boxcut

Defined Module Subroutines

name description

no subroutines

Interface ppm_tree_boxcut

Subroutines contained in this interface:

name description

ppm_tree_boxcut_s

This routine cuts a box into 2, 4 or 8 pieces using

ppm_tree_boxcut_d

This routine cuts a box into 2, 4 or 8 pieces using

Subroutine ppm_tree_boxcut_d

This routine cuts a box into 2, 4 or 8 pieces using the given cut directions and cut positions.

[Note]Note

The routine only works for ncut=1, 2, or 3.

Arguments

name type dimension intent optional description

xp

real array

(:,:)

(IN)

Positions of the points.

cutbox

integer

(IN)

ID of the box to be cut.

min_box

real array

(:)

(IN)

Minimum coordinates of the box to be cut.

max_box

real array

(:)

(IN)

Maximum coordinates of the box to be cut.

ncut

integer

(IN)

Number of cuts to apply

cutdir

integer array

(:)

(IN)

Directions of the cuts. cutdir(1)=2 means that the first

cutpos

real array

(:)

(IN)

Positions of the cuts along the given axes.

mincut

real array

(:,:)

Minimum coordinates of the cut boxes.

maxcut

real array

(:,:)

Maximum coordinates of the cut boxes.

lhbx

integer array

(:)

Pointer to the first point (in lpdx) in each sub-box. This is

lpdx

integer array

(:)

Index of particles in sub-boxes. This is only allocated and returned

info

integer

(OUT)

Return status, 0 on success

xp

real array, (:,:), (IN)

Positions of the points.

cutbox

integer, , (IN)

ID of the box to be cut.

min_box

real array, (:), (IN)

Minimum coordinates of the box to be cut.

max_box

real array, (:), (IN)

Maximum coordinates of the box to be cut.

ncut

integer, , (IN)

Number of cuts to apply

cutdir

integer array, (:), (IN)

Directions of the cuts. cutdir(1)=2 means that the first cut is perpendicular to the second coordinate axis (y axis).

cutpos

real array, (:), (IN)

Positions of the cuts along the given axes.

mincut

real array, (:,:), no intent declared

Minimum coordinates of the cut boxes.

1st: x,y[,z] 2nd: ibox.

maxcut

real array, (:,:), no intent declared

Maximum coordinates of the cut boxes.

1st: x,y[,z] 2nd: ibox.

lhbx

integer array, (:), no intent declared

Pointer to the first point (in lpdx) in each sub-box. This is only allocated and returned if there are particles at all.

lpdx

integer array, (:), no intent declared

Index of particles in sub-boxes. This is only allocated and returned if there are particles at all.

info

integer, , (OUT)

Return status, 0 on success

Used Modules

ppm_module_data, ppm_module_error, ppm_module_alloc, ppm_module_substop, ppm_module_data_tree, ppm_module_write, ppm_module_substart

Subroutine ppm_tree_boxcut_s

This routine cuts a box into 2, 4 or 8 pieces using the given cut directions and cut positions.

[Note]Note

The routine only works for ncut=1, 2, or 3.

Arguments

name type dimension intent optional description

xp

real array

(:,:)

(IN)

Positions of the points.

cutbox

integer

(IN)

ID of the box to be cut.

min_box

real array

(:)

(IN)

Minimum coordinates of the box to be cut.

max_box

real array

(:)

(IN)

Maximum coordinates of the box to be cut.

ncut

integer

(IN)

Number of cuts to apply

cutdir

integer array

(:)

(IN)

Directions of the cuts. cutdir(1)=2 means that the first

cutpos

real array

(:)

(IN)

Positions of the cuts along the given axes.

mincut

real array

(:,:)

Minimum coordinates of the cut boxes.

maxcut

real array

(:,:)

Maximum coordinates of the cut boxes.

lhbx

integer array

(:)

Pointer to the first point (in lpdx) in each sub-box. This is

lpdx

integer array

(:)

Index of particles in sub-boxes. This is only allocated and returned

info

integer

(OUT)

Return status, 0 on success

xp

real array, (:,:), (IN)

Positions of the points.

cutbox

integer, , (IN)

ID of the box to be cut.

min_box

real array, (:), (IN)

Minimum coordinates of the box to be cut.

max_box

real array, (:), (IN)

Maximum coordinates of the box to be cut.

ncut

integer, , (IN)

Number of cuts to apply

cutdir

integer array, (:), (IN)

Directions of the cuts. cutdir(1)=2 means that the first cut is perpendicular to the second coordinate axis (y axis).

cutpos

real array, (:), (IN)

Positions of the cuts along the given axes.

mincut

real array, (:,:), no intent declared

Minimum coordinates of the cut boxes.

1st: x,y[,z] 2nd: ibox.

maxcut

real array, (:,:), no intent declared

Maximum coordinates of the cut boxes.

1st: x,y[,z] 2nd: ibox.

lhbx

integer array, (:), no intent declared

Pointer to the first point (in lpdx) in each sub-box. This is only allocated and returned if there are particles at all.

lpdx

integer array, (:), no intent declared

Index of particles in sub-boxes. This is only allocated and returned if there are particles at all.

info

integer, , (OUT)

Return status, 0 on success

Used Modules

ppm_module_data, ppm_module_error, ppm_module_alloc, ppm_module_substop, ppm_module_data_tree, ppm_module_write, ppm_module_substart

Defined Module Variables

name type dimension description

no variables

Used Modules

has no uses