John's primary education began in 1925 when he entered the Waterside School in Bishops Stortford. In 1929, his last year at this elementary school, he was taught Latin and algebra. He then was sent as a boarder to Bembridge School on the Isle of Wight. The education at this school appeared poor and after two terms his parents took him away from the school and sent him instead to a preparatory school in Stratton Park near Bletchley which he attended from 1930 to 1934. Here, after a poor experience with his first mathematics teacher, he was taught by Gerald Meister :-
During his time at Stratton Park he gave me a solid education in mathematics and a liking for the subject. This covered plenty of Euclidean geometry (including such topics as the nine-point circle) and algebra (Newton's identities for roots of polynomials) and trigonometry (identities governing angles of a triangle, circumcircle, incircle, etc), but no calculus. Due to his help, I got a scholarship to Sedbergh.At Sedbergh he gained qualifications in mathematics, physics and chemistry in 1937. Then, in December 1937, he sat the scholarship examination for Emmanuel College, Cambridge. Having no success, in March 1938 he sat the scholarship examination of New College, Oxford, but again was not successful. Another attempt to win a scholarship to Emmanuel College in December 1938 was successful and he entered the College to begin his university studies in 1939. Of course the start of World War II in that year interrupted his university studies. He enlisted and continued to study mathematics at Cambridge while waiting to be called up for military service. He only obtained a 3rd class pass in the examinations of 1940, then began his war service in the Royal Artillery :-
I was called up for military service in the late summer of 1940, first as a gunner and next as a lance-bombardier at a training camp at Arborfield until being sent to an officer training cadet unit at Shrivenham. I was commissioned as a second lieutenant in the spring of 1941 and posted to an anti-aircraft gun site defending an armament factory near Warsham.Hammersley had learnt of the experiments being conducted with radar while at Shrivenham and he now requested that he receive training :-
This training began with a six weeks course on basic wireless technology at the Regent Street Polytechnic, followed by a longer and more specialized course on radar at Watchet in Somerset. ... On passing out of Watchet as a qualified I.F.C., which carried the automatic rank of captain, I was posted first to an establishment at Oswestry which trained operators of radar equipment, and next to anti-aircraft brigade headquarters in the Orkneys where I was responsible for the radar installations of the gun sites defending Scapa Flow. Finally in 1942 I was transferred to the Trials Wing at Lydstep.In fact this war service proved highly significant in fashioning the future direction of his mathematical career:-
There were certain bits of mathematics, of which I had no previous knowledge; in particular I needed to learn about numerical methods and statistics. ... to cover this [lack of knowledge of statistics] I obtained leave of absence to return to Cambridge for a few weeks. The first volume of M G Kendall's book on mathematical statistics had just been published. I also read R A Fisher's book on statistical methods for research workers. Statistical techniques played an important role at Lydstep in assuring the performance of anti-aircraft radars and predictors, and in liaising with radar developments from the Radar Research Establishment at Malvern. By the end of the war I had been promoted to the rank of major, and appointed a consultant to the Ordnance Board in London.Returning to Cambridge in 1946 after the end of World War II, Hammersley was now considerably more motivated than he had been in his pre-war university year. He graduated as a Wrangler in Part II of the Mathematical Tripos in 1948 having enjoyed courses from A J Ward, J A Todd and R A Lyttleton. He had already begun publishing statistical papers with The "effective" number of independent observations in an autocorrelated time series, a joint publication with G V Bayley apprearing in the Journal of the Royal Statistical Society in 1946. After graduating he applied unsuccessfully for lectureships at the universities of Reading and St Andrews, then was appointed ;-
... as a graduate assistant at Oxford in the Lectureship in the Design and Analysis of Scientific Experiment.While at Oxford he published papers such as The unbiased estimate and standard error of the interclass variance (1949), The numerical reduction of non-singular matrix pencils (1949), Further results for the counterfeit coin problems (1950), The distribution of distance in a hypersphere (1950), and On estimating restricted parameters (1950). Reviewing this last mentioned paper D G Chapman writes:-
Several estimation problems are considered where the parameter space is a discrete set of points. These problems introduce variations from those usually encountered and at the same time focus attention on some of the deeper aspects of the whole general question of estimation. The extensive discussion, in particular, raises several questions in this direction.Hammersley published a variety of papers in 1951 including A theorem on multiple integrals, On a certain type of integral associated with circular cylinders, The sums of products of the natural numbers, and The total length of the edges of the polyhedron. In the same year he married Shirley Gwendolene Bakewell, known as Gwen, on 14 June. They had two sons Julian (born 1954) and Hugo (born 1956).
In 1955 he was appointed as Principal Scientific Officer at the Atomic Energy Research Establishment, Ministry of Supply, at Harwell, Berkshire. After four years, he returned to Oxford in 1959 when appointed as Senior Research Officer at the Institute of Economics and Statistics. He was promoted to Reader in Mathematical Statistics in 1969, and in the same year was elected to a Professorial Fellowship at Trinity College, Oxford.
Geoffrey Grimmett writes :-
He was the only mathematics don at Trinity until Chris Prior joined in 1976, and he organised Trinity Maths in his own special way. If there were no sufficiently strong candidates in any given year, he would admit none. He believed an Oxford Tutor should be capable of teaching every branch of his subject for the undergraduate degree, and that undergraduates should, in principle, be able to answer questions in all areas. If he was not acquainted with an area, he would work it out live within the tutorial. True to his beliefs, he volunteered classes on problem-solving, but his problems were rather difficult, and few students were able to meet his high standards. Those able to make some progress recognised him as a tremendous force for good in their mathematics education.In  Grimmett writes:-
John Hammersley was an exceptionally inventive mathematician and a fearless problem-solver. He had the rare ability to identify the basic mathematics of a scientific problem, and to develop an applicable theory. His most outstanding achievements were in the two areas of spatial disorder and Monte Carlo methods, and his scientific legacies in these important fields have proved extremely influential.One of the areas which typified Hammersley's mathematical contributions was in Monte Carlo methods, a technique to estimate a quantity through computations involving random numbers. It is an important method to solve problems using a probabilistic method and in much used in computer systems to attack very hard problems. In 1965, after contributing many papers on the topic, Hammersley published the book Monte Carlo Methods, jointly authored with D C Handscomb. R R Coveyou writes in a review that the little book of only 178 pages:-
... deserves to become the standard introduction to the study of Monte Carlo methods. No detailed analysis of its content is here made because it would be irrelevant. Anyone interested in the subject should read the book. Also, anyone who reads the book will, with probability one, become interested in the subject, and will be able to begin to use it.The book was translated into French and published as Les méthodes de Monte-Carlo in 1967. With the publication of the book Hammersley seemed to feel that he should move on to other topics, which indeed he did. Although this was his only book, he did publish around 135 papers. Let us note the title of a few of these papers to indicate the breadth of his interests: Electronic computers and the analysis of stochastic processes (1950); The absorption of radioactive radiation in rods (1951); Capture-recapture analysis (1953); Tables of complete elliptic integrals (1953); Percolation in crystals: gravity crystals (1956); The zeros of a random polynomial (1956); On the statistical loss of long-period comets from the solar system (1961); The mathematical analysis of traffic congestion (1962); Long-chain polymers and self-avoiding random walks (1963); Contribution to discussion on subadditive ergodic theory (1973); The design of future computing machinery for functional integration (1985); and Biological growth and spread (1980).
In addition to his research, Hammersley was also passionately interested in mathematical education and wrote many articles on the topic. His views are clearly stated in the titles of some of these papers, such as: On the enfeeblement of mathematical skills by 'Modern Mathematics' and by similar soft intellectual trash in schools and universities (1968); and Modern mathematics, the great debate: Motion proposing that this house deplores the enthusiastic teaching of modern mathematics, particularly in schools (1973).
In 1987 he retired from his positions in Oxford and David Kendall gave a Speech proposing the toast to John Hammersley - 1 October 1987 which was subsequently published under this title. Hammersley was also honoured with a conference at the Mathematical Institute in Oxford in 1990 to celebrate his 70th birthday. Many colleagues and friends came to wish him well and to speak about work which had been influenced by his contributions. The proceedings of the conference were published under the title Disorder in physical systems edited by G R Grimmett and D J A Welsh (who were both Hammersley's doctoral students).
Hammersley received many honours for his outstanding contributions. He was awarded the Von Neumann Medal for Applied Mathematics by the University of Brussels (1966). He was elected to the Royal Society in 1976. In 1984 he was awarded the Gold Medal of the Institute of Mathematics and its Applications, and the Polya Prize of the London Mathematical Society in 1997. He gave the 1980 Rouse Ball lecture under the title Room to wriggle at Cambridge University.
Article by: J J O'Connor and E F Robertson