# number theory

Published articles for number theory.

This is one page of public article previews, not the complete archive. Follow Next page to continue. Summaries are not the original full articles.

## How NuminaMath Won the 1st AIMO Progress Prize

DevFeed: [How NuminaMath Won the 1st AIMO Progress Prize](<https://devfeed.tech/articles/how-numinamath-won-the-1st-aimo-progress-prize-7569.md>)

Original publisher: [Read original article](<https://huggingface.co/blog/winning-aimo-progress-prize>)

Author: Yann Fleureau; LI Jia; Edward Beeching; Lewis Tunstall; Ben Lipkin; Roman Soletskyi; Shengyi Costa Huang; Kashif Rasul

Published: 2024-07-11T00:00:00Z

Content type: article

Language: en

Sources: [Hugging Face - Blog](<https://devfeed.tech/sources/hugging-face-blog.md>)

Topics: [Mathematics](<https://devfeed.tech/topics/mathematics.md>), [Artificial Intelligence](<https://devfeed.tech/topics/ai.md>), [Open Source](<https://devfeed.tech/topics/open-source.md>), [AI Models](<https://devfeed.tech/topics/ai-models.md>), [Fine-tuning](<https://devfeed.tech/topics/fine-tuning.md>), [hugging face](<https://devfeed.tech/topics/hugging-face.md>)

Tags: [ai-models](<https://devfeed.tech/tags/ai-models.md>), [ai4math](<https://devfeed.tech/tags/ai4math.md>), [artificial-intelligence](<https://devfeed.tech/tags/artificial-intelligence.md>), [blog](<https://devfeed.tech/tags/blog.md>), [blog-post](<https://devfeed.tech/tags/blog-post.md>), [community](<https://devfeed.tech/tags/community.md>), [fine-tuning](<https://devfeed.tech/tags/fine-tuning.md>), [hugging-face](<https://devfeed.tech/tags/hugging-face.md>), [leaderboard](<https://devfeed.tech/tags/leaderboard.md>), [math](<https://devfeed.tech/tags/math.md>), [maths](<https://devfeed.tech/tags/maths.md>), [nlp](<https://devfeed.tech/tags/nlp.md>), [number-theory](<https://devfeed.tech/tags/number-theory.md>), [open-science-collab](<https://devfeed.tech/tags/open-science-collab.md>), [open-source](<https://devfeed.tech/tags/open-source.md>), [research](<https://devfeed.tech/tags/research.md>), [science](<https://devfeed.tech/tags/science.md>)

### AI overview

This article introduces the Numina initiative and describes the technical work behind its winning solution for the 2024 AIMO progress prize. It focuses on open development of AI models for mathematical reasoning, including the role of LLM fine-tuning and support from Hugging Face and other organizations.

### Source excerpt

We're on a journey to advance and democratize artificial intelligence through open source and open science.

## Encoding Schemes in FHE

DevFeed: [Encoding Schemes in FHE](<https://devfeed.tech/articles/encoding-schemes-in-fhe-40476.md>)

Original publisher: [Read original article](<https://www.jeremykun.com/2023/09/18/encoding-schemes-in-fhe/>)

Published: 2023-09-18T11:08:39Z

Content type: tutorial

Language: en

Sources: [Jeremy Kun](<https://devfeed.tech/sources/jeremy-kun.md>)

Topics: [Encoding](<https://devfeed.tech/topics/encoding.md>), [FHE](<https://devfeed.tech/topics/fhe.md>), [homomorphic encryption](<https://devfeed.tech/topics/homomorphic-encryption.md>), [Cryptography](<https://devfeed.tech/topics/cryptography.md>), [Decoding](<https://devfeed.tech/topics/decoding.md>)

Tags: [bits](<https://devfeed.tech/tags/bits.md>), [complex-numbers](<https://devfeed.tech/tags/complex-numbers.md>), [cryptography](<https://devfeed.tech/tags/cryptography.md>), [decoding](<https://devfeed.tech/tags/decoding.md>), [encoding](<https://devfeed.tech/tags/encoding.md>), [fhe](<https://devfeed.tech/tags/fhe.md>), [homomorphic-encryption](<https://devfeed.tech/tags/homomorphic-encryption.md>), [learning-with-errors](<https://devfeed.tech/tags/learning-with-errors.md>), [lwe](<https://devfeed.tech/tags/lwe.md>), [mathematics](<https://devfeed.tech/tags/mathematics.md>), [number-theory](<https://devfeed.tech/tags/number-theory.md>), [programming](<https://devfeed.tech/tags/programming.md>), [residue-number-system](<https://devfeed.tech/tags/residue-number-system.md>), [rlwe](<https://devfeed.tech/tags/rlwe.md>), [scaling](<https://devfeed.tech/tags/scaling.md>), [scheme](<https://devfeed.tech/tags/scheme.md>)

### AI overview

This article explains how cleartexts are transformed into plaintexts through encoding, and reversed through decoding, in homomorphic encryption. It catalogs encoding approaches for different HE schemes, including bit-field encoding for LWE and considerations for noise, scaling, bit positions, and programmable bootstrapping in CGGI/TFHE.

### Source excerpt

In cryptography, we need a distinction between a cleartext and a plaintext. A cleartext is a message in its natural form. A plaintext is a cleartext that is represented in a specific way to prepare it for encryption in a specific scheme. The process of taking a cleartext and turning it into a plaintext is called encoding, and the reverse is called decoding. In homomorphic encryption, the distinction matters. Cleartexts are generally all integers, though the bit width of allowed integers can be restricted (e.

## The Gadget Decomposition in FHE

DevFeed: [The Gadget Decomposition in FHE](<https://devfeed.tech/articles/the-gadget-decomposition-in-fhe-40450.md>)

Original publisher: [Read original article](<https://www.jeremykun.com/2021/12/11/the-gadget-decomposition-in-fhe/>)

Published: 2021-12-11T13:57:25Z

Content type: tutorial

Language: en

Sources: [Jeremy Kun](<https://devfeed.tech/sources/jeremy-kun.md>)

Topics: [FHE](<https://devfeed.tech/topics/fhe.md>), [homomorphic encryption](<https://devfeed.tech/topics/homomorphic-encryption.md>), [Cryptography](<https://devfeed.tech/topics/cryptography.md>), [Computing](<https://devfeed.tech/topics/computing.md>), [data](<https://devfeed.tech/topics/data.md>), [Code](<https://devfeed.tech/topics/code.md>), [GitHub](<https://devfeed.tech/topics/github.md>)

Tags: [bootstrapping](<https://devfeed.tech/tags/bootstrapping.md>), [core](<https://devfeed.tech/tags/core.md>), [encryption](<https://devfeed.tech/tags/encryption.md>), [fhe](<https://devfeed.tech/tags/fhe.md>), [gadget-decomposition](<https://devfeed.tech/tags/gadget-decomposition.md>), [group-theory](<https://devfeed.tech/tags/group-theory.md>), [homomorphic-encryption](<https://devfeed.tech/tags/homomorphic-encryption.md>), [learning-with-errors](<https://devfeed.tech/tags/learning-with-errors.md>), [linear-algebra](<https://devfeed.tech/tags/linear-algebra.md>), [lwe](<https://devfeed.tech/tags/lwe.md>), [mathematics](<https://devfeed.tech/tags/mathematics.md>), [matrix](<https://devfeed.tech/tags/matrix.md>), [number-theory](<https://devfeed.tech/tags/number-theory.md>), [operations](<https://devfeed.tech/tags/operations.md>), [programming](<https://devfeed.tech/tags/programming.md>), [python](<https://devfeed.tech/tags/python.md>)

### AI overview

A tutorial on gadget decomposition in fully homomorphic encryption (FHE). It explains how GSW and related schemes use random noise, how homomorphic operations increase that noise, why bootstrapping is needed, and how gadget decomposition helps limit noise growth.

### Source excerpt

Lately I've been studying Fully Homomorphic Encryption, which is the miraculous ability to perform arbitrary computations on encrypted data without learning any information about the underlying message. It's the most comprehensive private computing solution that can exist (and it does exist!). The first FHE scheme by Craig Gentry was based on ideal lattices and was considered very complex (I never took the time to learn how it worked). Some later schemes (GSW = Gentry-Sahai-Waters) are based on matrix multiplication, and are conceptually much simpler.

## Searching for RH Counterexamples -- Unbounded Integers

DevFeed: [Searching for RH Counterexamples -- Unbounded Integers](<https://devfeed.tech/articles/searching-for-rh-counterexamples-unbounded-integers-40440.md>)

Original publisher: [Read original article](<https://www.jeremykun.com/2020/10/13/searching-for-rh-counterexamples-unbounded-integers/>)

Published: 2020-10-13T09:00:00Z

Content type: article

Language: en

Sources: [Jeremy Kun](<https://devfeed.tech/sources/jeremy-kun.md>)

Topics: [Database](<https://devfeed.tech/topics/database.md>), [Python](<https://devfeed.tech/topics/python.md>), [Software Engineering](<https://devfeed.tech/topics/software-engineering.md>), [Numba](<https://devfeed.tech/topics/numba.md>), [Sorting](<https://devfeed.tech/topics/sorting.md>)

Tags: [arbitrary-precision-arithmetic](<https://devfeed.tech/tags/arbitrary-precision-arithmetic.md>), [database](<https://devfeed.tech/tags/database.md>), [databases](<https://devfeed.tech/tags/databases.md>), [mathematics](<https://devfeed.tech/tags/mathematics.md>), [numba](<https://devfeed.tech/tags/numba.md>), [number-theory](<https://devfeed.tech/tags/number-theory.md>), [open-closed](<https://devfeed.tech/tags/open-closed.md>), [postgres](<https://devfeed.tech/tags/postgres.md>), [python](<https://devfeed.tech/tags/python.md>), [riemann-hypothesis](<https://devfeed.tech/tags/riemann-hypothesis.md>), [software](<https://devfeed.tech/tags/software.md>), [software-engineering](<https://devfeed.tech/tags/software-engineering.md>), [sorting](<https://devfeed.tech/tags/sorting.md>), [superabundant-numbers](<https://devfeed.tech/tags/superabundant-numbers.md>)

### AI overview

This article examines how searching for Riemann Hypothesis counterexamples reaches the limits of 64-bit integers. It explains unbounded integer arithmetic and considers database and performance alternatives for storing and processing the search results.

### Source excerpt

We're ironically searching for counterexamples to the Riemann Hypothesis. Setting up Pytest Adding a Database Search strategies In the last article, we improved our naive search from "try all positive integers" to enumerate a subset of integers (superabundant numbers), which RH counterexamples are guaranteed to be among. These numbers grow large, fast, and we quickly reached the limit of what 64 bit integers can store. Unbounded integer arithmetic is possible on computers, but it requires a special software implementation.

## Searching for RH Counterexamples -- Adding a Database

DevFeed: [Searching for RH Counterexamples -- Adding a Database](<https://devfeed.tech/articles/searching-for-rh-counterexamples-adding-a-database-40437.md>)

Original publisher: [Read original article](<https://www.jeremykun.com/2020/09/11/searching-for-rh-counterexamples-adding-a-database/>)

Published: 2020-09-11T18:53:48Z

Content type: tutorial

Language: en

Sources: [Jeremy Kun](<https://devfeed.tech/sources/jeremy-kun.md>)

Topics: [Database](<https://devfeed.tech/topics/database.md>), [Software Engineering](<https://devfeed.tech/topics/software-engineering.md>), [Code](<https://devfeed.tech/topics/code.md>), [interface](<https://devfeed.tech/topics/interface.md>), [Testing](<https://devfeed.tech/topics/testing.md>), [Git](<https://devfeed.tech/topics/git.md>)

Tags: [code](<https://devfeed.tech/tags/code.md>), [database](<https://devfeed.tech/tags/database.md>), [databases](<https://devfeed.tech/tags/databases.md>), [dependency](<https://devfeed.tech/tags/dependency.md>), [git](<https://devfeed.tech/tags/git.md>), [interface](<https://devfeed.tech/tags/interface.md>), [mathematics](<https://devfeed.tech/tags/mathematics.md>), [number-theory](<https://devfeed.tech/tags/number-theory.md>), [oeis](<https://devfeed.tech/tags/oeis.md>), [programming](<https://devfeed.tech/tags/programming.md>), [riemann-hypothesis](<https://devfeed.tech/tags/riemann-hypothesis.md>), [software](<https://devfeed.tech/tags/software.md>), [software-design](<https://devfeed.tech/tags/software-design.md>), [sql](<https://devfeed.tech/tags/sql.md>), [testing](<https://devfeed.tech/tags/testing.md>)

### AI overview

This tutorial extends a Python application that computes divisor sums related to attempts to disprove the Riemann Hypothesis by adding a database dependency. It advocates defining and testing a minimal interface before choosing a database, so the dependency can change as the application evolves.

### Source excerpt

In the last article we set up pytest for a simple application that computes divisor sums $ \sigma(n)$ and tries to disprove the Riemann Hypothesis. In this post we'll show how to extend the application as we add a database dependency. The database stores the computed sums so we can analyze them after our application finishes. As in the previous post, I'll link to specific git commits in the final code repository to show how the project evolves.

## Searching for RH Counterexamples -- Setting up Pytest

DevFeed: [Searching for RH Counterexamples -- Setting up Pytest](<https://devfeed.tech/articles/searching-for-rh-counterexamples-setting-up-pytest-40438.md>)

Original publisher: [Read original article](<https://www.jeremykun.com/2020/09/11/searching-for-rh-counterexamples-setting-up-pytest/>)

Published: 2020-09-11T15:51:48Z

Content type: tutorial

Language: en

Sources: [Jeremy Kun](<https://devfeed.tech/sources/jeremy-kun.md>)

Topics: [Pytest](<https://devfeed.tech/topics/pytest.md>), [Python](<https://devfeed.tech/topics/python.md>), [Testing](<https://devfeed.tech/topics/testing.md>), [Code](<https://devfeed.tech/topics/code.md>), [Development](<https://devfeed.tech/topics/development.md>)

Tags: [development-environment](<https://devfeed.tech/tags/development-environment.md>), [git](<https://devfeed.tech/tags/git.md>), [github](<https://devfeed.tech/tags/github.md>), [mathematics](<https://devfeed.tech/tags/mathematics.md>), [number-theory](<https://devfeed.tech/tags/number-theory.md>), [programming](<https://devfeed.tech/tags/programming.md>), [project-organization](<https://devfeed.tech/tags/project-organization.md>), [pytest](<https://devfeed.tech/tags/pytest.md>), [python](<https://devfeed.tech/tags/python.md>), [riemann-hypothesis](<https://devfeed.tech/tags/riemann-hypothesis.md>), [setup](<https://devfeed.tech/tags/setup.md>), [shell](<https://devfeed.tech/tags/shell.md>), [software](<https://devfeed.tech/tags/software.md>), [testing](<https://devfeed.tech/tags/testing.md>)

### AI overview

A hands-on tutorial that sets up a Python 3.8 project with pytest and Git, using a search for counterexamples related to the Riemann Hypothesis as the example problem. It explains terminal-based project setup, testing, organization, and how design evolves during development.

### Source excerpt

Some mathy-programmy people tell me they want to test their code, but struggle to get set up with a testing framework. I suspect it's due to a mix of: There are too many choices with a blank slate. Making slightly wrong choices early on causes things to fail in unexpected ways. I suspect the same concerns apply to general project organization and architecture. Because Python is popular for mathy-programmies, I'll build a Python project that shows how I organize my projects and and test my code, and how that shapes the design and evolution of my software.

## Foobar, Blossoms, and Isomorphism

DevFeed: [Foobar, Blossoms, and Isomorphism](<https://devfeed.tech/articles/foobar-blossoms-and-isomorphism-22352.md>)

Original publisher: [Read original article](<https://yifan.lu/2017/09/13/foobar-blossoms-and-isomorphism/>)

Author: yifanlu

Published: 2017-09-13T07:00:00Z

Content type: tutorial

Language: en

Sources: [Yifan Lu](<https://devfeed.tech/sources/yifan-lu.md>)

Topics: [Programming](<https://devfeed.tech/topics/programming.md>), [Code](<https://devfeed.tech/topics/code.md>), [Google](<https://devfeed.tech/topics/google.md>)

Tags: [algorithm](<https://devfeed.tech/tags/algorithm.md>), [computer-science](<https://devfeed.tech/tags/computer-science.md>), [foobar](<https://devfeed.tech/tags/foobar.md>), [google](<https://devfeed.tech/tags/google.md>), [guards](<https://devfeed.tech/tags/guards.md>), [latex](<https://devfeed.tech/tags/latex.md>), [math](<https://devfeed.tech/tags/math.md>), [number-theory](<https://devfeed.tech/tags/number-theory.md>), [programming](<https://devfeed.tech/tags/programming.md>), [technical](<https://devfeed.tech/tags/technical.md>)

### AI overview

A detailed solution to Google Foobar's "Distract the Guards" problem. The article models when two guards enter an infinite loop and explains how maximum matching can pair the greatest possible number of guards into such loops.

### Source excerpt

A friend recently invited me to participate in Foobar, Google's recruiting tool that lets you solve interesting (and sometimes not-so-interesting) programming problems. This particular problem, titled "Distract the Guards" was very fun to solve but I found no good write-ups about it online! Solutions exist but it is rather hard to understand how the author came upon the solution. I thought I might take a shot and go into detail into how I approached it-as well as give proofs of correctness as needed.

## Beal's Conjecture Revisited

DevFeed: [Beal's Conjecture Revisited](<https://devfeed.tech/articles/beal-s-conjecture-revisited-40544.md>)

Original publisher: [Read original article](<http://norvig.com/beal.html>)

Published: 2015-10-20T00:00:00Z

Content type: article

Language: en

Sources: [Peter Norvig](<https://devfeed.tech/sources/peter-norvig.md>)

Topics: [floating-point](<https://devfeed.tech/topics/floating-point.md>)

Tags: [errors](<https://devfeed.tech/tags/errors.md>), [floating-point](<https://devfeed.tech/tags/floating-point.md>), [number-theory](<https://devfeed.tech/tags/number-theory.md>), [precision](<https://devfeed.tech/tags/precision.md>), [program](<https://devfeed.tech/tags/program.md>)

### AI overview

An update on a program that searches for counterexamples to Beal's Conjecture, explaining why apparent counterexamples caused by floating-point arithmetic are invalid. The page also catalogs common errors in purported proofs and counterexamples.

### Source excerpt

Updating the work I did in 2000 to search for counterexamples to Beal's Conjecture. Lists some of the things that people do wrong in trying to settle the conjecture.

## Learning a single-variable polynomial, or the power of adaptive queries

DevFeed: [Learning a single-variable polynomial, or the power of adaptive queries](<https://devfeed.tech/articles/learning-a-single-variable-polynomial-or-the-power-of-adaptive-queries-40370.md>)

Original publisher: [Read original article](<https://www.jeremykun.com/2014/11/18/learning-a-single-variable-polynomial-or-the-power-of-adaptive-queries/>)

Published: 2014-11-18T09:00:18Z

Content type: tutorial

Language: en

Sources: [Jeremy Kun](<https://devfeed.tech/sources/jeremy-kun.md>)

Topics: [Computing](<https://devfeed.tech/topics/computing.md>), [Algorithm](<https://devfeed.tech/topics/algorithm.md>), [Query (disambiguation)](<https://devfeed.tech/topics/query.md>)

Tags: [adaptive-queries](<https://devfeed.tech/tags/adaptive-queries.md>), [algorithm](<https://devfeed.tech/tags/algorithm.md>), [github](<https://devfeed.tech/tags/github.md>), [implementation](<https://devfeed.tech/tags/implementation.md>), [learning-theory](<https://devfeed.tech/tags/learning-theory.md>), [number-theory](<https://devfeed.tech/tags/number-theory.md>), [polynomial-identity-testing](<https://devfeed.tech/tags/polynomial-identity-testing.md>), [polynomial-interpolation](<https://devfeed.tech/tags/polynomial-interpolation.md>), [polynomials](<https://devfeed.tech/tags/polynomials.md>)

### AI overview

This tutorial shows how adaptive queries can recover a secret single-variable polynomial with nonnegative integer coefficients using only two queries: p(1) and p(p(1)+1). It explains how modular arithmetic extracts the coefficients and contrasts this with the larger number of non-adaptive queries required by polynomial interpolation.

### Source excerpt

Problem: Alice chooses a secret polynomial $ p(x)$ with nonnegative integer coefficients. Bob wants to discover this polynomial by querying Alice for the value of $ p(x)$ for some integer $ x$ of Bob's choice. What is the minimal number of queries Bob needs to determine $ p(x)$ exactly? Solution: Two queries. The first is $ p(1)$, and if we call $ N = p(1) + 1$, then the second query is $ p(N)$.

## Ramsey Number Lower Bound

DevFeed: [Ramsey Number Lower Bound](<https://devfeed.tech/articles/ramsey-number-lower-bound-40293.md>)

Original publisher: [Read original article](<https://www.jeremykun.com/2012/12/02/ramsey-number-lower-bound/>)

Published: 2012-12-02T15:17:26Z

Content type: article

Language: en

Sources: [Jeremy Kun](<https://devfeed.tech/sources/jeremy-kun.md>)

Topics: [graph theory](<https://devfeed.tech/topics/graph-theory.md>), [Graphs](<https://devfeed.tech/topics/graphs.md>), [Mathematics](<https://devfeed.tech/topics/mathematics.md>)

Tags: [combinatorics](<https://devfeed.tech/tags/combinatorics.md>), [computational-complexity](<https://devfeed.tech/tags/computational-complexity.md>), [graph](<https://devfeed.tech/tags/graph.md>), [graph-coloring](<https://devfeed.tech/tags/graph-coloring.md>), [graph-theory](<https://devfeed.tech/tags/graph-theory.md>), [mathematics](<https://devfeed.tech/tags/mathematics.md>), [number-theory](<https://devfeed.tech/tags/number-theory.md>), [probabilistic-method](<https://devfeed.tech/tags/probabilistic-method.md>), [ramsey-numbers](<https://devfeed.tech/tags/ramsey-numbers.md>), [random-graph](<https://devfeed.tech/tags/random-graph.md>)

### AI overview

The article proves a lower bound for the diagonal Ramsey number R(m,m). By randomly coloring the edges of a complete graph, it shows that if binom(n,m)2^(1−binom(m,2)) is less than 1, there exists a coloring with no monochromatic m-vertex subgraph, so R(m,m) > n.

### Source excerpt

Define the Ramsey number $ R(k,m)$ to be the minimum number $ n$ of vertices required of the complete graph $ K_n$ so that for any two-coloring (red, blue) of the edges of $ K_n$ one of two things will happen: There is a red $ k$-clique; that is, a complete subgraph of $ k$ vertices for which all edges are red. There is a blue $ m$-clique. It is known that these numbers are always finite, but it is very difficult to compute them exactly.

## Number Theory--A Primer

DevFeed: [Number Theory--A Primer](<https://devfeed.tech/articles/number-theory-a-primer-40235.md>)

Original publisher: [Read original article](<https://www.jeremykun.com/2011/07/30/number-theory-a-primer/>)

Published: 2011-07-30T15:03:38Z

Content type: tutorial

Language: en

Sources: [Jeremy Kun](<https://devfeed.tech/sources/jeremy-kun.md>)

Topics: [primes](<https://devfeed.tech/topics/primes.md>), [Cryptography](<https://devfeed.tech/topics/cryptography.md>), [Encryption](<https://devfeed.tech/topics/encryption.md>)

Tags: [arithmetic](<https://devfeed.tech/tags/arithmetic.md>), [encryption](<https://devfeed.tech/tags/encryption.md>), [factoring](<https://devfeed.tech/tags/factoring.md>), [gcd](<https://devfeed.tech/tags/gcd.md>), [mathematics](<https://devfeed.tech/tags/mathematics.md>), [number](<https://devfeed.tech/tags/number.md>), [number-theory](<https://devfeed.tech/tags/number-theory.md>), [primer](<https://devfeed.tech/tags/primer.md>), [primes](<https://devfeed.tech/tags/primes.md>), [programming](<https://devfeed.tech/tags/programming.md>), [rsa](<https://devfeed.tech/tags/rsa.md>)

### AI overview

A primer on elementary number theory covering integers, divisibility, composite and prime numbers, prime factorization, and the greatest common divisor. It provides background for a separate post on RSA encryption.

### Source excerpt

This primer exists for the background necessary to read our post on RSA encryption, but it also serves as a general primer to number theory. Oh, Numbers, Numbers, Numbers We start with some easy definitions. Definition: The set of integers, denoted $ \mathbb{Z}$, is the set $ \left \{ \dots -2, -1, 0, 1, 2, \dots \right \}$. Definition: Let $ a,b$ be integers, then $ a$ divides $ b$, denoted $ a \mid b$, if there exists an integer $ n$ such that $ na = b$.