For three positive integers ai, aj, ak pairwise coprime, we present an algorithm that find the least multiple of ai that is a positive linear combination of aj, ak. The average running time of this algorithm is O(1). Using this algorithm and the chinese remainder theorem leads to a direct computation of the Frobenius number f(a1, a2, a3).
Deep Dive into On a problem of Frobenius in three numbers.
For three positive integers ai, aj, ak pairwise coprime, we present an algorithm that find the least multiple of ai that is a positive linear combination of aj, ak. The average running time of this algorithm is O(1). Using this algorithm and the chinese remainder theorem leads to a direct computation of the Frobenius number f(a1, a2, a3).
We begin with some facts and notation [2,5]. Let a 1 < a 2 < a 3 be relatively prime positive integers. It is well known that if n is sufficientely large integer the Diophantine equation
has solutions in positives integers x 1 , x 2 , x 3 and we say in this case that n is N-representable by a 1 , a 2 , a 3 . Let f(a 1 , • • • , a n ) be the largest integer not representable by the form (1) in positive integers. There are representation of f(a 1 , a 2 , a 3 ) for each i = 1, 2, 3 of the form [5]:
If a 1 , a 2 , a 3 are pairwise prime, we prove that in each representation above, there is only one term y ij a j that is N-representable by a i , a k . We give a simple algorithm that find the least multiple of a i that is representable by a j , a k . This method is very simple (few lines of code) and similar to euclidean algorithm. It compute f(a 1 , a 2 , a 3 ) for large number, we test it for numbers having thousand digits and the average running time is O(1) for pairwise prime triplet of unmbers.
There are other algorithms to compute f(a 1 , a 2 , a 3 ). The Davison algorithm [3] is based on the LLL lattice method. The elbows algorithm is [4] is based on the integer linear programming (ILP) method.
In section 2, we give semi-explicit representation of f(a i , a j , a k ) for pairwise coprime integers (a i , a j , a k ). We present in Section 3 our algorithm for computing the least multiple N-representable and prove that it terminates. Section 4 is devoted to randomized testing and average time needed for computation of f(a 1 , a 2 , a 3 )
Representation of f(a i , a j , a k )
For any ordering (i, j, k) of the set {1, 2, 3}, let (a i , a j , a k ) three integers relatively prime. It is no restriction to assume that (a i , a j , a k ) are pairwise coprime and none of (a i , a j , a k ) is N-representable by the two others [2].
and suppose that
Then x j a j is the smallest multiple of a j that is N-representable by a i , a k
Proof. Suppose that f(a i , a j , a k ) have another representation:
And
Combining the two expressions, we can represent f(a i , a j , a k ) as:
so f(a i , a j , a k ) would be representable by a 1 , a 2 , a 3 , a contradiction to the definition of f(a i , a j , a k ).
Lemma 2.2. For each i let f(a i , a j , a k ) = y ij a j + y ik a k with (i, j, k) a permutation cycle of (1, 2, 3). Then either y ij a j is representable by (a i , a k ), or y ik a k representable by (a i , a j )
Proof. Reresent f(a i , a j , a k ) as: Consider now integers n that is not N-representable by a 1 , a 2 , a 3 but is N-representable by any couples (a j , a k ):
In the first right expression above, suppose u 12 a 2 N-representable by a 1 , a 3 . Lemma 2.2, implies that the N-representable term for the third expressions must be u 31 a 1 , and consequently the term N-representable for the second expression u 21 a 1 . This give us a first decomposition of n. An other decomposition is given when we suppose u 13 a 3 N-representable in the first right expression. Finally, such integers n have exactly two possible decompositions.
To compute f(a, b, c) consider the two congruent systems:
mod a 2 Solutions of the two congruent systems are given by the chinese remainder theorem and f(a, b, c) is maximum of the two solutions.
3 Least multiple of b N-representable by a, c Algorithm (Find least multiple representable).We are given three integers a, b, c pairwise prime. This algorithm find the least multiple of b that is N-representable by (a, c). where
p 1 = k 1 p 0 mod c, p i ≡ k i p i-1 mod p i-2 , i 2 (13)
a 2 , a 3 ) = y 12 a 2 + y 13 a 3 = y 21 a 1 + y 23 a 3 = y 31 a 1 + y 32 a 2 , y ij > 0, i, j = 1, 2, 3 (8)
This content is AI-processed based on ArXiv data.