The code is well commented (refer to the Postscript two-column listing for
Here, we go through the process, subroutine by subroutine.
- First, the geometry is calculated (lines 182 through 219).
- Next, the material properties are computed and stored (lines 220 through
- Finally, the analytical answers are calculated and stored (lines 233
Next, the solution phase is invoked. Line 54 initiates the loop over surfaces.
For each surface, we loop over nstop full surface emissions (line 58),
each of np particles (here, 10,000).
Within this loop, we invoke the following subroutines:
- The ``starting'' coordinate is defined for the first particle of this
vector of np particles (lines 292--298).
- The emission coordinates are defined in lines 299--306.
The student must supply the right sides of lines 305 and 306.
- The outgoing local spherical angles (lines 307 through 318), local
Cartesian components (lines 319 through 325) and global Cartesian components
(lines 326--333) are obtained.
The student must supply the right sides of lines 313, 318, 324, 325, 332 and