Next: Testing the code
Up: Making a hydrodynamics code
Previous: Source term integration
The boundary conditions are usually dealt with using one or more ghost cells, in our Fortran case these are cells 0 and meshmax+1. Before the integration step the value for W is set
in a pre-determined way, depending on the problem. Possible choices
are:
- Inflow: The ghost cells are filled with the material
flowing onto the grid.
- Outflow: The ghost cells are filled so that material can
flow off the grid without influencing the material on the grid
(normally achieved by setting W equal to the value of the last
proper grid cell).
- Reflection: The ghost cells are filled so that it seems
that the material runs into a wall (normally achieved by setting
W equal to the value of the last proper grid cell but changing the
sign of the velocity).
Garrelt Mellema
2003-01-20