telescoping_sum

std.seq.telescoping_sum · Level L2

The telescoping sum Σ_{k=0}^{N−1} (b_k − b_{k+1}) = b_0 − b_N of a sequence b_0 … b_N: every inner term cancels. The infinite series converges exactly when b_N has a limit, to b_0 − lim b_N.

Σ (b_k − b_{k+1}) = b_0 − b_N

Signature

telescoping_sum(bseq: f64[n]) → f64[]

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.

bseqf64[n]SlicefSlicelSubtractdReduceSumsumsumf64[]
  • input
  • operation
  • constant
  • call
  • output

Verification

  • Signature proven by NOVA’s shape solver, for every size.
  • Equal to the reference sum of b[k] − b[k+1] in exact rational arithmetic, on all 40 test cases.
  • All 40 float64 results inside the running error bound; the closest uses 64% 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 80% of it.
Accuracy in detail
correctly rounded (the float64 nearest the exact value)
100%
bit-equal to the NumPy formula in float64
83%
largest error, in units in the last place
0.50

Identity

Calls
—
Called by
—
sha256:04c8bcd931a02339e06c192f46cb2bea1e595a9a0dcb8eb9cbcde57cec490c97

The semantic hash of the graph. It changes when the program changes, and never when only its documentation does.

Control handle

Symbol
Ω:std.seq.telescoping_sum · Ω:telescoping_sum
Pins
sha256:7443ce99a10c9e5feb24d380123d6ec1487a13b38ad4a172dc7d749dac14756bthis graph alone
Evidence
sha256:5e52b2a2726dc93a6631509ae0773554fd9a0b09cec88a38f2ed2aaec45aeba0the 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.

ΣEML 2026

Efficient New Language — a high-density semantic overlay for humans and AI agents.

This site’s demos run on the real EML toolchain, in your browser.

© 2026 EveMissLab (一言諾科技有限公司) / Neo.K. All rights reserved.