My BarCamp presentation disaster

It was the longest 15 minutes I had ever lived through in the recent decade.

It was the 5th BarCamp held in Singapore, on the 27th March 2010. My friends were attending, and one of them said it would be great to present. And he bullied me into presenting as well. It would also be an opportunity to build what the social media people were calling the “personal branding”, so I thought “why not?”.

BarCamp is an event where people gather to give presentations, hold discussions over shared topics and generally share ideas. I’m sure I gave the wrong definition, and you can find more pertinent information yourself.

Well, I don’t have a lot of presentation experience, so I had my work cut out for me. I needed a topic first, and I also searched around for presentation advice (Andrew Lightheart dishes out good tips).

For over a week, I prepared my notes, mostly in my head, because it didn’t feel concrete enough to be fleshed out into presentation material. I watched some TED videos to hopefully gain some of the presenters’ charisma and flair. I researched on what BarCamp attendees were (probably) like, to better speak to them.

Well, 3 days before the event, I scrapped my notes and begun anew. Covering many ideas, my polymath nature sought to teach many things and will surely achieve nothing for that group of people. I even wanted to juggle (thank goodness I didn’t), to emphasise a point.

Eventually, I settled on what I previously wanted to write an ebook about, “Discipline and Deflection“. And here was where I willingly and knowingly made a mistake. On the day of the event, I put up “Discipline and Deflection” as the topic for voting (attendees voted on the topics they most wanted to hear about).

I’ve studied blogging and writing tips before. I’ve even studied Internet marketing techniques. What’s the most important thing to note? The title. In this case, the topic title.

Surprisingly, the topics most sought for were HTML5, entrepreneurship, and start ups. There’s also a small undercurrent of interest in non-tech stuff. So, understanding human interests, my topic should preferably have included a number (preferably odd, better if it’s prime because they irk the human psyche), plus any keywords involving “HTML5”, “entrepreneur”, and “start up”, plus the usual attention-catching words such as “sex”, “violence”, and “relationships”.

So my ideal topic title should have read “7 tips on using HTML5 to discipline yourself to focus on being an entrepreneur and creating start ups, while deflecting distractions about having sex, doing violence and still have a healthy relationship”. But I’m not a bombastic writer. If you’ve been reading this blog for any significant amount of time, you would probably have noticed my titles aren’t any stand-outter. I mean, “Why are signals from passive optical networks split into 32?“? That probably bored the typical adolescent student to tears after hearing the title.

And the typical adolescent student, aged 18 years or so, comprised maybe a third of the attendees. Probably because it’s held at Singapore Polytechnic. So I decided to ignore all those tips and appealed to curiosity instead, and simply stated “Discipline and Deflection”.

Zero takers. Unless you count that one vote from my friend.

Discipline and Deflection

Well, it was still early in the morning. And my friend got selected for speaking, so the bunch of us went to support that friend. He’s talking about “A Hacker’s Guide to Financial Independence“.

Hacker Guide to Financial Independence

Much attention, many questions, and much follow-up after his talk. He’s good.

I went back to check on my submission. A couple more sticker votes, but the morning slots were all taken up, so I’ll have to wait till the afternoon to know if I’m to speak. I had fun with the morning sessions, and was nervous at the same time.

Lunch came and went.

And practically everyone went for the Aikido session, because, well, it’s Aikido, and there’s a hot chick doing the demonstration.

There was this mounting feeling of stuttering somewhere between my heart and my throat. You know that feeling where you’re nervous and when you speak, your words fall over each other and you can’t quite string together a few words to form a sentence? Yeah, that feeling.

I checked the submission board again. My topic was still there. All the early submissions were already assigned a time slot, and mine was the only piece of paper on the left side of the board, bravely and defiantly challenging anyone with a mote of curiosity to vote, like a weed growing unabashedly amidst a rose garden, like a smudge of dirt on a pristine white wall.

My thoughts were scattering like a flock of pigeons chased by a playful child, and my feelings were fluttering like a butterfly from flower to flower. To make matters worse, I couldn’t find my friends. There were only 4 (5?) rooms for presentation, and somehow, my cognitive powers failed to accomplish the simple act of locating my friends. I wandered the corridor, and flit from room to room, neither really listening to the presenter nor brave enough to stand along the corridor with my thoughts (and the reminder that my submission was still on the board). Which was ironic, since I was going to talk about focussing and distractions.

It was mid-afternoon, and I finally found my friends when they emerged from a presentation room. There was one presentation at the 4pm slot (about publishing and ebooks), and then all the interesting topics would have been covered. Mine was still on the board. I had half a mind to wrench my submission off the board and end my misery there and then. I left it as is, and we went for a coffee/tea break.

After our break, I went (yet again) to the board. It’s not there anymore! I’m not sure whether I was happy or sad at that point. I went to the master list of presentations, and it wasn’t listed. Did someone tear down my submission? I went to the rooms, and found my submission pasted onto the door of room C.

Room C presentation
[I added the subtext because from my friend’s comment, it wasn’t clear what it was about. Not that it cleared any confusion. But my mind was in a confused state then.]

I was assigned the 5:30pm slot, the very last time slot of the event. I didn’t see any of the organisers at that point. The master list wasn’t even updated with my submission topic (everyone else’s was, even the other 5:30pm slots), even though it was selected. The sessions my friends and I wanted to attend were all attended, save the ebook publishing one at 4pm. And my friends, good people that they are, decided to stay the entirety of the event just to attend my presentation.

At about 5:20pm, we went into room C. There were perhaps 7 people in the room. I sat down some 3 rows away from the presenter. I could tell he was palpably frustrated and dejected, because he was going through his points and slides with taps on his keyboard filled with unmistakeable resignation and anger. I believe it was on something about sTeam, and he was asking for help with user interface design. Well, he still had 1 person responding to him with questions, if nothing else.

Then it was my turn. Yeah, after reading over a thousand words, you finally reached the point where I’m going to talk about my presentation.

My friend wanted to help assuage my feelings of unhappiness by standing up and introducing me. That actually created the opposite effect. There were 10 people in the room, excluding me. 4 were my friends, 2 were standing at the back (probably ready to sprint to another place), and 4 were seated.

Vincent presenting at BarCamp
[thanks to Aaron who took this photo]

I started with “getting started“, with references to Merlin Mann. No one knew who Merlin Mann was, or Inbox Zero (which Merlin was famous for), or maybe they were too tired or scared or found it bothersome to raise their hands. I said it wasn’t necessary that you had to buy a moleskine to jot down your notes. That you don’t need a killer app to organise all your notes so you can finally start on that project of yours. You can just start.

Then I talked about Seth Godin and his latest book Linchpin, that people have difficulty finishing projects, of shipping. That there’s a resistance, the lizard brain that’s giving you the final obstacle to completing that project of yours.

It was at this point that the 2 people standing at the back disappeared. I don’t know. Who could blame them? The topic being discussed next door was “The Future Of XXX” where XXX starts with “P” and rhymes with “corn”. I was starting to inherit (even more of) the frustration and dejection from the previous presenter in that room.

I continued with my accidental discovery of disciplining myself by “adventuring”. I took a 5 hour long walk from the centre of Singapore to the east end of Singapore, which was approximately 21 kilometres in length. There was a point in that journey of mine where I was tired, hungry, thirsty, and a long stretch of road with empty grass on both sides of it. And that was the last part of my journey, and I likened it to the 17 mile mark of the 26 mile marathon, where marathoners start to doubt their ability to go on. Breaking through that point, to continue on that long stretch of road, was a key to developing discipline.

Out of the 4 attendees seated (who were not my friends), only 1 was listening. The other 3 were just there for the free electricity and wireless connection. I had only 1 listener (so to speak). Celine Dion was singing “It’s All Coming Back to Me Now” in my mind, where I remembered how destitute I was when I started writing this blog. It was one thing to know that the rough estimated number of people reading was only 1. It’s another to see right in front of you, only 1 person listening to you. To be frank, I was getting ready to FTS.

Suppressing that urge to just walk out of the room, I told a story of Garion, a young sorcerer, trying to move a rock. Which I wrote about before in the discipline and deflection article. I talked of Newton’s 3rd Law of Motion:

Every action has an equal and opposite reaction

Then I mentioned the concept of duality in mathematics, that of changing a problem from one form to another. And solving one form of the problem is equivalent to solving the other form. Graphs (in graph theory) have a dual form. So do sets of linear inequalities or equations. And proof by contradiction is an example of proving the alternate form of the original statement.

“Perhaps the discipline to focus is the dual of the deflection of distractions?” I proposed. “Solve one, and you solve the other.”

Then I brought in Elizabeth Gilbert, a writer who talked about this separation of the self from the genius (That’s a TED talk, and it’s awesome. Go watch it first before returning here to find out more about my mishappening), the source of inspiration and creativity.

I continued something like:

Why don’t we take this further? We separate the body, the mind, this genius, and this consciousness that is us. The body does the thing you want to do, the mind focusses on the task at hand, the genius providing inspiration and creativity. And the consciousness that is you? You go deflect all the distractions that’s coming your way. Because when you’re focussing on the task, there is, by Newton’s 3rd Law, an equal and opposite force trying to distract you.

There will always be distractions. Even if you take out Twitter and Facebook and email, there will still be distractions. Twitter and Facebook are just distractions to your real distractions.

Even if I put you in a room with no outside connections, you will still face distractions.

I’m hungry. Where’s the coffee? I need my caffeine. The room’s too hot. The room’s too cold. I don’t want to write with a pencil, where’s my pen? They are all going to laugh at me. This will never succeed.

The distractions ultimately come from you.

The distractions ultimately come from you. That’s why it has an equal and opposite force to you focussing.

Well, I ended with trying to convince the lone listener (and maybe my friends too) that the future depends on you finishing that crazy project you’re passionate about. That game you’re creating. That art you’re painting. That book you’re writing. That software you’re coding. That building you’re designing. That invention you’re thinking of. That race around the world you’re doing.

I asked if there were any questions, and not surprisingly, there were none. It was 15 minutes since I stood in front of a room that’s 2 tutorial rooms combined, which made the audience that much silencer. I sat down beside my friends, tired, strained and completely drained, and they didn’t know what else to do. Then I suggested we go over next door to see what the XXX was about. It was full and standing room only, not surprisingly.

The anguish and frustration and nervousness and humiliation and embarrassment and anger that built up since 9:30am that morning, and crescendoed at 5:30pm, was finally over. I wished I had never submitted in the first place. I wished the votes were more decisive, either more so I know I’m gonna speak, or so much less that it’s impossible I get to speak. I wished the organisers had ignored the votes and chosen some other topic. I wished the audience veered towards content (like you) instead of bombastic titles.

But I stayed. Because as Hugh MacLeod said,

this is totally stupid. this is utterly moronic. this is a complete waste of time.

i’m going to do it anyway.

Because Elizabeth Gilbert said that, even if what we did was not inspiring, not magical, we should be proud that we have the sheer stubbornness to keep showing up. To do our part.

My friends and I went for dinner. I was barely succeeding in trying to keep my spirits up. A friend recorded my session, but I didn’t have the strength to go through it or even put it up here. Then we went for dessert. I went for the ginormous ice cream mudpie. Females aren’t the only ones who can drown their sorrow in ice cream you know…

And that was how I spent that Saturday at BarCamp. Now if you’ll excuse me, I’m going to go curl up in a corner and wallow in self pity.

Udja Eye and Egyptian fractions

It was one of those friend meetups. No, my engineer friend did not approach me with a twinkle in his eye to top his last math problem. However, my sociologist friend had something…

“Eh Vince, I got something to show you. You know about the Udja Eye?”
“The what?”

So he showed me this book “The Secret History of the World” by Jonathan Black (or Mark Booth as the author explained).

“It’s got fractions and stuff. Wait, lemme find it for you…”

Then he flipped through the book, and “Here! Udja Eye.” It looks interesting. “I was thinking you could do something with it for one of your Math Wizard powers.” (bless the man) I noted the term down for further research because another friend wanted to read through the book first.

Fast forward maybe a week later, that friend with the book (my engineer friend, coincidentally) practically shoved the book at me. “Vince, you have got to read it.” As of this writing, I haven’t started reading it yet. I wanted to find out more about this Eye first. It looks like this:

Eye of Horus
[source image]

According to my research, apparently “Udja Eye” was not a popular term. It was frequently referred to as “Wedjat (Eye)”, “Wadjet (Eye?)”, “Udjat Eye”, “Oudjat” or the easier to pronounce version “Eye of Horus“. It had been Eye of the Moon, and then Eye of Ra. Which is confusing (to me at least), because Ra (or Horus) is the Egyptian god of Sun.

“I see it’s an Egyptian thing…” you say.
“Are you trying to be funny?”

Oh wait,

Since Horus was said to be the sky, he was considered to also contain the sun and moon. It became said that the sun was his right eye and the moon his left, and that they traversed the sky when he, a falcon, flew across it.

That kind of explained the eyes of moon and sun thing. Wait, what falcon? Oh nevermind…

So what about the fractions? It turns out that the Eye of Horus is composed of 6 fractions.

Oudjat
[source image]

Don’t ask me why it’s reversed…

In the Ancient Egyptian measurement system, the Eye Of Horus defined Old Kingdom number one (1) = 1/2 + 1/4 + 1/8 + 1/16 + 1/32 + 1/64, by throwing away 1/64 for any rational number. Eye of Horus numbers created six-term rounded-off numbers. The Old Kingdom definition had dropped a seventh term, a remainder 1/64, that was needed to report exact series.

The confusion sets in…

I did some more research. And Wikipedia failed me. I don’t want to look at any other search results because “Udja Eye” (and its variants) is an esoteric topic, and appears to have connections with the occult. Basically I don’t trust search results on this. I’m looking specifically for the math background, but some historic information is also appreciated. And possibly needed (to explain the math stuff). This feels like a “Da Vinci Code” moment…

I read up on Egyptian mathematics and fractions. Still no clue.

So I’m undergoing psychic damage because of:

  • What is “Old Kingdom” math? How does it work?
  • Why is the 7th term (1/64) dropped? Is it because the Egyptians valued the 5 senses and thought (so total 6)? Or the ancient Egyptians couldn’t work with the higher precision?
  • Did the hieroglyphics for the fractions appear first? Or was the Eye of Horus formed, and then individual parts were used to denote the fractions?
  • Horus‘ mother, Isis did what to her murdered husband Osiris’ uh, manhood? It was thrown in the Nile and eaten by a catfish?!?
  • In a battle, Horus ripped off his uncle Seth’s (who’s the murderer of Osiris) testicles (?!? must they be so graphic)?
  • Seth tried to seduce Horus and inseminate him with his, oh I can’t even go on…
  • What is wrong with these people?!?

*take deep breath* Ok. So. Maybe the book my sociologist friend lent me will shed some light…

Working for myself

From today 15 March 2010 onwards, I will be working for myself. (Today’s article won’t have any math or programming stuff, so you might want to skip this if you’re not interested in entrepreneurship, online businesses, or personal journey kind of thing.)

It was a tough decision, but I realised that the decision was made a long time ago when I started writing this blog. Nearly 3 years ago, I started writing, in part because I needed an outlet to put my thoughts down, and in part to see what this “blogging” thing was all about. On the way, I learned what I could of online businesses; what they are and how to set them up.

Nearly 3 years later, I still don’t have something compelling to offer. I’ve looked at probably every way to earn something through this blog. Blog advertising, paid posts, affiliate products and the variants of each method. I don’t like them (or they don’t work), and they don’t fit with the blog. They “uglify” the site, and don’t add value to you.

So I took everything out and just continued to write. Once, I was asked why I continue to write when there’s clearly no benefit. I don’t get paid. My blog’s not popular. There are hardly any comments, let alone other bloggers linking to me.

That would be disheartening if not for the fact that I installed FeedBurner and Google Analytics. They tell me how many people subscribe to my blog RSS feed, and how many people visit my blog. The statistics aren’t even close to what a mid-range blog have. Yet they are consistently growing, albeit slowly.

So why do I continue to write? Because of you. Because you continue to read what I write, even if you choose to remain silent (which is totally ok). Which makes the few times where I get to hear from you all the more worthwhile.

Anyway, back to that working for myself thing. Since there’s little I could do to monetise this blog, I started Honeybeech where I write about games and RPGs and Dungeons and Dragons. That blog gave me a glimmer of chance to start an online business.

All this had been done part-time. I write software, design user interfaces, handle user queries, and generally solve problems in my day job. And I write about math and programming at night. And learn all those things about online businesses at night too. The goal had always been to set up a part-time business, and grow it enough so it can feed me and support my family. And then I’ll quit my day job, and be free to do whatever I want. Which is most probably that business, and write math and programming articles here.

I actually didn’t consider my (old) day job to be a “day job”. “Day job” has a negative connotation that it’s just a way to earn money. Mine wasn’t like that to me. At least it wasn’t when I started out. I got to learn new things and the people I worked with were great. Everyone worked hard, little (if any) office politics (backstabbing was unheard of), and they were professional in their work.

Now, consider job satisfaction. The key point of distinction between places to work is rarely the work you’ll be asking the employee to do. It’s the perceived connection between the employee and the people she works with. – Linchpin, Seth Godin

As time went by, my colleagues left one by one, either due to personal reasons or company rule (downsizing). What used to be a vibrant garden for me became a lonely graveyard. Sure, no one wanted to discuss C pointers with me, but at least I had company.

The work I was tasked to do wasn’t interesting any more. I started to stagnate. My programming skills plateaued. There weren’t any projects for me to apply new skills.

Think of all the reasons why you’re doing whatever it is you do during the day. Because the work is interesting? Because it’s challenging? Because you get to meet and talk to cool people? Because you get to impart knowledge? Because you get to learn? Because the work you do makes a difference in someone’s life? Because you get to make the world a little better? Because you get paid?

I won’t go into the reasons why I quit my job. Suffice to say, near the end, the only reason I continue to do that job was to earn a paycheck. And that’s a lousy reason to keep doing whatever I had to do.

I do not recommend this to you. I’ve decided to explore setting up an online business instead of looking for another programming job. Your mileage may vary.

I will continue to write math and programming articles here. Now that I’m freer (relatively speaking), some hobbyist math research and dabbling with programming techniques will be possible. First, I have to concentrate on feeding myself…

Oh yes, in case you’re interested, I’ll create some game products for sale, and offer writing services at Honeybeech. I haven’t had this planned out to the last detail. At this point, I’ve managed to sell a few copies of my Math Wizard (by being displayed at DriveThruRPG). Not quite be-able-to-eat-3-meals-a-day state, but better than nothing…

I’ll probably write on my adventures in how I manage to feed myself through whatever means here. Maybe tutoring. Let’s see if academic students are what I remember when I was their age…

A square described in any rotational orientation with 1 equation

What started out as an innocent question meant to poke me became an interesting math problem to ponder. You might want to read the original question and the answers presented. The final question was, can a square be described in any rotational orientation (based on the 2D Cartesian plane) with just 1 equation?

The answer is a resounding YES.

Meet Roie, who proposed this solution:

maximum {|r cos(theta-theta_0)|,|r sin(theta-theta_0)|} = c

This is basically modified from the max-abs solution by Mike Anderson:

max(abs(x),abs(y)) = c

You move from Cartesian coordinates to polar coordinates. Once you’re in polar plane, you can rotate by changing one variable (the angle). I actually wrote something about converting between Cartesian and polar coordinates for the use of image rotations. I can’t believe I forgot about that…

Roie also gave sample (GNU Octave or MATLAB) code:

theta0 = 0.5;
x = ones(201,1) * (-10:0.1:10);
y = x’;
z = max(abs(sqrt(x.^2+y.^2) .* cos(atan(y./x)-theta0)),abs(sqrt(x.^2+y.^2) .* sin(atan(y./x)-theta0)));
contour(z)
axis square

Unfortunately, I am unable to verify that. Fortunately, Cees Meijer confirmed it for me. He introduced me to FreeMat, a free open source software that works like MATLAB. Unfortunately, I cannot install the Windows version because I need an x64 executable (I’m on Windows 7 64-bit), and FreeMat currently only has x86 version (32-bit).

Oh well, if it works, then I can finally do matrix multiplications in one line of code. So there, Will.

Answered: Can you describe a square with 1 equation?

First, I want to say how humbled I am by the people who read this blog. You are awesome.

You might want to read the original post where the question came from. So, can you describe a square with only 1 equation? 3 readers gave their opinions, and they are all correct (meaning they’re smarter than me). I will present their answers first, then present my engineer friend’s answer, and then mine (which is worthless, and didn’t work out the way I wanted).

The first answer was from Mike Anderson, who gave this:

max(abs(x),abs(y)) = c

max(abs(x),abs(y)) = c

That actually took me a while to understand. And is actually the more complicated answer. But it’s exactly the answer my friend was looking for, which is an upright square. We’ll assume the centre of the square to be the origin. The absolute function reduces the working Cartesian plane to just the first quadrant (if it works in the first quadrant, it works in the other quadrants). The maximum function ensures that either the x-value or y-value (or both) is equal to c (half the width of the square).

What if the absolute function is not in action? Then if -c < x < c, then y must be either -c or c (because of the maximum function). Therefore there are 2 horizontal parallel lines. Similarly vice versa, creating 2 vertical parallel lines. And there’s your square. This is brilliant.

The second answer was from Christopher Tay, who gave this:

|x| + |y| = C

which is the L1 norm.

L1 norm square

The norm of a matrix is the magnitude of the matrix. In this case, the matrix is actually a 2 dimensional vector. The pipe character | surrounding the x and y values mean we’re taking the absolute value.

This one is interesting. It means that the larger the value of x, the smaller y has to be to compensate, so that the sum of x and y is C. This see-sawing effect created a triangular shape for each quadrant. Which when formed together, becomes a square (tilt your head 45 degrees to see it better).

Then Chris McAloney came in with this:

abs(x) + abs(y) = c

This equation is equivalent to the L1 norm form. Chris also pointed out that the squares formed by the previous 2 equations differ from each other by a rotation of PI/4 (radians) or 45 degrees.

So there are 2 solutions! My engineer friend was shocked when I told him. I had to admit, I was gloating just a little when I told him my readers solved his problem…

One small point to note. The constant c in each equation is specific to each equation. As in if you supplied the same constant to each equation, the width of the squares formed are different. Let me illustrate:

Square comparison

The square formed by the max-abs way has a width of 2c.

The square formed by the L1 norm way has a width of sqrt(2)*c.

The engineer’s answer

So what’s my friend’s answer? He said the answer might anger some mathematicians. He also said the answer might demonstrate a fundamental difference between how engineers and mathematicians think. And his answer is…

x^10000 + y^10000 = 1

Or basically x and y to the power of a sufficiently large number. The result is not exactly a square, but it looks sufficiently like a square.

And that was his point. That engineers take “good enough” and practicality as priority. If a wooden beam is in the correct position, and is supporting the weight of the roof, who cares if it’s 1 nanometre off the intended position?

How did he come up with it? He was playing with Wolfram Alpha and was just dumping equations into it… To see what happens, start with

x^2 + y^2 = 1

That’s a circle with radius 1. Then increase the power to 10

x^10 + y^10 = 1

You’ll see a square with round edges. Actually x^100 + y^100 = 1 gives a nice square plot. To my friend, that’s a good enough square. He posed the question to me for an analytical answer, because even he knows his answer wasn’t exact.

And my (worthless excuse of an) answer?

I hit upon the idea of starting with a circle. Then morphing it somehow into a square. The idea came from a super equation that can describe a cube or sphere or some other 3D object. I can’t find it anymore… I saw the equation when I was doing research on the demoscene. You vary a parameter t, and you get different 3D objects. That’s neat.

So I started with this:

(r * sin(θ))^2 + (r * cos(θ))^2 = r^2

Yup, I used polar coordinates. I was thinking of somehow wrangling the sines and cosines with ceiling and floor and rounding functions. I was trying to force something like:

ceiling(cos(θ)) * (sin(θ))^2 [<- NOOO, THIS IS WRONG]

to work… That was for y. I had a correspondingly elaborate term for x.

Then it dawned on me.

How am I going to draw a square in the polar coordinate plane when I basically only had theta to work with? Everything will be circular.

I tore my math working off my writing pad and threw it down the rubbish chute. I might also have sworn vehemently. Can’t remember…

So there you have it, 2 equations to describing a square. And 1 equation that creates a result that looks like a square, which for most purposes and intents may be regarded as a square.

Then my friend came in with the last word:

“For bonus points, can you use some trig functions to tilt it back so that the equation can have any angle?”

We have 1 upright square, and 1 square that’s tilted 45 degrees. My friend wanted to know if there’s an equation that creates a square in any rotational orientation. I don’t believe there’s one, so please don’t bother to try. It’ll just waste your brain cells. But you’re welcome to try it as an intellectual exercise.

Me? I need to get another writing pad…