|
Download ai/ai-0018.jsonl from winapiadmin/tinycodinglm: direct link, hf CLI and curl.
- Browser
- Download file 4.66 kB
-
https://huggingface.co/datasets/winapiadmin/tinycodinglm/resolve/main/ai/ai-0018.jsonl
- Command line
-
hf download hf://datasets/winapiadmin/tinycodinglm/ai/ai-0018.jsonl
-
curl -L -o ai-0018.jsonl https://huggingface.co/datasets/winapiadmin/tinycodinglm/resolve/main/ai/ai-0018.jsonl
4.66 kB
| {"type": "session", "harness": "opencode", "id": "ai-0018", "name": "pi algs summarization"} | |
| {"type": "message", "message": {"role": "system", "content": "You're going to compact the text as short as possible."}} | |
| {"type": "message", "message": {"role": "user", "content": "Yes. There is a genuine higher-convergence alternative to Chudnovsky.\nThe **Berndt–Chan \\(m=3315\\) Ramanujan-type series** gives about **75.3178 decimal digits per term**, versus about **14.1816 digits/term** for Chudnovsky, so it needs about **5.31× fewer terms** for the same number of digits.\nA later Campbell preprint extends this family to about **153.8732 digits/term**, but that construction is substantially more complicated. (arXiv)\nThat does **not** automatically mean it is 5× faster in wall-clock time. Chudnovsky's binary splitting and highly optimized multiplication are extremely effective, which is why record computations still use it. The latest y-cruncher record listed through 2025 was computed with its Chudnovsky machinery. (Number World)\nAlso: **Gauss–Legendre / Brent–Salamin is much faster in convergence per iteration than Chudnovsky**, but there is an important catch: an iteration becomes substantially more expensive as the precision grows.\nand it has **quadratic convergence**. (MathWorld)\nFor **moderate precision**, AGM is extremely attractive.\nFor **huge precision**, not necessarily.\n| Algorithm | Convergence | Main expensive operation |\n| --------------- | ------------------------------------------: | ------------------------------------------ |\n| Chudnovsky | ~14.18 decimal digits/term | Large integer multiplication |\n| Gauss–Legendre | quadratic, roughly doubles digits/iteration | High-precision square root |\n| Borwein quartic | quartic | Several high-precision operations |\n| Borwein quintic | quintic | More complicated high-precision operations |\nThe amusing part is that **Chudnovsky has terrible-looking convergence by iteration count but excellent computational structure**. Binary splitting turns its series into large integer arithmetic that modern multiplication algorithms handle extremely well.\nSo:\n$$\n\\boxed{\\text{fewer iterations} \\neq \\text{faster computation}}\n$$\nwhich is one of those irritating cases where asymptotic convergence politely refuses to tell you the whole story.\nFor example, to obtain \\(10^6\\) digits, Gauss–Legendre only needs on the order of\n$$\n\\log_2(10^6)\\approx 20\n$$\niterations, but those iterations involve million-digit square roots. Chudnovsky needs roughly\n$$\n\\frac{10^6}{14.18}\\approx 70\\,500\n$$\nseries terms, but binary splitting makes those terms dramatically cheaper to aggregate.\nFor very large record computations, Chudnovsky-style binary splitting therefore remains highly competitive despite its lower convergence order.\n### One important terminology point\nThe **Gauss–Legendre algorithm for \\(\\pi\\)** is not the same thing as **Gauss–Legendre quadrature**. Here \"Gauss–Legendre\" refers to the AGM-based π algorithm, also called the **Brent–Salamin algorithm**. (MathWorld)\nAnd if the actual goal is **\"find something genuinely better than Chudnovsky for arbitrary huge precision\"**, then the interesting direction is not Gauss–Legendre. It is the **quartic/quintic/high-order Borwein algorithms**, or the more recent higher-order modular identities. (MathWorld)"}} | |
| {"type": "message", "message": {"role": "assistant", "content": "### Condensed summary\n\n* **Berndt–Chan \\(m=3315\\)**: ~**75.32 digits/term**, about **5.31× Chudnovsky's** ~14.18 digits/term.\n\n* **Campbell's extension**: ~**153.87 digits/term**, but much more complicated.\n\n* Higher convergence **doesn't imply proportionally faster runtime**. Chudnovsky's **binary splitting + fast multiplication** is exceptionally efficient at huge precision.\n\n* **Gauss–Legendre / Brent–Salamin** uses the AGM and has **quadratic convergence**, roughly doubling the number of correct digits per iteration.\n\n* Its problem is that each iteration requires increasingly expensive **high-precision square roots**.\n\n* Therefore:\n\n $$\n \\boxed{\\text{fewer iterations}\\neq\\text{faster computation}}\n $$\n\nFor \\(10^6\\) digits:\n\n* Gauss–Legendre: ~20 iterations.\n* Chudnovsky: ~70,500 terms.\n\nBut Chudnovsky's terms can be efficiently combined through binary splitting, making it highly competitive for massive computations.\n\n**If the goal is genuinely beating Chudnovsky at extreme precision**, the relevant territory is **Borwein quartic/quintic methods and newer high-order modular identities**, not simply Gauss–Legendre.\n"}} | |