next up previous contents
Next: ``rtbisp480'' Up: Solving Schrödinger's equation Previous: Solving Schrödinger's equation

``func_Schrodinger''

double func_Schrodinger(double E,
		 int kmatch, double Veff[], double r[], double dr[], int N)

As discussed in lecture, our basic strategy to find the energies of the atom is to set tex2html_wrap_inline172 and tex2html_wrap_inline174 at one end of our solution (r=0 or tex2html_wrap_inline178 ), define a function f(E) as the value of tex2html_wrap_inline126 at the other end, and then seek the roots of f(E).

As discussed in class, there are a variety of methods for root finding, solving one equation in one unknown of the form f(x)=0. Computationally, these methods depend upon calling a function subroutine which returns the value of the function f(x) for any input value x.

Design a routine ``func_Schrodinger'' with the above prototype which calls upon ``schint'' to integrate Schrödinger's equation from k1=0 to k2=N using Psi=0 and Psip=1 as initial conditions, and then returns the final value of Psi.

Note that we do not make use of the argument kmatch but will use it in the next homework.



Tomas Arias
Wed Feb 16 12:12:49 EST 2000