Computing the light-bending table…

A Pulsar, Ray Traced

What am I looking at?

A simulation, not an animation. The neutron star's surface is ray traced through curved spacetime, its magnetic field comes from Maxwell's equations, and the pulses below are what a distant observer would record.

Drag to turn the star or tilt the view. Ctrl + scroll to zoom.Drag to turn or tilt. Pinch to zoom.

A Simulation, Not an Animation

A pulsar is a neutron star that spins and has a strong magnetic field: about one and a half times the mass of the Sun packed into a ball some 24 km across. Its magnetic poles are not aligned with its spin axis, so beams of radiation from near the poles sweep around the sky. If a beam crosses Earth, we see a pulse once per turn. The fastest known pulsar turns 716 times a second.

Everything above is calculated, in three parts:

  • The star's surface is ray traced. For each pixel, your graphics card follows a ray of light back through the curved spacetime around the star, using general relativity, to find the point on the surface it came from. The pixel's color and brightness come from that point's temperature, its speed and the gravity the light climbs out of.
  • The magnetic field lines are integrated from an exact solution of Maxwell's equations for a spinning magnet in empty space. Each point on each line is then placed on screen where its light would appear, bent by the star's gravity.
  • The pulse plots are what a distant observer would record: X-rays from the hot spots, summed over the whole visible surface at every moment of the turn, and radio waves from a beam above the poles, including its polarization.

Change a setting and all three are recalculated. The equations, their simplifications and the tests they pass are on the method page. It runs best on a laptop or desktop computer.

How Extreme Is a Neutron Star?

24 km
Across: about the length of Manhattan, holding 1.4 times the mass of the Sun.
2 billion tonnes
The weight of one teaspoon of neutron star, several times the combined weight of every person alive.
43,000 rpm
The fastest pulsar's spin: a city-sized ball turning about twice as fast as a kitchen blender's blade.
1,800 km/s
How fast something dropped from 1 metre would hit the surface, under gravity 160 billion times Earth's.
19%
How much slower a clock on the surface runs than one far away.
30 million
Times stronger than the magnet in a hospital MRI scanner, for a typical young pulsar's field.

For a star of 1.4 suns and 12 km. How each number was worked out is on the method page.

The Numbers Behind the Image

5.8 M
Radius of a 1.4-solar-mass, 12 km star in units of M = GM/c². A black hole of the same mass would have a radius of 2 M.
76%
Share of that star's surface visible at once. Without light bending you could see half.
0.81×
Frequency of light from the surface on arrival, relative to emission (gravitational redshift z = 0.24).
67 km
Light cylinder radius at 716 turns per second. For the Crab pulsar it is 1,590 km; for a magnetar, 360,000 km.
0.22 c
Speed of the equator at 716 turns per second, as measured on the surface.

Reading the Image

The hot spots

Near the magnetic poles, charged particles accelerated in the magnetosphere strike the surface and heat it to around a million kelvin. The spots shine mainly in X-rays. Here the temperature is scaled down into visible light so the spots appear white and the rest of the star a dull orange; the shapes and brightness ratios are unchanged.

The tilted magnetic axis

A pulsar's magnetic poles are not at its spin poles. Here the magnetic axis (red) is tilted 60° from the spin axis (white), so the hot spots and the field lines sit on the star's sides and are carried around as it turns. The tilt is what makes a pulsar pulse: if the two axes were aligned, the beams would point along the spin axis and look the same at every moment (try the “Aligned axes” view). Nothing forces the two to line up. Earth's magnetic axis is about 10° from its spin axis, and Uranus's about 60°.

Seeing past the edge

Gravity bends light leaving the surface, so rays from points slightly behind the edge still reach you. For a typical neutron star you see about three quarters of the surface at once, which is why a hot spot stays in view for most of a turn. Switch on the grid to see how far round the far side the view reaches.

Closed field lines

Close to the star the field is that of an ordinary bar magnet, a dipole. Lines that leave one pole and return to the other within the light cylinder turn with the star like spokes on a wheel.

Open field lines

Lines from close to the poles reach the light cylinder before they can turn back. Beyond it they cannot turn with the star, so they trail behind it in spirals. The footprints of these open lines on the surface are the polar caps, which is why the hot spots sit there.

The light cylinder

Anything that turned with the star at distance r from its spin axis would move at speed Ωr. At r = c/Ω that speed is the speed of light. This radius sets the size of the whole magnetosphere: 67 km for the fastest pulsar, 1,590 km for the Crab.

The radio beam

Radio waves come from charges streaming out along the open field lines, tens to hundreds of km above the surface, beamed along their direction of motion. The beam is a cone around the magnetic axis. Each time it sweeps past you, you see a pulse.

What an Observer Records

Telescopes cannot resolve a neutron star; it is far too small and far away. What they record is brightness over time, folded on the spin period into a pulse profile. The “What an observer records” panel in the lower-left corner of the simulator (click its title to open it) shows three such profiles for whatever you have set up, and the vertical line marks the present moment.

X-ray brightness comes from the hot spots. Light bending keeps the spots visible for longer, which smooths the pulse: in the first experiment below, the brightness swings 38% either side of its mean with bending and 78% without. The amount of bending depends on the star's compactness, the ratio of its mass to its radius. Rotation adds Doppler shifts that make the pulse lopsided, and the size of that effect depends on the radius. Together, the two let a profile be fit for mass and radius separately. That is how NASA's NICER X-ray telescope measures neutron star radii:

PulsarMass (suns)RadiusAnalysis
PSR J0030+04511.34 (+0.15 / −0.16)12.71 (+1.14 / −1.19) kmRiley et al. 2019
PSR J0437−47151.418 ± 0.03711.36 (+0.95 / −0.63) kmChoudhury et al. 2024
PSR J0740+66202.072 (+0.067 / −0.066)12.39 (+1.30 / −0.98) kmRiley et al. 2021

Ranges are 68% credible intervals. An independent team analyzing the same data found similar values (for J0030, 1.44 suns and 13.02 km; Miller et al. 2019). For J0030 the best fits put both hot regions in the same hemisphere, one of them a narrow arc, which a simple centered dipole cannot produce. The simulator's “same hemisphere” option shows a configuration of that kind but is not a fit to the data.

Radio brightness and polarization come from the beam. The radio waves are linearly polarized along the local magnetic field direction. As the beam sweeps past, the projected field direction rotates, and the polarization angle traces an S-shaped curve. Its steepest point marks the moment the magnetic pole passes closest to your line of sight. The shape of the curve gives the magnetic tilt and viewing angle. This is the rotating vector model of Radhakrishnan and Cooke (1969), shown dashed in the third plot.

The computed points differ from the dashed curve because the charges move with the star as well as along the field. Their beam is tilted forward by aberration, and light from the far side of the beam arrives later. Blaskiewicz, Cordes and Wasserman showed in 1991 that the polarization swing then lags the center of the pulse by 4h/RLC radians, where h is the emission height. This is one of the few ways to measure where in the magnetosphere radio waves are made. The simulator's numerical beam reproduces that shift to within 13% (details).

Switch Off the Physics, One Effect at a Time

Each comparison below changes a single setting. All of them are available in the simulator above, and every image and curve on this page was produced by it.

Light bending

With straight-line light you see exactly half of the star. With general relativity you see 76% of it: the grid lines bunch up near the edge as the far side comes into view. The same effect flattens the X-ray pulse, because neither hot spot ever fully disappears.

Neutron star surface with a latitude and longitude grid, rendered with straight light raysStraight-line light: half the surface
The same star with light bending: the grid wraps further round the edge and more of the far side is visibleGeneral relativity: 76% of the surface
X-ray pulse profile with and without light bending. Pulse fraction 38% with bending, 78% without. 0 0.5 1 -0.25 0 0.25 0.5 0.75 Rotation phase (turns)
General relativity: pulse fraction 38%Straight-line light: 78%
X-ray brightness through one turn, each curve scaled to its own peak. 1.4 suns, 12 km, 500 turns per second, magnetic tilt 50°, viewing angle 50°, two 20° hot spots at the magnetic poles. Pulse fraction is (max − min) / (max + min).

Three magnetic fields

A static dipole turning rigidly is the textbook picture, and it is correct only far inside the light cylinder. The rotating dipole in vacuum is the exact solution of Maxwell's equations for a spinning point magnet in empty space. Deutsch (1955) solved the same problem for a magnetized sphere; outside the star the two differ by under 4%. Near the light cylinder its lines stop following the star and sweep back into spirals that carry energy away as electromagnetic waves. Real pulsars are not surrounded by vacuum but by plasma, which carries currents and reshapes the field. The plasma-filled sketch joins a dipole inside the light cylinder to Bogovalov's (1999) exact “split monopole” wind outside it. In that wind, field lines from the two magnetic hemispheres are separated by a rippled current sheet, purple here. The join between the two regions is our interpolation, not a calculation.

Field lines of a static dipole, closed loops extending past the light cylinderStatic dipole
Field lines of a rotating dipole in vacuum, sweeping back into spirals beyond the light cylinderRotating dipole, vacuum (exact)
Plasma-filled sketch: closed field lines inside the light cylinder, open spiral lines and a rippled current sheet outsidePlasma-filled (sketch)
The 716 Hz pulsar with a 60° magnetic tilt, viewed 75° from the spin axis. The faint grey cylinder is the light cylinder.

Where you stand

The same star produces very different pulses depending on the magnetic tilt χ and your viewing angle ζ. When both are near 90° you see both hot spots in turn: a main pulse and an interpulse half a turn later. When both are small, one spot stays in view all the time and the pulse is shallow. Some pulsars are invisible in radio from Earth because their beam never sweeps across us.

X-ray pulse profiles for three combinations of magnetic tilt and viewing angle Tilt χ = 20°, viewing ζ = 25° 0 0.5 1 -0.25 0.25 0.75 pulse fraction 11% (17% without bending)Tilt χ = 50°, viewing ζ = 60° -0.25 0.25 0.75 pulse fraction 26% (80% without bending)Tilt χ = 85°, viewing ζ = 85° -0.25 0.25 0.75 pulse fraction 29% (81% without bending)
General relativityStraight-line light
The same star (1.4 suns, 12 km, 200 turns per second, 15° hot spots) seen from three geometries. Horizontal axis: rotation phase in turns, from −0.25 to 0.75; each curve is scaled to its own peak.

Doppler shifts

At 716 turns per second the surface moves at up to 0.22 c. A hot spot moving toward you is beamed brighter, and one moving away is dimmer. Light-travel time adds to the effect: while a spot approaches, points near the edge show it as it was slightly earlier, so its image is stretched and covers more of the surface. In the example below, Doppler shifts raise the pulse fraction from 24% to 55%, move the peak about a tenth of a turn earlier than the moment the spot faces you, and make the pulse rise faster than it falls. NICER uses this asymmetry, along with the light bending, to separate a star's mass from its radius.

X-ray pulse at 716 turns per second with and without Doppler shifts. Pulse fraction 55% with, 24% without. 0 0.5 1 -0.25 0 0.25 0.5 0.75 Rotation phase (turns)
Doppler + gravitational shifts: pulse fraction 55%Gravitational shift only: 24%
The 716 Hz pulsar (1.4 suns, 12 km), magnetic tilt 60°, viewing angle 70°, 25° hot spots, light bending on in both curves. Each curve is scaled to its own peak.

Radio emission height

Raising the emission height widens the beam, because the open field lines spread out with distance. It also moves the polarization swing later relative to the pulse.

Radio brightness and polarization angle at two emission heights Emission height 0.03 R_LC: brightness 0 1 Polarization angle -90° 0° 90° -0.2 -0.1 0 0.1 0.2 Emission height 0.15 R_LC: brightness 0 1 Polarization angle -90° 0° 90° -0.2 -0.1 0 0.1 0.2 Rotation phase (turns)
Computed beamRotating vector model, no aberration
A pulsar spinning 10 times per second, magnetic tilt 50°, viewing angle 60°, core-and-cone beam, light bending on. Phase zero is when the magnetic axis passes closest to the line of sight.

What a Pulsar Beam Really Looks Like

Most people picture a pulsar the way textbooks and science videos draw it: a star with two narrow, straight searchlight beams sweeping around, like the left image below. Part of that is right. A radio pulsar does emit a beam around each magnetic pole, and the pulses come from that beam sweeping past Earth. Three things about the picture are not right.

The beam can't be a rigid searchlight. The textbook beams on the left reach 8 light-cylinder radii from the star. Turning with it, their far ends would move at up to 8 times the speed of light. Nothing actually moves that way. Each photon flies straight outward from where it was emitted while the beam's direction keeps sweeping on. At any instant the light already emitted lies along a spiral, as on the right, like water from a spinning lawn sprinkler. The spiral has one turn per c × P, about 420 km for the 716 Hz pulsar. The “light in flight” view plays at 0.25 turns per second by default, six times faster than the others, so you can watch the spiral being laid down.

A beam can't be seen from the side. Searchlight beams on Earth are visible because fog and dust scatter some of their light toward you. A pulsar has almost nothing around it to do that, so you only detect the beam when it points at you. The middle image draws the beam as a cone anyway, as a visual aid, in the same way as the field lines, and stops it at the light cylinder.

Real beams are wider and less tidy. The computed beam (middle and right) is the brightest ring of emission from the open field lines. It is tens of degrees wide for this pulsar, comes from just above the surface, and is tilted forward by the star's rotation. Real beams vary from a few degrees to a few tens of degrees across and are often hollow. A pulsar's gamma rays come from somewhere else again, farther out near the light cylinder.

Is this to scale? Yes. The star (12 km), the light cylinder (67 km) and the spiral (420 km per turn) are drawn at their true sizes. The spacing of the spiral is always 2π light-cylinder radii, because both are set by the spin period. The fastest pulsars are the only ones where the star is visible at that scale. For the Crab pulsar one turn of the spiral is 10,000 km, about 830 times the star's radius. For a pulsar that spins once a second it is 300,000 km, and the star would be far too small to see.

The textbook picture: two narrow, bright, straight beams reaching far out from the star along its magnetic axisTextbook beams (not physical)
Two translucent green cones along the tilted magnetic axis, ending at the light cylinderCone to the light cylinder (visual aid)
The beam's light at one instant: two broad green spiral sheets winding outward from the star far beyond the light cylinderLight in flight, at one instant
The 716 Hz pulsar, magnetic tilt 60°, viewed 80° from the spin axis, all at the same scale and the same instant. Left: the textbook picture, two 4° straight beams along the magnetic axis. Middle and right: the beam the simulator computes. The small grey cylinder is the light cylinder, 67 km in radius. All three are under Emission → Beam display.

How Fast, and How Much Slowed Down

Periods are from the ATNF Pulsar Catalogue. The last column is how much the default playback speed (0.04 turns per second, one turn every 25 seconds) slows each one. The “light in flight” beam view plays at 0.25 turns per second, so it is slowed about 6 times less.

ObjectSpin periodLight cylinderEquator speedSlowed by
PSR J1748−2446ad1.40 ms67 km0.22 c18,000×
PSR J0740+66202.89 ms138 km0.13 c8,700×
PSR J0030+04514.87 ms232 km0.066 c5,100×
PSR J0437−47155.76 ms275 km0.052 c4,300×
Crab pulsar33.4 ms1,590 km0.0093 c750×
Vela pulsar89.3 ms4,260 km0.0035 c280×
Magnetar SGR 1806−207.56 s360,000 km0.00004 c3.3×

Equator speeds use each star's NICER radius where one exists, otherwise 12 km, and are measured by an observer at rest on the surface. Magnetars spin slowly, and their light cylinders lie hundreds of thousands of kilometres out. At the scale of the star their field is a plain dipole, so the simulator shows a magnetar's field out to 60 stellar radii only. What makes magnetars distinctive, a field of about 1015 gauss that decays and powers bursts, is outside this model.

What This Model Leaves Out

Method, Verification and Sources

The method page gives the equations behind each part: the light-bending table, the vacuum field, the pulse integration and the radio beam. It also lists the tests the code passes against independent calculations, and 27 references.

Built with Claude Opus 5.5: the physics design, the GPU code, the test programs and the write-up.

Free to Use, With Credit

Images and recordings you make with this simulator, and the figures on this page, may be used for any purpose, including teaching, publication and commercial work, without asking permission. We only ask that you credit Frosty Wren Studios, for example:

Pulsar simulation: Frosty Wren Studios, frostywren.com/pulsar

“Save image” adds this line to the corner of each picture by default; you can switch it off under Display and output. The simulator’s source code is not covered by this permission.

← Frosty Wren Studios Method → Black Hole → Dev Journal →