Avatar: The Last Airbender Power Levels

When physics and “superpowers” reconcile (or not), it’s all in great fun.

A show that I like for various reasons, but that has also shown a variety of great feats is “Avatar: The Last Airbender” and the subsequent “Avatar: The Legend of Korra.”

One of the most extreme examples of bending happens when Ghazan melts the Northern Air Temple Mountain:

Given: an approximate energy of 900kJ/kg to melt rock[1] and an average density of 2.7g/cm^3 for rock [2].

[1] ( http://home.earthlink.net/~jimlux/lava.htm )

[2] ( http://en.m.wikipedia.org/wiki/Continental_crust )

Approximate: The temple has a footprint of about 500m x 500m = 250,000m^2.  The mountain has rather sheer faces so let’s give it a cylindrical profile and say about 400m vertically is melted.  That’s 100,000,000m^3 of rock.

Based on our givens, that is 270,000,000,000kg of rock or 243,000,000,000,000kJ of energy, 243 petaJoules.

Gazan outputs the energy equivalent of the Tsar Bomba, the largest nuclear device ever tested.

Or enough to power all the electricity in New York City for 6,136 days, i.e. 17 years.

If the energy all came from within him through conventional biology, he burned 5.8×10^13 kilocalories (or just capital “C” Calories – of which we are recommended to eat 2000 a day by food packaging), that’s 29,000,000,000 days or 79 million years of meals.  If he was converting mass directly to energy, then via Einstein, he lost 2.7kg of pure mass (not bad!).

One could argue that characters are tapping into energy sources external to themselves when bending, nevertheless, it is interesting to know just how much of it they must be accessing.

See this Google Doc for further calculations with Zaheer, Avatar Kyoshi, etc.

Google Doc with More Details

On Reasons I Like Third-Person Camera

There has been plenty written about why one should make a game in third-person or first-person:  Convention and what your target audience will already be familiar with.  How much you want the player to be immersed as the character in your game.  And so on.  Today, I would like to discuss my biggest consideration: information – as a gamer who likes when UX/UI emphasizes information and clarity, third-person camera appeals to me more.

While first-person camera appears immersive immediately, there is quite a bit of information that it will not be able to capture until VR tech gets further along.  Forefront is touch/proprioception.  In addition to the first-person view I have out of my own head, I can feel where the ground is below me and where a wall is behind or beside me without having to look at it.  Touch/proprioception allows me move comfortably around my environments in spite of my own limited field of view.  With first-person camera however, you can’t tell that you’ve landed on a surface or if you’ve bumped up against a wall unless the camera stops moving or if one your directional movements starts pushing you along something.  It’s not ideal and, at least for me, requires an additional moment of mental processing to figure out what is going on.

Now enters third-person camera.  It does not give us completely natural proprioception of the environment; however, it does allow me to see the floor and the walls in lieu of feeling them.  I can more closely see where my character is in space just as I would feel where they are in space if it were ideal first-person.  In lieu of physically being able to brush up against things, at least I can see where the 3D models touch.  This restores more of my sense of space and allows me to move in the game more reflexively.

I can’t just outright recommend third-person camera.  Of course, when poorly implemented, it can cause just as much frustration.  What I do want to say is that in most cases, when given a choice by a game, I would choose the third-person camera over the first-person camera because it feels more natural to me.  More natural because, though it sacrifices the sense of immediacy and of seeing “through the character’s eyes”, it offers information normally provided by touch/proprioception.

Geometry 12/2/2015

Here’s another puzzle that had me occupied all of my bike ride home yesterday:

While stopped at an intersection, I noticed how the windows on the building across the street allowed me to see oncoming traffic from the side from farther away than I had turned my head.  And so I wondered, what relation and how much of a reduction in neck strain does such a situation promote?


Clearly you need to turn your head only b degrees instead of a degrees, but that relationship can be anywhere from a negligible difference when the target is right against the mirror to a near complete reduction if the mirror was at infinity.  What’s the actual relationship though?


The target is at some x and y position away from us the viewer, and in the case of a building where the reflection is always ideally positioned, it only matters the y’ distance of the building from the target (the image will be the same distance behind the mirror).

With all of three of these values, we can find the angle of the triangles formed in the diagram by arctan(y/x) and arctan((y+2y’)/x).

The angle I must turn to look at a car then is (90º – arctan(y/x)), while I only need to turn (90º – arctan((y+2y’)/x)).

Wolfram alpha can help us with the rest of the work here in visualizing this relationship, and we can choose to look at all three as variables or arbitrarily set certain one’s as constants.

For example, if we are interested in how the ratio of the reduction behaves as a function of the distance of the mirror, see the following graph.  The ratio of the image in the mirror angle to the object angle is y and the distance of the mirror from the object is x in this case.  (as expected, mirror farther away means you have to turn your head less)


Or, if we are interested in how the ratio of the reduction behaves as a function of the x position of the object (the farther away it is, the closer the angle is between the mirror image and it):


Or we can vary both the position of the object and the mirror at the same time (reflected in the top right quadrant of the below graph since both values can only be positive):



By the way, if you were wondering about the ideal positioning of a mirror to see an object at your side, the relationship is governed by (y+y’)/(x-x’) = y’ / x’ where x and y are the position of the desired target object to your side and x’ and y’ are the position of the mirror relative to that object.


x’ and y’ have an expected asymptotic relationship where they start right on top of the target to halfway between you and the target in x while infinitely far away in y. Per Wolfram Alpha below (setting y=1 and x=2).


Paracord Shock Load

Here’s a question that I’ve wondered about:  What’s actually a safe load to put on paracord in case of it slipping and dynamic loading?  Paracord should be a shock cord since it was originally for parachutes, but it’s always rated by a static load weight.

Here’s the best I’ve gathered (internet, please correct me if any of this is wrong):

An approximate equation for shock load is:  shock load = weight * ((fall distance / elongation) + 1)

Properly rated paracord should elongate at minimum 30% (more is better so let’s use 30% as a worst case).

If are you dropping something with the cord, the fall distance is the cord length or 100%.  The equation reduces to weight * (1/0.3 + 1) or weight * (13/3).  A weight being dropped on paracord can generate a shock force of about 4.333 times it’s weight.

So going in reverse, if we take the static load of paracord as it’s net breaking strength, do not load it with more than the inverse of that factor in weight, 3/13 or 23% of it’s rated strength.

Geometry 7/16/2015

Inverse kinematics today.

So here’s another random geometrical situation that caught my attention while I had some downtime at work today.

Imagine we have two monitors that we would like to pivot so that they always stay in contact; however, we don’t want to install and ugly hinge along the front surfaces so we build an arm attachment in the back.  Of course, it can’t be one arm because that doesn’t physically work, but two arms hinged to each other and to the monitors will.  This raises interesting questions about how the arms need to move together to pivot the screens, especially if we would like the system to be automatically driven and move at an even and smooth speed.


I haven’t yet figured out all the equations and differentials that govern the relative movements of the arms, but some quick thought on the ideal case can get us in the right direction.  Imagining a perfectly equilateral triangle setup, and also ignoring the thickness of the screens, we see that every 3° rotated by the screen requires a 1° rotation on each internal angle of the hinges.  Twisting each hinge at a fixed speed will result in the screen pivoting at 3 times that speed.

Of course, this becomes less true as the arm lengths vary: an armature with a √2 ratio with the short arm being the length of the distance between the two screen hinges (starts off in a 90°, 45°, 45° triangle) will not be able to rotate the screens to a full 90°.  But to get to a 45° angle, must rotate ~27.0°, ~4.4°, ~22.3° respectively.

Or, think of an armature that can just get to a 90° screen rotation by having a long arm that is the distance between the two screen hinges and a short arm that is 1/√2 times that.  It starts off in a ~69.3°, ~69.3°, ~41.4° triangle, rotating ~24.3°, ~24.3°, 41.4° respectively.

Of course, the correct way to do this is clearly just to build the darn setup, manually rotate the screens, have sensors record the movement, and then feed those movement curves back into the motors.

Reflection on Werewolf

I’ve played Mafia, a lot of Mafia, and some of my thoughts are probably anchored based on how those experiences went.  Nevertheless, I wanted to comment on something that stood out to me the most on my first game of Werewolf played on 1/30/2015:

We let every villager have a role. While letting every villager have a role was a nice way to give everyone something to do, I didn’t like it from a game design perspective. Having too many clear roles upset the fuzziness in identity that makes this type of game confusingly compelling.

For example, say there is one werewolf and two villagers left:

If those two villagers had specific roles, say bodyguard and seer, then in that case, the werewolf must claim to be one or the other. However, the person with that card would know that is a lie and it would simply come down to a shouting match between the two.

If on the other hand, those two villagers roles were just “villager,” then the werewolf could claim to be a villager. In that case, both real villagers only know that they themselves are one of two villagers, and could be played against each other by the werewolf claiming to be the second villager.

In the first case, the onus is entirely on the werewolf to process all the information, make an optimal choice, and then try to be the loudest.  In the second case, the werewolf has the choice to be more deceptive, and play both villagers against each other, creating flexibility.

When my group played with too many roles last night, then, it was simply a process of elimination and matching up individual roles with people, which made it easy to solve the game. I found it difficult as a werewolf to pretend to be “part of the crowd” as there was no generic “crowd” to be a part of. Instead the game was about knowing the ideal next steps.

My recommendation would be to play with more regular villager cards but give them artifacts if they want to have unique powers. Having duplicates makes it more difficult to determine who people are and creates more confusion, politics, and intrigue, which is what I believe is the essence of these types of games.

On the Wonders of IFERROR()

If you’re spreadsheet is meant to be looked at by other people, you should just about nest everything in an IFERROR([formula],).  The nothing after the comma means that in the case that your formula throws an error (#VALUE, #N/A, #REF!, et cetera), nothing shows up in the cell.  No distracting error text.

Now, this doesn’t mean you shouldn’t debug your formulas first, but if there are normal cases where they might throw some of these errors, IFERROR() is invaluable.  (e.g. I have a dynamically updating query list and I know that sometimes the query will return nothing).