Appendix D: SPCTRL2 FORTRAN Source Code