test for hexagonal numbers
Given an arbitrary positive integer , one can determine whether or not it is a hexagonal number by calculating
If is an integer, (that is, ), then is a hexagonal number. If is a triangular number but not a hexagonal number, then , with being an odd integer. In all other cases, will be an irrational number.
It will suffice to work out an example of each. We choose 1729, 277770576188160 and 1900221452387519291741168640. With the exception of 1729, these numbers have been deliberately chosen so that they would be so big that in Sloane’s OEIS they would be crowded out by much smaller numbers.
1729 has many properties, and it is relevant here to note that is 12-gonal and 24-gonal. But is it hexagonal?
Though 1729 is a figurate number in a few different ways, hexagonal is not among them.
Given set to 277770576188160, . Clearly this is a rational number, but not an integer. This tells us that 277770576188160 is a triangular number but not a hexagonal number.
Given 1900221452387519291741168640, our is 30823866178560, an integer. If we plug in this integer into the formula for hexagonal numbers, we should get 1900221452387519291741168640 back, confirming that this number is in fact the 30823866178560th hexagonal number.
Title | test for hexagonal numbers |
---|---|
Canonical name | TestForHexagonalNumbers |
Date of creation | 2013-03-22 17:50:54 |
Last modified on | 2013-03-22 17:50:54 |
Owner | PrimeFan (13766) |
Last modified by | PrimeFan (13766) |
Numerical id | 6 |
Author | PrimeFan (13766) |
Entry type | Result |
Classification | msc 11D09 |