Jim's
Tutorials

Fall 2013
course
navigation

jim on oct 21

So I've uploaded a discussion, code, and plots of a lot of what we've discussed this term. See this attached html file.

I haven't put in runge-kutta or other diffeq solvers, but just used the simple 2nd order one I discussed earlier.
I have implemented quantum shooting, on \( V(x) = 1/2 k x^2 \).
You might want to try something similar on \( V(x) = \lambda x^4 \).
I've also put in a short, slow, brute force DFT implementation, along with a few questions about what it produces.
All the python code is here, so moving to C should be simple if you want to go that way.
The ipython environment really is very nice - much faster than trying to code this stuff in C, output to *.csv text files, and then run gnuplot. That's how we used to roll in the old days, I admit ... but a notebook in a browser window with built-in plotting makes it so much simpler.

ipython

The ipython (interactive python) I'm using is described at http://ipython.org/
The anaconda install from http://continuum.io/downloads is pretty painless, or you can use regular python package thingies like "pip".
With ipython installed, the workflow that creates the documents here is
# download .ipynb $ cd <folder_with_ipynb_file> $ ipython notebook --pylab=inline This starts a web server on your machine, and a browser window pops up. In it you'll see a listing of files.ipynb in the current folder. Click one, and then work in it. Cells can be a variety of MarkDown (with LaTeX markup), python code, and graphics. The .html file was created after I finished with $ ipython nbconvert --to html jims_numeric_work.ipynb
Anyway, this should at least explain the quantum shooting.
And if you haven't already converted Schrodinger's Equation into a dimensionless form (which is the first step before numerical play), I explain that here.
Best,
Jim
http://cs.marlboro.edu/ courses/ fall2013/jims_tutorials/ ahernandez/ jim_on_oct_21
last modified Monday October 21 2013 11:20 pm EDT

attachments [paper clip]

     name last modified size
[TXT]jims_numeric_work.html Oct 21 2013 11:08 pm 624kB    jims_numeric_work.ipynb Oct 21 2013 11:08 pm 395kB