# Time dependent electric force at large distance

1. Dec 26, 2007

### Shintao

I need some help with time dependent equations. I have two electrically charged particles in space that are at large distances. How would I write a time dependent equation to simulate there positions at give times. I know there initial positions and there initial velocities. And for simplicity one object is unmovable. This is what I have:

$$f = \frac{kq_{1}q_{2}}{r^2}$$

$$a = \frac{f}{m}$$

$$x = x_{0} + v_{0}t + \frac{at^2}{2}$$

But, the force between the two objects is non-constant because as they get closer to each other force increases rapidly. So do I use the yank instead of force. But, that creates the problem of making the equation distance dependent. I don't need the force at given distances. I need the force a given times based on distances.

for those that know C++:

f = cos(atan2(particle2.y - particle1.y, particle2.x - particle1.x)) * COULOMB_CONSTANT * -particle2.charge * particle1.charge / (_hypot(particle2.y - particle1.y, particle2.x - particle1.x));

a = f / particle1.mass;

x = particle1.initial_x + particle1.initial_velocity.x * time + a * pow(time, 2) / 2;

It seems to me that the force should be time dependent because the distance between the two particles is time dependent. I need some calculus help. I think????

2. Dec 27, 2007

### Staff: Mentor

First off, this equation does not apply. This is not a general equation, but rather an equation that is only valid for the special case of constant acceleration. And of course, in your situation you already know that the force is not constant.

Here you are dealing with electrical forces, but do you know of any other forces with the same form for their equation? If so, do you know the solution for that equation?

By the way, I don't know your level of math, but this is a vector differential equation that would probably be covered after 3 semesters of calculus or more.

r'' = C/(r |r|)

If you don't know how to solve that, then you are going to have to look up the solution somewhere else.

3. Dec 29, 2007

### Shintao

I looked up differiental equations. When you say vector differiental equation, are you referring to the fact that I have to break the force into its three respective vectors(x, y, z). If that is what you mean, I understand how to pull apart the force vector into the respective parts.

$$r'' = \frac{C}{r|r|}$$

I need some help breaking this down. Correct me if I'm wrong. 2nd derivative of r = C/(r|r|). What does C stand for? And wouldn't r have to relate to time and position???

4. Dec 29, 2007

### Staff: Mentor

C is just a constant. In this case C = k q1 q2/m1. But if you were dealing with gravity then C = G m1 m2/m1

I should have been more explicit r is actually r(t) = (x(t),y(t),z(t)), a vector function of time indicating the position at a time t.

Last edited: Dec 29, 2007
5. Dec 29, 2007

### Shintao

I get what you are saying. U were just short-hand writting with C in the equation. If I can figure this out it should relate to most of the inverse-squared laws in physics.

r is the three dimensional displacement of the object(electron, e) or the stationary object(proton, p)

For simpicity I just want to use 2 dimensions(x, y)
d = distance between e and p
m = slope
C = k * q1 * q2

$$d = \sqrt{(e_{x} - p_{x})^2 + (e_{y} - p_{y})^2}$$

$$m = \frac{e_{y} - p_{y}}{e_{x} - p_{x}}$$

$$F_{x} = \cos{(\arctan{(m))} * \frac{C}{d^2}}$$

$$a = \frac{F}{m}}$$

Then integrate a twice for t to get the new position along the x axis. Then do the same for the y axis. Then start over with the new position. But, since position is related to the distance between the two objects how do I write a continous equation for the distance between the two objects. d is what I don't know how to do continously.