Standing wave calculator
On a 1 m string vibrating in its second harmonic, the wavelength is 1 m and the nodes sit at 0, 0.5 and 1 m. Enter the harmonic number and the string length to get the wavelength and every node and antinode position. Free in your browser.
- Free
- Runs in your browser
- No sign-up
- Your data stays on your device
Run — free
Worked example
- Harmonic number n
- 2
- Length
- 1
- Wavelength
- 1
- Node positions
- 0, 0.5, 1
- Antinode positions
- 0.25, 0.75
- Node count
- 3
A standing wave on a string fixed at both ends is a resonant pattern formed when two identical travelling waves move in opposite directions and interfere so that certain points never move and others oscillate with maximum amplitude. Those fixed zeros are the nodes; the midpoints of maximum swing are the antinodes. For length L and harmonic number n (the mode index, with n equals one for the fundamental), the wavelength is always two L over n, and the nodes sit at multiples of L over n from zero through L inclusive. This calculator returns that wavelength, the ordered list of node positions, the matching antinode positions, node and antinode counts, loop count, and the constant spacing between consecutive nodes, all from a pure closed-form model with no simulation and no network. Zero length is rejected with a clear validation error because the reciprocal geometry is undefined.
Standing-wave geometry on a fixed-end string
Begin with a flexible string of length L whose ends are fixed so displacement is zero at x equals zero and at x equals L for every time. A pure standing wave of harmonic number n fits exactly n half-wavelengths along the string, which is the same statement as L equals n times lambda over two, or lambda equals two L over n. Because the ends cannot move, they are always nodes.
Additional interior nodes appear wherever the mode shape sin of n pi x over L is zero, that is at x equals k L over n for every integer k from zero through n inclusive, giving n plus one node positions in total. Antinodes sit halfway between neighbouring nodes, at x equals two j minus one times L over two n for j from one through n, giving n antinodes. The uniform spacing between consecutive nodes is L over n, which equals half a wavelength.
The fundamental n equals one has only the two end nodes and a single antinode at the midpoint; the second harmonic adds a node at midspan and two antinodes; higher harmonics keep adding one interior node and one antinode per step. This capability encodes exactly that fixed-end geometry. It does not require tension, linear density, or wave speed because those quantities set frequency and period once lambda is known, while node positions and wavelength are pure geometry.
Inputs must be finite; length must be strictly positive; the harmonic must be a positive integer. NaN, Infinity, zero length, and non-integer modes fail with invalid input rather than inventing a pattern.
What you send and what you get back
Send two fields: harmonic, a positive integer n for the mode index, and length, a finite positive number L in whatever length unit you want the answer expressed in. Zero or negative length fails with a message that standing-wave wavelength and node positions require L greater than zero. Non-positive or non-integer harmonics fail so callers cannot accidentally request a fractional mode as if it were a fixed-end resonance.
Classic textbook checks include n equals one and L equals one with wavelength two and nodes at zero and one; n equals two and L equals one with wavelength one and nodes at zero, one half, and one; n equals three and L equals one point five with wavelength one and four nodes at steps of zero point five. Wire the free browser form for homework and lab prep, then call the identical contract from scripts when you need bulk answer keys.
Where standing-wave node calculators show up in real work
Secondary-school and college physics courses constantly assign fixed-string standing-wave problems: sketch the third harmonic, mark every node, compute the wavelength from a measured length, and compare consecutive-node spacing to half a wavelength. Lab write-ups that photograph a vibrating string under strobe light need predicted node coordinates before they can score student measurements. Guitar, violin, and piano pedagogy explain frets and harmonics with the same n and L geometry, and instrument makers check that a calculated antinode lands under a pickup or bridge sensor.
Programming contest and interview warm-ups sometimes hide mode counting under string or rope constraints and expect exact positions rather than a hand-wavy diagram. If you later need period-to-frequency conversion, beat frequency between two tones, sound intensity in decibels, or free-end pipe resonances, treat those as separate search intents and landings rather than overloading this fixed-string standing-wave calculator page.
What you can do with it
Homework node and wavelength keys
Generate λ = 2L/n and every node position for textbook fixed-string harmonics so teachers and auto-graders share one ground truth.
Vibrating-string lab prep
Predict node and antinode coordinates on a measured string length before strobe photography or phone slow-motion capture in the lab.
Instrument harmonic geometry
Check where open-string harmonics place nodes and antinodes relative to frets, pickups, or bridge sensors without solving the full wave equation.
FAQ
What formula does this standing wave calculator use?
Spacing between consecutive nodes is L/n = λ/2.
What happens if length is zero?
Wavelength λ = 2L/n and node positions require a finite positive string length L > 0.
Can I use centimetres instead of metres?
Yes. Length is unit-agnostic: node positions and wavelength come back in the same unit you send for L.
What does it cost?
The browser tool is free and runs locally.
How many nodes and antinodes does each harmonic have?
Harmonic n has n plus one nodes, counting both fixed ends, and n antinodes. The fundamental has only the two end nodes and one antinode in the middle, and each higher harmonic adds one node and one antinode.
Related tools
For developers — API access
Everything on this page is available programmatically. This section is for teams who want to wire it into their own systems; everyone else can just use the tool above.
API endpoint
Prefer to automate it? One authenticated POST creates the task; the result comes back by webhook or a signed link. The same capability also runs here on the web, by email and from Telegram — and soon from our app too.
Call it from your stack
curl -X POST https://api.kit.forhosting.com/phys/standing-wave \
-H "Authorization: Bearer $KIT_KEY" \
-H "Content-Type: application/json" \
-d '{"harmonic":2,"length":1}'const res = await fetch("https://api.kit.forhosting.com/phys/standing-wave", {
method: "POST",
headers: {
"Authorization": `Bearer ${process.env.KIT_KEY}`,
"Content-Type": "application/json"
},
body: JSON.stringify({
"harmonic": 2,
"length": 1
})
});
const { task_id } = await res.json();import os, requests
res = requests.post(
"https://api.kit.forhosting.com/phys/standing-wave",
headers={"Authorization": f"Bearer {os.environ['KIT_KEY']}"},
json={
"harmonic": 2,
"length": 1
},
)
task_id = res.json()["task_id"]<?php
$res = file_get_contents("https://api.kit.forhosting.com/phys/standing-wave", false, stream_context_create([
"http" => [
"method" => "POST",
"header" => "Authorization: Bearer " . getenv("KIT_KEY") . "\r\nContent-Type: application/json",
"content" => '{"harmonic":2,"length":1}',
],
]));
$task = json_decode($res, true);body := bytes.NewBufferString(`{"harmonic":2,"length":1}`)
req, _ := http.NewRequest("POST", "https://api.kit.forhosting.com/phys/standing-wave", body)
req.Header.Set("Authorization", "Bearer "+os.Getenv("KIT_KEY"))
req.Header.Set("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)Example request
{
"harmonic": 2,
"length": 1
}Example response
{
"task_id": "tsk_a1b2c3d4e5f6a1b2c3d4e5f6",
"type": "phys.standing_wave",
"status": "queued",
"_links": {
"result": "/tasks/tsk_…/result"
}
}The API is asynchronous: the call returns a task_id immediately and the result arrives by webhook. Polling is capped at 1 req/s per task.
Pricing
Published price — no tokens, no invented credits. A failed task is never charged.
Errors
| HTTP | Code | Meaning |
|---|---|---|
401 | unauthorized | Missing or invalid API key. |
402 | insufficient_balance | Your balance doesn't cover the task price. |
404 | unknown_type | That task type doesn't exist. |
429 | rate_limited | Too many requests. Use the webhook instead of polling. |
Technical notes
What you send and what you get back
Aliases n, mode, and harmonic_number are accepted for the harmonic; L, l, and string_length are accepted for the length. Missing fields, non-numeric strings, NaN, and Infinity fail with invalid_input and are not charged. On success the response echoes cleaned harmonic and length, wavelength equal to two L over n, node_positions as an ordered array from the left end through the right end, antinode_positions between the nodes, node_count equal to n plus one, antinode_count equal to n, loop_count equal to n, node_spacing equal to L over n, ends fixed, unit notes that positions share the input length unit, and short formula and relation strings for worksheets. Pricing for successful API calls is the published base of $0.002 per item; validation failures do not consume prepaid balance.
Where standing-wave node calculators show up in real work
Because this capability is a pure parse engine, API pricing is the published base of $0.002 per successful item and failed validation does not consume balance.
Technical questions
Does it include the end nodes?
Yes. Fixed ends are always nodes, so node_positions always starts at 0 and ends at L, with n+1 entries total for harmonic n.