Physics and mechanics
Electromagnetic Wave Trajectory Calculator
Trace a geometric-optics ray through a plane-parallel dielectric slab, including Snell refraction, exit position, lateral displacement, optical path length, and total internal reflection.
CURRENT MODEL
Define the slab, incident ray, and observation plane
Optics students, alignment technicians, instrument designers, and educators tracing a narrow beam through a flat transparent plate.
LIVE REFRACTION GEOMETRY
Piecewise ray path through the slab
The live geometry uses current indices, angle, thickness, and downstream distance; a higher-to-lower-index boundary switches to the total-internal-reflection state when required.

| Quantity | Equation | Current value | Unit |
|---|
How to use
Trace a ray without mixing face angle and normal angle
- Enter the refractive index of the surrounding incident medium at the working wavelength.
- Enter the slab index at that same wavelength; do not mix catalog values from different spectral lines.
- Measure incidence from the surface normal and enter a value below 90 degrees.
- Enter perpendicular slab thickness and the normal distance from the exit face to the observation plane.
- Review whether the model transmits or reports total internal reflection before using any downstream coordinate.
- Use the Snell residual and parallel-output statement as independent reconciliation checks.
Trajectory fundamentals
Six distinctions that control a plate-shift result
- Ray trajectory
- The geometric-optics path is normal to local wavefronts; it is not an electron or photon orbit.
- Angle reference
- Snell angles are measured from the normal, so a 35-degree normal angle is 55 degrees from the face.
- Parallel faces
- Equal and opposite surface normals make the final ray parallel to the incident ray when both external media match.
- Coordinate versus displacement
- Exit coordinate is measured along the face; lateral displacement is the shortest separation between parallel rays.
- Optical path
- Geometric distance is weighted by refractive index before converting to phase-equivalent path or transit time.
- Critical boundary
- Only higher-to-lower-index incidence can make the Snell sine exceed one and produce total internal reflection.
Calculation method
Snell refraction first, then geometry and phase path
The solver converts the entered angle to radians and evaluates (n1/n2) sin(theta1). A magnitude above one is handled as total internal reflection. Otherwise, theta2 establishes the slanted path through the slab and the intersection at the second face.
Because the second face is parallel, the transmitted output returns to theta1. The observation-plane coordinate adds the downstream run at that angle, while optical path separately weights the slab and external path lengths by their indices.
Dispersion discipline
Index changes with wavelength and temperature. The wavelength field alone does not lookup dispersion; preserve the source and conditions for both entered indices.
Near-critical sensitivity
As the Snell argument approaches one, small angle or index uncertainty produces a large refracted-angle change. Report tolerances rather than treating the last displayed digit as stable.
Finite beams
A real beam has width, divergence, polarization, Fresnel loss, and possibly interference between faces. This central-ray model locates the nominal path only.
Observation reference
The downstream coordinate is referenced to the first-interface normal. Mark that datum physically or compare only the stated lateral displacement.
Detailed calculation process
Symbols, current substitution, intermediate quantities, and reconciliation
| Symbol | Meaning | Default | Unit |
|---|---|---|---|
| n1 | External-medium refractive index | 1.000293 | dimensionless |
| n2 | Slab refractive index | 1.5 | dimensionless |
| theta1 | Incidence angle from normal | 35 | deg |
| t | Normal slab thickness | 12 | mm |
| L | Downstream normal distance | 100 | mm |
| lambda0 | Vacuum wavelength | 550 | nm |
| d | Perpendicular lateral displacement | calculated | mm |
Waiting for valid inputs.
Interpretation
Use the exit state before reading a coordinate
A transmitted result gives one ideal central ray and a downstream datum. A total-internal-reflection result means no real refracted ray exists in this lossless geometric model; the displayed critical angle is then the actionable boundary. Optical path length addresses phase and time, not transverse shift.
Evidence and measurement
Retain the actual optical and geometric basis
Record material grade, wavelength, temperature, index source and uncertainty, plate thickness map, face parallelism, angle-reference method, beam centroid definition, and observation-plane datum. Preserve whether surrounding gas conditions materially change n1.
Scope and limitations
What this slab trajectory does not certify
- Fresnel reflection, polarization, coating performance, or absorption
- Diffraction, finite-beam diameter, divergence, or Gaussian propagation
- Wedge, curved surfaces, surface figure, roughness, or decenter
- Multiple internal reflections and etalon interference
- Material dispersion unless indices are independently updated
- Eye safety, laser classification, or alignment procedure
A monochromatic geometric-optics ray meets two planar parallel faces; the surrounding medium is the same before and after the slab, dispersion is represented only by entered refractive indices, and interface thickness is negligible.
Key terminology
Plane-parallel refraction glossary
- Surface normal
- Line perpendicular to the interface and reference for Snell angles.
- Refractive index
- Ratio relating vacuum speed to phase speed in a medium.
- Snell's law
- Interface relation n1 sin(theta1) = n2 sin(theta2).
- Critical angle
- Higher-index incidence angle that makes the lower-index refracted angle 90 degrees.
- Lateral displacement
- Perpendicular distance between the incident-line continuation and parallel outgoing ray.
- Optical path length
- Sum of each geometric segment multiplied by its refractive index.
- Plane-parallel slab
- Transparent plate whose entrance and exit faces are parallel planes.
- Evanescent field
- Non-propagating field beyond a total-internal-reflection interface, outside this ray calculation.
Practical cases
Two trajectory decisions with different risks
Camera cover-glass alignment
An engineer checks whether a 12 mm protective window moves the chief ray enough to miss a downstream aperture. The nominal shift guides mechanical clearance, while index and angle tolerances remain in the alignment budget.
High-index escape boundary
A student sends a ray from glass toward air at 50 degrees. The calculator reports total internal reflection instead of inventing a refracted coordinate, clarifying why prism coupling needs a different boundary.
Important note
A central ray is not a complete optical tolerance analysis
Use this result for first-order geometry. Preserve unrounded inputs and obtain optical design review when coatings, finite beams, tolerances, exposure, or safety affect the decision.
Frequently asked questions
Why is trajectory defined as a ray path here?
The page uses geometric optics: trajectory means the piecewise straight path normal to electromagnetic wavefronts. It does not integrate a charged particle orbit or a full diffraction field.
Why does the outgoing ray recover the original angle?
For parallel faces with the same external medium, applying Snell's law at both interfaces gives the original external angle. The outgoing ray is parallel but laterally displaced.
What is the difference between horizontal offset and lateral displacement?
The normal-plane offset compares exit coordinates at the second face. Lateral displacement is the shortest perpendicular separation between the incident-line continuation and outgoing ray.
When is total internal reflection possible?
It requires travel from a higher refractive index toward a lower one and an incidence angle above the critical angle asin(n2/n1). This page checks the first interface only.
Does wavelength change the geometric path?
Only through refractive-index dispersion. With fixed entered indices, Snell geometry is unchanged; the calculator separately reports wavelength inside each medium.
Can this model handle a prism or curved lens?
No. Nonparallel or curved surfaces require tracing each surface normal and intersection separately; this model is specific to one plane-parallel slab.
Authority and follow-on work
Reliable sources and related calculators
- OpenStax Physics — Key EquationsStates the law of reflection, Snell's law, and critical-angle relation.
- OpenStax University Physics — Total Internal ReflectionExplains the higher-to-lower-index boundary and critical angle.
- NIST — SI defining constantsSupports the exact SI value of the speed of light used for propagation time.
Related calculators
Continue with a distinct optics question without silently changing the model boundary.