Numerical Calculation for Work Done Near a Dipole

I’ll be honest. This connection between the electric potential (change in electric potential) and the electric field can get sort of crazy. But let’s just start with a problem and then solve it in more ways than you wanted.

Here is the problem.

Let’s start with the energy to bring an electron to point B. The energy needed would be equal to the change in electric potential energy which is equal to:

\Delta U_E = q\Delta V

That means I just need to calculate the change in electric potential from infinity to point B. Yes, you could also calculate the work needed to move the charge—I’ll do that also.

Since I am dealing with two point charges, I can use the following expression for the potential due to a point charge (with respect to infinity):

V = k\frac{q}{r}

Where k is the Coulomb constant (k = 9 \times 10^9 \text{ Nm}^2\text{/C}^2 and r is the distance from the point charge to the final location. Since there are two point charges, the total potential will just be the sum of the two potentials. Let me call the positive charge “1” and the negative charge “2”. That means the total potential will be:

V = V_1 + V_2 = k\frac{q_1}{r_1} +k\frac{q_2}{r_2}

From the original problem, q_1 = 2 \times 10^{-9}\text{ C} and q_2 = -2 \times 10^{-9}\text{ C} . The distance r_1 will be 6 mm and the distance r_2 will be 4 mm (need to convert these to meters).

Putting this all together, I get the following. I will do my calculations in python. Here is the code.

Running gives the following output.

Boom. There is your first answer. What about point A instead of B? Well, in this case, I just have different distances. The distance for both r_1 AND r_2 are the same. Since they have the same distances but equal and opposite charges, the two potentials will be opposite. When added together, the total potential is zero volts. Yes, the energy needed to put a point charge at A from infinity is zero Joules.

What? Yes. How about this? Suppose you take the electron from infinity on the positive y-axis. As you move down the axis to point A, the electric field is in the x-direction. That means the electric force is in the negative x-direction. You would have to push it in the positive x-direction and move in the y-direction. But that requires ZERO work since the force and displacement are perpendicular.

Oh. You want to get to A from a point of infinity on the positive x-axis? OK. That still works. Remember that for electric potential, the path doesn’t matter—only the change in position (path independent). I can take whatever path I like. I’m going to move in a circle from positive infinity x to positive infinity y. The electric field is zero out there, so that requires zero work. Now I’m at positive infinity y—and I just did that problem. Zero work.

Another way—by calculating the work

Remember that work-energy principle? It says this:

W = \Delta E

And the work can be defined as the following (if the force and displacement are constant):

W = F\Delta s \cos \theta

Oh, and the force will be the opposite of the electric force where:

\vec{F} = q\vec{E}

So, as you push a charge towards point B (point A is boring—for now) the electric field changes. That means we have a problem. We can’t use the above formula to calculate the work—unless we cheat. Let’s cheat.

Instead of calculating the total work to move the charge to point B, I’m just going to move it a tiny bit. During this tiny move, the electric field (and thus the force) will be approximately constant. Then I can do another tiny move. Keep repeating this until I get to point B. Here is a diagram.

If this distance is short (\Delta \vec{s}) then the force is approximately constant. That means the tiny amount of work (which I will call \Delta W) would be equal to:

\Delta W = eE\Delta s

OK, just to be clear. This is the force needed to PUSH the electron (with a charge e)—it’s not the electric force on the electron (which is in the opposite direction). Also, the angle between F and the displacement is zero. That means the cosine term is just one. I wrote the force and displacement as scalars because it’s just the magnitude that matters.

Now we are ready for some stuff. Here are the steps I am going to use.

  • Start at some position far away (but not actually infinity because that would be crazy). It just needs to be far enough away such that the electric force is negligible.
  • Calculate the total electric field and the force needed to push the electron at this point.
  • Move some short distance towards point B.
  • Over this distance, assume the force is constant and calculate the small work done—add this to the total work.
  • Repeat until you get to point B.

Before making this one program, I’m going to just make a program to plot the electric field from some value up to point B. Here is the plot from that program. (here is the code)

Note that I started from just 5 cm away from the origin—which is TOTALLY not infinity. However, it makes the graph look nice. But still, this is good because it looks like the calculation is working. Now I can use this same calculation go find the work needed to move the electron. Here is the code.

And the output:

Notice that gives a close, but wrong answer (compared to my previous calculation). Why is it wrong? Is it because I started at y = 0.5 meters (I just realized I’ve been using the variable y instead of x—but it should be fine). Or is it wrong because my step size is too big?

The answer can be found by just changing up some stuff. If you move the starting point to 1 meter, you get about the same answer. However, if you change dy to 0.0001, you get the following output.

That works. Oh, I added some more stuff to the output.

Non-straight Path

One more thing (and then I will look at the electric field in another post). What if I use a different path to get to point B? Instead of coming along the x-axis (which I previously called “y”), I come parallel to the axis a distance of 2 mm above it. Once I get right over point B, I turn down.

Like this.

This introduces some “special” problems.

  • I can break this path into two straight pieces (path 1 is parallel to x-axis and path 2 is parallel to y-axis).
  • Along path 1, the force needed to push the electron is NOT parallel to the path. So, the angle is not zero in \cos \theta. This means I’m going to have to calculate the actual vector value of the electric field at every step along this path.
  • The same is true along path 2.
  • But in the end, I should get the same work required—right?

OK, hold on because this is going to get a little more complicated. Let me just include one sketch and then I will share the code for this new path. Here is how to calculate the electric field and work for a particular step in path 1.

Here’s what needs to happen to calculate the electric field (and force) for each step:

  • Find the vector from the positive charge to step location.
  • Use this vector to find a unit vector (to give the electric field a direction).
  • Use that vector to also find the magnitude of the electric field.
  • Calculate the electric field due to the positive charge (as a vector).
  • Repeat this for the negative charge.
  • Add the two vector values for the electric field to get the total electric field.
  • Multiply by the charge to get the force (which would be in the opposite direction).

Now, to calculate the work done during each small step, I could use the angle between the force and displacement. But I don’t know that. Instead, I can use the vector definition of work:

W = \vec{F} \cdot \Delta \vec{s}

Yes, that is the dot product. Fortunately, the dot product is already built into VPython (Glowscript). So, once I get a vector value for the force and the displacement I can just use the “dot()” function.

OK, let’s do it. Here is the code (warning—vector stuff in the code) and the output.

Wow. I didn’t think that would work the first time. I’m pumped.

OK, the real reason for this post was to look at the connection between the electric field and the change in electric potential. I’ll make that in a follow up post.

Basics: Work Energy

**Pre Reqs:** [What is a Force](http://blog.dotphys.net/2008/09/basics-what-is-a-force/)

[Previously, I talked about the momentum principle](http://blog.dotphys.net/2008/10/basics-forces-and-the-momentum-principle/). Very useful and very fundamental idea. The other big (and useful) idea in introductory physics is the work-energy theorem. Really, with work-energy and momentum principle, you will be like a Jedi with a lightsaber and The Force – extremely powerful.

Well, what is work? What is energy? How are they related? In [another post, I talked about energy.](http://blog.dotphys.net/2008/10/what-is-energy/) I think it is interesting to look at how most textbooks define energy:

*Energy is the ability to do work*

This is really a stupid definition. Kind of circular logic, if you ask me. In the post I mentioned earlier, I claim there are two kinds of energy, particle energy and field energy. At low speeds (not near the speed of light), particle energy can be written as:

![Screenshot 53](http://blog.dotphys.net/wp-content/uploads/2008/10/screenshot-53.jpg)

Where *m* is the mass of the particle, *c* is the speed of light. So, if you just look at a particle, that is it for the energy. Now, what about the “work” portion? Work is defined as:

![Screenshot 54](http://blog.dotphys.net/wp-content/uploads/2008/10/screenshot-54.jpg)

Where *F* is the net force on the particle, ?r is the vector displacement of the particle. The “dot” in between F and ?r represents the “dot product” operation between vectors (also known as the scalar product). In a [previous post](http://blog.dotphys.net/2008/09/basics-vectors-and-vector-addition/) I showed that you could multiply a scalar quantity by a vector quantity. Here I need to do “something” with two vectors. You can’t multiply two vectors in the same sense that you multiply scalars. A general definition of the dot product for two vectors:

![Screenshot 55](http://blog.dotphys.net/wp-content/uploads/2008/10/screenshot-55.jpg)

That looks a little more messy than I wanted, but it can not be helped. Really, it is not that complicated. The dot product is simply the projection of one vector on the other. Let me explain in terms of work.

Continue reading “Basics: Work Energy”

What is Energy?

I think it is time for me to talk about energy. My ultimate goal is to give some insight into the many stories about perpetual motion. To do this, I will first talk about the fundamentals of energy.

**What is Energy**

I started thinking about this, and at first I realized that I did not have a good, short explanation of energy. The most commonly used definition in science text books is:

*Energy: the ability to do work (or something dreadfully vague like this).*

But what is work? It may be no surprise to find that many college level physics texts avoid defining energy. After some serious contemplation, I think I have this energy figured out.

**There are only two types of energy**

I don’t need a general definition of energy, since there are only two types I can just describe those two. ALL energy is either:

  • Particle Energy: Energy of particles (obviously). I was originally going to just say kinetic energy (energy of things that move) but I forgot about mass (of course you remember E=mc2). This is sort of complicated, so I can perhaps summarize it by saying a particle can have energy because of its mass and because of its motion (really this is just one thing). So, particle energy can be an electron moving, a water molecule moving, or a car (a car is a collection of atoms that are mostly moving in the same direction). For the rotational kinetic energy of the Earth, this is really the same thing. Imagine all the pieces of the Earth (atoms) they are moving and thus have kinetic energy. The idea of rotational kinetic energy is to simplify the calculation. Instead of summing the kinetic energy of each of the atoms of the Earth, one can use the radius, mass, and the angular velocity of the Earth to do the same thing. But realize this is mostly just a short cut.
  • Field Energy: Energy in the fields associated with the fundamental forces – gravity, electric, magnetic, strong nuclear and weak nuclear. Suppose I hold a ball above the Earth, it has particle energy (because of its mass) and there is also energy in the gravitational field associated with the ball and Earth. A chemical battery has energy stored in the electric field due to the configuration of atoms. A final example of energy in fields would be the energy from electromagnetic radiation.

But wait! What about ….. What about …. (insert some energy). All these other energies you read about are one of the above two. Other energies (for example thermal energy) are short cuts. They allow us to deal with large collections of particles without having to calculate ALL the particle energies and the field energies.

**Conservation of Energy**

There have been many many experiments in the history of science. In all of these experiments, the total energy of the situation as been conserved. Well, this is to say that there has not been an experiment where clearly the total energy before something happened was different than the total energy after something happened. Most experiments don’t look at this “energy accounting” directly. Energy conservation isn’t the law, its just what we see. How about a couple of examples of everyday things and I explain where all the energy is?

**Example: A cup of hot tea sitting on a table**

First, where is all the energy in this hot cup of tea? The cup and the tea both have particle energy. The particles (carbon and stuff) have mass energy. If I somehow annihilated this cup and tea it would turn all this mass into field energy. In this case that energy would be in the form of electromagnetic radiation. In fact, this would be so much energy in electromagnetic radiation that it would create pairs of particles (matter and antimatter pairs).

The particles also have energy because of their motion. If we assume the cup is stationary, the particles in the cup are still moving. The hotter something is, the more they move. For the particles that make up the cup, these particles are essentially just vibrating and staying in the same general area. For the tea, the particles are moving around and mostly staying in the cup (but some are leaving at the surface through evaporation). This energy is generally called thermal energy.
The cup also has energy in fields. There is energy associated with the gravitational field of the Earth-Cup(and tea) system. This would be called gravitational potential energy. There is also energy associated with the electric field is the interactions between the electrons and protons in the atoms of both the tea and the cup. People usually call this chemical energy, you could see this energy change forms if you burned the cup or had some other chemical reaction.

As the cup is sitting in the room, it gets cooler. That corresponds to lower particle energies. Where does the energy go? In this case, the stuff surrounding the cup gains energy. The table gets a little warmer (particle energy) and so does the air. This energy transfer takes place by the higher energy particles of the cup and tea interacting (through the electric field) with the particles of the air and the table. You might ask, why is it that the table gains energy and the cup loses energy? Couldn’t it happen the other way and energy would still be conserved? Yes, it would. But the probability of this happening (remember that there are on the order of 1025 particles in this cup) is so near to zero that you have a much greater chance of winning the lottery.
What if the cup were in outer space with nothing touching it? It would still cool (unless the sun was shinning on it). The particles in the cup still radiate electromagnetic energy (usually in the Infra Red region). This IR radiation could causes something else to increase in energy, but the cup still loses energy. The tea would all evaporate and lose energy to IR radiation.

I didn’t think it would be possible to take a simple thing and make it so boring, but I did it. I know that was painful (and likely in some places technically wrong) but it was necessary. Don’t make me do it again. Hopefully, you have an idea of conservation of energy and of the fundamental ideas of energy.

Continue reading “What is Energy?”

Bullets have a lot of kinetic energy (apparently)

I was recently re-watching a MythBusters episode and I found something I had wanted to explore previously (but accidentally deleted the episode). Here is a short clip from the “shooting fish in a barrel” episode:

Did you see what I found interesting? That big barrel of water left the floor from being hit by a bullet.
The question here is: Does a bullet have enough energy to increase the gravitational potential energy of the barrel to that height?

Continue reading “Bullets have a lot of kinetic energy (apparently)”

Turn off daytime running lights, or reduce speed? Which saves more?

Which wastes more fuel? (and thus produces more carbon dioxide). This is a difficult to question to answer for a variety of reasons. The main reason is that a speed change from 71 mph to 70 mph is different than a reduction from 56 to 55 mph.

First, let me be clear that the question of how much fuel is wasted using daytime running lights (or DRL as they are called) has already been addressed. The first source I found was howstuffworks.com

**Assumptions**

  • The daytime running lights on a car run at about 100 watts (for the pair)
  • The energy density of gasoline is 1.21 x 108 Joules/gallon.
  • A car is 20% efficient at converting this energy to mechanical energy.
  • The alternator is 70% efficient at converting mechanical energy into electrical.
  • At highway speeds, air resistance is the dominating factor in fuel efficiency (this might be wrong)
  • The air resistance can be modeled as Fair = (1/2)?CAv2
  • I will assume an “average” car that has combined CdA of 9 ft2 or 0.84 m2 (where Cd is the coefficient of drag and A is the cross sectional area. Also ? is the density of air, about 1.2 kg/m2)
  • An average trip of 50 miles (I completely made this up).
  • My mythical “average” car gets 25 mpg when going 70 mph

Continue reading “Turn off daytime running lights, or reduce speed? Which saves more?”

Amazing Blob Jump Launch Video Analysis

Can you believe it? Have you seen this video?

Are you thinking what I am thinking? WOW. How could these people not follow my rules for cool internet video. Once again, here they are:
1 Keep the camera stationary. This way I don’t have to keep moving the origin in the movie.
2 Don’t Zoom. Same reason, this video followed that rule.
3 Include a clear and obvious calibration object. A meter stick would work, or even a Kobe Bryant (I can look up his height). Maybe it could be a Ford F-150 that has a known length. Something!
4 Include the mass and height of all people involved.
5 Use high quality video.
6 Don’t talk about fight club – oh wait, wrong list.

Despite failure to follow all these rules, I have managed to analyze this video. Really when I saw it, I said “wow” – was that real? It looked real, but who would get shot up that high? (it is on break.com, so fake is a possibility).

Continue reading “Amazing Blob Jump Launch Video Analysis”

Physics of Linerider IV: Friction?

Friction in Line Rider

Is there friction in Line Rider? Does it function as physics would expect? To test this, I set up a simple track:

![Page 6 1](http://blog.dotphys.net/wp-content/uploads/2008/09/page-6-1.jpg)

Basically, a slope with a flat part to start with and to end with. Let me show you something simple before further analysis:

![Page 6 2](http://blog.dotphys.net/wp-content/uploads/2008/09/page-6-2.jpg)

This is the x-position vs. time for the line rider on the first horizontal portion of the track (before he or she goes down the incline). This shows the rider traveling at a constant speed of 0.71 m/s. If friction were present, the rider would slow down. If you do not believe me (and why should you?) try creating your own line rider track with a long horizontal section. The rider will not stop, but continue on at a constant speed.

Ok, so no friction on the horizontal line. This makes a little bit of gaming sense. Who would want a rider to stop in the middle of the track and be stuck? That wouldn’t be fun. But, is there friction on non-horizontal portions? To test this, I will use the work-energy principle.

Continue reading “Physics of Linerider IV: Friction?”