Council commends ‘outstanding’ police G20 work

July 9th, 2010

After an emotional morning-long debate, city council voted 36-0 to “commend the outstanding work” of Toronto Police Chief Bill Blair, his officers and other police forces working during the G20 summit in Toronto.

Two amendments — lauding Blair for supporting a civilian review planned by the Toronto Police Services board, and the board itself for “exercising its appropriate oversight role” — passed 35-1, with Councillor Rob Ford, a candidate for mayor, the nay on both votes.

See the whole article here.

Two interesting points:

“The decision was unanimous because some who voiced opposition to Grimes’s motion, including Councillor Gord Perks (Ward 14, Parkdale-High Park) and others from council’s left wing, weren’t present when the vote was called.”

… So where were they?

“Ford, alone in his vote opposing the inquiry, said that in the face of anarchists who ran down Yonge St. smashing shop windows, “our police were too nice.””

… Thanks for making my October voting decision a little easier, Ford. Do you also think Police Chief Blair was “too honest” about the scope of the Police’s authority throughout the G20 weekend?

There are too many reports and videos floating around about questionable strategies employed by security forces over the weekend to not have some kind of inquiry. If Ford isn’t on board with that, he doesn’t represent my interests.

And it certainly doesn’t help that he fails when it comes to environmental priorities:
http://www.torontoenvironment.org/voteto/priorities/reportcard#more

Dear Climate Change Deniers: Booyah!

July 8th, 2010

All I can say is, this article from Anderegg et al published earlier this year should be subtitled “Booyah!”

Abstract

Although preliminary estimates from published literature and expert surveys suggest striking agreement among climate scientists on the tenets of anthropogenic climate change (ACC), the American public expresses substantial doubt about both the anthropogenic cause and the level of scientific agreement underpinning ACC. A broad analysis of the climate scientist community itself, the distribution of credibility of dissenting researchers relative to agreeing researchers, and the level of agreement among top climate experts has not been conducted and would inform future ACC discussions. Here, we use an extensive dataset of 1,372 climate researchers and their publication and citation data to show that (i) 97–98% of the climate researchers most actively publishing in the field surveyed here support the tenets of ACC outlined by the Intergovernmental Panel on Climate Change, and (ii) the relative climate expertise and scientific prominence of the researchers unconvinced of ACC are substantially below that of the convinced researchers.

The full article is available online here:
http://www.pnas.org/content/early/2010/06/22/1003187107.abstract

SPAM Discussion Posters

April 8th, 2010

It’s not easy, posting to a blog. As soon as I open up the ability to post messages on the site, random postings start to appear that… I’m almost certain… are SPAM.

Some of them are more subtle than I expected, and I’m not sure if it’s just a friendly posting from someone who also happened to have a site to advertise. For example, one posting I received was

Nice site you have here; I love the colours!

Seems innocuous enough, except that the user also linked their name to a website. So … is that the only reason that the posting was made? And this begs the question: Is there anything wrong with that? In this case, I made a judgment call using a couple of simple criteria:

  1. Does this posting add value to the page? (No, it does not.)
  2. Does the comment seem genuine? (Not really — I’ve used the standard template.)

So I apologize to the commenter if that was an innocent compliment, but I didn’t accept it.

I received a couple of other comments, along the lines of

lol … nice site you have have going on here! a lot of sites seem to just be meaningless words, but it’s nice to see some intelligent commentary like this. keep it up — i’ll be back. but for now, i’m off to play some facebook blackjack. :)

So again, innocent enough until the last line… and the link to something related to it thrown into the poster’s info.

What’s a man to do? Am I being paranoid? Am I not quite embracing the expected Blogger’s etiquette?

Array Functions in Excel

March 29th, 2010

Keeping an Excel journal of my running has forced me to learn a few new tricks in Excel. The latest of these tricks is the ability to create array functions.

An array function in Excel is also knows as a Control-Shift-Enter (or CSE) function, because that’s what you have to hit (instead of just Enter) once you’ve entered the function in order to tell Excel that what you’ve just entered is an array function.

So what is an array function? Well, according to Microsoft, “An array formula is a formula that can perform multiple calculations on one or more of the items in an array.” Nice. And an array, for those of you who have never heard the term, is simply a set of values. For example:

{Monday, Tuesday, Wednesday, Thursday, Friday}

is an array of days of the week.

But back to Excel. Here’s the conundrum I was dealing with. I have a spreadsheet with the following data:

A B
Week Distance
1 5.5
1 7.9
2 12.3
2 5.3
2 3.5

Now, imagine I want to create a summary of my longest runs for each week. How is a man to manage this? Usually, finding the largest of a series of values uses the Max(RANGE) function; in Excel, this would give me the largest of a number of values. But how to select for the week? Something like CountIf would let me count up the number of instances for a given week number… and SumIf would let me sum them… but, sadly, MaxIf does not exist.

Looking for a MaxIf function, I stumbled across several references to array formulas. It turns out that, if I start with a column of week numbers, as in column D, below:

A B C D E
Week Distance Week (Summary) Longest Run
1 5.5 1
1 7.9 2
2 12.3 3
2 5.3 4
2 3.5 5

I can then create another column to display the maximum distance I’d run that week with the following:

={Max((A2:A65536=D2)*(B2:B65536))}

(Being sure to enter this formula without the curly brackets above, but hitting Control-Shift-Enter when I’m done.)

There are a couple of things to note, here:

  1. To explain the logic above: the entire array, A2:A65536 (the maximum row in Excel) is checked one at a time; if the element in the array = D2 (the week of interest) a 1 (“true”) is returned, which is then multiplied by the Distance. Otherwise, a 0 (“false”) is returned. Then, this array of distances and zeros is returned, and the Max function returns the highest one.
  2. Some may ask why I’ve decided to multiply these two arrays together instead of using an IF function, which should allow me a similar result. The reason is because it didn’t work, and I’m not sure why. Perhaps someone will enlighten me, some day.
  3. The reason I use A2:A65536 instead of just A:A (to select the entire column) is that doing the latter gives me an error. Including the non-numeric label in the range, apparently, confuses the array interpreter. (Though in actuality, I defined the ranges as “Week” and “Distance”.)

So that’s it — my adventure in array formulas. I hope this helps someone in need of a MaxIf function!

Coal power plants expose us to more radioactivity than nuclear ones

March 5th, 2010

This was a bit of a surprise to me. I knew that nuclear plants boasted less toxic waste, but less radioactive waste exposure?

I could paraphrase the Wikipedia article where I found this, but perhaps I’d better just quote it:

In countries with nuclear power, radioactive wastes comprise less than 1% of total industrial toxic wastes, which remain hazardous indefinitely unless they decompose or are treated so that they are less toxic or, ideally, completely non-toxic.[62] Overall, nuclear power produces far less waste material than fossil-fuel based power plants. Coal-burning plants are particularly noted for producing large amounts of toxic and mildly radioactive ash due to concentrating naturally occurring metals and radioactive material from the coal.

Recent reports claim that coal power actually results in more radioactive waste being released into the environment than nuclear power, and that the population effective dose equivalent from radiation from coal plants is 100 times as much as nuclear plants.[79] Indeed, coal ash is not more radioactive than nuclear waste, but nuclear plants use shielding to protect the environment from the irradiated reactor vessel, fuel rods, and any radioactive waste on site.[80]

Of course, there’s the possibility of a reactor meltdown, which is a fairly major inconvenience. But such events are quite rare. (Although the Pickering reactor, near my home, is on a major fault in the Canadian shield, so it’s something to think about.)

Still, it seems that having a nuclear reactor in my neighbourhood is better than having a coal plant, even when it comes to radioactive exposure.

Crazy stuff.

Balancing chemical equations: no more guessing!

March 1st, 2010

I’ve recently begun tutoring high school chemistry. Unfortunately, I’m quite rusty at the subject and, truth be told, it has never been one of my favourites. So I’ve been re-learning a lot of chemistry in the last little while to keep up with my students’ demands. I would begrudge it, if not for the fact that I really should be more comfortable with basic chemistry if I plan to continue a career in any area related to environmental science. So learn, I will.

In one of my lessons, I encountered a chemical equation that gave me and my student a little trouble when we tried to balance it. It’s not particularly complicated, and we happened upon the correct molar ratios eventually, but it highlighted what I felt was a deficiency in the way they’d been taught to balance equations at the high school level.

Here’s the chemical equation (not yet balanced):

Na3PO4(aq) +  Ba(OH)2(aq) —>  NaOH(aq) + Ba3(PO4)2(s)

And here’s the guidance, as provided by the lesson:

The third step is to show that atoms on both sides of the arrow are conserved. Remember that you cannot alter the formula of the compounds but you can alter the number or coefficients of the compounds or elements. A balanced equation has the smallest whole-number ratio of coefficients.

Now, though this provides the theory necessary to balance the equation, it stops short of actually providing a methodology for doing so. Instead, the expectation seems to be that students should “play around” with the coefficients until atoms are conserved (that is, until the same number of Na, Ba, etc are on each side of the equation).

In a lot of cases, that’s fine. But it’s hardly a scientific method, and as equations quickly become more complicated, it’s simply not sufficient. Fortunately, I remembered hearing something about an algebraic method for solving chemical equations a long time ago (we won’t get into quite how long ago). It’s not complicated. It goes like this:

Step 1: Assign each molecule a letter

A Na3PO4(aq) + B Ba(OH)2(aq) —> C NaOH(aq) + D Ba3(PO4)2(s)

Step 2: Create equations for each atom

For example, to balance sodium (Na), one can see that for every molecule A on the left of the equation, there must be three molecule Cs, so A = 3C. (Polyatomic ions can be considered as “one atom” for this purpose.)

Na –> 3A = C
PO4 –> A = 2D
Ba –> B = 3D
OH –> 2B = C

Step 3: Solve the equations

Now, there is not a unique solution to these equations, as you can always multiply all the terms by something to arrive at a different overall quantity of reactants/products. However, the ratios will remain the same. Thus, you can start by arbitrarily selecting a coefficient for any one of the values. I’m going to select “A = 1″. Once I plug that in, I end up with the following values:

If A = 1 :
Na –> 3A = C … C = 3

PO4 –> A = 2D … D = 1/2
Ba –> B = 3D … B = 3 /2
OH –> 2B = C

Oh no! I’ve got fractions! No worries — as I mentioned above, the actual values don’t matter: just the ratios. Simply multiply all of the coefficients by something that will kill the fractions (ideally, the lowest common denominator). In this case, that’s 2. So…

A = 1 x 2 = 2
B = 3/2 x 2 = 3
C = 3 x 2 = 6
D = 1/2 x 2 = 1

Step 4: Plug the coefficients back into the equation

2 Na3PO4(aq) + 3 Ba(OH)2(aq) —> 6 NaOH(aq) + Ba3(PO4)2(s)

This level of algebra should be understood by any student in grade 11 chemistry, so I don’t know why this method isn’t the first thing taught to them.

So I don’t know about you, but I’m through guessing.