physics
Import it with :physics, then call its constructs under that name.


@use:physics#Constructs
physics.forceOne labelled force: an arrow of a given length, from a point, at a bearing. The whole of a free-body diagram is several of these at one point, which is why it is this rather than a construct taking four forces at once — a figure with three forces should not have to leave a fourth blank.


magnitudeThe arrow's length, in graph units rather than newtons.
Default
2bearingThe arrow's direction, in degrees anticlockwise from the right.
Default
0xThe arrow's starting point, x coordinate.
Default
0yThe arrow's starting point, y coordinate.
Default
0labelThe force's label.
inlineDefault
styleThe arrow's stroke.
enumDefault
solidwidthThe arrow's line width.
Default
2colourThe arrow's colour.
paintDefault
redphysics.resolveA force with its two components drawn dashed beside it, and the right angle between them marked.
along is the direction the components are taken in — 0 for the ordinary horizontal and vertical pair, the slope's angle for a block on a slope, which is the case the resolution exists for. The arithmetic is the point: the parallel component is and the perpendicular one , and getting the sign of that difference right by hand is where the figure usually goes wrong.

magnitudeThe force's length, in graph units rather than newtons.
Default
3bearingThe force's direction, in degrees anticlockwise from the right.
Default
55alongThe direction the components are resolved in, in degrees — the slope's angle for a block on a slope.
Default
0xThe force's starting point, x coordinate.
Default
0yThe force's starting point, y coordinate.
Default
0labelThe original force's label.
inlineDefault
$F$parallel-labelThe component along
along's label.inlineDefault
perpendicular-labelThe component perpendicular to
along's label.inlineDefault
colourThe original force arrow's colour.
paintDefault
redparallel-colourThe parallel component's colour.
paintDefault
orangeperpendicular-colourThe perpendicular component's colour.
paintDefault
tealphysics.inclineA block on a slope: the ground, the incline, the block sitting on it and the angle at the foot. The block is a rectangle turned to lie on the slope, so its corners come out of the slope's own direction and normal rather than being written down — which is what a hand-drawn version of this figure never quite manages.
at is how far along the slope it sits, as a fraction.

angleThe slope's angle to the ground, in degrees.
Default
30baseThe horizontal length of the ground the slope rises from.
Default
6atHow far along the slope the block sits, as a fraction from 0 to 1.
Default
0.55blockThe block's side length.
Default
1xThe foot of the slope's x coordinate.
Default
0yThe foot of the slope's y coordinate.
Default
0labelThe angle at the foot's label.
inlineDefault
$\theta$colourThe ground segment's colour.
paintDefault
greyslope-colourThe slope and its angle mark's colour.
paintDefault
blueblock-colourThe block's colour.
paintDefault
orangephysics.pendulumA pendulum hanging from a pivot: the string at an angle FROM THE VERTICAL, the bob, the vertical it swings about, and the angle between them.


angleThe string's angle from the vertical, in degrees.
Default
25lengthThe string's length.
Default
4bobThe bob's size.
Default
14xThe pivot's x coordinate.
Default
0yThe pivot's y coordinate.
Default
5labelThe angle between the string and the vertical's label.
inlineDefault
$\theta$length-labelThe string's label.
inlineDefault
$l$colourThe pivot point and the vertical dashed line's colour.
paintDefault
greystring-colourThe string and its angle mark's colour.
paintDefault
bluebob-colourThe bob's colour.
paintDefault
orangephysics.projectileA projectile's flight: the trajectory, the apex, and the range, from a launch speed and an angle. Everything but the curve is a consequence of those two — the range is and the apex — so the markers land where the curve actually goes rather than where they were dragged.


uThe launch speed.
Default
20angleThe launch angle above the horizontal, in degrees.
Default
45gThe acceleration due to gravity.
Default
9.81labelThe trajectory curve's label.
inlineDefault
apex-labelThe apex point's label.
inlineDefault
$H$range-labelThe range brace's label.
inlineDefault
$R$launch-labelThe launch velocity vector's label.
inlineDefault
$u$colourThe trajectory curve, the range point and the brace's colour.
paintDefault
blueapex-colourThe apex point and its dropped segment's colour.
paintDefault
teallaunch-colourThe launch velocity vector's colour.
paintDefault
redphysics.vt-displacementA velocity–time graph under constant acceleration, with the area under it shaded: the displacement, which is what the area IS. The line is a
curve rather than a line so that integral can shade under it — the area is sampled from the curve itself, so it follows the line however the acceleration changes.

uThe initial velocity.
Default
2aThe constant acceleration.
Default
1.5fromWhere the shaded area starts, along the time axis.
Default
0toWhere the line is drawn to, and where the shaded area ends.
Default
6labelThe velocity line's label.
inlineDefault
$v = u + at$area-labelThe shaded displacement area's label.
inlineDefault
$s$colourThe velocity line's colour.
paintDefault
bluearea-colourThe shaded displacement area's colour.
paintDefault
tealshow-valuePrint the displacement on the shading, beside its label. Off by default: the number is always available to prose through the call's id, and a figure that states it as well is a choice about that figure.
boolDefault
falsephysics.waveA travelling wave, with its amplitude ruled across and its wavelength braced along the axis.
phase moves the wave along without changing anything else, so a step can show the same wave a quarter period later.

amplitudeThe wave's amplitude.
Default
2wavelengthThe wave's wavelength.
Default
4phaseHow far the wave is shifted along the axis, without changing anything else.
Default
0fromWhere the wave is drawn from, along the axis.
Default
0toWhere the wave is drawn to, along the axis.
Default
12labelThe wave curve's label.
inlineDefault
amplitude-labelThe ruled amplitude line's label.
inlineDefault
$A$wavelength-labelThe braced wavelength's label.
inlineDefault
$\lambda$colourThe wave curve's colour.
paintDefault
bluemarks-colourThe amplitude rule and the wavelength brace's colour.
paintDefault
greyphysics.thin-lensA thin converging lens with the three construction rays and the image they meet at. The image is where the lens equation puts it: , with the height scaled by — so the rays meet AT the image rather than near it, which is the one thing a hand-drawn ray diagram cannot promise. Distances are positive: the object stands
u to the left of the lens, the focal points at either side. The real-image case, so u must be greater than f. Nearer than the focal point the rays diverge and the image is virtual — a different construction, with the rays extended back rather than crossing.

uThe object's distance to the left of the lens.
Default
9fThe lens's focal length, the same either side.
Default
3hThe object's height.
Default
2apertureThe lens symbol's half-height, drawn to scale with the figure rather than the optics.
Default
2.6fill-styleHow the lens symbol is filled — outlined leaves it empty.
enumDefault
outlinedobject-labelThe object arrow's label.
inlineDefault
$O$image-labelThe image arrow's label.
inlineDefault
$I$focus-labelBoth focal points' label.
inlineDefault
$F$colourThe axis and the focal points' colour.
paintDefault
greylens-colourThe lens symbol's colour.
paintDefault
blueray-colourThe three construction rays' colour.
paintDefault
orangeobject-colourThe object arrow's colour.
paintDefault
tealimage-colourThe image arrow's colour.
paintDefault
purplephysics.refractionRefraction at a boundary: the incident ray, the normal, and the refracted ray at the angle Snell's law puts it, with both angles marked. The refracted angle is , worked out here rather than by the author — so the ray bends towards the normal when it should, and by as much as it should. Both angles are measured FROM THE NORMAL, as they are in the subject. The boundary runs along with medium 1 above it.


angleThe incident ray's angle from the normal, in degrees.
Default
40n1The refractive index of the medium the incident ray travels through.
Default
1n2The refractive index of the medium the refracted ray travels through.
Default
1.5lengthBoth rays' length.
Default
4spanHow far the boundary and the normal are drawn either side of the point of incidence.
Default
5incident-labelThe incident ray's label.
inlineDefault
refracted-labelThe refracted ray's label.
inlineDefault
normal-labelThe normal's label.
inlineDefault
angle-labelThe incident angle's label.
inlineDefault
$\theta_1$refracted-angle-labelThe refracted angle's label.
inlineDefault
$\theta_2$colourThe normal's colour.
paintDefault
greyboundary-colourThe boundary's colour.
paintDefault
neutralray-colourThe incident ray and its angle mark's colour.
paintDefault
orangerefracted-colourThe refracted ray and its angle mark's colour.
paintDefault
purple