rotate2d
std.geometry.rotate2d · Level L5Rotate points of the plane counterclockwise by the angle θ (radians) about the origin: each row p of P becomes R(θ)·p.
Signature
rotate2d(P: f64[n, 2], theta: f64[]) → f64[n, 2]
Structure
The function as NOVA stores it: one box per input, operation and output, and arrows that carry values. A double border marks another library function this one runs — called once, or by Scan once per element; select it to open that function.
- input
- operation
- constant
- call
- output
Verification
- Signature proven by NOVA’s shape solver, for every size.
- Agrees with the reference
P @ np.array([[cos θ, sin θ], [−sin θ, cos θ]])to 80 digits (100-digit arithmetic), on all 40 test cases. - All 310 float64 results inside the running error bound; the closest uses 18% of it.
- Interpreter and NumPy backend return bit-identical results.
- At float32 too: the 40 test cases rounded to float32, and 40 of them inside the running error bound at u = 2⁻²⁴; the closest uses 16% of it.
- correctly rounded (the float64 nearest the exact value)
- 70%
- bit-equal to the NumPy formula in float64
- 83%
- largest error, in units in the last place
- 105
Large ulp counts appear where a result is tiny next to the numbers it is computed from (after cancellation, for example), so one unit in the last place is tiny too; the absolute error is still inside the bound. Results within their own error of zero are not counted.
Identity
sha256:6066e2a77f7141d76328a991fba614497d4c639995a7ef5c9d415bc091b9a280The semantic hash of the graph. It changes when the program changes, and never when only its documentation does.
Control handle
- Symbol
- Ω:std.geometry.rotate2d · Ω:rotate2d
- Pins
sha256:b6d3f3e786c284a5b20c68052147d7f69a80c8b473c1deda0966bc001e70663dthis graph alone- Evidence
sha256:49bcd85eee4a0dfa75f88d0a9c9e92d4386bd5db7534b7991868ff9464b61ad7the hash of its verification record- Needs
- no capability: a pure function
Through NOVA’s control layer, the symbol launches this function only while the program still matches what it pins: a change to this graph, or to any graph it reaches, needs a migration first.