Tuesday, November 27, 2012

Mass of a Spherical Shell with a Linearly Varying Radial Density

In my last post I was investigating what would happen if you jumped into a hole that went through the Earth, and to make the maths easier I made the assumption that the Earth was made up of a material with homogeneous density.  That's just plain wrong.  As we all know the Earth's surface is mainly water, therefore its density is about 1000 kg per cubic meter, whereas the core of the planet is molten metal, which has a significantly larger density.  The point is however, the density of Earth varies with depth and there are couple of different models to account for this.

Using these models I plan to run a couple of simple numerical simulations to see how the results differ as the models become more authentic.  To make the simulations more accurate I need to be able to calculate the mass of a spherical shell that has a linearly varying radial density.  With this I can take any spherical symmetric object with a varying density, break it into layers and calculate the object's total mass.  Using the shell theorem, we can see that the gravitational field of this body outside of the sphere would be exactly the same as a body with all of the mass concentrated at a point in the centre of the sphere.  Calculating the acceleration at different positions within the sphere becomes easy.

The following document shows how to derive an expression for the mass of a spherical shell with an inner radius r0 and an outer radius r1, with a linearly varying density from the inner to the outer shell of p0 to p1.

SphericalShell.tex

Friday, November 16, 2012

What if Felix Kept Falling & Rode the Gravity Train?

By now everyone's probably seen Felix Baumgartner's high altitude parachute jump where he set a free fall speed record of mach 1.24.  The part of the footage that surprised me the most was how fast he disappeared after stepping off the platform.  After approximately 8 seconds he was just gone.  Thinking about the acceleration and speeds involved reminded me about the physics thought experiment called The Gravity Train.  If there was a tunnel the entire way through the earth and you jumped in what would happen?  How fast would you end up going?

First of all, ignore all the engineering challenges that make this impossible using any technology that we currently have.  There's no chance of this happening, this is one of those spherical chicken in a vacuum problems.  Then you need to know how the gravitational field inside the earth is orientated.  For this, we'll assume that the planet is spherical and has a constant density.  Which is way off, so just humour me.

We're all familiar with physics problems where the gravitational force between 2 planets is proportional to the inverse square of the distances between them, which is still true.  However, things get a little different once you start to get below the surface of a planet.  The equation for gravity doesn't change, the only difference is that you are now inside a distributed mass, so as well as being pulled down by the mass under you, there's mass above you pulling up.  Using The Shell Theorem, we know that the gravitational forces acting on a body inside a homogeneous shell of matter are zero.  They're all pulling in different directions and cancel each other out.  So the forces inside the planet depend only on the matter contained in the sphere underneath you.

The formula for acceleration on the planets surface is  GM / r^2.  As the radius changes linearly, the mass changes with the 3rd power, which is partially cancelled by the radius squared term, leaving the acceleration with a linear dependence on the radius.  This means at the centre of the planet the gravitational force experienced is 0, while at the surface it is 9.8 meters per second squared.

Gravity Train Calculations
Gravitational acceleration inside Earth

As you travel though the tunnel from one side of the planet to the other you would accelerate until you reached the centre, you would then start to slow down, and because of the symmetry of the problem you would reach the other side of the planet just as your velocity reached zero.  At this point you would start to fall again, which hints at a cosine term somewhere in the answer.  So let's throw some maths at this and see what numbers we can come up with.

The second derivative of displacement with respect to time is acceleration.  This can be placed into the formula for the acceleration inside Earth to give a differential equation to solve.

Gravity Train Calculations
Differential equation describing motion though Earth

This is an equation that will be familiar to many, it's not that hard and it describes quite a few oscillating systems.  It can be used to analyse the voltage in an LC circuit, or the displacement of a mass on a spring, among other uses.  It's useful to remember that the first derivative of displacement with respect to time is velocity.

Gravity Train Calculations
Calculating the coefficients

Now to work out the frequency and period of oscillation along with the maximum velocity by substituting back into our original differential equation.

Gravity Train Calculations
Final results

The period of the motion is around 84 minutes and is sinusoidal as suspected.  This would be for a round trip, so going from one side of the planet to the other would only take 42 minutes.  You would also reach a maximum speed of around 7850 m/second, or 28,000 km/hour, or 24 times the speed of sound.

It turns out that the 42 minute trip time is the same between any two points on the planets surface.  You don't have to go through the centre of the planet, and in the spirit of all "good" textbooks, I'll leave that as an exercise for the reader.

As an aside, 42 is a wonderful number, apart from "The Answer To the Ultimate Question of Life, The Universe, and Everything", the time in minutes a gravity train takes between two points on earth, the gyromagnetic ratio of a Hydrogen nucleus is 42.576 MHz/Telsa.  A useful fact if you do any work on MRI machines.


Why won't it work?

Now we've worked this out lets go through why it's completely useless.

First we would need a material for the tunnel walls that could withstand the tremendous heat and pressure at the centre of the planet.  It would also need to be able to deal with stresses induced by plate tectonics and the slight variation in the planets shape over time.  For this we would need to take a quick trip to Pandora to grab some of that Unobtainium that they have.

The tunnel would need to be evacuated.  If it wasn't, drag would cause objects to reach their terminal velocity and not reach the other side, eventually losing all kinetic energy and coming to rest in the centre of the planet.  Because of the large distances involved, there's a lot of atmosphere above the centre of the tunnel which would create a high air pressure meaning the drag would be even worse.  Just for fun, lets say drag didn't exist and we could reach 28,000 km/hour.  That's re-entry speed territory.  You would need a heat shield to prevent the object from burning up.

There is also another issue that I can't quite get a handle on.  If it was just a free-fall though the planet not using any sort of friction free rail system I think that the rotating Earth would rotate into the falling object.  I'm thinking Coriolis Effect. Maybe, maybe not.


Let's sum things up

It ain't going to happen.  No way, no how.  It's a good thing Felix had things like a parachute, and land to land on, otherwise he could be just floating around the Earth's core covered in energy drink advertisements.  So until we figure out how to build a Stargate, we'll have to be satisfied using planes to get around our planet.  How boring. :-(

Monday, November 5, 2012

Improvised Motor Reversal Switch With Dynamic Braking

Sometimes tracking down an unusual replacement part can be almost impossible and you just have to use what you can find.  When the main switch on a 12 volt DC winch failed recently I found myself in this situation.  The problem is that it's not a normal switch.  It's a rocker switch that short circuits the load terminals when in the centre position.  When connected to a motor this creates a dynamic braking effect which gives the winch a holding torque.  The other two positions simply apply 12 volts from a battery to the motor with different polarities to give forward and reverse motion.

At first I tried to replace the switch, which didn't go too well.  When you don't know what to Google for, and salesmen tell you that the thing in your hand doesn't exist, you kind of hit a dead end.  Luckily after cleaning the switch contacts it worked again and was put back into service, but I still wanted a solution in case it failed in the future.  I've come up with something, but haven't been able to try it, so for now it's just a theory.

All of the functionality apart from the dynamic braking can be done using a Double Pole Double Throw (DPDT) rocker switch and a little wiring.  In the centre position the switch disconnects the winch motor from the battery and leaves the motor open circuit allowing it to turn freely.

Motor Reversal Switch Dynamic Braking Wiring
Motor Unpowered - No Braking

By flicking the switch one way, voltage is applied to the motor and it turns.

Motor Reversal Switch Dynamic Braking Wiring
Motor Powered

Flicking the switch in the other direction applies the voltage again, except with the polarity reversed causing the motor to turn in the other direction.

Motor Reversal Switch Dynamic Braking Wiring
Motor Powered

To brake the motor while the switch is in the centre position a relay needs to be added.  The relay needs to be rated to operate at the same voltage as the load you are trying to control.  By connecting the motor to the common and normally closed terminals the winch motor will be short circuited when the relay isn't energised.

Motor Reversal Switch Dynamic Braking Wiring
Motor Unpowered - With Braking

When the switch is in the up or down position, the relay is energised and the motor's second terminal is connected to the DPDT switch via the common and normally open terminals of the relay.  As before, the position of the switch determines the polarity of the voltage applied to the motor, which controls the motors direction.

Motor Reversal Switch Dynamic Braking Wiring
Motor Powered - Braking Disengaged

Motor Reversal Switch Dynamic Braking Wiring
Motor Powered - Braking Disengaged

The dynamic braking that the motor experiences when its terminals are short circuited can be thought of in a couple of ways.  I tend to think of the motor acting as a generator, which drives a current through the motor, this current tries to drive the motor in the opposite direction.  These opposing motions lock up the motor and create a braking effect.  You can also think of things in terms of Lenz's law.  When moving a magnet though a coil, the current induced will generate a magnetic field that opposes the motion of the magnet.

There is one really important thing to make sure of before trying this.  The terminals on the relay coil need to be able to handle a positive or negative voltage.  If the relay is controlled by a single coil you should be fine, if however it's a solid state relay you may need to look into things a bit more.  Even if your relay is controlled by a coil you need to be make sure it doesn't have a diode across the terminals to protect the rest of the circuit from back EMF.  If you skip this step there'll be a race between the diode and the fuse for the first to fail.  In my situation protecting the rest of the circuit isn't necessary.  If however protecting the circuit from the back EMF created when voltage is removed from the relay coil is important, you could place an ordinary diode before the DPDT switch, between the battery and the switch.  You could also put a bidirectional TVS diode with a working voltage of at least 12 volts directly on the relay coil.

In theory this should all work, I can't see any problem with it.  So when the time comes I'll be prepared and have a solution ready to go.