1
$\begingroup$

How many pairs $(a,b)$ are there,such that $a^2 +b^2 = t^2$ where $a,b,t \in \mathbb{N}$ and $a,b \lt 15$?

I need a "fast" approach for solving this problem that could be work under a minute.

  • 3
    The fastest I know is if you know the basic Pythagorean triples: the only two are (3,4,5) and (5,12,13). Then you can multiply (3,4,5) by 2 or 3 and interchange a and b. Makes 8. Or do you include 0 in $\mathbb{N}$?2011-08-24
  • 0
    @Ross Millikan:$a$ and $b$ are non-zero positive integer,however the answer is stated as $9$ but I guess may be a typo?!2011-08-24
  • 2
    @FoolForMath: since $a\ne b$ and you can switch in any pair, the answer must be even.2011-08-24

2 Answers 2

4

There are only $2$ such primitive pairs by inspection:

  • $(3,4)$
  • $(5,12)$

Thus one also has:

  • $(6,8)$
  • $(9,12)$

There are thus $4$ pairs $(a,b)$ with $a,b < 15$.

Added: As pointed out by Ross in the comments to the original question, I did not account for the trivial swapping of $a$ and $b$. This then makes $8$ such pairs. Furthermore, if one includes $0 \in \mathbb{N}$, then $0^2 + a^2 = t^2$ is also a solution when $a = \pm t$.

2

If you just need the answers I would look at a list of Pythagorean Triples.

P.S. - Why do you need to solve this in under 1 minute?

  • 0
    Because that's the time you get to solve a question for which I am preparing for :)2011-08-24
  • 0
    Oh, well good luck with whatever it is.2011-08-24
  • 0
    Thanks I need it,this method of exams sucks though,not much room to show creativity in proofs and problem solving everything boils down to smart choosing of options and some mumbo-jumbo with calculations:/2011-08-24