simulations.objects Class ElectricDipoleRotating

```java.lang.Object
simulations.objects.BaseObject
simulations.objects.ElectricDipoleRotating
```

public class ElectricDipoleRotating
extends BaseObject

This is a rotating electric dipole. It rotates about the z axis, lies in the xy plane Important note: we multiply the overall electric field of this dipole by one factor of the radius and scale it by 1/100. If you want this dipole to interact with other electromagnetic objects you must compensate for this.

Version:
1.0
Author:
Andreas Sunquist, John Belcher

 Field Summary ` double` `omega`           The angular frequency of rotation of the rotating dipole ` double` `p0`           The magnitude of the dipole moment of the rotating dipole ` double` `t`           The time. ` double` `theta`           The angle that the dipole moment mades to the z-axis ` Vec3` `x`           The position of the dipole.

 Constructor Summary ```ElectricDipoleRotating(Vec3 x, double p0, double omega, double theta)```           Create an electric dipole

 Method Summary ` Vec3` ```Bfield(Vec3 x, Vec3 B)```           Compute the magnetic field at position x and time t ` Vec3` ```Efield(Vec3 x, Vec3 E)```           Compute the electric field at position x and time t ` void` `Evolve(double dt)`           Evolve the dipole time ` Vec3` `getDDP(double dt)`           Returns the second time derivative of the dipole moment at a time retarded by dt. ` Vec3` `getDP(double dt)`           Returns the first time derivative of the dipole moment at a time retarded by dt We use the method getT to find out the current time of the dipole ` Vec3` `getP(double dt)`           Returns the dipole moment at a time retarded by dt. ` double` `getT()`           Get the time.

 Methods inherited from class simulations.objects.BaseObject `Bfield, Efield, Pfield, Pfield`

 Methods inherited from class java.lang.Object `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

 Field Detail

x

`public Vec3 x`
The position of the dipole.

t

`public double t`
The time.

p0

`public double p0`
The magnitude of the dipole moment of the rotating dipole

omega

`public double omega`
The angular frequency of rotation of the rotating dipole

theta

`public double theta`
The angle that the dipole moment mades to the z-axis

 Constructor Detail

ElectricDipoleRotating

```public ElectricDipoleRotating(Vec3 x,
double p0,
double omega,
double theta)```
Create an electric dipole

 Method Detail

getT

`public double getT()`
Get the time. This allows us the find the current time for this dipole.

getP

`public Vec3 getP(double dt)`
Returns the dipole moment at a time retarded by dt. We use the method getT to find out the current time of the dipole

getDP

`public Vec3 getDP(double dt)`
Returns the first time derivative of the dipole moment at a time retarded by dt We use the method getT to find out the current time of the dipole

getDDP

`public Vec3 getDDP(double dt)`
Returns the second time derivative of the dipole moment at a time retarded by dt. We use the method getT to find out the current time of the dipole

Evolve

`public void Evolve(double dt)`
Evolve the dipole time

Overrides:
`Evolve` in class `BaseObject`
Parameters:
`dt` - the time step

Efield

```public Vec3 Efield(Vec3 x,
Vec3 E)```
Compute the electric field at position x and time t

Specified by:
`Efield` in class `BaseObject`
Parameters:
`x` - the position of the observer
`E` - the electric field at the observer's position
Returns:
E the electric field at the observer's position

Bfield

```public Vec3 Bfield(Vec3 x,
Vec3 B)```
Compute the magnetic field at position x and time t

Specified by:
`Bfield` in class `BaseObject`
Parameters:
`B` - the magnetic field at the observer's position
Returns:
B the magnetic field at the observer's position