# The tutor reports another of his tree finds.

Back in my June 21 post, I reminisced about the black locust trees of the Annapolis Valley, Nova Scotia. I have some news in that direction.

On August 3, returning from Courtenay to Campbell River, I was convinced we passed a few black locust trees. However, I didn’t ask my wife to stop the car so I could check one close up. I decided to wait, anticipating that later in the summer another opportunity would arise.

Yesterday, down in Nanaimo, I once again, from a distance, recognized the lacy foliage of a black locust. Passing close by, I saw the deeply furrowed bark; the tree was possibly 80 ft tall, its crown perhaps 50 ft across.

We pulled into our nearby destination. After my family went inside, I walked back towards the suspected black locust to make a close-up inspection. I never reached it; there was one much closer, in a better situation for examination. Brown pods littered the grass around it.

So we have a positive ID of black locust in Nanaimo:)

Source:

Brockman, Frank, Rebecca Merrilees and Herbert Zim. Trees of North America.
New York: Golden Press, 1968.

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

# The tutor follows up his earlier post about an algorithm for exponentiation.

In my Aug 28 post I brought up exponentiation and a straightforward algorithm that uses a loop. However, there is a less straightforward, yet more efficient, algorithm for it:

#!/usr/bin/perl

\$orbase=ARGV[0];#reads original base as a param. from function call
\$orexp=ARGV[1];#the original exponent
\$exp=\$orexp;
\$base=\$orbase;#this program changes the exponent and base
\$res=1;#this variable will become the result

while(\$exp>0){

if(\$exp%2==1){#checks if the exponent is odd
\$res*=\$base;
}

\$exp=int(\$exp/2);#for example: int(11/2)=5

if(\$exp>0){
\$base*=\$base;
}

}#end while loop
print “\$orbase to the exponent of \$orexp is \$res\n\n”;

Let’s assume this file is named exp.txt. To call it and ask it to evalute 210, one would type at the command prompt

perl exp.txt 2 10

This algorithm is more efficient than the looping one because it can square the base, then halve the number of times it needs to be multiplied by itself. Furthermore, it can separate the expression into even and odd segments, then tackle the even one(s) as just described.

I’ll be talking more about the details of this algorithm in future posts:)

Source:

Grimaldi, Ralph P. Discrete and Combinatorial Mathematics. Addison-Wesley: Toronto,
1994.

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

# The tutor discusses the change in weather on BC’s south coast.

From early July until mid August, our summer has been uncommonly hot and dry. While we did receive one or two well-timed rains, the threat of forest fires has been unnerving.

I doubt the forest fire risk profile has officially changed at this moment, but we received heavy rain today. Looking at a weather map, I think I can see why.

The map shows us under a low pressure system, with a cold front also present. Although I’m not trained in weather, my simple explanation for the heavy rain is this: The low pressure system, which comprises warm, moisture-filled air (some of tropical origin) is colliding with the cold front. As the air in the low pressure system cools down, it can no longer hold so much moisture, so drops it as rain. The heavy rainfall results from the plunge in temperature as the low pressure system hits the cold front.

Over the next three days more rain is forecast:)

Source:

theweathernetwork.com

cbc news

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

# By way of finding a power of a number the tutor opens a discussion about algorithms.

Years ago my computer science professor presented the following definition:

An algorithm is a set of steps to solve a problem.

Suppose there wasn’t a dedicated function to calculate ab. Then one would need to devise an algorithm for it. One might commonly imagine a loop that multiplied the base by itself the necessary number of times;eg:

#!/usr/bin/perl

\$base=\$ARGV[0];
\$expon=\$ARGV[1];

\$ans=1;

for(\$i=0;\$i<\$expon;\$i++){
\$ans*=\$base;#means \$ans=\$ans*\$base;
}
print “\$base to the exponent \$expon is \$ans\n\n”;

Perhaps surprisingly, there is another way of evaluating ab that is more efficient. I’ll be introducing that algorithm soon.

Currently we are anticipating heavy rainfall on the west coast. It’s a welcome development after a very dry summer; I’ve high hopes it will squelch the forest fire hazards. Perhaps a coming post will celebrate this change in weather:)

Source:

Grimaldi, Ralph P. Discrete and Combinatorial Mathematics. Addison-Wesley: Don
Mills, 1994.

# The tutor further explores the golden ratio.

In my previous posts here and here, I’ve discussed some aspects of the golden ratio. Trying to find other special facets of it, I’ve dreamed up color combinations that express the golden ratio between colors:

Recalling that the golden ratio is approx. 162:100, behold the following color mixes:

100 red: 162 blue

162 red: 100 blue

162 red: 100 green

100 red: 162 green

162 green: 100 blue

100 green: 162 blue

If you feel something special in these color combinations, it’s possibly attributed to the golden ratio:)

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

# The tutor shares another surprise from Boggle.

I’ve seen the word anon in various places, but can’t remember where. Of course, it’s an abbreviation for anonymous.

Playing Boggle with the family the other night, I had the opportunity to make anon, so I did, hoping it means more than just the abbreviation of anonymous.

Merriam-Webster says that, indeed, anon means soon. I’ll admit my Oxford Canadian doesn’t include that definition.

I’ll be sharing my vocabulary finds as they develop:)

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

# The tutor reveals how he solved a problem with Windows Live Mail.

As the in-house computer troubleshooter, I received the following request from my wife today: “I can’t open .pdf attachments from within the email program, but I always could before. Now I have to copy them to the desktop and open them thence. Please fix it so they can be opened from within the email program like before.”

My wife rarely brings me a computer problem. We run Windows 7 with Bitdefender, and update our software regularly. However, the rare occasion I learn of a problem seems just as often after an update. I know that Windows did an update a few days back; perhaps an unanticipated change resulted.

The problem of not being able to open .pdf attachments from within the email program, so having to copy them to the desktop to open from there, is commonly reported on the Web. I looked at several solutions, none of which turned out to be the fix for my case.

After an hour’s digging around, I opened Adobe Reader XI from the Start menu. On the toolbar I clicked Help; the resulting dropdown menu includes the choice Repair Adobe Reader Installation. I clicked that, and was greeted with the question Do you really want to repair? Nervously I informed the program that, indeed, I did want to repair it. The repair began. After a couple of notices and progress bars, I was informed that, to complete the repair, I had to restart the computer. After doing so, the email attachments could once again be opened from within the email program.

That’s how I fixed the problem.

Good luck with your computer troubleshooting: )

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

# The tutor shares a definition he stumbled upon.

I’ve never thought about it much, but always believed I knew the difference between a lake and a pond. However, the guessing is over for any who may be in doubt; I encountered the distinction between them in a biology text the other day:

Throughout a pond, light penetrates full depth, so plants live everywhere along the bottom. By contrast, a lake contains water deeper than light penetrates; parts of its bottom do not host plants.

Some of my reading suggests that sunlight can penetrate 25 to 100 metres deep in water. Therefore, a lake must be quite deep indeed – possibly 80 to 330 feet – unless its water is cloudy enough to block sunlight at shallower depth.

Many inland bodies of water I would have called lakes are, I suppose, ponds.

I’ll be sharing more of my biology browsings in future posts:)

Source:

Ritter, Bob. Nelson Biology. Scarborough: Nelson Canada, 1996.

lakeaccess.org

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

# The tutor continues about the golden ratio.

In yesterday’s post I brought up the golden ratio. Historically, it’s believed to be the ideal shape for a rectangle. The ratio of length to width is

(1+5^(1/2)):2 or 1.618:1

Below is a rectangle whose shape is indeed the golden ratio of length to width:

Is the golden ratio the ideal shape for a rectangle? You be the judge:)

Source:

Wikipedia

w3.org

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

# The tutor introduces the golden ratio.

The golden ratio is defined as x/y, where

x/y = (x+y)/x, x>y, y>0

Muliplying both sides by xy gives

x^2=xy+y^2

x^2-xy-y^2=0

Using the quadratic formula to solve for x, we imagine

x=(-b ± (b^2-4ac)^0.5)/(2a)

based on

ax^2+bx+c=0

In our particular equation is

a=1, b=-y, c=-y^2

x=(-(-y)±((-y)^2-4(1)(-y^2))^0.5)/(2*1)

Simplifying, we get to

x=(y+(5y^2)^0.5)/2 or x=(y-(5y^2)^0.5)/2

which becomes

x=(y+y(5)^0.5)/2 or (y-y(5)^0.5)/2

Since x>0,

x=(y+y(5)^0.5)/2 only.

Continuing to simplify, we get

x=y(1+5^0.5)/2

So the golden ratio, x/y, is

x/y = (y(1+5^0.5)/2)/y = (1+5^0.5)/2 ≈ 1.618

I’ll be discussing the golden ratio further in future posts:)

Source:

Wikipedia

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