Magic Hexagon

Author

Eric W. Weisstein
August 9, 2004

This notebook downloaded from http://mathworld.wolfram.com/notebooks/RecreationalMath/MagicHexagon.nb.

For more information, see Eric's MathWorld entry http://mathworld.wolfram.com/MagicHexagon.html.

©2005 Wolfram Research, Inc. except for portions noted otherwise

Hexagonal Numbers

Table[3n(n-1)+1,{n,10}]

Magic Constant

Table[((9(n^4-2n^3+2n^2-n)+2)/(2(2n-1))),{n,20}]

Through[{Numerator,Denominator}[%]]

Solutions

Reduce[((9(n^4-2n^3+2n^2-n)+2)/(2(2n-1)))==k &&n>0&&(k|n)∈Integers,{k,n}]

Table[((9(n^4-2n^3+2n^2-n)+2)/(2(2n-1))),{n,20}]

Factor[9(n^4-2n^3+2n^2-n)+2]

Reduce[((1-3 n+3 (n^2))/(2(2n-1)))==k&&n>0&&(k|n)∈Integers,{k,n}]

Reduce[((2-3 n+3 (n^2))/(2(2n-1)))==k&&n>0&&(k|n)∈Integers,{k,n}]

{((1-3 n+3 (n^2))/(2(2n-1))),((2-3 n+3 (n^2))/(2(2n-1)))}/.n->3