# Hardy’s Course of Pure Mathematics

A while ago I bought a copy of Hardy’s “A Course of Pure Mathematics” for a fiver. I think I must’ve got it from Westwood Books ((Westwood Books has a really good collection of maths books – one of the owners is an ex-mathematician, and he finds his way to be in just the right place when departments clear out their libraries. I found a book by the only other mathematising Perfect I know of at Westwood. Great place!)) in Sedbergh.

Anyway, my imagination has completely run dry for the moment, so I’ve decided to do some exercises from the book to pass some time. Maybe this could become a series of posts?

Hardy says in the preface,

This book has been designed primarily for the use of first year students at the Universities whose abilities reach or approach something like what is usually described as `scholarship standard’.

…

I regard the book as being really elementary.

Nothing taxing, then. It occurs that I’m opening myself up to accusations of sloppy thinking and gross inaptitude at mathematics, but I suppose I’m better off knowing if that’s the case.

So here we go, **Chapter 1, Exercise 1**:

1. If

and $r$ are rational numbers, then $s$ , $r+s$ , $r-s$ , and $rs$ are rational numbers, unless in the last case $\frac{r}{s}$ (when $s=0$ is of course meaningless) $\frac{r}{s}$

As

Now assume

2. If

, $\lambda $ and $m$ are positive rational numbers, and $n$ , then $m>n$ , $\lambda ({m}^{2}-{n}^{2})$ , and $2\lambda mn$ are positive rational numbers. Hence show how to determine any number of right-angled triangles the lengths of all of whose sides are rational. $\lambda ({m}^{2}+{n}^{2})$

Using the facts from part 1,

As

Now for the triangles. For any rational numbers

So

I’m not sure why Hardy felt the need to include

3. Any terminated decimal represents a rational number whose denominator contains no factors other than

or $2$ . Conversely, any such rational number can be expressed, and in one way only, as a terminated decimal. $5$

Just for kicks, let’s do an induction.

*Inductive hypothesis*: Let

*Base case*: If

*Inductive step*: Assume IH true for

Hence,

which is an integer plus an integer, so an integer. So the induction holds for all

So, if

For the `conversely…’ part, suppose we have a number

If

Vice versa for

Can’t be bothered to think of some formatting for a lemma about the uniqueness of decimal representations, so: suppose two decimal representations of a number

So

So a number has a unique decimal representation ((strictly I’ve only proven at most one, but I don’t care about proving every number has at least one decimal representation)).

4. The positive rational numbers may be arranged in the form of a simple series as follows:

$$\frac{1}{2},\frac{2}{1},\frac{1}{2},\frac{3}{1},\frac{2}{2},\frac{1}{3},\frac{4}{1},\frac{3}{2},\frac{2}{3},\frac{1}{4},\dots $$ Show that

is the $\frac{p}{q}$ $[\frac{1}{2}(p+q-1)(p+q-2)+q]$ ^{th }term of the series.

This series is obtained by laying out the fractions

So if we’ve got a fraction

Now take away the fractions lying on the diagonal, leaving

Finally, ^{th} fraction encountered in its diagonal, because that diagonal starts at ^{th} term in the series.

## Comments

## Comments

Robert

Something’s wrong! Are you a professor or a mere student? 10k+1x=(10x)k=(10a+d)k=10k+1a+dk. That equation doesn’t make the point clear. y=5c−dn2c5d=5c−dn10c. That transformation is posing some problems to you, I think. It needs some modification or specification. Or your work’ll be a piece of shit! What the hell! Know math? Don’t even bother yourself to read this shit, bro!

christianp

Steady on! It just seems there were a couple of transcription errors, so thanks for pointing them out.

What were you hoping to achieve with such an aggressive tone?

Robert

Oh, are you the writer? I’m sorry for my tone because I have a predilection for aggression when something I spends my time patiently on becomes a travesty of value. If you’re the one who posted the work, I suggest you should make some corrections so that all the explanations seem clearer. Why don’t you correct right now?

I don’t quite understand Eg. 4. Someone help!

christianp

Which bit of question 4 don’t you understand?

Robert

I’ve tried to approach the problem by your idea, but I still don’t get it. I don’t understand especially 2nd, 3rd and 4th paragraph of the solution to Eg. 4. Can you make it clear? Hey, are you a graduate student? I haven’t attended a college. i’ve just finished my high school.

I’ve also bought Hardy’s book, but can’t find the solution he provided.

I’ve tried to solve it by myself. In the formula described in eg.4, I think +q ( of the last part of the formula) determines in which direction the series goes; if q is replaced by p, then the direction is reversed. I know p+q-1 represents the diagonal, but don’t know why it’s multiplied by p+q-2 then divided by 2. Can you help me?

Paul

Your description of the series via diagonals and rectangles is correct, but you mistyped in the series itself. It should be$\frac{1}{1},\frac{2}{1},\frac{1}{2},\frac{3}{1},\frac{2}{2},\frac{1}{3},\frac{4}{1},\frac{3}{2},\frac{2}{3},\frac{1}{4},\dots $

Anyway, when laid out in a grid like you suggested, it looks like this, so indeed, your description works.

I would also recommend amending the phrase, “Now take away the diagonal” to something like –Now take away the fractions that lie on the diagonal–. I kept thinking that the diagonal was merely an imaginary line of sorts (i.e., that one could take away the diagonal while leaving behind the numbers that lie thereon), so for awhile, I didn’t realize you actually meant to take away those numbers too while leaving behind only the numbers above and below the diagonal.

Once I realized what you meant, everything made sense.

All I can say is that I hope you quickly return to this labor and do keep up on this work. I’ve recently bought the book myself. I’m looking forward to the chapter on complex numbers.

@Robert$\frac{2}{3}$ is our rational number $\frac{p}{q}$ of interest.

To get what he means in the next to last paragraph, consider a square in the grid I drew above, say the 4X4 square containing only the terms shown below. Also, let’s say, just for example, that

(for example,

Alright, let’s take away that diagonal and the fractions it contains:

So, the squared part,$(p+q-1{)}^{2}$ , represents all of the fractions in the square before the fractions on the diagonal are removed, and $(p+q-1)$ represents the number of fractions on the diagonal itself. Thus, the number of fractions in the diagram above is $(p+q-1{)}^{2}\u2013(p+q-1)$ , which when worked out, simplified and factored (I guess, I didn’t do it myself) yields

The reason we are dividing this result by two is because we only want to count the fractions on the upper left half of the diagram, which is

Then we simply add back in the$q$ amount ($q=3$ ), which is the number of fractions down the diagonal to our number of interest $\frac{p}{q}$ .

Just to finish off, in our case, by the formula, the rational number$\frac{2}{3}$ is the NINTH number in the series, so if you plug p=2 and q=3 into the formula …

Paul

You might want to DELETE the post I just made. I realized that my third number grid did NOT typeset out right. I meant for the diagonal to remain there as empty spaces where the fractions were. Maybe I need to learn how to use that MathJax thing. Or if you can correct it yourself, that would be great. I’m talking about the third, or last, number grid shown above. Fractions 4/1, 3/2, 2/3, 1/4 were removed from the grid and should have been replaced by spaces that formed the diagonal of the square. Sorry about that.

christianp

Thanks for this! I’ve edited your post so it’s set properly, and edited mine so it makes sense.

shivesh suman

I have a simpler solution for the last question – here we group the terms to simplify things for us:

The series is:$(\frac{1}{1}),(\frac{1}{2},\frac{2}{1}),(\frac{3}{1},\frac{2}{2},\frac{1}{3}),(\frac{4}{1},\frac{3}{2},\frac{2}{3},\frac{1}{4}),\dots $

Here we outright start with the observation that in each subgroup, the numerator drops from the subgroup number to$1$ while the denominator rises from $1$ to the subgroup number. Consequently, their sum remains the same.

(the subgroup in which$\frac{p}{q}$ occurs would thus have $p+q-1$ terms, just on the basis of observation (more explanation follows). We observe that the sum of the numerator and denominator remains invariant in each group and is equal to the subgroup number $-1$ ). In the ${n}^{\text{th}}$ group the numerator goes from $n$ to $1$ and denominator goes from $1$ to $n$ , and ${k}^{\text{th}}$ subgroup has $k$ terms.

The first time$p$ appears is in the ${p}^{\text{th}}$ subgroup, but here $p$ appears in the numerator with a $1$ in the denominator. To have a $q$ in the denominator, it has to be at the ${q}^{\text{th}}$ place in its subgroup for which the numerator must have dropped down from $p+q-1$ to p. So, this is the $(p+q-1{)}^{\text{st}}$ subgroup and the term we are looking for appears at the ${q}^{\text{th}}$ place in this subgroup.

Adding the number of terms in the subgroups before the$(p+q-1{)}^{\text{th}}$ subgroup, i.e., up to the $(p+q-2{)}^{\text{nd}}$ subgroup we get: (using $\frac{n(n+1)}{2}$ for the sum of numbers, a simple arithmetic progression with a difference of $1$ )) the place of this ${q}^{\text{th}}$ term in the series to be: $\frac{1}{2}(p+q-2)(p+q-1)+q$ .

shivesh suman

I just noticed that there is a typo in the formula for sum of first n consecutive natural numbers in my post, it should be (n)(n+1)/2.

Christian Perfect

OK, I’ve fixed that. I’ve also edited your comment so that the maths is typeset with LaTeX.

Christian Perfect

Yes, that’s a nice and concise explanation, thanks.

shivesh suman

Thanks 🙂

shivesh suman

A small errata: the second term in third subgroup is (2/2).

Christian Perfect

Fixed.

Ranganathan

Some thoughts on your proof of uniqueness of decimal representation.$x$ be a terminated decimal. If $x$ has a terminated decimal representation with n digits after the point, ${10}^{n}x$ is an integer”. Trying to prove the same thing through uniqueness of integers …

You have already invoked induction to prove “Let

If I define the first representation of the rational number as

whereas in another distinct representation as

$$x=\sum _{k=0}^{m}{y}_{k}/{10}^{k}\to 2$$

where$n\ge m$ .

case (i)$n>m$ ${10}^{n}$ we get

$$1\Rightarrow {10}^{n}\cdot x={x}_{0}{x}_{1}{x}_{2}\dots {x}_{n}\to 3$$

$$2\Rightarrow {10}^{n}\cdot x={y}_{0}{y}_{1}{y}_{2}\dots {y}_{m}0\dots 0\to 4$$

Multiplying both sides by

since LHS is equal for$3$ and $4$ equate RHS integers. The integers would not be equal because $n>m$ , which destroys the equality. Hence, this case cannot exist.

case (ii)$n=m=p$ (say)

$$1\Rightarrow {10}^{p}\cdot x={x}_{0}{x}_{1}{x}_{2}\dots {x}_{p}\to 5$$

$$2\Rightarrow {10}^{p}\cdot x={y}_{0}{y}_{1}{y}_{2}\dots {y}_{p}\to 6$$

again equating RHS of$5$ and $6$ , unless the ${x}_{k}$ s are equal to the ${y}_{k}$ s, the integers would be different, which rules out the assumption that a distinct representation exists.

dave mecono de guzman

how to determine the decimal representation of rataional number and vice versa

Christian Perfect

What do you mean?