Math: counting: multiply or add

Tutoring math 12, you may discuss counting problems.  The tutor offers a quick guide for when to multiply vs when to add.

One question you’re sometimes asked about counting is when you multiply, vs when you add.  The answer is simple.  Consider two events, one of which can happen n ways, while the other can happen m ways.

If the events are both going to happen, then the total number of different ways they can happen is nm; you multiply.  However, if only one of the events will happen, but it could be either one, then there are n + m outcomes; you add in that case.  Let’s consider a couple of examples:

Example 1

Bill is going to order dinner and dessert.  There are five dinner choices and three dessert choices.  How many ways can he order the two courses?

Solution:  We know he will order both, so we multiply to get the total number of possibilities.  He can order the two courses in 5×3 = 15 different ways.

Example 2

On a different night, Bill finds himself at another restaurant.  Being in a hurry, he will just order dinner.  There are seven meat choices and three vegetarian choices.  Looking at the menu, Bill is not yet sure whether he will go meat or vegetarian tonight.  How many possible orders could he give for dinner?

Solution:  Bill will only order one dinner.  However, he could go either meat or vegetarian.  Since we don’t know which, we must add the possibilities to get the total. He could order dinner in 7+3 10 different ways.

These counting rules are simple, yet they clarify a good many problems that might seem harder at first.  Good luck with your counting problems:)

Jack of Oracle Tutoring by Jack and Diane, Campbell River, BC.

Math: div and mod

Tutoring math, you know that div and mod are also fundamental to computer science.  The tutor presents them with an example.

Consider the age-old long division situation:

In this case, the question posed is “30 divided by 7”. The answer is “4, remainder 2.” But in terms of div and mod, what does it mean?

4 is the answer to 30 div 7. The div operation gives the integer quotient of a division: it gives the number of times the divisor can go in. The mod operator, on the other hand, gives the remainder of a division: 30 mod 7 is 2, just as shown above.

A really neat example of div and mod in action is the following:

Example: Convert 103 inches to feet and inches

Solution: Set it up long division style, like so:

The answer is that 103 inches is 8 feet, 7 inches. 103 div 12=8 gives the feet, while 103 mod 12=7 gives the inches. Once again: div gives the integer quotient, whereas mod gives the remainder.

For more implications of div and mod, come visit again:)

Jack of Oracle Tutoring by Jack and Diane, Campbell River, BC.

Math: radicals: rationalizing the denominator

Tutoring math, you cover this topic with students in late middle school or early high school.  The math tutor shows the first case.

This article assumes that the reader is familiar with multiplying radicals. If necessary, see my article here about that.

Rationalizing the denominator is done when there’s a radical on the bottom of a fraction.  Consider the following:

Example 1: Simplify 7/(2√(3))


To rationalize the denominator, you multiply the top and bottom by the same number. The number is chosen so it turns the radical on the bottom into a whole number:


Above, we have multiplied 7/(2√(3)), top and bottom, by √(3). We can do so because when you multiply the top and bottom by the same amount, the fraction’s value doesn’t change, just its form. Notice that √(3)√(3)=3. Therefore,


So it turns out that, when you rationalize the denominator,7/(2√(3)) becomes 7√(3)/6

Of course, there are more complicated situations where you have to rationalize the denominator. I’ll get to them in future posts:)

Jack of Oracle Tutoring by Jack and Diane, Campbell River, BC.

Math: multiplying radicals

Tutoring high school math, you realize that radicals are a problem for many. Today the math tutor gives brief coverage of multiplying radicals.

Consider the following example:

Simplify 3√(6)*4√(7)

Multiplying with radicals goes “number times number, radical times radical.” Like so:

Step 1: Number times number: In our case, 3 times 4, which gives 12.

Step 2: Radical times radical. In our case, √(6)√(7) gives √(42).

Putting it all together, we get


So far, so good. Beware, though: a simplification can creep in when the radicals are multiplied together:

Example 2: Simplify 3√(10)*7√(6)

Solution: Using number times number, radical times radical, we get


From my earlier post on simplifying radicals, we know we can’t just leave the answer 21√(60). After all, 60 contains the perfect square 4; we must simplify it as follows:


Note that if one of the factors is missing the number part, you just imagine it’s a 1 and proceed:


On the other hand, one of the factors might be missing the radical part. Then, you just multiply the numbers together and tack the radical at the end:


Visit again for more tips on operations with radicals:)

Jack of Oracle Tutoring by Jack and Diane, Campbell River, BC.

Organic chemistry: a beginning

The tutor knew that eventually, he would discuss organic chemistry.  While it might be mentioned only briefly in high school, it is important at university.

Organic chemistry is a bit different from the chemistry most students are first taught. Yet, in real life, organic chemistry is a much bigger field.  Plastics, drugs, insecticides – they’re all organic.

Here, we need to clarify a definition.  “Organic” now has two meanings.  The grocers and naturalists define it as “natural.”

To a chemist, however, “organic” means “carbon-based.”  Hence, from a chemist’s point of view, DDT is organic.

Recently the two definitions came into direct conflict when one of my students said her water was “organic.”  What she meant, of course, was that the water was “from a natural source.”  From a chemistry point of view, though, you can’t have organic water.  Being H2O, water is not carbon based.

Organic chemistry is a huge topic. In the beginning, nomenclature (how to name the compounds) is the focus. We’ll start today with some of that.

An alkane is an organic compound with only single bonds between the carbons. If it’s an alkane, but nothing more besides, then it just contains carbons and hydrogens. An example is propane:

This compound is propane because it has three carbons. Each joining line is a bond. Carbon makes four bonds and hydrogen makes only one, which dictates the structure of an alkane once you know how many carbons it has. You can tell an alkane because it ends in “ane”.

As the number of carbons grows, different arrangements become possible. For example, here are two possibilites for pentane:

Both structues are pentane since both have five carbons. Alkanes are named by how many carbons they contain as follows:

number of carbons name of alkane
1 methane
2 ethane
3 propane
4 butane
5 pentane
6 hexane
7 heptane
8 octane
9 nonane
10 decane

There is much more to say about organic chemistry, even at the high school level. For further discussion, see future posts:)

Source: Solomons, T.W. Graham. Organic Chemistry, 4th edition. 1988: John Wiley & Sons, Inc.

Jack of Oracle Tutoring by Jack and Diane, Campbell River, BC.

Math: Finding the slope of a line

Tutoring math, you know this skill is essential.  The math tutor provides a quick explanation and example.

The concept of slope is known to all in everyday life.  In math, it is defined as follows:


Indeed, slope is often referred to as m. The rise refers to the change in height; the run, to the change in horizontal position.

This article assumes you understand points on the cartesian plane. If you don’t, see my article here.

Example: Let’s imagine you need the slope of the line pictured here:

We need to realize three facts:

1) Every point is (x,y); x means horizontal position, while y means vertical.

2) “Change” means the final value minus the initial value.

3) Once again, the rise refers to the change in height; the run, to the change in horizontal position.

Now we involve the equation for slope:


Notice that (x1,y1) means “the first point”, while (x2,y2) means “the second point.” It’s helpful to label your two points (x1,y1) and (x2,y2). Next, carefully insert the values in their right places in the equation:


Simplifying, we get

m=-135/340=-27/68 or -0.397

Slope is always pictured from left to right. If a line rises to the right, its slope is positive. The line in our example falls to the right; hence, its slope is negative.

The slope of a line has many applications, which I’ll be discussing in future posts:)

Jack of Oracle Tutoring by Jack and Diane, Campbell River, BC.

Biology: diffusion

When you tutor biology, molecular movement and transport are topics you need to explain.  Front and centre is diffusion.

Diffusion is the tendency of particles to move from an area of high concentration to lower concentration.  It happens spontaneously, meaning it does not require an output of energy.

Moving from high concentration to lower concentration can be referred to as following the concentration gradient.  Therefore, diffusion follows the concentration gradient. The gradient can be thought of as a “slope” that the molecules “roll down” to get to lower concentration.

In everyday life, diffusion is everywhere.  Consider, for instance, a pleasant walk on a calm, dark night.  You smell steaks barbecuing.  You look around, but can’t seem them. Yet, the airborne aromatic molecules have reached you from the barbecue.  That movement of the molecules from the cooking steaks to your nose is an example of diffusion.  Note that it happens by itself; it’s spontaneous.

The human body relies on diffusion for some means of transport.  For instance, at the cell membrane, oxygen passes in and carbon dioxide leaves by diffusion.  It’s perfect: since the cell is constantly using oxygen, its concentration is always low inside.  The concentration of oxygen in the surrounding blood is much higher.  Therefore, oxygen constantly diffuses into the cell.  Carbon dioxide, on the other hand, is constantly being produced in the cell, but is much lower in the blood.  Therefore, it diffuses out of the cell into the blood, whence it is carried away.

The cell can depend on diffusion for gas exchange for two reasons:

1)  The cell membrane is permeable to oxygen and carbon dioxide.

2)  Diffusion happens fast enough, at the cellular level, to be effective.

Permeable means that it can be passed through.  The cell membrane is permeable to oxygen and carbon dioxide, allowing them to diffuse in and out.  The cell membrane is not permeable to many molecules and/or ions, however.  For briefing on that issue, check my post here about the cell membrane.

The reason that diffusion happens fast enough, at the cellular level, for effective gas exchange is that the cell is very small. Therefore, it has high efficiency. See my post here about cell efficiency.

Diffusion is only one method of transport in the body. It is spontaneous, but depends on permeability and efficiency. It is sufficient, for example, for gas exchange between the cells and the blood. However, there are many other contexts in which diffusion is not sufficient. Therefore, I’ll be discussing other transportation methods in future posts:)

Source: Mader, Sylvia S. Inquiry into Life, 11th edition. New York: McGraw-Hill, 2006.

Jack of Oracle Tutoring by Jack and Diane, Campbell River, BC.

Computer science: interpretation of the perl for loop

Tutoring math, you are likely aware of its connection to computer science.  The math tutor continues the explanation of the perl for loop.

In my previous post, I began exploring the field of computer science with a look at a for loop. The loop was written in perl. Now I will explain, line by line, the meaning of the loop code:

for ($i=0;$i<3;$i++){

print “The counter is now at $i.\n”;


First off, the dollar sign in front of the i means that i is a variable. In perl, a variable has a dollar sign in front of it to show it’s a variable. Programmers often call a counter variable i, j, or k. So $i means “the counter variable i”.

$i<3 means that as long as the value of i is less than three, the loop will continue running. When i equals 3, the program will exit the loop.

$i++ means that every time the program executes the loop, it adds 1 to the counter variable (also known as incrementing the counter variable by 1). Importantly, a for loop increments the counter variable at the end, rather than at the start.

The brace { means the program is entering the loop body, which contains the commands to be executed during each pass through the loop (also known as each iteration of the loop). In our case, there is only one instruction:

print “The counter is now at $i.\n”;

print means display what’s in the quotation marks. The $i is displayed as its value each time. Substituting the value of a variable in a quoted sentence is called interpolation. The \n means “newline”.

Now, the program reaches the closing brace }, which means the loop instructions are complete for this cycle. It’s time to increment the counter and return to the beginning of the loop. If $i<3, the loop will execute again.

Hence the output

The counter is now at 0.
The counter is now at 1.
The counter is now at 2.

Hope this clarifies the perl for loop. In a coming post I’ll mention how to get (or find) perl on your own system, should you want to experiment with the code yourself:)

Source: Robert Pepper’s Perl Tutorial. Robert taught me almost everything I know about perl:)

Computer Science: the for loop

Tutoring math – especially if you have a degree in it – you likely realize that some of your students are on their way to computer science courses.  The math tutor opens the discussion on programming with the concept of the for loop.

Although computer programming offers separation from the machine that was unknown twenty years ago, the basic constructs of how a computer processes data are more relevant than ever.  After all, more and more people are, undoubtedly, headed towards the field.

A loop is a repeating operation that continues until some external condition is met.  Alternatively, the loop may be infinite.

The for loop is the type of loop that is often learned first in computer programming.  Its basic structure:


the number of times a counter variable remains less than the upper limit


these instructions
increase the counter

back to for

Giving a real example of a for loop, the immediate question is which language to use. Imagine a space traveller arrived on earth and asked how to say “Hello”. You’d tell them “Hello” in your own language; there isn’t a universal way to say it.

Computer science offers the added complication that preferred languages change. Someone “in the know” might well ask, Why did you show it in that language?

The language I’m introducing the for loop in is perl. Known as “the duct tape of the internet,” it was critical in the early web boom. Now it has competition from some languages purported to be easier to use. Perl is famously powerful and well-loved by its own programmers. It was developed by Larry Wall in 1987. The name is an acronym: Practical Extraction and Reporting Language.

Here is a perl for loop:


print “The counter is now at $i.\n”;


The above loop outputs the following:

The counter is now at 0.
The counter is now at 1.
The counter is now at 2.

For a detailed explanation of how the code above produces that output, please return soon. I’ll also discuss how to start experimenting with perl yourself, should you catch the bug:)

Jack of Oracle Tutoring by Jack and Diane, Campbell River, BC.