# Number of animals based on legs: Claire looks at some animals and counts 38 legs.

#### patelsm

##### New member
hi,
This question is for my 10 year old (Year 6 in the UK).

[FONT=&quot]A bird has 2 legs, a cat has 4 legs, an insect has 6 legs and a spider has 8 legs.[/FONT]
[FONT=&quot]Claire looks at some animals and counts all their legs.[/FONT]
[FONT=&quot]She counts 38 legs.[/FONT]
[FONT=&quot]There are twice as many birds as spiders and twice as many cats as insects.[/FONT]
[FONT=&quot]How many of each type of animal can she see?
[/FONT]

We tried to build an equation based on the above:
b + c + i + s = 38
but for me this does not sound right because b,c,i and s will need to be total number of animals that make 38 legs?
Then we have the information where there are twice as many birds as spiders and twice as many cats as insects.
So this will make the above equation:
2s + 2i + i + s = 38
3s + 3i = 38

...i do not think i am going anywhere with this...so we tried the "manual" method

bird has two legs
cat has 4 legs
insect has 6 legs
spider has 8 legs
so at the minimum level if we add all the legs to together we get:

birds (4) + cats (8) + Insects (6) + spider (8) = 26
but we still need to get 38 i.e 38 - 26: 12 more...however we cannot see how we can get 12 more because there is a link between cats and insects, birds and spiders...if we add an insect or spider we will only go upto 36....

Any direction on this will be helpful.

saf

#### Dr.Peterson

##### Elite Member
hi,
This question is for my 10 year old (Year 6 in the UK).

A bird has 2 legs, a cat has 4 legs, an insect has 6 legs and a spider has 8 legs.
Claire looks at some animals and counts all their legs.
She counts 38 legs.
There are twice as many birds as spiders and twice as many cats as insects.
How many of each type of animal can she see?

We tried to build an equation based on the above:
b + c + i + s = 38
but for me this does not sound right because b,c,i and s will need to be total number of animals that make 38 legs?
Then we have the information where there are twice as many birds as spiders and twice as many cats as insects.
So this will make the above equation:
2s + 2i + i + s = 38
3s + 3i = 38

...i do not think i am going anywhere with this...so we tried the "manual" method

bird has two legs
cat has 4 legs
insect has 6 legs
spider has 8 legs
so at the minimum level if we add all the legs to together we get:

birds (4) + cats (8) + Insects (6) + spider (8) = 26
but we still need to get 38 i.e 38 - 26: 12 more...however we cannot see how we can get 12 more because there is a link between cats and insects, birds and spiders...if we add an insect or spider we will only go upto 36....

Any direction on this will be helpful.

saf
You want an equation that says the total number of legs is 38. Your b + c + i + s = 38 says that the total number of animals is 38.

So, how many legs will b birds, c cats, i insects, and s spiders have? Well, each bird has 2 legs, so that makes 2b legs in all; and so on.

Similarly, you need separate equations saying that there are twice as many birds as spiders and twice as many cats as insects. The first of these says that the number of birds (b) is twice the number of spiders (s). So b = 2s.

Can you finish up? You will have only 3 equations for 4 variables, so it will not be strictly algebra; you will in the end have to find a positive integer solution by trial and error.

#### patelsm

##### New member
You want an equation that says the total number of legs is 38. Your b + c + i + s = 38 says that the total number of animals is 38.

So, how many legs will b birds, c cats, i insects, and s spiders have? Well, each bird has 2 legs, so that makes 2b legs in all; and so on.

Similarly, you need separate equations saying that there are twice as many birds as spiders and twice as many cats as insects. The first of these says that the number of birds (b) is twice the number of spiders (s). So b = 2s.

Can you finish up? You will have only 3 equations for 4 variables, so it will not be strictly algebra; you will in the end have to find a positive integer solution by trial and error.
Thanks for the response Dr P.
this is what I get:
b +c + i + s = 38
we know b = 2s and c = 2i
so replacing this in the equation I get:
2s + 2i + i + s = 38
3s + 3i = 38
this does not look correct because to test this equation, if i replace s and i by the number of their legs respectively, i will not get 38
24 + 24 = 38
48 not equal to 38...
so i think i understood it incorrectly...

sorry

#### patelsm

##### New member
Thanks for the response Dr P.
this is what I get:
b +c + i + s = 38
we know b = 2s and c = 2i
so replacing this in the equation I get:
2s + 2i + i + s = 38
3s + 3i = 38
this does not look correct because to test this equation, if i replace s and i by the number of their legs respectively, i will not get 38
24 + 24 = 38
48 not equal to 38...
so i think i understood it incorrectly...

sorry
Doctor P, i think i got the answer
4 birds, 2 cats, 2 spiders and 1 insect

this was done using manual method so i started of with the basic number
2 birds, 2 cats, 1 insects and 1 spider = total legs is 26
to get 38 i needed 12 more legs - and this can be done by adding another spider (8) which requires adding two birds (4 legs) = 12

but i still would like to teach her using the trial/error algebric method...please help

#### JeffM

##### Elite Member
Doctor P, i think i got the answer
4 birds, 2 cats, 2 spiders and 1 insect

this was done using manual method so i started of with the basic number
2 birds, 2 cats, 1 insects and 1 spider = total legs is 26
to get 38 i needed 12 more legs - and this can be done by adding another spider (8) which requires adding two birds (4 legs) = 12

but i still would like to teach her using the trial/error algebric method...please help
A preliminary point: trial and error is part of mathematics, but is called numerical methods to make it sound impressive. The fundamental idea in numerical methods is to figure out ways to reduce the work involved. So we use algebra as much as we can before wasting time on silly guesses. Does that make sense?

So we write down equations, letting b stand for the unknown number of birds, c stand for the unknown number of cats, i stand for the unknown number of insects, and s stand for the unknown number of spiders.

$$\displaystyle 2b + 4c + 6i + 8s = 38.$$

$$\displaystyle b = 2s.$$

$$\displaystyle c = 2i.$$

Now I "see" that we cannot have as many as 5 spiders, which would have 40 legs, or as many as 7 insects, which would have 42 legs. Thus, we can reduce the number of guesses by focusing on insects and spiders. This is where experience has value.

So we can start by simplifying the first equation to be spider-oriented.

$$\displaystyle b = 2s \text { and } 2b + 4c + 6i + 8s = 38 \implies 2 * 2s + 4c + 6i + 8s = 38 \implies$$

$$\displaystyle 4c + 6i + 4s + 8s = 38 \implies 4c + 6i + 12s = 38.$$

And next we can simplify further to make the equation above insect-oriented.

$$\displaystyle c = 2i \text { and } 4c + 6i + 12s = 38 \implies 4 * 2i + 6i + 12s = 38 \implies$$

$$\displaystyle 8i + 6i + 12s = 38 \implies 14i + 12s = 38.$$

Now we start guessing systemtically.

$$\displaystyle \text {No spiders } \implies 14i + 12 * 0 = 38 \implies 14i = 38 \implies i = \dfrac{38}{14} \implies$$

$$\displaystyle i \text { is not a whole number } \implies s = 0 \text { IS WRONG.}$$

$$\displaystyle 1 \text { spider } \implies 14i + 12 * 1 = 38 \implies 14i + 12 = 38\implies$$

$$\displaystyle 14i = 26 \implies i = \dfrac{26}{14} \implies i \text { is not a whole number } \implies s = 1 \text { IS WRONG.}$$

$$\displaystyle 2 \text { spiders } \implies 14i + 12 * 2 = 38 \implies 14i + 24 = 38 \implies 14i = 14\implies$$

$$\displaystyle i = \dfrac{14}{14} = 1 \text { SUCCESS.}$$

$$\displaystyle s = 2 \implies b = 2 * 2 = 4.$$

$$\displaystyle i = 1 \implies c = 2 * 1 = 2.$$

Let's check to ensure we made no mistakes.

4 birds means 8 legs.

2 cats means 8 legs.

2 spiders means 16 legs.

1 insect means 6 legs.

8 + 8 + 16 + 6 = 38.

I am not sure whether the combination of algebra and guessing was more efficient in this rather basic problem, but you can probably see that, in more complicated problems, using algebra and perhaps calculus can greatly reduce the amount of trial and error required.

Last edited:

#### Dr.Peterson

##### Elite Member
Thanks for the response Dr P.
this is what I get:
b +c + i + s = 38
we know b = 2s and c = 2i
so replacing this in the equation I get:
2s + 2i + i + s = 38
3s + 3i = 38
this does not look correct because to test this equation, if i replace s and i by the number of their legs respectively, i will not get 38
24 + 24 = 38
48 not equal to 38...
so i think i understood it incorrectly...

sorry
But you defined s as the number of spiders, not the number of legs on a spider, right? This is a reason to be clear on the definitions of variables.

Doctor P, i think i got the answer
4 birds, 2 cats, 2 spiders and 1 insect

this was done using manual method so i started of with the basic number
2 birds, 2 cats, 1 insects and 1 spider = total legs is 26
to get 38 i needed 12 more legs - and this can be done by adding another spider (8) which requires adding two birds (4 legs) = 12

but i still would like to teach her using the trial/error algebric method...please help
You seem to have missed the whole point about the main equation. The total number of legs is 2 per bird + 4 per cat + 6 per insect + 8 per spider, so that

2b + 4c + 6i + 8s = 38

Your other equations are correct:

b = 2s
c = 2i

So we can replace b and c in the equation,

2(2s) + 4(2i) + 6i + 8s = 38

This simplifies to

12s + 14i = 38

Dividing by 2,

6s + 7i = 19

The trial and error part is easy: if s=1, 7i has to be 13, which doesn't work; if s=2, 7i has to be 7, which is fine. (And if s>2, i has to be less than 1.) So we have

s=2
i=1
b=2(2) = 4
c = 2(1) = 2

So that is the algebraic way. (There are more advanced ways to solve an equation whose solutions have to be integers (called a Diophantine equation), but with small numbers trial and error in the last part is much quicker.)

When you talk about a "manual method", so you mean fully trial-and-error, with no algebra but using logic? Your work is good; if it were not inferred that there is at least one of each, there would be more work needed, and you might have needed to be more systematic. Such reasoning is in some ways a more important thing to learn than algebra.