Skip to article frontmatterSkip to article content
Site not loading correctly?

This may be due to an incorrect BASE_URL configuration. See the MyST Documentation for reference.

Python Calculator

1. Constants and quick calculations

scipy.constants knows every physical constant (full list):

A scratchpad, seeded with a photon-energy calculation. Edit it and press play; the value of the last line is displayed:

Or let the slider do the arithmetic. Can this photon break a C-C bond?

2. Unit converter

3. Plotting panel

A ready-to-edit plotting template. Swap in any function of x; the slider is yours to repurpose:

4. Symbolic window

Derivatives, integrals, and equation solving with sympy; results render as typeset math. Each pad is editable:

5. Orbital visualizer

Pick quantum numbers; the menus only ever offer valid combinations. Drag to rotate the orbital (blue and red are the wavefunction’s positive and negative lobes):

6. Orbital overlap

Bonding starts here: slide two 1s orbitals together and watch their overlap integral S(d)=ed(1+d+d2/3)S(d) = e^{-d}\left(1 + d + d^2/3\right) grow (distances in Bohr radii). The shaded region is the product ψAψB\psi_A \psi_B whose integral is SS:

At d=0d = 0 the orbitals coincide and S=1S = 1; by d8a0d \approx 8\,a_0 the overlap is essentially gone. The window where SS is a few tenths is exactly where chemical bonds live.

7. One-dimensional Schrödinger solver

Pick a potential and get its bound states instantly: energies as horizontal lines, wavefunctions drawn at their own energy (units: =m=1\hbar = m = 1, hard walls at x=±4x = \pm 4). To see how the solver works inside, open the numerical Schrödinger lab.

Try the classics: the box gives the n2n^2 ladder, the harmonic well gives perfectly even spacing (the fingerprint of vibrations), the linear well spaces levels like Airy zeros, and the double well pairs levels into tunneling doublets.

8. Numerical integral

Define any function and limits in the pad; the plot shades area above the axis in green and below in red, and the value comes from np.trapezoid, the same tool your homework uses:

The green and red areas fight each other: an integral is a signed sum. For probability densities like ψ2|\psi|^2 the red never appears, which is exactly why they can be interpreted as probabilities.