Arithmetic Series Sum Calculator
Compute the sum of an arithmetic series from term count and first and last terms.
📐 计算公式
等差数列前 n 项和 Sₙ = n × (首项a₁ + 末项aₙ) ÷ 2;公差 d = (aₙ − a₁) ÷ (n − 1)(n ≥2 才显示,否则记 —);各项平均值 = Sₙ ÷ n(n 为 0 时按 1 兜底防除零)。校验:无强校验,数值缺省按 0。判据:Sₙ 保留 2 位小数、公差保留 4 位小数,公差为负即递减数列。
输入项数 n、首项 a₁ 与末项 aₙ,求前 n 项和。
📌 计算说明
- 高斯求和公式。
- 10×(1+10)/2 → 55。