Lagrange four-square (Bachet Conjecture) for 91

<-- Enter Number
  

What is the Lagrange four-square (Bachet Conjecture) for 91

Lagrange's Four Square Theorem states that any natural number (p) can be stated as the sum of four-square integers
p = a2 + b2 + c2 + d2

Step 1: - Determine a:

Step 1a: Floor(√91 = 9.5393920141695) = Floor(9.5393920141695)
Step 1a: Floor(9.5393920141695) = 9 <-- This is the maximum value of a, call it max_a

Step 1b. Obtain the first value of a such that a2 ≥ n/4, call it min_a
Start with min_a = 1 and increase by 1 until we reach or breach n/4 → 91/4 = 22.75
When min_a = 5, then it is a2 = 25 ≥ 22.75, so min_a = 5

Step 2: Test values for a in the range of (min_a, max_a) --> (5, 9)

a = 5

Step 3a: Determine max_b which is Floor(√n - a2)
max_b = Floor(√91 - 52)
max_b = Floor(√91 - 25)
max_b = Floor(√66)
max_b = Floor(8.124038404636)
max_b = 8

Step 3b. Obtain the first value of b such that b2 ≥ (n - a2)/3, call it min_b
Start with min_b = 1 and increase by 1until we reach or breach (n - a2)/3 → (91 - 52)/3 = 22
When min_b = 5, then it is b2 = 25 ≥ 22, so min_b = 5

Step 4: Test values for b in the range of (min_b, max_b) --> (5, 8)

b = 5

Step 5a: Determine max_c which is Floor(√n - a2 - b2)
max_c = Floor(√91 - 52 - 52)
max_c = Floor(√91 - 25 - 25)
max_c = Floor(√41)
max_c = Floor(6.4031242374328)
max_c = 6

Step 5b. Obtain the first value of b such that b2 ≥ (n - a2)/3, call it min_b
Start with min_c = 1 and increase by 1 until we reach or breach (n - a2 - b2 )/2 → (91 - 52 - 52)/2 = 20.5
When min_c = 5, then it is c2 = 25 ≥ 20.5, so min_c = 5

Step 6: Test values for c in the range of (min_c, max_c) --> (5, 6)

c = 5

Step 7: Determine if d is an integer solution which is √n - a2 - b2
max_d = √91 - 52 - 52 - 52
max_d = √91 - 25 - 25 - 25
max_d = √16
max_d = 4

Since max_d = 4, then (a, b, c, d) = (5, 5, 5, 4) is an integer solution proven below
52 + 52 + 52 + 42 → 25 + 25 + 25 + 16 = 91


c = 6

Step 7: Determine if d is an integer solution which is √n - a2 - b2
max_d = √91 - 52 - 52 - 62
max_d = √91 - 25 - 25 - 36
max_d = √5
max_d = 2.2360679774998

Since max_d = 2.2360679774998 is not an integer, this is not a solution


b = 6

Step 5a: Determine max_c which is Floor(√n - a2 - b2)
max_c = Floor(√91 - 52 - 62)
max_c = Floor(√91 - 25 - 36)
max_c = Floor(√30)
max_c = Floor(5.4772255750517)
max_c = 5

Step 5b. Obtain the first value of b such that b2 ≥ (n - a2)/3, call it min_b
Start with min_c = 1 and increase by 1 until we reach or breach (n - a2 - b2 )/2 → (91 - 52 - 62)/2 = 15
When min_c = 4, then it is c2 = 16 ≥ 15, so min_c = 4

Step 6: Test values for c in the range of (min_c, max_c) --> (4, 5)

c = 4

Step 7: Determine if d is an integer solution which is √n - a2 - b2
max_d = √91 - 52 - 62 - 42
max_d = √91 - 25 - 36 - 16
max_d = √14
max_d = 3.7416573867739

Since max_d = 3.7416573867739 is not an integer, this is not a solution


c = 5

Step 7: Determine if d is an integer solution which is √n - a2 - b2
max_d = √91 - 52 - 62 - 52
max_d = √91 - 25 - 36 - 25
max_d = √5
max_d = 2.2360679774998

Since max_d = 2.2360679774998 is not an integer, this is not a solution


b = 7

Step 5a: Determine max_c which is Floor(√n - a2 - b2)
max_c = Floor(√91 - 52 - 72)
max_c = Floor(√91 - 25 - 49)
max_c = Floor(√17)
max_c = Floor(4.1231056256177)
max_c = 4

Step 5b. Obtain the first value of b such that b2 ≥ (n - a2)/3, call it min_b
Start with min_c = 1 and increase by 1 until we reach or breach (n - a2 - b2 )/2 → (91 - 52 - 72)/2 = 8.5
When min_c = 3, then it is c2 = 9 ≥ 8.5, so min_c = 3

Step 6: Test values for c in the range of (min_c, max_c) --> (3, 4)

c = 3

Step 7: Determine if d is an integer solution which is √n - a2 - b2
max_d = √91 - 52 - 72 - 32
max_d = √91 - 25 - 49 - 9
max_d = √8
max_d = 2.8284271247462

Since max_d = 2.8284271247462 is not an integer, this is not a solution


c = 4

Step 7: Determine if d is an integer solution which is √n - a2 - b2
max_d = √91 - 52 - 72 - 42
max_d = √91 - 25 - 49 - 16
max_d = √1
max_d = 1

Since max_d = 1, then (a, b, c, d) = (5, 7, 4, 1) is an integer solution proven below
52 + 72 + 42 + 12 → 25 + 49 + 16 + 1 = 91


b = 8

Step 5a: Determine max_c which is Floor(√n - a2 - b2)
max_c = Floor(√91 - 52 - 82)
max_c = Floor(√91 - 25 - 64)
max_c = Floor(√2)
max_c = Floor(1.4142135623731)
max_c = 1

Step 5b. Obtain the first value of b such that b2 ≥ (n - a2)/3, call it min_b
Start with min_c = 1 and increase by 1 until we reach or breach (n - a2 - b2 )/2 → (91 - 52 - 82)/2 = 1
When min_c = 1, then it is c2 = 1 ≥ 1, so min_c = 1

Step 6: Test values for c in the range of (min_c, max_c) --> (1, 1)

c = 1

Step 7: Determine if d is an integer solution which is √n - a2 - b2
max_d = √91 - 52 - 82 - 12
max_d = √91 - 25 - 64 - 1
max_d = √1
max_d = 1

Since max_d = 1, then (a, b, c, d) = (5, 8, 1, 1) is an integer solution proven below
52 + 82 + 12 + 12 → 25 + 64 + 1 + 1 = 91


a = 6

Step 3a: Determine max_b which is Floor(√n - a2)
max_b = Floor(√91 - 62)
max_b = Floor(√91 - 36)
max_b = Floor(√55)
max_b = Floor(7.4161984870957)
max_b = 7

Step 3b. Obtain the first value of b such that b2 ≥ (n - a2)/3, call it min_b
Start with min_b = 1 and increase by 1until we reach or breach (n - a2)/3 → (91 - 62)/3 = 18.333333333333
When min_b = 5, then it is b2 = 25 ≥ 18.333333333333, so min_b = 5

Step 4: Test values for b in the range of (min_b, max_b) --> (5, 7)

b = 5

Step 5a: Determine max_c which is Floor(√n - a2 - b2)
max_c = Floor(√91 - 62 - 52)
max_c = Floor(√91 - 36 - 25)
max_c = Floor(√30)
max_c = Floor(5.4772255750517)
max_c = 5

Step 5b. Obtain the first value of b such that b2 ≥ (n - a2)/3, call it min_b
Start with min_c = 1 and increase by 1 until we reach or breach (n - a2 - b2 )/2 → (91 - 62 - 52)/2 = 15
When min_c = 4, then it is c2 = 16 ≥ 15, so min_c = 4

Step 6: Test values for c in the range of (min_c, max_c) --> (4, 5)

c = 4

Step 7: Determine if d is an integer solution which is √n - a2 - b2
max_d = √91 - 62 - 52 - 42
max_d = √91 - 36 - 25 - 16
max_d = √14
max_d = 3.7416573867739

Since max_d = 3.7416573867739 is not an integer, this is not a solution


c = 5

Step 7: Determine if d is an integer solution which is √n - a2 - b2
max_d = √91 - 62 - 52 - 52
max_d = √91 - 36 - 25 - 25
max_d = √5
max_d = 2.2360679774998

Since max_d = 2.2360679774998 is not an integer, this is not a solution


b = 6

Step 5a: Determine max_c which is Floor(√n - a2 - b2)
max_c = Floor(√91 - 62 - 62)
max_c = Floor(√91 - 36 - 36)
max_c = Floor(√19)
max_c = Floor(4.3588989435407)
max_c = 4

Step 5b. Obtain the first value of b such that b2 ≥ (n - a2)/3, call it min_b
Start with min_c = 1 and increase by 1 until we reach or breach (n - a2 - b2 )/2 → (91 - 62 - 62)/2 = 9.5
When min_c = 4, then it is c2 = 16 ≥ 9.5, so min_c = 4

Step 6: Test values for c in the range of (min_c, max_c) --> (4, 4)

c = 4

Step 7: Determine if d is an integer solution which is √n - a2 - b2
max_d = √91 - 62 - 62 - 42
max_d = √91 - 36 - 36 - 16
max_d = √3
max_d = 1.7320508075689

Since max_d = 1.7320508075689 is not an integer, this is not a solution


b = 7

Step 5a: Determine max_c which is Floor(√n - a2 - b2)
max_c = Floor(√91 - 62 - 72)
max_c = Floor(√91 - 36 - 49)
max_c = Floor(√6)
max_c = Floor(2.4494897427832)
max_c = 2

Step 5b. Obtain the first value of b such that b2 ≥ (n - a2)/3, call it min_b
Start with min_c = 1 and increase by 1 until we reach or breach (n - a2 - b2 )/2 → (91 - 62 - 72)/2 = 3
When min_c = 2, then it is c2 = 4 ≥ 3, so min_c = 2

Step 6: Test values for c in the range of (min_c, max_c) --> (2, 2)

c = 2

Step 7: Determine if d is an integer solution which is √n - a2 - b2
max_d = √91 - 62 - 72 - 22
max_d = √91 - 36 - 49 - 4
max_d = √2
max_d = 1.4142135623731

Since max_d = 1.4142135623731 is not an integer, this is not a solution


a = 7

Step 3a: Determine max_b which is Floor(√n - a2)
max_b = Floor(√91 - 72)
max_b = Floor(√91 - 49)
max_b = Floor(√42)
max_b = Floor(6.4807406984079)
max_b = 6

Step 3b. Obtain the first value of b such that b2 ≥ (n - a2)/3, call it min_b
Start with min_b = 1 and increase by 1until we reach or breach (n - a2)/3 → (91 - 72)/3 = 14
When min_b = 4, then it is b2 = 16 ≥ 14, so min_b = 4

Step 4: Test values for b in the range of (min_b, max_b) --> (4, 6)

b = 4

Step 5a: Determine max_c which is Floor(√n - a2 - b2)
max_c = Floor(√91 - 72 - 42)
max_c = Floor(√91 - 49 - 16)
max_c = Floor(√26)
max_c = Floor(5.0990195135928)
max_c = 5

Step 5b. Obtain the first value of b such that b2 ≥ (n - a2)/3, call it min_b
Start with min_c = 1 and increase by 1 until we reach or breach (n - a2 - b2 )/2 → (91 - 72 - 42)/2 = 13
When min_c = 4, then it is c2 = 16 ≥ 13, so min_c = 4

Step 6: Test values for c in the range of (min_c, max_c) --> (4, 5)

c = 4

Step 7: Determine if d is an integer solution which is √n - a2 - b2
max_d = √91 - 72 - 42 - 42
max_d = √91 - 49 - 16 - 16
max_d = √10
max_d = 3.1622776601684

Since max_d = 3.1622776601684 is not an integer, this is not a solution


c = 5

Step 7: Determine if d is an integer solution which is √n - a2 - b2
max_d = √91 - 72 - 42 - 52
max_d = √91 - 49 - 16 - 25
max_d = √1
max_d = 1

Since max_d = 1, then (a, b, c, d) = (7, 4, 5, 1) is an integer solution proven below
72 + 42 + 52 + 12 → 49 + 16 + 25 + 1 = 91


b = 5

Step 5a: Determine max_c which is Floor(√n - a2 - b2)
max_c = Floor(√91 - 72 - 52)
max_c = Floor(√91 - 49 - 25)
max_c = Floor(√17)
max_c = Floor(4.1231056256177)
max_c = 4

Step 5b. Obtain the first value of b such that b2 ≥ (n - a2)/3, call it min_b
Start with min_c = 1 and increase by 1 until we reach or breach (n - a2 - b2 )/2 → (91 - 72 - 52)/2 = 8.5
When min_c = 3, then it is c2 = 9 ≥ 8.5, so min_c = 3

Step 6: Test values for c in the range of (min_c, max_c) --> (3, 4)

c = 3

Step 7: Determine if d is an integer solution which is √n - a2 - b2
max_d = √91 - 72 - 52 - 32
max_d = √91 - 49 - 25 - 9
max_d = √8
max_d = 2.8284271247462

Since max_d = 2.8284271247462 is not an integer, this is not a solution


c = 4

Step 7: Determine if d is an integer solution which is √n - a2 - b2
max_d = √91 - 72 - 52 - 42
max_d = √91 - 49 - 25 - 16
max_d = √1
max_d = 1

Since max_d = 1, then (a, b, c, d) = (7, 5, 4, 1) is an integer solution proven below
72 + 52 + 42 + 12 → 49 + 25 + 16 + 1 = 91


b = 6

Step 5a: Determine max_c which is Floor(√n - a2 - b2)
max_c = Floor(√91 - 72 - 62)
max_c = Floor(√91 - 49 - 36)
max_c = Floor(√6)
max_c = Floor(2.4494897427832)
max_c = 2

Step 5b. Obtain the first value of b such that b2 ≥ (n - a2)/3, call it min_b
Start with min_c = 1 and increase by 1 until we reach or breach (n - a2 - b2 )/2 → (91 - 72 - 62)/2 = 3
When min_c = 2, then it is c2 = 4 ≥ 3, so min_c = 2

Step 6: Test values for c in the range of (min_c, max_c) --> (2, 2)

c = 2

Step 7: Determine if d is an integer solution which is √n - a2 - b2
max_d = √91 - 72 - 62 - 22
max_d = √91 - 49 - 36 - 4
max_d = √2
max_d = 1.4142135623731

Since max_d = 1.4142135623731 is not an integer, this is not a solution


a = 8

Step 3a: Determine max_b which is Floor(√n - a2)
max_b = Floor(√91 - 82)
max_b = Floor(√91 - 64)
max_b = Floor(√27)
max_b = Floor(5.1961524227066)
max_b = 5

Step 3b. Obtain the first value of b such that b2 ≥ (n - a2)/3, call it min_b
Start with min_b = 1 and increase by 1until we reach or breach (n - a2)/3 → (91 - 82)/3 = 9
When min_b = 3, then it is b2 = 9 ≥ 9, so min_b = 3

Step 4: Test values for b in the range of (min_b, max_b) --> (3, 5)

b = 3

Step 5a: Determine max_c which is Floor(√n - a2 - b2)
max_c = Floor(√91 - 82 - 32)
max_c = Floor(√91 - 64 - 9)
max_c = Floor(√18)
max_c = Floor(4.2426406871193)
max_c = 4

Step 5b. Obtain the first value of b such that b2 ≥ (n - a2)/3, call it min_b
Start with min_c = 1 and increase by 1 until we reach or breach (n - a2 - b2 )/2 → (91 - 82 - 32)/2 = 9
When min_c = 3, then it is c2 = 9 ≥ 9, so min_c = 3

Step 6: Test values for c in the range of (min_c, max_c) --> (3, 4)

c = 3

Step 7: Determine if d is an integer solution which is √n - a2 - b2
max_d = √91 - 82 - 32 - 32
max_d = √91 - 64 - 9 - 9
max_d = √9
max_d = 3

Since max_d = 3, then (a, b, c, d) = (8, 3, 3, 3) is an integer solution proven below
82 + 32 + 32 + 32 → 64 + 9 + 9 + 9 = 91


c = 4

Step 7: Determine if d is an integer solution which is √n - a2 - b2
max_d = √91 - 82 - 32 - 42
max_d = √91 - 64 - 9 - 16
max_d = √2
max_d = 1.4142135623731

Since max_d = 1.4142135623731 is not an integer, this is not a solution


b = 4

Step 5a: Determine max_c which is Floor(√n - a2 - b2)
max_c = Floor(√91 - 82 - 42)
max_c = Floor(√91 - 64 - 16)
max_c = Floor(√11)
max_c = Floor(3.3166247903554)
max_c = 3

Step 5b. Obtain the first value of b such that b2 ≥ (n - a2)/3, call it min_b
Start with min_c = 1 and increase by 1 until we reach or breach (n - a2 - b2 )/2 → (91 - 82 - 42)/2 = 5.5
When min_c = 3, then it is c2 = 9 ≥ 5.5, so min_c = 3

Step 6: Test values for c in the range of (min_c, max_c) --> (3, 3)

c = 3

Step 7: Determine if d is an integer solution which is √n - a2 - b2
max_d = √91 - 82 - 42 - 32
max_d = √91 - 64 - 16 - 9
max_d = √2
max_d = 1.4142135623731

Since max_d = 1.4142135623731 is not an integer, this is not a solution


b = 5

Step 5a: Determine max_c which is Floor(√n - a2 - b2)
max_c = Floor(√91 - 82 - 52)
max_c = Floor(√91 - 64 - 25)
max_c = Floor(√2)
max_c = Floor(1.4142135623731)
max_c = 1

Step 5b. Obtain the first value of b such that b2 ≥ (n - a2)/3, call it min_b
Start with min_c = 1 and increase by 1 until we reach or breach (n - a2 - b2 )/2 → (91 - 82 - 52)/2 = 1
When min_c = 1, then it is c2 = 1 ≥ 1, so min_c = 1

Step 6: Test values for c in the range of (min_c, max_c) --> (1, 1)

c = 1

Step 7: Determine if d is an integer solution which is √n - a2 - b2
max_d = √91 - 82 - 52 - 12
max_d = √91 - 64 - 25 - 1
max_d = √1
max_d = 1

Since max_d = 1, then (a, b, c, d) = (8, 5, 1, 1) is an integer solution proven below
82 + 52 + 12 + 12 → 64 + 25 + 1 + 1 = 91


a = 9

Step 3a: Determine max_b which is Floor(√n - a2)
max_b = Floor(√91 - 92)
max_b = Floor(√91 - 81)
max_b = Floor(√10)
max_b = Floor(3.1622776601684)
max_b = 3

Step 3b. Obtain the first value of b such that b2 ≥ (n - a2)/3, call it min_b
Start with min_b = 1 and increase by 1until we reach or breach (n - a2)/3 → (91 - 92)/3 = 3.3333333333333
When min_b = 2, then it is b2 = 4 ≥ 3.3333333333333, so min_b = 2

Step 4: Test values for b in the range of (min_b, max_b) --> (2, 3)

b = 2

Step 5a: Determine max_c which is Floor(√n - a2 - b2)
max_c = Floor(√91 - 92 - 22)
max_c = Floor(√91 - 81 - 4)
max_c = Floor(√6)
max_c = Floor(2.4494897427832)
max_c = 2

Step 5b. Obtain the first value of b such that b2 ≥ (n - a2)/3, call it min_b
Start with min_c = 1 and increase by 1 until we reach or breach (n - a2 - b2 )/2 → (91 - 92 - 22)/2 = 3
When min_c = 2, then it is c2 = 4 ≥ 3, so min_c = 2

Step 6: Test values for c in the range of (min_c, max_c) --> (2, 2)

c = 2

Step 7: Determine if d is an integer solution which is √n - a2 - b2
max_d = √91 - 92 - 22 - 22
max_d = √91 - 81 - 4 - 4
max_d = √2
max_d = 1.4142135623731

Since max_d = 1.4142135623731 is not an integer, this is not a solution


b = 3

Step 5a: Determine max_c which is Floor(√n - a2 - b2)
max_c = Floor(√91 - 92 - 32)
max_c = Floor(√91 - 81 - 9)
max_c = Floor(√1)
max_c = Floor(1)
max_c = 1

Step 5b. Obtain the first value of b such that b2 ≥ (n - a2)/3, call it min_b
Start with min_c = 1 and increase by 1 until we reach or breach (n - a2 - b2 )/2 → (91 - 92 - 32)/2 = 0.5
When min_c = 1, then it is c2 = 1 ≥ 0.5, so min_c = 1

Step 6: Test values for c in the range of (min_c, max_c) --> (1, 1)

c = 1

Step 7: Determine if d is an integer solution which is √n - a2 - b2
max_d = √91 - 92 - 32 - 12
max_d = √91 - 81 - 9 - 1
max_d = √0
max_d = 0

Since max_d = 0, then (a, b, c, d) = (9, 3, 1, 0) is an integer solution proven below
92 + 32 + 12 + 02 → 81 + 9 + 1 + 0 = 91


List out 8 solutions:

(a, b, c, d) = (5, 5, 5, 4)
(a, b, c, d) = (5, 7, 4, 1)
(a, b, c, d) = (5, 8, 1, 1)
(a, b, c, d) = (7, 4, 5, 1)
(a, b, c, d) = (7, 5, 4, 1)
(a, b, c, d) = (8, 3, 3, 3)
(a, b, c, d) = (8, 5, 1, 1)
(a, b, c, d) = (9, 3, 1, 0)

Special thanks to Stack Overflow for this algorithm suggestion


Lagrange Four Square Theorem (Bachet Conjecture) Video


Tags:



Add This Calculator To Your Website