Today I've posted Phred, the 3d FDTD program I wrote for my M.A.Sc,
to Google code. In some ways it is very simple: it only supports
uniform grading for instance. The way the updates are handled is not
very flexible. The testing is pretty primitive. Other things about
it are still really cool: it runs on a variety on super-computers, or
at least it did five years ago. It uses Python as a scripting
language for problem set-up. It implements the Drude model for
modelling some kinds of metal. It's a good example of my skills as
they were five years ago. Despite cringing at some of this code, I'm
still pretty proud of it.
You can find the Phred Google Code project page here.
Cool stuff about Phred:
- Runs on a variety of machines:
- Problems are scripted in Python
- Drude model for simulating dispersive materials such as gold and silver.
- Uses a hybrid MPI/OpenMP model for parallel computation. I found
that MPI by itself generally gave better performance, even on SMP
machines.
I ran the majority of my large simulations on Nexus and Glacier,
and smaller simulations on Debian Linux, so those are the best
tested. However, things have come along way in five years, and I'm
not sure if everything would still compile given various software
updates than may have been rolled out.
There are a lot of rough edges and unfinished things in the code.
I was experimenting with template meta-programming for the updates,
for instance. Template meta-programming is interesting, but because
it's a side-effect of a language feature designed for something else
it is hard to use. The error messages are particularly
unhelpful.
My goal in releasing this is mostly just to preserve it for my own
reference, to ensure that it is not lost when the hard drive it was on
is disposed of or dies. Open source is more than just the code. It
takes a lot of work to build up a community, get people interested,
accept patches, and so on. I don't have time to give this project
that kind of love. Perhaps someone else will be interested in picking
it up and taking it over, but that seems unlikely. There are already
many other actively maintained open source FDTD packages out there.