next up previous contents
Next: Number of nodes Up: Debugging Previous: Endpoint values

Output wave functions

Again, run the program with E=-0.5. Your results for the outward integration should agree with the analytic solution to about 4-5 decimal places (except for k>80). Because the Schrödinger equation determines the wave function only up to a constant normalization factor, the results for the inward integration will not match the analytic solution, but the ratio should be constant to within about 4-5 decimal places, except for numerical errors near the ends of the integration interval.

Note: The facts that V(r)=-1/r and r[0]=0 cause numerical difficulties at the origin. To avoid this, ``schdebug.c'' uses the change of variables map tex2html_wrap_inline424 . Under this map, near the origin tex2html_wrap_inline426 , tex2html_wrap_inline428 , tex2html_wrap_inline430 and tex2html_wrap_inline432 . Thus, it is mathematically correct to regard the offending term tex2html_wrap_inline434 as zero at the origin. The program ``schdebug.c'' achieves the same effect, but without the division by zero and the NaN's, by simply setting V[0]=0 when initializing the array V[].



Tomas Arias
Sun Feb 11 18:46:55 EST 2001