Hamilton was the fourth of nine children born to Sarah Hutton (1780–1817) and Archibald Hamilton (1778–1819), who lived in Dublin at 38 Dominick Street. Hamilton's Father, who was from Dunboyne, worked as a solicitor. By the age of three, Hamilton had been sent to live with his uncle James Hamilton, a graduate of Trinity College who ran a school in Talbots Castle in Trim, Co. Meath.
In September 1813, the American calculating Prodigy Zerah Colburn was being exhibited in Dublin. Colburn was 9, a year older than Hamilton. The two were pitted against each other in a mental arithmetic contest with Colburn emerging the clear Victor. In reaction to his defeat, Hamilton dedicated less time to studying languages and more time to studying mathematics.
Around this time Hamilton was also preparing to enter Trinity College, Dublin, and therefore had to devote some time to classics. In mid-1822 he began a systematic study of Laplace's Mécanique Céleste.
Hamilton made important contributions to optics and to classical mechanics. His first discovery was in an early paper that he communicated in 1823 to Dr. Brinkley, who presented it under the title of "Caustics" in 1824 to the Royal Irish Academy. It was referred as usual to a committee. While their report acknowledged its novelty and value, they recommended further development and simplification before publication. Between 1825 and 1828 the paper grew to an immense size, mostly by the additional details that the committee had suggested. But it also became more intelligible, and the features of the new method were now easily seen. Until this period Hamilton himself seems not to have fully understood either the nature or importance of optics, as later he intended to apply his method to dynamics.
Hamilton's career at College was perhaps unexampled. Amongst a number of extraordinary competitors, he was first in every subject and at every examination. He achieved the rare distinction of obtaining an optime both for Greek and for physics. Hamilton might have attained many more such honours (he was expected to win both the gold medals at the degree examination), if his career as a student had not been cut short by an unprecedented event. This was Hamilton's appointment to the Andrews Professorship of Astronomy in the University of Dublin, vacated by Dr. Brinkley in 1827. The chair was not exactly offered to him, as has been sometimes asserted, but the electors, having met and talked over the subject, authorised Hamilton's personal friend (also an elector) to urge Hamilton to become a candidate, a step which Hamilton's modesty had prevented him from taking. Thus, when barely 22, Hamilton was established at the Dunsink Observatory, near Dublin.
While attending Trinity College, Hamilton proposed to his friend's sister, who rejected. Hamilton, being a sensitive young man, became sick and depressed, and almost committed suicide. He was rejected again in 1831 by Aubrey De Vere (1814-1902). Luckily, Hamilton found a woman who would accept his proposal. She was Helen Marie Bayly, a country preacher's daughter, and they married in 1833. Hamilton had three children with Bayly, but their married life turned out to be difficult and unhappy when Bayly proved to be pious, shy, timid, and chronically ill.
He was twice awarded the Cunningham Medal of the Royal Irish Academy. The first award, in 1834, was for his work on conical refraction, for which he also received the Royal Medal of the Royal Society the following year. He was to win it again in 1848.
In 1835, being secretary to the meeting of the British Association which was held that year in Dublin, he was knighted by the lord-lieutenant. Other honours rapidly succeeded, among which his election in 1837 to the president's chair in the Royal Irish Academy, and the rare distinction of being made a corresponding member of the Saint Petersburg Academy of Sciences. Later, in 1864, the newly established United States National Academy of Sciences elected its first Foreign Associates, and decided to put Hamilton's name on top of their list.
The other great contribution Hamilton made to mathematical science was his discovery of quaternions in 1843. However, in 1840, Benjamin Olinde Rodrigues had already reached a result that amounted to their discovery in all but name.
Hamilton introduced, as a method of analysis, both quaternions and biquaternions, the extension to eight dimensions by introduction of complex number coefficients. When his work was assembled in 1853, the book Lectures on Quaternions had "formed the subject of successive courses of lectures, delivered in 1848 and subsequent years, in the Halls of Trinity College, Dublin". Hamilton confidently declared that quaternions would be found to have a powerful influence as an instrument of research. When he died, Hamilton was working on a definitive statement of quaternion science. His son william Edwin Hamilton brought the Elements of Quaternions, a hefty volume of 762 pages, to publication in 1866. As copies ran short, a second edition was prepared by Charles Jasper Joly, when the book was split into two volumes, the first appearing 1899 and the second in 1901. The subject index and footnotes in this second edition improved the Elements accessibility.
Hamilton retained his faculties unimpaired to the very last, and steadily continued the task of finishing the Elements of Quaternions which had occupied the last six years of his life. He died on 2 September 1865, following a severe attack of gout precipitated by excessive drinking and overeating. He is buried in Mount Jerome Cemetery in Dublin. He had married Helen Bayly and had several children.
One of the features of Hamilton's quaternion system was the differential operator del which could be used to express the gradient of a vector field or to express the curl. These operations were applied by Clerk Maxwell to the electrical and magnetic studies of Michael Faraday in Maxwell's Treatise on Electricity and Magnetism (1873). Though the del operator continues to be used, the real quaternions fall short as a representation of spacetime. On the other hand, the biquaternion algebra, in the hands of Arthur W. Conway and Ludwik Silberstein, provided representational tools for Minkowski space and the Lorentz group early in the twentieth century.
A plaque under the bridge was unveiled by the Taoiseach Éamon de Valera, himself a Mathematician and student of quaternions, on 13 November 1958.
Since 1989, the National University of Ireland, Maynooth has organised a pilgrimage, where mathematicians take a walk from Dunsink Observatory to the bridge, where no trace of the carving remains, though a stone plaque does commemorate the discovery.
A 10 Euros commemorative silver Proof coin was issued by the Central Bank of Ireland in 2005 to commemorate 200 years since his birth.
William Rowan Hamilton's scientific career included the study of geometrical optics, classical mechanics, adaptation of dynamic methods in optical systems, applying quaternion and vector methods to problems in mechanics and in geometry, development of theories of conjugate algebraic couple functions (in which complex numbers are constructed as ordered pairs of real numbers), solvability of polynomial equations and general quintic polynomial solvable by radicals, the analysis on Fluctuating Functions (and the ideas from Fourier analysis), linear operators on quaternions and proving a result for linear operators on the space of quaternions (which is a special case of the general theorem which today is known as the Cayley–Hamilton theorem). Hamilton also invented "icosian calculus", which he used to investigate closed edge paths on a dodecahedron that visit each vertex exactly once.