Multiple Cartesian Boxes

Jump to: navigation, search

Parameter File

This is the parameter file, which is also found in


Definition of Multiple Cartesian Boxes

A general excerpt of the parameter file below shows how multiple cartesian boxes have to be defined in the parameter file.

!====================================================================== !
!====================================================================== !
  Mode         =1                       ! Mode for Cartesian boxes
  nZones       =n                       ! number of boxes
! ===  zone 1 ===
! ===  zone 2  ===
! ===  zone n  ===

At first the parameter nZones has to be adapted to the number of cartesian boxes one going to define. The cartesian boxes can defined simply by writing them and their specifications (Corner, nElems, BCIndex, elemtype, ...) among themselves. Furthermore it is important that the boxes are defined correctly to each other. If there shall be a contact between two boxes, it is mandatory that the corresponding surfaces will coincide. That means that also the surfaces' corner nodes have to coincide.

However, a correct defining of the corner nodes is not sufficient for the functionality. Therefore, the parameter BCIndex which assigns boundary conditions to box's surfaces has to be adapted.

Parameters Setting Description
BCIndex (/0,0,0,0,0,0/) The BCIndex parameter assigns a bondary condition to each surface of the cartesian box in order of the surfaces. The number of a vector's component represents the nth boundary condition in order of its position in the file. Hence, each position refers to the six box sides (/z-,y-,x+,y+,x-,z+/).
In case of multiple cartesian boxes there are surfaces which coincide with other ones. To such surfaces no boundary condition can assign. Therefore, The number of the corresponding vector's component is set to 0. Here, all components of the parameter BCIndex are set to 0 ((/0,0,0,0,0,0/)). That means that the this box is surounded completely by six other boxes so that no boundary condition can assign to a single surface.

A description of all parameters of the parameterfile can be found in List of Parameters.


Picture 1 shows the sketch of the current problem. As on can see the generated mesh shall consist of three cartesian boxes. These zones are thereby defined in the following order in the parameter file:

1st zone: lower left zone
BCIndex setting: (/-,-,-,-,-,0/)
2nd zone: upper left zone
BCIndex setting: (/0,-,-,-,-,-/)
3rd zone: upper right zone
BCIndex setting: (/-,-,-,-,0,-/)

For a better understanding the different settings of the parameter BCIndex are also given. The given settings just consider the components which are set to 0 because of coinciding surfaces are given.

Picture 1: Sketch of the current problem; For a greater clarity in this picture the displacement vectors are shown shorter than they are. In truth the vector arrows are as long as the side length of the cartesian box.

Output Visualization

If there is a need for assistance of visualizing the HOPR output visit Visualization.


This is a visualization of the cartbox_multiple_Debugmesh.dat file.

Picture 2: Mesh of the multiple cartesian boxes

Boundary Conditions

This is a visualization of the cartbox_multiple_Debugmesh_BC.dat file. The colors of the surfaces represent the boundary conditions and are the same as in the excerpt of the parameter file.

Picture 3: Boundary condition 1 (BC_slipwall) is assigned to surface 1 of the first box
Picture 4: Boundary condition 2 (BC_upperwall) is assigned to surface 6 of the second and the third box
Picture 5: Boundary condition 3 (BC_lowerwall) is assigned to surface 3 of the first box and to surface 1 of the third box
Picture 6: Boundary condition 4 (BC_inflow) is assigned to surface 5 of the first and the second box
Picture 7: Boundary condition 5 (BC_outflow) is assigned to surface 3 of the third box
Picture 8: Periodic boundary condition 6 (BC_yminus) is assigned to surface 2 of the first, the second and the third box
Picture 9: Periodic boundary condition 7 (BC_yplus) is assigned to surface 4 of the first, the second and the third box

Next Tutorial: Stretching Functions