Available online at www.sciencedirect.com a f s b f u t o o © T K ScienceDirect Indagationes Mathematicae 34 (2023) 1373–1396 www.elsevier.com/locate/indag Three essays on Machin’s type formulas Armengol Gasulla, Florian Lucab,c, Juan L. Varonad,∗ Dep. de Matemàtiques, Universitat Autònoma de Barcelona and Centre de Recerca Matemàtica, Cerdanyola del Vallès (Barcelona), Spain b School of Maths, Wits University, Johannesburg, South Africa c Centro de Ciencias Matemáticas, UNAM, Morelia, Mexico d Departamento de Matemáticas y Computación, Universidad de La Rioja, Logroño, Spain Received 1 February 2023; received in revised form 13 July 2023; accepted 16 July 2023 Communicated by P. Moree Abstract We study three questions related to Machin’s type formulas. The first one gives all two terms Machin ormulas where both arctangent functions are evaluated 2-integers, that is values of the form b/2a for ome integers a and b. These formulas are computationally useful because multiplication or division y a power of two is a very fast operation for most computers. The second one presents a method or finding infinitely many formulas with N terms. In the particular case N = 2 the method is quite seful. It recovers most known formulas, gives some new ones, and allows to prove, in an easy way, that here are two terms Machin formulas with Lehmer measure as small as desired. Finally, we correct an versight from previous result and give all Machin’s type formulas with two terms involving arctangents f powers of the golden section. 2023 The Author(s). Published by Elsevier B.V. on behalf of Royal Dutch Mathematical Society (KWG). his is an open access article under the CC BY license (http://creativecommons.org/licenses/by/4.0/). eywords: Machin’s type formulas; Lehmer measure; Computation of π ; Golden section 1. Introduction In 1706, John Machin found the identity 4 arctan 1 5 − arctan 1 239 = π 4 . (1) ∗ Corresponding author. E-mail addresses: Armengol.Gasull@uab.cat (A. Gasull), florian.luca@wits.ac.za (F. Luca), jvarona@unirioja.es (J.L. Varona). https://doi.org/10.1016/j.indag.2023.07.002 0019-3577/© 2023 The Author(s). Published by Elsevier B.V. on behalf of Royal Dutch Mathematical Society (KWG). This is an open access article under the CC BY license (http://creativecommons.org/licenses/by/4.0/). http://www.elsevier.com/locate/indag https://doi.org/10.1016/j.indag.2023.07.002 http://www.elsevier.com/locate/indag http://crossmark.crossref.org/dialog/?doi=10.1016/j.indag.2023.07.002&domain=pdf http://creativecommons.org/licenses/by/4.0/ mailto:Armengol.Gasull@uab.cat mailto:florian.luca@wits.ac.za mailto:jvarona@unirioja.es https://doi.org/10.1016/j.indag.2023.07.002 http://creativecommons.org/licenses/by/4.0/ A. Gasull, F. Luca and J.L. Varona Indagationes Mathematicae 34 (2023) 1373–1396 d o c t t M o i w i w ( w t t c T In conjunction with the arctan expansion arctan x = ∞∑ m=0 (−1)m 2m + 1 x2m+1, |x | < 1, (2) iscovered by Gregory in 1671, Machin used (1) to compute 100 digits of π . In the mathematical literature there are many formulas similar to (1), that is, combinations f arctan functions that, in some way, generate π . Besides (1), the following are the most lassical formulas arctan(1/2) + arctan(1/3) = π/4, (3) 2 arctan(1/2) − arctan(1/7) = π/4, (4) 2 arctan(1/3) + arctan(1/7) = π/4, (5) hat are usually known as Euler’s, Hermann’s and Hutton’s formulas, respectively (actually, heir attribution to these authors is not clear; for instance, [7] also attributes all of them to achin, see [23] for more historical details). While many of these formulas have been used to effectively compute many digits of π , ther formulas do not have such practical interest, but they are interesting by themselves. For nstance, this is the case with the relation arctan Fn Fn+1 + arctan Fn−1 Fn+2 = π 4 , (6) here (Fn)n are the Fibonacci numbers (a simple geometric proof of this formula can be found n [18]). Moreover, taking into account that when n → ∞, Fn/Fn−1 → φ := (1 + √ 5)/2, the golden section, taking limits in (6) gives the identity arctan φ−1 + arctan φ−3 = π 4 . (7) Many questions can be posed around this subject. A first natural one was: How many formulas of the type x1 arctan 1 m1 + x2 arctan 1 m2 = π 4 , (8) ith rationals xk and integers mk ≥ 2 there exist? Nowadays, after 1895 Störmer’s paper [20] see also [21]) it is known that only the four above identities (1), (3), (4) and (5) do exist. How about if we allow identities of the type x1 arctan a1 b1 + · · · + xN arctan aN bN = π 4 , (9) ith xk ∈ Q, ak ∈ Z, bk ∈ N∗ (and |ak/bk | < 1 to guarantee the convergence of (2) with x = ak/bk), are there many other such formulas? Which of them gives a faster algorithm to compute digits of π? In 1938, D. H. Lehmer [15] gave the now so-called Lehmer measure N∑ k=1 1 log10(|bk/ak |) , (10) hat can be used as a hint of the computational efficiency of (9); without explaining the details hat motivate the definition, note that, if |ak/bk | is small, the series (2) for arctan(ak/bk) onverges quickly, and less summands are necessary to compute it with a prescribed precision. hus, the smaller is the Lehmer measure, the faster is the corresponding algorithm to compute 1374 A. Gasull, F. Luca and J.L. Varona Indagationes Mathematicae 34 (2023) 1373–1396 i s c d w t “ t t a o digits of π . Many formulas of type (9) with their corresponding Lehmer measures can be found in [10,15,24]. For instance, the Lehmer measure of (1) is 1.85113 and thus it is faster than (3), (4) and (5), whose Lehmer measures are, respectively, 5.41783, 4.50522 and 3.2792; moreover, both [10] and [24] give the same identity of type (9), with N = 6, and whose Lehmer measure s 1.51244, the lowest at that time. Are there Machin-like formulas with Lehmer measure as mall as we want? Nowadays, the use of this type of formulas to compute many digits of π is not so useful, because faster types of algorithms are available (for instance, Chudnovsky algorithm [11], which is based on Ramanujan’s π formulas; for more details on these types of algorithms see [14]). Actually, more than 1015 decimal digits of π are already known. Moreover, to ompute more digits of π does not have any practical interest, but the one of beating records. In relation to (7), a different question can be asked: are there similar formulas with other powers of φ? The aim of this paper is to answer some of the above questions. In Section 2, we analyze the solutions of an equation similar to (8) but allowing arctan(2ak /mk) or arctan(mk/2ak ) in the place of arctan(1/mk). We prove that there are ten sporadic Machin-type formulas of this type, together with two parametric families, see Theorem 1. Let us comment why the interest of having 2ak /mk or mk/2ak instead of ak/bk in general (we assume here that ak, bk, mk are positive integers). Let us assume that we want to compute many summands in (2), to get many digits of π . If we have x = 1/mk , every summand requires to divide by 2m + 1 and by m2 k (two operations); if we have x = ak/bk , a division by 2m + 1 and by b2 k and a multiplication by a2 k (three operations). Due to this reason, most of the Machin-like formulas to compute π that have been used in the practice (or whose Lehmer measure have been analyzed in the above mentioned papers [10,15,24]) are of the form 1/mk . But, if we have 2ak /mk or mk/2ak , to multiply or to divide by 2ak can be done with a shift in the binary representation of the number, whose computational time is negligible compared with a multiplication or a division, so this case can be considered as fast as the case with 1/mk . Thus, perhaps a better way to estimate the computational efficiency of a formula like (9) would be to take N∑ k=1 wk log10(|bk/ak |) with some “weights” wk ≥ 1 that may depend on ak , and bk (as well as on the hardware and the software), so it not totally clear how to compare such formulas. In Section 3 we define some rational functions R j (n, x) (both the numerator and the enominator being polynomials in the variable x depending on n and with integer coefficients), j = 0, 1, 2, 3 and n ∈ N, in such a way that, for any x ∈ Q, the combinations x1 arctan(R j1 (n1, x)) + · · · + xN arctan(R jN (nN , x)), ith xk = rk/nk and r1 + · · · + rN = 0, always give a rational multiple of π (we ignore he poles, namely the values of x that are roots of any denominator). We have used the name Machin’s formulas machine” to denominate this method, because it allows finding Machin’s ype formulas without any difficulty. In particular, taking N = 2, it allows us to find Machin’s ype formula with Lehmer measure as small as we want, see Theorem 3. As we will comment t the end of Section 3.3 our Machin’s type formulas when N = 2 extend some of the results f [4]. 1375 A. Gasull, F. Luca and J.L. Varona Indagationes Mathematicae 34 (2023) 1373–1396 w i s k l o s k T r t t R w t 2 g Finally, in Section 4, we classify the formulas of the type x1 arctan(φa1 ) + x2 arctan(φa2 ) = π 4 , ith ak ∈ Z\{0} and xk ∈ Q\{0}, showing that there are, essentially, sixteen of these identities. In fact, this part is a correction of the previous paper [17] where some of these formulas were missed due to an oversight in the proof. 2. Machin’s formulas with powers of two The purpose of this section is to solve x1 arctan(z1) + x2 arctan(z2) = π 4 (11) n rational numbers x1, x2, z1, z2, where zk ∈ (0, 1) for k = 1, 2 and zk = 2ak /bk or bk/2ak for ome integers ak, bk ≥ 1. The case where ak ≤ 0 for both k = 1, 2 leads to zk = 1/mk for = 1, 2, and this has been treated [21]. We do not treat the case when z1 = z2 = z, since that eads to arctan(z)/π ∈ Q \ {0}, and the only corresponding value of z is 1. So, we assume that z1 < z2. In case ak ≤ 0, we incorporate 2−ak into bk . Hence, we assume that ak ≥ 0 and bk is dd unless ak = 0 in which case bk can be even. As we will see, a main tool in the proof of next theorem will be that all positive integer olutions (x, y, a, n), n ≥ 3, of the diophantine equations x2 + 1 = 2yn and x2 + 2a = yn , are nown, see [13,16]. heorem 1. All solutions (x1, z1, x2, z2) of Eq. (11) in non-zero rational numbers x1, x2 and ational numbers z1 < z2 in (0, 1) of the form 2ak /bk or bk/2ak for k = 1, 2 are the following en sporadic ones( −1, 1 239 , 4, 1 5 ) , ( −1, 1 7 , 2, 1 2 ) , ( −1, 2 11 , 3 2 , 3 4 ) ,( −1, 2 11 , 3, 1 3 ) , ( 1 3 , 1 239 , 4 3 , 2 3 ) , ( 1 2 , 2 11 , 3 2 , 1 2 ) ,( 1, 1 41 , 2, 2 5 ) , ( 1, 1 7 , 2, 1 3 ) , ( 1, 1 2 , 1 2 , 3 4 ) , ( 3, 1 7 , 2, 2 11 ) , ogether with the two parametric families( 1, 1 2a2+1 + 1 , 1, 2a2 2a2 + 1 ) , ( 1, 1 2a2+1 − 1 , 1, 2a2 − 1 2a2 ) , a2 ∈ N∗. emark. Allowing a2 = 0 in the first parametric family we get the solution ( 1, 1 3 , 1, 1 2 ) hich also belongs to the second parametric family (for a2 = 1). We cannot allow a2 = 0 in he second family because z2 vanishes in this case. .1. A reformulation We write xk = uk/(w/d0), where u1, u2, d0 ≥ 1 are integers with |u1|, |u2|, d0, w ≥ 1 and cd(u1, u2) = 1 and so u1 arctan(z1) + u2 arctan(z2) = wπ = cπ . (12) 4d0 d 1376 A. Gasull, F. Luca and J.L. Varona Indagationes Mathematicae 34 (2023) 1373–1396 w d s a t T w E w 2 a a w c d w i T Formally, we write first x1 = U1/w, x2 = U2/w, with a common denominator w, then let d0 = gcd(U1, U2), so u1 = U1/d0, u2 = U2/d0. We write w/(4d0) = c/d ̸= 0 in reduced terms. Applying tan, we get that tan(cπ/d) ∈ Q. In particular, this implies that e2ciπ/d ∈ Q[i], so e2ciπ/d is a root of unity of order at most 2. This implies that ϕ(d) ≤ 2, so d ∈ {1, 2, 3, 4, 6}, here ϕ is the Euler’s totient function. In fact, by using [7, Cor. 3], it can be seen that ∈ {1, 2, 4}, but we will not use this fact because this stronger restriction does not imply substantial changes in our proof and in this way our argument is more self-contained. To fix notations, we assume that a1 ≤ a2 and we do not consider the case a1 = a2 = 0, since those olutions have already been found in [21]. Thus, a2 ≥ 1. 2.2. Proof of Theorem 1 Assume for the sake of the argument that z1 = 2a1/b1, z2 = 2a2/b2. The cases where zk = bk/2ak for one or both of k = 1, 2, can be reduced to the present one via the formula arctan ( 1 x ) = π 2 − arctan(x), rriving to an equation similar to (12) with a different value of c/d in the right-hand side. Up o replacing (u1, u2) by (−u1, −u2) if needed, we assume that u1 ≥ 1. Noting that d | 12, it follows that 12/d ∈ N. Next, we get (1 + i2a1/b1)12u1 (1 + i2a2/b2)12u2 = (1 − i2a1/b1)12u1 (1 − i2a2/b2)12u2 . hus, (b1 + i2a1 )12u1 (b2 ± i2a2 )12|u2| = (b1 − i2a1 )12u1 (b2 ∓ i2a2 )12|u2|, here the sign in ± on the left is sgn(u2) (and the sign in ∓ on the right is − sgn(u2)). xtracting 12th roots we get (b1 + i2a1 )u1 (b2 ± i2a2 )|u2| = ζ (b1 − i2a1 )u1 (b2 ∓ i2a2 )|u2|, here ζ is a root of unity in Q[i]. Hence, ζ ∈ {±1, ±i}. .2.1. The case a1 ≥ 1 Assume first that a1 ≥ 1. Then b1 +2a1 i and b1 −2a1 i are coprime in Z[i] since their norms re b2 1 + 22a1 (odd) but the norm of their difference 2a1+1i is a power of 2 and the same is true bout b2 + 2a2 i and b2 − 2a2 i . It follows up to relabeling ζ that (b1 + 2a1 i)u1 = ζ (b2 ∓ 2a2 i)|u2|, here ζ is unit in Z[i]. Thus, ζ ∈ {±1, ±i}. If u1 = |u2|, then 1 = u1 = |u2| (since they are oprime) so b1 + 2a1 i = ζ (b2 ∓ 2a2 i), so we get b1 = b2, a1 = a2, so z1 = z2, a case that we o not consider. So, we assume that u1 ̸= |u2|. Then there exists γ ∈ Z[i] such that b1 + 2a1 i = ζ1γ |u2| and b2 ∓ 2a2 i = ζ2γ u1 , here again ζ1, ζ2 are in {±1, ±i}. Assume next that {u1, |u2|} = {1, 2}. Swapping u1 and |u2| f needed and incorporating ζ1 into γ we get b1 + 2a1 i = γ and b2 ∓ 2a2 i = ±ζ2γ 2. hus, b ∓ 2a2 i = ζ (b + 2a1 i)2 = ζ (b2 − 22a1 + 2a1+1b i), ζ ∈ {±1, ±i}. 2 2 1 2 1 1 2 1377 A. Gasull, F. Luca and J.L. Varona Indagationes Mathematicae 34 (2023) 1373–1396 T s f a T 2 t T s a n γ u w a Since b2 and b2 1−22a1 are both odd, we get that ζ2 ∈ {±1}, 2a2 = 2a1+1b1 and b2 = ±(b2 1−22a1 ). he first equation leads to a2 = a1 +1, b1 = 1, and now the second leads to b2 = ±(12 −22a1 ), o b2 = 22a1 − 1. This leads to 2 arctan ( 1 2a1 ) − arctan ( 2a1+1 22a1 − 1 ) = 0, which follows from the well-known formula 2 arctan(x) = arctan ( 2x 1 − x2 ) , or x ∈ (−1, 1), with x = 1/2a1 . When a1 = 1 the above formula gives rise to the solution (1, 1 2 , 1 2 , 3 4 ). For a1 > 1 this looks like (12) except that it has c/d = 0, which is not convenient for us. This was for a1 ≥ 1 and {u1, |u2|} = {1, 2}. Up to swapping u1, u2, we next assume that |u2| ≥ 3. Then b1 + 2a1 i = ζ1γ |u2|. Taking norms we get b2 1 + 22a1 = y|u2|. The solutions of the equation x2 + 2a = yn, with x odd and n ≥ 3, have been found in [16]. They are 52 + 2 = 33, 112 + 22 = 53, 72 + 25 = 34. Only the second one is convenient for us (the exponent of 2 must be even) giving b1 = 11, 1 = 1, u2 = ±3. Thus, γ = 1 + 2i and u1 ∈ {1, 2}. Hence, we must also have b2 ∓ 2a2 i = ζ2(1 ± 2i)1,2 ∈ {ζ2(1 ± 2i), ζ2(−3 ± 4i)}. hus, we get ζ2 ∈ {±1}, (b2, a2) ∈ {(1, 1), (3, 2)}. .2.2. The case a1 = 0 In case b1 is even, the same arguments apply because b1 + i and b1 − i are coprime since heir norm is b2 1 + 1 (odd) and the norm of their difference 2i is 4 which is a power of 2. he previous arguments apply. We get (u1, u2) = (1, ±1) and (b1, a1) = (b2, a2) which leads z1 = z2 which is not convenient. The case (u1, |u2|) = (1, 2) does not lead to convenient olutions since b2 = 22a1 − 1 = 0, which is not possible. The case max{u1, |u2|} ≥ 3, leads gain to x2 + 22a = yn , where (x, a) = (bk, ak) for some k ∈ {1, 2}. This equation has o solution with a = 0, so we get (b2, a2, u1) = (11, 1, 3). Hence, |u2| ∈ {1, 2}, a1 = 0, = 1 + 2i , so b1 + i = ζ1γ 1,2 ∈ {ζ1(1 + 2i), ζ1(−3 + 4i)}, so the only possibility is b1 = 2, 2 = ±1. Finally suppose that a1 = 0, b1 is odd. In this case in (b1 + i)4u1 (b2 ± 2a2 i)4|u2| = (b1 − i)4u1 (b2 ∓ 2a2 i)4|u2|, e have that b1 + i has norm b2 1 + 1 ≡ 2 (mod 8). Thus, 1 + i | b1 + i and (b1 + i)/(1 + i) is n integer in Z[i] of odd norm. Thus,( b1 + i )4u1 (b2 ± 2a2 i)4|u2| = ( b1 − i )4u1 (b2 ∓ 2a2 i)4|u2|. 1 + i 1 − i 1378 A. Gasull, F. Luca and J.L. Varona Indagationes Mathematicae 34 (2023) 1373–1396 2 f I W T w O y a g w T A n o I Now the integer (b1 + i)/(1 + i) is coprime to (b1 − i)/(1 − i) (since they have odd norms and is linear combination of the above two integers with coefficients in Z[i]), so we get that( b1 + i 1 + i )4u1 = ζ (b2 ∓ 2a2 i)4|u2|, or some unit ζ in Z[i]. Thus, there is γ ∈ Z[i] and two units ζ1, ζ2 such that b1 + i 1 + i = ζ1γ |u2| and b2 ∓ 2a2 i = ζ2γ u1 . (13) f u1 = |u2|, then u1 = |u2| = 1. In this case we get b1 + i = ζ (1 + i)(b2 ∓ 2a2 i) = ζ (b2 ± 2a2 + i(b2 ∓ 2a2 )), ζ ∈ {±1, ±i}. e study the four possibilities. If ζ = ±1, we then get b1 + i = ±(b2 ± 2a2 + i(b2 ∓ 2a2 )). his gives b1 = ±(b2 ± 2a2 ), 1 = ±(b2 ∓ 2a2 ), hich correspond to the systems{ b1 = b2 + 2a2 , 1 = b2 − 2a2 , { b1 = b2 − 2a2 , 1 = b2 + 2a2 , { b1 = −(b2 + 2a2 ), 1 = −(b2 − 2a2 ), { b1 = −(b2 − 2a2 ), 1 = −(b2 + 2a2 ). nly the first system gives the acceptable solution b2 = 2a2 + 1, b1 = b2 + 2a2 = 2a2+1 + 1 ielding the first parametric family together with the solution with a2 = 0, which is ( 1, 1 3 , 1, 1 2 ) nd which is also a member of the second parametric family. The other three systems do not ive acceptable solutions since one (or both) of b1, b2 are negative. Assume next that ζ = ±i . We obtain b1 = ∓(b2 ∓ 2a2 ), 1 = ±(b2 ± 2a2 ), which correspond to the systems{ b1 = −b2 + 2a2 , 1 = b2 + 2a2 , { b1 = −b2 − 2a2 , 1 = b2 − 2a2 , { b1 = b2 − 2a2 , 1 = −b2 − 2a2 , { b1 = b2 + 2a2 , 1 = −b2 + 2a2 , here only the last one gives the acceptable solution b2 = 2a2 − 1, b1 = b2 + 2a2 = 2a2+1 − 1. his yields the second parametric family, after using arctan(x) = π/2 − arctan(1/x) for x > 0. gain the other three systems do not give convenient solutions since one or both of b1, b2 are egative. Assume next that u1 ̸= |u2|. If (u1, |u2|) ∈ {(2, 1), (1, 2)}, then we get equations b1 + i 1 + i = γ and b2 ± 2a2 i = ζ2γ 2, r b2 ± 2a2 i = γ and b1 + i 1 + i = ζ1γ 2. n the first case, we get b2 ± 2a2 i = ζ ( b1 + i )2 = ζ ′ (b2 1 − 1 + 2b1i) (with ζ ′ := −iζ ), 1 + i 2 1379 A. Gasull, F. Luca and J.L. Varona Indagationes Mathematicae 34 (2023) 1373–1396 b I W o T T s f w w s n ζ o T which gives b2 = b1, 2a2+1 = b2 1 − 1. The only solution of the last equation above is a2 = 2, 1 = b2 = 3. This leads to the useless formula 2 arctan ( 1 3 ) − arctan ( 3 4 ) = 0. n the second case, we get b1 + i = ζ (1 + i)(b2 ∓ 2a2 i)2 = ζ (1 + i)(b2 2 − 22a2 ∓ 2a2+1b2i) = ζ (b2 2 − 22a2 ± 2a2+1b2 + (b2 2 − 22a2 ∓ 2a2+1b2)i). hen ζ = ±1, we find b2 2 − 22a2 ± 2a2+1b2 = b1, b2 2 − 22a2 ∓ 2a2+1b2 = 1, r b2 2 − 22a2 ± 2a2+1b2 = −b1, b2 2 − 22a2 ∓ 2a2+1b2 = −1. he first case gives rise to the system{ (b2 ± 2a2 )2 − 22a2+1 = b1, (b2 ∓ 2a2 )2 = 22a2+1 + 1. his is solvable in integers only when a2 = 1. In this case, we find{ (b2 + 2)2 − 8 = b1, (b2 − 2)2 = 9, { (b2 − 2)2 − 8 = b1, (b2 + 2)2 = 9, o from (b2 − 2)2 = 9, we have the only acceptable solution b2 = 5, therefore b1 = 41, while rom (b2 + 2)2 = 9, we have the only acceptable solution b2 = 1, but this leads to b1 = −7, hich is not acceptable. On the other hand the second case corresponds to{ (b2 ± 2a2 )2 − 22a2+1 = −b1, (b2 ∓ 2a2 )2 = 22a2+1 − 1, hich is solvable in integers only when a2 = 0. In this case we find{ (b2 + 1)2 − 2 = −b1, (b2 − 1)2 = 1, { (b2 − 1)2 − 2 = −b1, (b2 + 1)2 = 1, o from (b2 − 1)2 = 1, we have the only acceptable solution b2 = 2, so b1 = −7, which is ot acceptable, while from (b2 + 1)2 = 1 we do not have acceptable solutions. Finally, when = ±i , we find b2 2 − 22a2 ∓ 2a2+1b2 = −b1, b2 2 − 22a2 ± 2a2+1b2 = 1, r b2 2 − 22a2 ∓ 2a2+1b2 = b1, b2 2 − 22a2 ± 2a2+1b2 = −1. he first case gives rise to the system{ (b2 ∓ 2a2 )2 − 22a2+1 = −b1, a2 2 2a2+1 (b2 ± 2 ) = 2 + 1, 1380 A. Gasull, F. Luca and J.L. Varona Indagationes Mathematicae 34 (2023) 1373–1396 s f w w s f T 2 t t f I a v o k B 3 which is solvable in integers only when a2 = 1. Accordingly, we find{ (b2 − 2)2 − 8 = −b1, (b2 + 2)2 = 9, { (b2 + 2)2 − 8 = −b1, (b2 − 2)2 = 9, o from (b2 + 2)2 = 9 we have the only acceptable solution b2 = 1, therefore b1 = 7, while rom (b2 − 2)2 = 9 we have the only acceptable solution b2 = 5 but this leads to b1 = −41, hich is not acceptable. On the other hand the second case corresponds to{ (b2 ± 2a2 )2 − 22a2+1 = b1, (b2 ∓ 2a2 )2 = 22a2+1 − 1, hich is solvable in integers only when a2 = 0. In this case, we find{ (b2 + 1)2 − 2 = b1, (b2 − 1)2 = 1, { (b2 − 1)2 − 2 = b1, (b2 + 1)2 = 1, o from (b2 − 1)2 = 1 we have the only acceptable solution b2 = 2, therefore b1 = 7, while rom (b2 + 1)2 = 1, we do not have acceptable solutions. Resuming this discussion, we find (a2, b1, b2) ∈ {(0, 7, 2), (1, 7, 1), (1, 41, 5)}. he first two instances lead to the same sporadic solution ( −1, 1 7 , 2, 1 2 ) as 2a1/b1 = 1/7 and a2/b2 ∈ {1/2, 2}, namely the second one in the list from the statement of the theorem, while he third instance leads to the seventh sporadic solution ( 1, 1 41 , 2, 2 5 ) from the statement of the theorem. Finally, assume that max{u1, |u2|} ≥ 3. In this case taking norms in (13) we get b2 1 + 1 = 2yu1 and b2 2 + 22a2 = y|u2|. If |u2| ≥ 3, then we saw before that b2 = 11, a2 = 1 are the only possibilities and then y = 5. If this is so and u1 ∈ {1, 2}, we get b2 1 + 1 ∈ {2 · 5, 2 · 52 }, so b1 ∈ {3, 7}. Finally, if u1 ≥ 3, hen we get the equation b2 1 + 1 = 2yn, or some n ≥ 3, and the only solutions are (b1, y, n) ∈ {(1, 1, n), (239, 13, 4)} (see [13]). The first one gives no solution for b2 2 + 22a2 = y|u2| = 1. The second one gives u1 = 4, b1 = 239. f also |u2| ≥ 3, then u2 = ±3, b2 = 11, a2 = 1, otherwise u2 ∈ {±1, ±2}, and b2 ± 2a2 i = ζ (3 ± 2i)1,2 ∈ {ζ (3 ± 2i), ζ (5 ± 12i)}, nd the only convenient one is u2 ∈ {±1}, b2 = 3, a2 = 1. Collecting all the intermediary alues, we get the theorem modulo checking for the solutions to (12) which come from values f the parameters (u1, u2, a1, b1, a2, b2, c/d) in the ranges |uk | ≤ 4, ak ∈ {0, 1, 2} for both = 1, 2, d ∈ {1, 2, 3, 4, 6}, 0 < |c| ≤ 24 and bk ∈ {1, 2, 3, 5, 7, 11, 41, 239} for k = 1, 2. oth Mathematica and Maple codes returned the ten listed sporadic solutions. . The Machin’s formulas machine An easy way to prove well-known formulas as arctan(x) + arctan(1/x) = sgn(x)π/2 or arctan(x) − 1 2 arctan ( 2x 1 − x2 ) = ⎧⎪⎨⎪⎩ π/2, if x > 1, 0, if |x | < 1, −π/2, if x < −1, 1381 A. Gasull, F. Luca and J.L. Varona Indagationes Mathematicae 34 (2023) 1373–1396 s f s T w w i k w t i or many others, is to use derivatives. For instance, we can check that the derivative of arctan ( 2x 1−x2 ) coincides with d dx arctan(x) = 1 1+x2 except for a multiplicative constant, so a uitable linear combination of arctan(x) and arctan ( 2x 1−x2 ) gives a function whose derivative is zero, therefore it is piecewise constant (namely it is constant except at the discontinuity points). More generally, we can find relations of the form arctan(x) + C arctan( f (x)) = constant if we have functions f (x) such that d dx arctan( f (x)) = r 1 + x2 , (14) or some constant r . Furthermore, it is easy to check that d dx arctan( f (x)) = r 1 + x2 , d dx arctan(g(x)) = s 1 + x2 H⇒ d dx arctan(g( f (x))) = rs 1 + x2 , (15) o the composition of functions satisfying (14) provides new examples. For differentiable functions, (14) is equivalent to solve the differential equation f ′(x) 1 + f (x)2 = k 1 + x2 . (16) he solutions of this equation are f (x) = tan(k arctan(x) + c), (17) ith f (0) = tan(c) and c ∈ (−π/2, π/2). For our interest concerning Machin-like formulas, e want to have functions which are rational; that is, are ratios of polynomials with coefficients n Z. Moreover, if we fix c and denote the solution of (16) by fk , the use of tan(a + b) = tan a + tan b 1 − (tan a)(tan b) gives fk+1(x) = tan ( (k arctan(x) + c) + arctan(x) ) = tan(k arctan(x) + c) + tan(arctan(x)) 1 − tan(k arctan(x) + c) tan(arctan(x)) = fk(x) + x 1 − x fk(x) . (18) From this relation, if f1(x) is a rational function for a certain c, every function fk(x) will be rational. But f1(x) = (tan(c) + x)/(1 − x tan(c)), so we want that tan(c) ∈ Q (or we start with f0(x) such that f0(x) = tan c, and we arrive at the same condition). So, we take c ∈ πQ. This is not compulsory, but it is suitable for our purposes. It is well nown that tan(c) ∈ Q if and only if tan(c) = 0 or ±1. Because tan is (−π/2, π/2)-periodic, e can restrict to one of the cases: c = 0, c = π/4, c = π/2 and c = −π/4 (or c = 3π/4, hat will be more convenient notationwise). The recurrence relation (18) is nice and could be more widely studied, but here we are only nterested in more explicit formulas. 1382 A. Gasull, F. Luca and J.L. Varona Indagationes Mathematicae 34 (2023) 1373–1396 A F w T a s 3.1. The functions R j (n, x) Let us recall De Moivre’s formula cos(nθ ) + i sin(nθ ) = (cos(θ ) + i sin(θ ))n. Using the binomial expansion and equaling imaginary and real parts we get sin(nθ ) = ⌊(n−1)/2⌋∑ r=0 (−1)r ( n 2r + 1 ) cosn−2r−1(θ ) sin2r+1(θ ) = cosn(θ ) ⌊(n−1)/2⌋∑ r=0 (−1)r ( n 2r + 1 ) tan2r+1(θ ), cos(nθ ) = ⌊n/2⌋∑ r=0 (−1)r ( n 2r ) cosn−2r (θ ) sin2r (θ ) = cosn(θ ) ⌊n/2⌋∑ r=0 (−1)r ( n 2r ) tan2r (θ ). nd, by dividing these expressions, tan(nθ ) = ∑⌊(n−1)/2⌋ r=0 (−1)r ( n 2r+1 ) tan2r+1(θ )∑⌊n/2⌋ r=0 (−1)r ( n 2r ) tan2r (θ ) . or θ = arctan(x), this becomes tan(n arctan x) = ∑⌊(n−1)/2⌋ r=0 (−1)r ( n 2r+1 ) x2r+1∑⌊n/2⌋ r=0 (−1)r ( n 2r ) x2r , so this is an example of (17) with c = 0; namely a rational function. By convenience, let us denote numern(x) = ⌊(n−1)/2⌋∑ r=0 (−1)r ( n 2r + 1 ) x2r+1, denomn(x) = ⌊n/2⌋∑ r=0 (−1)r ( n 2r ) x2r , ith numer0 = 0 and denom0 = 1. Then, for c = 0 in (17), we have R0(n, x) = numern(x) denomn(x) , n = 0, 1, 2, . . . . (19) he above functions satisfy d dx arctan(R0(n, x)) = n/(1 + x2). The first few of these functions re R0(0, x) = 0, R0(1, x) = x, R0(2, x) = −2x x2 − 1 , R0(3, x) = x3 − 3x 3x2 − 1 , R0(4, x) = −4x3 + 4x x4 − 6x2 + 1 , R0(5, x) = x5 − 10x3 + 5x 5x4 − 10x2 + 1 . For the other values of c, we take c = jπ/4 with j = 1, 2, 3, and denote the corresponding olutions of (17) by R1(n, x), R2(n, x) and R3(n, x), respectively. For c = π/2 = 2π/4 it is clear that tan(nθ + π/2) = sin(nθ + π/2) = − cos(nθ ) , cos(nθ + π/2) sin(nθ ) 1383 A. Gasull, F. Luca and J.L. Varona Indagationes Mathematicae 34 (2023) 1373–1396 T s T s O t i m f 3 o t − a a c so, for c = π/2, we have R2(n, x) = − denomn(x) numern(x) = −1 R0(n, x) , n = 1, 2, . . . . (20) he above functions satisfy again d dx arctan(R2(n, x)) = n/(1 + x2). For c = π/4, tan(nθ + π/4) = cos(nθ ) + sin(nθ ) cos(nθ ) − sin(nθ ) , o, for c = π/4, we have R1(n, x) = denomn(x) + numern(x) denomn(x) − numern(x) , n = 0, 1, 2, . . . . (21) he above functions satisfy again d dx arctan(R1(n, x)) = n/(1+ x2). For instance, R1(0, x) = 1, R1(1, x) = −x − 1 x − 1 , R1(2, x) = x2 − 2x − 1 x2 + 2x − 1 , R1(3, x) = −x3 − 3x2 + 3x + 1 x3 − 3x2 + 3x + 1 , R1(4, x) = x4 − 4x3 − 6x2 + 4x + 1 x4 + 4x3 − 6x2 − 4x + 1 , R1(5, x) = −x5 − 5x4 + 10x3 + 10x2 − 5x − 1 x5 − 5x4 − 10x3 + 10x2 + 5x − 1 . Finally, for c = 3π/4, tan(nθ + 3π/4) = tan(nθ − π/4) = sin(nθ ) − cos(nθ ) sin(nθ ) + cos(nθ ) , o, for c = 3π/4, we have the functions R3(n, x) = numern(x) − denomn(x) numern(x) + denomn(x) = −1 R1(n, x) , n = 0, 1, 2, . . . . (22) nce more, they satisfy d dx arctan(R3(n, x)) = n/(1 + x2). Actually, another way to define the functions R j (n, x), j = 0, 1, 2, 3, n ∈ N, is to take R j (n, x) = tan(nθ + jπ/4), x = tan θ; (23) his definition is valid in a small range of x (to ensure that both the functions tan and arctan are nvertible). Then the previous arguments show that these functions are rational functions, and, oreover, we have found their explicit expressions. Of course, once that we have a rational unction defined in a small interval, we can extend it to the entire C. .2. Some properties of the functions R j (n, x) Here we present some of the algebraic properties of the functions R j (n, x). Actually, some f these properties are not related to the Machine-like formulas, but they are interesting by hemselves. Let us first note that, because the function tan is odd, we could instead use the functions R j (n, x) for our purposes; actually, we could use R j (−n, x) to denote them, because rctan(−R j (n, x)) = −n/(1 + x2), a formula which holds by looking at (14). This would llow to index the functions R j (n, x) over n ∈ Z, but this fact does not have any practical ontribution to finding additional Machin-like formulas. 1384 A. Gasull, F. Luca and J.L. Varona Indagationes Mathematicae 34 (2023) 1373–1396 b T B f a a t a F w a w i f g l 3 m When handling Machin-like formulas, it is more interesting to observe that the relation etween R j (n, 1/x) and R j (n, x), depends on whether n is even or odd: R0(2n, 1/x) = −R0(2n, x), R0(2n + 1, 1/x) = 1/R0(2n + 1, x), n = 0, 1, 2, . . . , R1(2n, 1/x) = 1/R1(2n, x), R1(2n + 1, 1/x) = −R1(2n + 1, x), n = 0, 1, 2, . . . . (24) he proofs of these properties are straightforward, so we do not include them. In relation to R j (n, −x), some symmetry properties also hold: R0(n, −x) = −R0(n, x), R1(n, −x) = 1/R1(n, x), n = 0, 1, 2, . . . . (25) oth for (24) and for (25), the corresponding properties for R2 and R3 can be easily established rom the properties of R0 and R1 using (20) and (22), respectively. According to (15), the composition of the functions R j (n, x) generates new functions that re useful in relation to the Machin-like formulas. However, we can see that these functions re not really new. Let us start analyzing a particular case. Let us first observe that, if the “internal” function in the composition is R0, we have R j (nm, x) = tan(nm arctan(x) + π j/4) = tan(n arctan(tan(m arctan(x))) + π j/4) = tan(n arctan(R0(m, x)) + π j/4) = R j (n, R0(m, x)), j = 0, 1, 2, 3; his argument is correct in a small enough interval of x’s (to guarantee that arctan ◦ tan = Id), nd then by analytic continuation we can ensure that R j (nm, x) = R j (n, R0(m, x)), x ∈ C, j = 0, 1, 2, 3. (26) or each j , this formula allows to compute R j (n, x) as composition of successive R0(pi , x) ith a final R j (pi , x), where the pi are the prime factors of n. In particular, it is enough to know R j (p, x) for primes p in order to generate (or to compute) all the R j (n, x) by composition. With full generality, it is not difficult to check that the composition of functions R j behaves s follows: R j (n, Ri (m, x)) = Rin+ j mod 4(nm, x). Let us note that the relation R0(n, R0(m, x)) = R0(nm, x) of the functions R0 coincides ith the property Tn(Tm(x)) = Tnm(x) satisfied by the Chebyshev polynomials of the first kind Tn(x) := cos(n arccos(x)), x ∈ [−1, 1]. These were used in [5,12] in relation to the Möbius nversion formula. Finally, let us also mention that, although with a different notation, the unctions R0(n, x) have been already defined in [6] (in particular, their rational expressions are iven), but they have not been used to obtain Machin-like identities. As we will comment a ittle later, the functions R3(n, x) have been already introduced in [4] with a different approach. .3. Machin-like formulas associated to R j (n, x) Once we have defined the functions R j (n, x) and studied their properties, we can state the ain result of this section. Before doing that, let us observe the following: (a) At x = 0 or x = ±∞, the value of the function arctan(R j (n, x)) (perhaps in the sense of a limit) is always a rational multiple of π . 1385 A. Gasull, F. Luca and J.L. Varona Indagationes Mathematicae 34 (2023) 1373–1396 d i s o t T i l M w f t a ( T t M T (b) The functions arctan(R j (n, x)) are not defined at the roots of the denominator of R j (n, x). However, and because arctan(∞) − arctan(−∞) = π , it is clear that, at every x that is a root of the denominator of R j (n, x), the jump arctan(R j (n, x+)) − arctan(R j (n, x−)) is a multiple of π . Let us now take any function of the form F(x) = N∑ k=1 rk nk arctan(R jk (nk, x)) with N∑ k=1 rk = 0, (27) efined in R except at the roots of the denominators. Since d dx arctan(R j (n, x)) = n/(1 + x2), t is clear that F ′(x) = N∑ k=1 rk nk nk 1 + x2 = 0, o the function F(x) is piecewise constant (the continuity and the differentiability disappear nly at the roots of the denominators). Thus, as a consequence of (27), (a) and (b), we have he following result. heorem 2. Let R0(n, x), R1(n, x), R2(n, x) and R3(n, x) be the rational functions with nteger coefficients defined in (19), (21), (20) and (22), respectively, with n = 0, 1, 2, . . . , and et rk , k = 1, 2, . . . , N, be integers such that ∑N k=1 rk = 0. Then, for any x ∈ Q we have the achin-like formula N∑ k=1 rk nk arctan(R jk (nk, x)) = r s π, (28) ith r/s ∈ Q (notice that, as the R j (n, x) are rational functions with integer coefficients, the unctions arctan that appear in (28) are evaluated at rational values). Let us make some comments on this result. First observe that r/s is constant on intervals of he variable x , but the constant changes when any of the R j (n, x) involved in (28) has a root t the denominator. Figs. 1, 2 and 3 show, in a graphical way, three examples of the theorem they are simple examples, without any special interest). Observe that, with the notation of heorem 2, the coefficients of arctan in Fig. 1 should be written as 12 3 and −12 4 , respectively, o get r1 + r2 = 0; and the same in Fig. 2 with 91 13 and −91 7 . Actually, it can happen that F(x) in (27) (or the left-hand-side sum in (28)) is the constant zero function in some of those intervals, and then r/s = 0 in that interval; but, of course, this is not the usual situation. For instance, this happens around x = −1 in the case of Fig. 1. An important point is that, if we want to use (28) to evaluate π using the Taylor expansion (2), we need that the R jk (nk, x) satisfy |R jk (nk, x)| < 1. Let us now recall that R2(n, x) = −1 R0(n, x) and R3(n, x) = −1 R1(n, x) . (29) oreover, the function arctan satisfies arctan(−1/t) = − arctan(1/t) and arctan ( 1 t ) = sgn(t) π 2 − arctan(t). (30) hus, if we use instead R j ′ with the notation 0′ = 2, 1′ = 3, 2′ = 0 and 3′ = 1, in the case of (28) with a |R (n , x)| > 1 we can replace arctan(R (n , x)) by the corresponding jk k jk k 1386 A. Gasull, F. Luca and J.L. Varona Indagationes Mathematicae 34 (2023) 1373–1396 Fig. 1. The function 4 π ( 4 arctan(R3(3, x)) − 3 arctan(R0(4, x)) ) , for x ∈ (−5, 5). Fig. 2. The function 4 π ( 7 arctan(R3(13, x)) − 13 arctan(R0(7, x)) ) , for x ∈ (−5, 5). Fig. 3. The function 4 π ( 4 13 arctan(R3(13, x)) − 9 7 arctan(R0(7, x)) + 5 8 arctan(R1(8, x)) ) , for x ∈ (−5, 5). 1387 A. Gasull, F. Luca and J.L. Varona Indagationes Mathematicae 34 (2023) 1373–1396 c b f i a t c a w d c 3 i i w f arctan(R j ′k (nk, x)), that will satisfy |R j ′k (nk, x)| < 1, so we can use the Taylor expansion. (This annot be done if R jk (nk, x) = ±1, but to evaluate our expression in those x is of no interest ecause arctan(±1) = ±π/4, so the corresponding summand arctan(R jk (nk, x)) can be removed rom the formula.) The use of (30) in the above mentioned procedure that replaces R jk by R j ′k modifies the dentity (28) to a new identity of the same kind with all the |R j (n, x)| < 1. In this process, nd since arctan(−1/t) = − arctan(1/t), the corresponding rk in the condition ∑N k=1 rk = 0 on he coefficients becomes −rk . But, at the same time, the value of r/s changes; in particular, it an become to be 0 and in this case we get a useless Machin-like identity. Finally, we want to comment that Theorem 2 extends some of the results of [4], where the uthors prove that, for a positive integer n, n arctan ( 1 x ) + arctan (R3(n, x)) = r s π, ith r/s ∈ Q. Recall that R2(1, x) = −1/x and then this equality can also be written as − n 1 arctan (R2(1, x)) + n n arctan (R3(n, x)) = r s π, that is of the form (28). In that paper, the rational functions R3(n, x) are obtained in a very ifferent way. They are given via a recurrent relation between polynomials that are a particular ase of the so called Rédei polynomials, see [19]. .4. Some examples With the notation of the R j (n, x), the ten sporadic cases of Theorem 1 (in particular, this ncludes the four classical examples by Machin, Euler, Hermann and Hutton mentioned in the ntroduction) can be obtained, in the same order as in the theorem, as follows: 4 arctan(R0(1, x)) − arctan(R3(4, x)) = π/4, with x = 1/5, 2 arctan(R0(1, x)) − arctan(R3(2, x)) = π/4, with x = 1/2, − 3 2 arctan(R0(2, x)) + arctan(R3(3, x)) = π/4, with x = 3, − arctan(R0(3, x)) + 3 arctan(R3(1, x)) = π/4, with x = 2, 4 3 arctan(R0(1, x)) − 1 3 arctan(R1(4, x)) = π/4, with x = 2/3, 1 2 arctan(R0(3, x)) − 3 2 arctan(R2(1, x)) = π/4, with x = 2, 2 arctan(R0(1, x)) − arctan(R3(2, x)) = π/4, with x = 2/5, 2 arctan(R0(1, x)) − arctan(R3(2, x)) = π/4, with x = 1/3, − 1 2 arctan(R0(2, x)) + arctan(R3(1, x)) = π/4, with x = 3, 2 arctan(R0(3, x)) − 3 arctan(R1(2, x)) = π/4, with x = 2, hile the two parametric families correspond to arctan ( R0 ( 1, 1 2a+1 + 1 )) − arctan ( R3 ( 1, 1 2a+1 + 1 )) = π 4 , arctan ( R0 ( 1, 1 2a+1 − 1 )) − arctan ( R3 ( 1, 1 2a+1 − 1 )) = π 4 , or a ∈ N∗. 1388 A. Gasull, F. Luca and J.L. Varona Indagationes Mathematicae 34 (2023) 1373–1396 m d f F t s M f I n o t e It is not difficult to identify many other two-term well-known Machin-like formulas by eans of our notation. Let us give some examples, with their corresponding Lehmer measures, enoted by µ. The combination 5 arctan(R1(2, x)) − 2 arctan(R0(5, x)) for x = 3 gives the ormula 5 arctan ( 1 7 ) + 2 arctan ( 3 79 ) = π 4 , µ ∼ 1.88727. (31) The combination 22 arctan(R2(17, x)) − 17 arctan(R3(22, x)) for x = 1/2 gives 22 arctan ( 24 478 873 121 ) + 17 arctan ( 685 601 69 049 993 ) = π 4 , µ ∼ 1.14343. (32) inally, 22 arctan(R0(1, x)) − arctan(R3(22, x)) for x = 1/28 gives 22 arctan ( 1 28 ) + arctan ( 1 744 507 482 180 328 366 854 565 127 98 646 395 734 210 062 276 153 190 241 239 ) = π 4 , µ ∼ 0.901429. Of course, each of the Machin’s formulas appearing in this paper can be checked by direct multiplication of its associated Gaussian integers. For instance, (31) and (32) hold because (7 + i)5(79 + 3i)2 = 23510(1 + i) and (873 121 + 24 478i)22(69 049 993 + 685 601i)17 = 285374(1 + i). It seems to us that our formulas are likely to reproduce most of the known Machin’s type formulas with two terms, as well as to obtain new ones with N = 2, but are not enough in general to include all formulas with N > 2, like for instance the ones appearing in [14]. In any case, two term formulas have been also shown to be useful as starting points to produce formulas with more terms, see for instance the procedures developed in [3,8,22,24]. Although the first main aim of our paper was to produce Machin-like identities with arbitrarily small Lehmer measure, with the help of Theorem 2, it is not difficult to look for examples satisfying this property. It is enough to take N = 2 and to use a suitable strategy, with the help of any computer algebra system. We want to get two functions R j (n, x) and Ri (m, x) whose absolute values are “small” at he same x , to guarantee that the corresponding series (2) converges quickly (that is, “few” ummands of the series are necessary to get a good precision). This is what happens with the achin-like identities having small Lehmer measure. With the aid of a computer, we can look or these x with different strategies: • Searching numerically for minima of each function of type R j (n, x)2 + Ri (m, x)2 (or similar, since, for example, we can put different weights or exponents on the two summands), and imposing that the value of the resulting function is small enough. • By numerically identifying intervals in which, simultaneously, −ε < R j (n, x) < ε and −ε < Ri (m, x) < ε, for ε > 0 fixed beforehand. n both cases, in order to obtain “nice” expressions, it is of interest to take x rational with a umerator and denominator that are not too large. This can be achieved by taking convergents f continued fractions of numbers that we have obtained with the previous strategies. A couple of new Machin-Like identities have been obtained with the above strategy (with heir corresponding Lehmer measure µ). Using R j (n, x) with big values of n it is easier to find xamples with small Lehmer measure, but then we end up with fractions a /b where both a k k k 1389 A. Gasull, F. Luca and J.L. Varona Indagationes Mathematicae 34 (2023) 1373–1396 d i o s w D I i ( a f v and bk have many digits. In this case, we denote f r s to indicate an irreducible fraction with r igits in the numerator and s digits in the denominator. • The relation 33 arctan(R0(1, x)) − arctan(R3(33, x)) with x = 1/42 gives 33 arctan(1/42) − arctan( f 50 54 ) = π/4, µ ∼ 0.880916. • The relation 48 arctan(R0(1, x)) − arctan(R3(48, x)) with x = 9/550 gives 48 arctan(9/550) − arctan( f 127 132 ) = π/4, µ ∼ 0.765513. To evaluate R j (n, x) for very big values of n (say, for instance, n > 100), it is not a good dea to use their rational expressions given in (19), (20), (21) and (22). For instance when n is dd, both the numerator and the denominator are polynomials with n +1 non-zero monomials, ee (21). From a computational point of view, it is better to proceed as follows. In practice, e have used these methods in some of the examples that appear in the next section. Because R0(n, x) = tan(nθ ) with x = tan θ we have R0(n, x) = tan(nθ ) = sin(nθ ) cos(nθ ) = Im ( (cos θ + i sin θ )n ) Re ( (cos θ + i sin θ )n ) . ividing both the numerator and the denominator by cosn(θ ) we get R0(n, x) = Im ( (cos θ + i sin θ )n ) Re ( (cos θ + i sin θ )n ) = Im ( (1 + i tan θ )n ) Re ( (1 + i tan θ )n ) = Im ( (1 + i x)n ) Re ( (1 + i x)n ) . f x ∈ Q is fixed, we can evaluate (1 + i x)n via successive squaring (this is particularly easy f n is a power of 2). Thus, (1 + i x)n is a number in Q[i], and using it we obtain R0(n, x). In the same way, using R1(n, x) = tan(nθ + π/4) with x = tan θ , we have R1(n, x) = sin(nθ + π/4) cos(nθ + π/4) = cos(nθ ) + sin(nθ ) cos(nθ ) − sin(nθ ) = Re ( (cos θ + i sin θ )n ) + Im ( (cos θ + i sin θ )n ) Re ( (cos θ + i sin θ )n ) − Im ( (cos θ + i sin θ )n ) = Re ( (1 + i tan θ )n ) + Im ( (1 + i tan θ )n ) Re ( (1 + i tan θ )n ) − Im ( (1 + i tan θ )n ) = Re ( (1 + i x)n ) + Im ( (1 + i x)n ) Re ( (1 + i x)n ) − Im ( (1 + i x)n ) , and again we can evaluate (1 + i x)n by means of successive squaring. Using (29), we get the corresponding expressions for R2(n, x) and R3(n, x). In the particular case of n = 2m , there is another clever way to evaluate R j (2m, x): using (26) we can write R j (2m, x) as a composition of successive R0(2, x) with a final R j (2, x); i.e., R j (2m, x) = R j (2, R◦(m−1) 0 (2, x)) to avoid confusion with multiplicative powers, we use f ◦n to denote the composition of the function f with itself n times). In the above, we have m rational functions (with numerators nd denominators of degree 1 or 2) that are easy to evaluate. Computer experiments show that, or n = 2m , this method is faster than the previous procedure based on computing (1 + i x)n ia successive squaring. 1390 A. Gasull, F. Luca and J.L. Varona Indagationes Mathematicae 34 (2023) 1373–1396 T w h P T c a I i 3.5. Machin-like identities with small Lehmer measure With the help of the functions R j (n, x), we can prove that there exist two-term Machin-like identities with Lehmer measure as small as we want. To do this, we use standard properties of the continued fractions. The formulas with Lehmer measure as small as desired can be given explicitly. For a real number x , let us denote its continued fraction by x = [c0, c1, c2, c3, . . . ], and let pk/qk = [c0, c1, c2, . . . , ck], with k = 0, 1, 2, . . . , be its convergents. It is well known that⏐⏐⏐⏐x − pk qk ⏐⏐⏐⏐ ≤ 1 q2 k . (33) heorem 3. For every ε > 0 there exist positive integers n, b1, b2, and another integer a2 ith 0 < |a2| < b2, such that the Machin-like identity n arctan 1 b1 − arctan a2 b2 = π 4 (34) as Lehmer measure (10) less than ε. roof. Let pk/qk be the convergents of the continued fraction of π . By (33),⏐⏐⏐⏐π − pk qk ⏐⏐⏐⏐ = O ( 1 q2 k ) , so ⏐⏐⏐⏐ π 4pk − 1 4qk ⏐⏐⏐⏐ = O ( 1 q3 k ) . aking ξ = 1/(4qk), the alternating series (2) easily gives arctan ( 1 4qk ) = 1 4qk + O ( 1 q3 k ) = π 4pk + O ( 1 q3 k ) . Multiplying by n = pk , we obtain n arctan(ξ ) = pk ( π 4pk + O ( 1 q3 k )) = π 4 + O ( 1 q2 k ) . (35) Note that the derivative of g(x) = n arctan(x) − arctan(R3(n, x)) is 0, so g is piecewise onstant. Because g(0) = n arctan(0) − arctan(R3(n, 0)) = 0 − arctan(−1) = π/4, there exists n interval I around 0 where the value the function is π/4 and on I, n arctan(x) − arctan(R3(n, x)) = π 4 . (36) t suffices to show that ξ = 1/(4qk) belongs to I, which we do below. By definition, see (23), the formula R3(n, x) = tan ( nθ + 3π 4 ) = tan ( nθ − π 4 ) , x = tan θ, s valid on an interval for the variable θ on which tan is a bijective function. That is, for −π/2 < nθ − π/4 < π/2, or −π/4 < nθ < 3π/4. Because tan θ ∼ θ for small θ , this is the case when −π/5 < nx < 3π/5 and θ is close to zero. Under this condition, we have n arctan(x) − arctan(R3(n, x)) = nθ − arctan ( tan ( nθ − π )) = nθ − ( nθ − π ) = π , 4 4 4 1391 A. Gasull, F. Luca and J.L. Varona Indagationes Mathematicae 34 (2023) 1373–1396 s r w w n a M T as desired. Since certainly, ξ = 1/(4qk) satisfies −π/5 < nξ = pk/(4qk) < 3π/5, because pk/qk are the convergents of π . Once proved that ξ = 1/(4qk) satisfies (36), it follows from (35) and (36) that |R3(n, ξ )| = O(1/q2 k ). We then have the Machin-like formula (34) with b1 = 1/ξ = 4qk and a2/b2 = R3(n, ξ ). Finally, 1 log10(1/ξ ) + 1 log10(1/|R3(n, ξ )|) = O ( 1 log10 qk ) (∗) = O ( 1 k ) , o taking k big enough, the thesis follows. The step (∗) can be justified as follows: the ecurrence relation qk = akqk−1 + qk−2 ≥ qk−1 + qk−2 (with ak ≥ 1 being the partial quotients of the continued fraction) gives that qk ≥ Fk , where Fm is the mth Fibonacci number. Consequently, qk ≥ φk−2 with φ the golden section, so log10 qk ≫ k. □ Corollary 4. For every ε > 0 and every N ≥ 2 there exists a Machin-like identity N∑ k=1 rk nk arctan ( ak bk ) = π 4 with N∏ k=1 rk ̸= 0, hich has Lehmer measure (10) less than ε. Proof. Given one of the two terms formulas obtained in Theorem 3, with arbitrarily small Lehmer measure, any of its arctangent terms can be split into two new ones by using the well known identity arctan(x) = 2 arctan(2x) − arctan(4x3 + 3x), which once more can be easily proved by derivation. By applying this procedure N−2 times we arrive to the desired result. As we have already commented, other ways to split one arctangent term into several ones are developed in [3,8,22,24]. □ Note that the above proof is constructive, and we can use the procedure given in the proof to explicitly state Machin-like formulas, see Table 1. We used the successive squaring method explained in the previous section to compute the values a2/b2 that appear in that table. To conclude this section, let us see another way to obtain two-term Machin-like identities ith small Lehmer measure. As shown in the proof of Theorem 3, the function g(x) = arctan(x)−arctan(R3(n, x)) is piecewise constant and its value is π/4 in an interval around 0. Then, for fixed n big enough, we can take x ∈ Q near 1 n π 4 by using a convergent of the continued fraction of 1 n π 4 , and thus we have a1/b1 = x and a2/b2 = R3(n, x). In this way, nd because x and R3(n, x) are small numbers, the Lehmer measure of the corresponding achin-like formula will be small (but the integers a2 and b2 have a lot of digits). We can do this with n = 2m and then use (26) with j = 3 to compute a2/b2 = R3(2m, x). his method is very fast. For m ≤ 30 and using three convergents for every 1 2m π 4 , we have found the corresponding Machin-line formulas, and computed their Lehmer measures. We summarize a collection of these formulas in Table 2. The Machin-like formulas corresponding to the first convergents of 25 (i.e., a1/b1 = 1/40) and 226 (i.e., a /b = 1/85 445 659) have been previously found in [1,2] by a different method. 1 1 1392 A. Gasull, F. Luca and J.L. Varona Indagationes Mathematicae 34 (2023) 1373–1396 a f Table 1 Machin-like identities n arctan(1/b1)−arctan(a2/b2) = π 4 , with the notation of the proof of Theorem 3. The notation f r s is used to indicate an irreducible fraction with r digits in the numerator and s digits in the denominator. k pk/qk a1/b1 a2/b2 Lehmer measure 1 22/7 1/28 f 28 32 ∼ 0.000 017 684 5 0.901 429 2 333/106 1/424 f 871 876 ∼ 0.000 022 261 1 0.595 55 3 355/113 1/452 f 937 943 ∼ 1.214 73 · 10−6 0.545 675 4 103 993/33 102 1/132 408 f 532 634 532 644 ∼ 1.594 05 · 10−10 0.297 306 5 104 348/33 215 1/132 860 f 534 606 534 617 ∼ −6.807 56 · 10−11 0.293 54 6 208 341/66 317 1/265 268 f 1 129 966 1 129 977 ∼ 3.430 96 · 10−11 0.279 937 7 312 689/99 532 1/398 128 f 1 751 055 1 751 066 ∼ −5.634 18 · 10−12 0.267 466 8 833 719/265 381 1/1 061 524 f 5 023 921 5 023 933 ∼ 2.411 2 · 10−12 0.252 025 9 1 146 408/364 913 1/1 459 652 f 7 066 733 7 066 745 ∼ −2.798 08 · 10−13 0.241 887 10 4 272 943/1 360 120 1/5 440 480 f 28 780 982 28 780 995 ∼ 1.098 62 · 10−13 0.225 63 11 5 419 351/1 725 033 1/6 900 132 f 37 062 153 37 062 169 ∼ −3.757 33 · 10−17 0.207 106 12 80 143 857/25 510 582 1/102 042 328 f 641 854 533 641 854 548 ∼ 1.699 14 · 10−16 0.188 275 13 165 707 065/52 746 197 1/210 984 788 f 1 379 387 210 1 379 387 226 ∼ −3.513 97 · 10−17 0.180 906 14 245 850 922/78 256 779 1/313 027 116 f 2 088 646 642 2 088 646 658 ∼ 2.221 66 · 10−17 0.177 756 15 411 557 987/131 002 976 1/524 011 904 f 3 588 514 476 3 588 514 494 ∼ −3.887 53 · 10−19 0.172 125 4. Machin’s formulas with powers of the golden section Recall that φ = (1+ √ 5)/2 denotes the golden section. There are some linear combinations of arctangents of powers of the golden section which evaluate to a rational multiple of π such s π 4 = 1 3 arctan(φ3) + 1 3 arctan(φ) = 1 5 arctan(φ6) + 2 5 arctan(φ2), π 4 = 1 7 arctan(φ5) + 3 7 arctan(φ3) = − 1 2 arctan(φ5) + 3 2 arctan(φ). The first three of them appear for instance in [9,17]. The last one, although can be easily obtained from the first three, does not appear in the above papers. They are all of the form π 4 = a arctan(φκ ) + b arctan(φℓ), (37) or positive integers κ > ℓ with some rational numbers a, b. Via the formula arctan(x) + arctan(1/x) = π/2 valid for all positive real numbers x , each one of the above formulas gives rise to three additional formulas of the same kind with different (a, b), replacing (κ, ℓ) by (±κ, ±ℓ). Via the above identity, we see that formula (37) holds as well with a = b = 1/2, whenever κ + ℓ = 0. So, eliminating such trivial solutions, we see that Eq. (37) holds in κ, ℓ ∈ Z, |κ| ≥ |ℓ|, κ + ℓ ̸= 0 and a, b ∈ Q for the following quadruples: (a, b, κ, ℓ) ∈ ⎧⎪⎪⎪⎪⎨⎪⎪⎪⎪⎩ ( 1 3 , 1 3 , 3, 1 ) , (1, 1, −3, −1) , (−1, 1, −3, 1) , (1, −1, 3, −1) ,( 1 5 , 2 5 , 6, 2 ) , (1, 2, −6, −2) , ( −1 3 , 2 3 , −6, 2 ) , (1, −2, 6, −2) ,( 1 7 , 3 7 , 5, 3 ) , (1, 3, −5, −3) , ( −1 5 , 3 5 , −5, 3 ) , (1, −3, 5, −3) ,( −1 3 ) ( −1 3 ) ( 1 3 ) ( 1 3 ) ⎫⎪⎪⎪⎪⎬⎪⎪⎪⎪⎭ . 2 , 2 , 5, 1 , 2 , 2 , −5, −1 , 4 , 4 , −5, 1 , 4 , 4 , 5, −1 1393 A. Gasull, F. Luca and J.L. Varona Indagationes Mathematicae 34 (2023) 1373–1396 w i E f o Table 2 Machin-like formulas 2m arctan(a1/b1)−arctan(a2/b2) = π 4 , corresponding to 2m arctan(x)−arctan(R3(2m , x)) = π 4 , ith x one of the first convergents of the continued fraction of π/2m+2. The notation f r s is used to indicate an rreducible fraction with r digits in the numerator and s digits in the denominator. 2m a1/b1 a2/b2 Lehmer measure 25 1/40 f 50 52 ∼ 0.014 436 1.167 51 = 1/41 f 45 47 ∼ −0.005 065 11 1.055 7 = 3/122 f 65 67 ∼ 0.001 328 54 0.969 041 26 1/81 f 111 113 ∼ 0.004 685 19 0.953 294 = 2/163 f 138 142 ∼ −0.000 161 494 0.786 967 = 39/3 178 f 220 225 ∼ −0.000 037 964 2 0.749 474 27 1/162 f 281 283 ∼ 0.004 715 29 0.882 42 = 1/163 f 261 265 ∼ −0.000 131 942 0.709 799 = 39/6 356 f 482 487 ∼ −8.397 46 · 10−6 0.649 066 28 1/325 f 603 605 ∼ 0.002 291 66 0.776 917 = 1/326 f 640 644 ∼ −0.000 124 553 0.654 001 = 19/6 193 f 927 933 ∼ 2.246 63 · 10−6 0.574 947 29 1/651 f 1 361 1 364 ∼ 0.001 083 55 0.692 67 = 1/652 f 1 438 1 442 ∼ −0.000 122 706 0.611 015 = 9/5 867 f 1 848 1 853 ∼ 0.000 011 140 4 0.557 238 210 1/1 303 f 3 033 3 036 ∼ 0.000 480 424 0.622 385 = 1/1 304 f 3 187 3 191 ∼ 0.000 122 244 0.576 572 = 4/5 215 f 3 803 3 807 ∼ 0.000 028 336 5 0.540 901 220 1/1 335 088 f 6 423 057 6 423 063 ∼ 2.522 87 · 10−7 0.314 81 = 2/2 670 177 f 6 738 709 6 738 716 ∼ −4.184 98 · 10−8 0.298 784 = 7/9 345 619 f 7 151 377 7 151 387 ∼ 1.697 4 · 10−10 0.265 604 221 1/2 670 176 f 13 477 425 13 477 432 ∼ 2.522 87 · 10−7 0.307 163 = 1/2 670 177 f 13 161 772 13 161 779 ∼ −4.184 97 · 10−8 0.291 137 = 7/18 691 238 f 15 249 721 15 249 731 ∼ 1.698 51 · 10−10 0.257 96 224 1/21 361 414 f 122 970 779 122 970 786 ∼ 3.168 46 · 10−8 0.269 781 = 1/21 361 415 f 120 445 556 120 445 564 ∼ −5.082 56 · 10−9 0.257 003 = 7/149 529 904 f 137 149 169 137 149 179 ∼ 1.698 87 · 10−10 0.238 788 225 1/42 722 829 f 250 992 010 250 992 018 ∼ 1.330 1 · 10−8 0.258 016 = 1/42 722 830 f 256 042 455 256 042 463 ∼ −5.082 56 · 10−9 0.251 621 = 3/128 168 489 f 267 001 542 267 001 550 ∼ 1.045 3 · 10−9 0.242 399 226 1/85 445 659 f 522 185 807 522 185 816 ∼ 4.109 22 · 10−9 0.245 319 = 2/170 891 319 f 552 488 478 552 488 488 ∼ −4.866 69 · 10−10 0.233 456 (continued on next page) q. (37) in positive integers κ, ℓ was treated in [17]. The main result in [17] claims to have ound all solutions of Eq. (37) in integers κ, ℓ with κ+ℓ ̸= 0. However, [17] missed the last row f solutions indicated above corresponding to (κ, ℓ) = (5, 1) and its variants with (±5, ±1). In 1394 A. Gasull, F. Luca and J.L. Varona Indagationes Mathematicae 34 (2023) 1373–1396 l ( i L p 1 a d p i Table 2 (continued). 2m a1/b1 a2/b2 Lehmer measure = 9/769 010 935 f 586 223 936 586 223 947 ∼ 2.398 6 · 1010−11 0.220 238 229 1/683 565 275 f 4 662 329 259 4 662 329 268 ∼ 6.623 04 · 10−10 0.222 134 = 1/683 565 276 f 4 743 136 384 4 743 136 393 ∼ −4.866 69 · 10−10 0.220 568 = 2/1 367 130 551 f 4 904 750 631 4 904 750 641 ∼ 8.781 78 · 10−11 0.212 628 230 1/1 367 130 551 f 9 647 887 023 9 647 887 033 ∼ 8.781 78 · 10−11 0.208 898 = 6/8 202 783 307 f 10 645 034 813 10 645 034 824 ∼ −7.929 92 · 10−12 0.199 544 = 7/9 569 913 858 f 10 716 918 381 10 716 918 392 ∼ 5.748 33 · 10−12 0.198 424 this section, we fill in the oversight from [17] and show that there are no other solutions up to signs except for the above four. Writing as in [17], a = u/w, b = v/w with coprime integers u, v, w and w ≥ 1, Eq. (37) eads to (1 + iφκ )4u(1 + iφℓ)4v = (1 − iφκ )4u(1 − iφℓ)4v (38) formula (4) in [17]). The norm of the element 1 + iφκ in the biquadratic field K = Q(i, √ 5) s 5F2 κ or L2 κ according to whether κ is odd or even, where Fκ , Lκ are the κth Fibonacci and ucas companion of the Fibonacci numbers, respectively. Since the above number is never a ower of 2 for any positive integer κ , it follows that for every odd prime factor p of the above number, there is a prime ideal π in OK dividing p such that π divides 1 + iφκ . Note that π does not divide 1 − iφκ , since otherwise π divides (1 + iφκ ) + (1 − iφκ ) = 2, which is false since π divides the odd prime p. The same argument applies to 1 + iφℓ. Using the Primitive Divisor Theorem for Fibonacci and Lucas numbers, it is argued in [17] that κ ≤ 12, so one is left with finding all pairs of positive integers (κ, ℓ) in the range 1 < ℓ < κ ≤ 12. Then in [17] (see formula (5)) it is said that π divides 1 + iφκ and 1 − iφℓ and it is shown that, under this assumption, (κ, ℓ) = (6, 2), (5, 3), (5, 1). Looking at formula (4) in [17] (or formula (38)) however, the assumption that π divides 1 + iφκ and 1 − iφℓ implies that u and v have the same sign. In fact the solutions from [17] have a and b with the same sign. Thus, the oversight comes from not having treated the case when u and v have opposite signs in [17]. In this case, π divides 1 + iφκ and 1 + iφℓ. This is the case missed in [17]. At any rate, all examples must satisfy that the set of odd prime factors of the two numbers NK/Q(1 + iφκ ) and NK/Q(1 + iφℓ) must be the same. One calculates all such numbers for 1 ≤ ℓ < κ ≤ 12 and gets the four solutions (κ, ℓ) = (3, 1), (5, 1), (5, 3), (6, 2) and no others. Acknowledgments The first author is partially supported by the Ministerio de Ciencia e Innovación (PID2019- 04658GB-I00 grant), by the grant Severo Ochoa and Marı́a de Maeztu Program for Centers nd Units of Excellence in R&D (CEX2020-001084-M) and also by the Agència de Gestió ’Ajuts Universitaris i de Recerca (2021 SGR 113 grant). The second author worked on this aper during a visit at the Max Planck Institute for Software Science in Saarbrücken, Germany, n Spring of 2022. He thanks the people of this Institute for hospitality and support. This 1395 A. Gasull, F. Luca and J.L. Varona Indagationes Mathematicae 34 (2023) 1373–1396 ( m fi R author was also partially supported by Project 2022-064-NUM-GANDA from the CoEMaSS at Wits. The third author is partially supported by the Ministerio de Ciencia e Innovación PID2021-124332NB-C22 grant). The authors want to acknowledge the helpful, constructive and detailed revision of the anuscript by the referees, that has allowed us to correct some errors and to improve the nal version of the paper. eferences [1] S.M. Abrarov, B.M. Quine, 2017. An iteration procedure for a two-term Machin-like formula for pi with small Lehmer’s measure, arXiv, https://arxiv.org/abs/1706.08835. [2] S.M. Abrarov, R. Siddiqui, R.K. Jagpal, B.M. Quine, Unconditional applicability of Lehmer’s measure to the two-term Machin-like formula for π , Math. J. 23 (2021) 23. [3] S.M. Abrarov, R. Siddiqui, R.K. Jagpal, B.M. Quine, A new form of the Machin-like formula for π by iteration with increasing integers, J. Integer Seq. 25 (2022) Article 22.4.5. [4] M. Abrate, S. Barbero, U. Cerruti, N. Murru, Writing π as sum of arctangents with linear recurrent sequences, golden mean and Lucas numbers, Int. J. Math. Math. Sci. 10 (5) (2014) 1309–1319. [5] M. Benito, L.M. Navas, J.L. Varona, Möbius inversion formulas for flows of arithmetic semigroups, J. Number Theory 128 (2) (2008) 390–412. [6] J.S. Calcut, Single rational arctangent identities for π , Pi Mu Epsilon J. 11 (1) (1999) 1–6. [7] J.S. Calcut, Gaussian integers and arctangent identities for π , Amer. Math. Monthly 116 (6) (2009) 515–530. [8] M. Chamberland, E.A. Herman, Arctangent formulas and pi, Amer. Math. Monthly 126 (7) (2019) 646–650. [9] H.-C. Chan, Machin-type formulas expressing π in terms of φ, Fibonacci Quart. 46/47 (1) (2008/2009) 32–37. [10] H. Chien-Lih, 81.22 More Machin-type identities, Math. Gaz. 81 (490) (1997) 120–121. [11] D. Chudnovsky, G.V. Chudnovsky, Approximation and Complex Multiplication According to Ramanujan, Ramanujan Revisited (Urbana-Champaign, Ill. 1987), Academic Press, Boston, MA, 1988, pp. 375–472. [12] Ó. Ciaurri, L.M. Navas, J.L. Varona, A transform involving Chebyshev polynomials and its inversion formula, J. Math. Anal. Appl. 323 (1) (2006) 57–62. [13] J.H.E. Cohn, Perfect Pell powers, Glasg. Math. J. 38 (1) (1996) 19–20. [14] J. Guillera, Historia de las fórmulas y algoritmos para π , Gac. R. Soc. Mat. Esp. 10 (1) (2007) 159–178 (in Spanish). [15] D.H. Lehmer, On arccotangent relations for π , Amer. Math. Monthly 45 (10) (1938) 657–664. [16] F. Luca, On the equation x2 + 2a · 3b = yn , Int. J. Math. Math. Sci. 29 (4) (2002) 239–244. [17] F. Luca, P. Stănică, On Machin’s formula with powers of the golden section, Int. J. Number Theory 5 (6) (2009) 973–979. [18] Á. Plaza, Identidades de tipo Machin con π y dos arcotangentes, Gac. R. Soc. Mat. Esp. 21 (3) (2018) 608 (in Spanish). [19] L. Rédei, Über eindeuting umkehrbare Polynome in endlichen Körpern, Acta Sci. Math. (Szeged) 11 (1–2) (1946-48) 85–92 (in German). [20] M.C. Störmer, Solution complète en nombres entiers m, n, x , y et k de l’équation m arctan 1 x +n arctan 1 y = kπ 4 , Skr. Vidensk. Christ. I. Math.-naturv. Klasse (Nr. 11) (1895) 21 (in French). [21] M.C. Störmer, Solution complète en nombres entiers de l’équation m arctan 1 x + n arctan 1 y = k π 4 , Bull. Soc. Math. France 27 (1899) 160–170 (in French). [22] J. Todd, A problem on arc tangent relations, Amer. Math. Monthly 56 (8) (1949) 517–528. [23] I. Tweddle, John Machin and Robert Simson on inverse-tangent series for π , Arch. Hist. Exact Sci. 42 (1) (1991) 1–14. [24] M. Wetherfield, The enhancement of Machin’s formula by Todd’s process, Math. Gaz. 80 (488) (1996) 333–344. 1396 https://arxiv.org/abs/1706.08835 https://arxiv.org/abs/1706.08835 https://arxiv.org/abs/1706.08835 https://arxiv.org/abs/1706.08835 https://arxiv.org/abs/1706.08835 https://arxiv.org/abs/1706.08835 https://arxiv.org/abs/1706.08835 https://arxiv.org/abs/1706.08835 https://arxiv.org/abs/1706.08835 https://arxiv.org/abs/1706.08835 https://arxiv.org/abs/1706.08835 https://arxiv.org/abs/1706.08835 https://arxiv.org/abs/1706.08835 https://arxiv.org/abs/1706.08835 https://arxiv.org/abs/1706.08835 https://arxiv.org/abs/1706.08835 https://arxiv.org/abs/1706.08835 https://arxiv.org/abs/1706.08835 https://arxiv.org/abs/1706.08835 https://arxiv.org/abs/1706.08835 https://arxiv.org/abs/1706.08835 https://arxiv.org/abs/1706.08835 https://arxiv.org/abs/1706.08835 https://arxiv.org/abs/1706.08835 https://arxiv.org/abs/1706.08835 https://arxiv.org/abs/1706.08835 https://arxiv.org/abs/1706.08835 https://arxiv.org/abs/1706.08835 https://arxiv.org/abs/1706.08835 https://arxiv.org/abs/1706.08835 https://arxiv.org/abs/1706.08835 https://arxiv.org/abs/1706.08835 http://refhub.elsevier.com/S0019-3577(23)00066-6/sb2 http://refhub.elsevier.com/S0019-3577(23)00066-6/sb2 http://refhub.elsevier.com/S0019-3577(23)00066-6/sb2 http://refhub.elsevier.com/S0019-3577(23)00066-6/sb3 http://refhub.elsevier.com/S0019-3577(23)00066-6/sb3 http://refhub.elsevier.com/S0019-3577(23)00066-6/sb3 http://refhub.elsevier.com/S0019-3577(23)00066-6/sb4 http://refhub.elsevier.com/S0019-3577(23)00066-6/sb4 http://refhub.elsevier.com/S0019-3577(23)00066-6/sb4 http://refhub.elsevier.com/S0019-3577(23)00066-6/sb5 http://refhub.elsevier.com/S0019-3577(23)00066-6/sb5 http://refhub.elsevier.com/S0019-3577(23)00066-6/sb5 http://refhub.elsevier.com/S0019-3577(23)00066-6/sb6 http://refhub.elsevier.com/S0019-3577(23)00066-6/sb7 http://refhub.elsevier.com/S0019-3577(23)00066-6/sb8 http://refhub.elsevier.com/S0019-3577(23)00066-6/sb9 http://refhub.elsevier.com/S0019-3577(23)00066-6/sb10 http://refhub.elsevier.com/S0019-3577(23)00066-6/sb11 http://refhub.elsevier.com/S0019-3577(23)00066-6/sb11 http://refhub.elsevier.com/S0019-3577(23)00066-6/sb11 http://refhub.elsevier.com/S0019-3577(23)00066-6/sb12 http://refhub.elsevier.com/S0019-3577(23)00066-6/sb12 http://refhub.elsevier.com/S0019-3577(23)00066-6/sb12 http://refhub.elsevier.com/S0019-3577(23)00066-6/sb13 http://refhub.elsevier.com/S0019-3577(23)00066-6/sb14 http://refhub.elsevier.com/S0019-3577(23)00066-6/sb14 http://refhub.elsevier.com/S0019-3577(23)00066-6/sb14 http://refhub.elsevier.com/S0019-3577(23)00066-6/sb15 http://refhub.elsevier.com/S0019-3577(23)00066-6/sb16 http://refhub.elsevier.com/S0019-3577(23)00066-6/sb17 http://refhub.elsevier.com/S0019-3577(23)00066-6/sb17 http://refhub.elsevier.com/S0019-3577(23)00066-6/sb17 http://refhub.elsevier.com/S0019-3577(23)00066-6/sb18 http://refhub.elsevier.com/S0019-3577(23)00066-6/sb18 http://refhub.elsevier.com/S0019-3577(23)00066-6/sb18 http://refhub.elsevier.com/S0019-3577(23)00066-6/sb19 http://refhub.elsevier.com/S0019-3577(23)00066-6/sb19 http://refhub.elsevier.com/S0019-3577(23)00066-6/sb19 http://refhub.elsevier.com/S0019-3577(23)00066-6/sb20 http://refhub.elsevier.com/S0019-3577(23)00066-6/sb20 http://refhub.elsevier.com/S0019-3577(23)00066-6/sb20 http://refhub.elsevier.com/S0019-3577(23)00066-6/sb21 http://refhub.elsevier.com/S0019-3577(23)00066-6/sb21 http://refhub.elsevier.com/S0019-3577(23)00066-6/sb21 http://refhub.elsevier.com/S0019-3577(23)00066-6/sb22 http://refhub.elsevier.com/S0019-3577(23)00066-6/sb23 http://refhub.elsevier.com/S0019-3577(23)00066-6/sb23 http://refhub.elsevier.com/S0019-3577(23)00066-6/sb23 http://refhub.elsevier.com/S0019-3577(23)00066-6/sb24 http://refhub.elsevier.com/S0019-3577(23)00066-6/sb24 http://refhub.elsevier.com/S0019-3577(23)00066-6/sb24 Three essays on Machin's type formulas Introduction Machin's formulas with powers of two A reformulation Proof of Theorem 1 The case a1≥1 The case a1=0 The Machin's formulas machine The functions Rj(n,x) Some properties of the functions Rj(n,x) Machin-like formulas associated to Rj(n,x) Some examples Machin-like identities with small Lehmer measure Machin's formulas with powers of the golden section Acknowledgments References