Science computer programs
- My “Getting started in Python / NumPy” guide for scientists: Click here
- If you know MATLAB, you can learn Python / NumPy very easily – and you should!! There are good reasons that the use of Python in science is growing rapidly in both universities and companies.
- Multilayer thin film optics calculator: Click here, or just Read the manual
- This is a Python (NumPy) program I wrote that uses the Fresnel equations and transfer-matrix method to calculate transmission and reflection from multilayer thin films. (Thick films are also OK.) It also calculates the Poynting vector and the absorbed energy density as a function of depth, as well as the parameters (ψ and Δ) measured in ellipsometry. Here is the manual containing installation instructions and detailed descriptions and explanations of all the formulas used.
- Also, here is a Mathematica 6 notebook that I wrote earlier, before the Python version. It does the same thing but has somewhat fewer features. Here is the Mathematica source code in PDF form.
- (List of similar programs for calculating multilayer-thin-film optics, written by other people: 1, 2, 3, 4, 5, 6, 7, 8, 9.)
- Units package for Python: Click here
- This is a Python package I wrote to deal with units and dimensional analysis. It is designed to be compatible with all numerical calculation routines, even those using specialized non-Python code like FORTRAN libraries etc.
- Units package for Mathematica: Click here for Mathematica notebook
- This is a Mathematica package I wrote to deal with units and dimensional analysis in Mathematica. It has a similar design to the Python one. Again, it is designed to be compatible with everything, even numerical operations like FindRoot and NIntegrate. Click the link and open the notebook in Mathematica for information on how to install and use it. [If you are not using FindRoot or NIntegrate, I suggest the Automatic Units package or Mathematica's built-in unit package instead.]
- Python program to calculate equilibrium semiconductor band diagrams: Click here
- This program solves the Poisson-Boltzmann Equation via finite differences, for planar multilayer semiconductor stacks.
- Python program to calculate surface plasmon polariton modes in planar multilayers: Click here
- This program calculates SPP modes, or more generally any transverse-magnetic (TM) mode, at a planar interface, or in a stack of arbitrarily many layers, including magnetic and anisotropic materials.
- MATLAB FROG algorithm: Click here
- This is a set of MATLAB programs for processing and analyzing “Frequency-Resolved Optical Gating” (“FROG”) measurements. FROG is a technique for measuring laser pulses. To analyze the data, you have to do a sort of multidimensional optimization. The algorithm is from the literature, although I invented some variations on the algorithm that I found worked better–at least, they worked better for my data.
- LAMMPS installation tutorial: Click here
- This is my guide to installing the LAMMPS molecular-dynamics simulation software in Windows (through cygwin), written for people who have never used UNIX before.
- LAMMPS source-code modification for outputting electric fields: Click here
- I needed to know the local electric fields in my molecular dynamics simulation. This requires some modification of the LAMMPS source code. I wrote up the procedure nicely in case anyone else needs to do this.