Hexagonal Number - Test For Hexagonal Numbers

Test For Hexagonal Numbers

One can efficiently test whether a positive integer x is an hexagonal number by computing

If n is an integer, then x is the nth hexagonal number. If n is not an integer, then x is not hexagonal.

Read more about this topic:  Hexagonal Number

Famous quotes containing the words test and/or numbers:

    Tried by a New England eye, or the more practical wisdom of modern times, they are the oracles of a race already in its dotage; but held up to the sky, which is the only impartial and incorruptible ordeal, they are of a piece with its depth and serenity, and I am assured that they will have a place and significance as long as there is a sky to test them by.
    Henry David Thoreau (1817–1862)

    He bundles every forkful in its place,
    And tags and numbers it for future reference,
    So he can find and easily dislodge it
    In the unloading. Silas does that well.
    He takes it out in bunches like birds’ nests.
    Robert Frost (1874–1963)