Advertisement
Sorceress

Sum of kth powers

Sep 24th, 2022
200
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.62 KB | None | 0 0
  1. Sums of kth powers
  2. ------------------
  3.  
  4. The Waring problem: all positive integers are a sum of at most g(k) kth powers of positive integers
  5. where g(k) is the minimum such quantity
  6.  
  7. g(k) = 1, 4, 9, 19, 37, 73, 143, 279, 548, 1079, 2132, 4223, 8384, 16673, 33203, 66190, 132055, 263619, 526502, 1051899
  8.  
  9. It is conjectured that g(k) = 2^k + floor((3/2)^k) - 2
  10.  
  11. k=1: every integer is a sum of 1x singlets:
  12. N = a^1
  13. eg, 1 = 1
  14.  
  15. k=2: every integer is a sum of 4x squares:
  16. N = a^2 + b^2 + c^2 + d^2
  17. eg, 7 = 4 + 1 + 1 + 1
  18.  
  19. k=3: every integer is a sum of 9x cubes:
  20. N = a^3 + b^3 + c^3 + d^3 + e^3 + f^3 + g^3 + h^3 + i^3
  21. eg, 23 = 8 + 8 + 1 + 1 + 1 + 1 + 1 + 1 + 1
  22.  
  23. k=4: every integer is a sum of 19x hypercubes:
  24. N = a^4 + b^4 + ... + s^4
  25. eg, 79 = 16 + 16 + 16 + 16 + 1 + 1 + 1 + 1 + 1 + 1 + 1 + 1 + 1 + 1 + 1 + 1 + 1 + 1 + 1
  26.  
  27. -------------------------------------------------------------------------------
  28.  
  29. Imagine (a) such that a^k < N < (a+1)^k
  30.  
  31. N is too small for (a+1)^k to be a term in the summation, so N must be
  32. represented by several copies of a^k, and a remainder made up of smaller
  33. terms. At an extreme, we can imagine those smaller terms would all be 1s.
  34.  
  35. N = x copies of a^k + [remainder]
  36.  
  37. Because of the adversarial nature of this game, we have to maximise x, to
  38. force use of a maximal number of "large" terms in the summation.
  39.  
  40. 2^k is the smallest term we can add other than 1, so to prevent 2^k contributing
  41. to this remainder, the remainder must be 1 less than 2^k. This maximises the
  42. number of 1s, while preventing larger terms appearing.
  43.  
  44. a^k < N < (a+1)^k
  45. N = x copies of a^k + (2^k - 1) copies of 1.
  46.  
  47. What is the value of a? Combining these expressions:
  48.  
  49. x.a^k + 2^k - 1 < (a+1)^k
  50.  
  51. x < (1 + 1/a)^k + (1 - 2^k)/a^k
  52.  
  53. To maximise x, we clearly must make (a) as small as possible. It cannot
  54. be 1, because of the above arguments, so a = 2 it is.
  55.  
  56. Which means that:
  57.  
  58. x < (3/2)^k + 1/2^k - 1 = (3^k + 1)/ 2^k - 1 < (3/2)^k - 1 => x = floor[(3/2)^k] - 1
  59.  
  60. Therefore,
  61.  
  62. g(k) = x + (2^k - 1) = floor[(3/2)^k] + 2^k - 2
  63.  
  64. And,
  65.  
  66. N = (floor[(3/2)^k] - 1) copies of 2^k, plus (2^k - 1) copies of 1.
  67.  
  68. N = 2^k * (floor[(3/2)^k] - 1) + 2^k - 1
  69.  
  70. N = 2^k * floor[(3/2)^k] - 1
  71.  
  72. Examples:
  73.  
  74. N(1) = 2^1 * floor(3/2) - 1 = 2*1 - 1 = 1
  75.  
  76. 1 = 1^1
  77.  
  78. N(2) = 2^2 * floor(9/4) - 1 = 4*2 - 1 = 7
  79.  
  80. 7 = 2^2 + 1^2 + 1^2 + 1^2
  81.  
  82. N(3) = 2^3 * floor(27/8) - 1 = 8*3 - 1 = 23
  83.  
  84. 23 = 2^3 + 2^3 + 1^3 + ... + 1^3
  85.  
  86. N(4) = 2^4 * floor(81/16) - 1 = 16*5 - 1 = 79
  87. N(5) = 2^5 * floor(243/32) - 1 = 32*7 - 1 = 223
  88. etc
  89.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement