Like with anything the best way to learn something new is to connect it to something one alreay knows. Here we took what we learned about gravity and transformed it ton electri fields. We wrote down how the field is created, what the magnitude of the field depends on, how distance effects the magnitude of the field and what a charge will experience when it is in an electric field.
These are the physical equations comparming the previous statements of the above picture. The force, the electric field, the form of the field and how it is all respected to the distance, direction, and magnitude.
The two different impressions on the plastic sheet is a "physical representation" of how negative and postive electrons creates a field. The positive pushes away objects so it has a hill representation; while a negative electron has a pulling function so it has a vallly type of a representation. These are just easy to understand representations. This is not the only factor in what causes two elements to be attracted to each other.
This is a set of pre-determined calculations off of an sent of values. The only thing that is changing is the radius of the function. The further the two charges are from each other the less they react to each other's charges.
These are some basic calculations of the eletric field or the system of three charges. This is just like an 2A equation of forces just now just with electrons.
This is a more complucated version of what was show above. It has to do e with different angles and distances. However, the calculations were fairly simple due to the predetermined calculations we did on Exel (shown below). Each charge effected all the other three charges.
This is the Excel document that we used to cacluate what we needed; which was the Electic field.
Here we are intoduced the to a calculus version of what we have been doing. This is just a bar of charge acting on a point charge in teh z-axis. This is the most simple problem that we can do in point charge and a mass of charge.
Here is the final equation of the day. This is what we were doing in the previous picture above but with a charge to the left of the rod at a certain distance.
The following pictures is the conformation of the little mini game with charges. We will go over more about this in the next lecture so I will be talking about his in the next blog so stay tune.
Goal!!
Goal!!
Goal!!
Instead of doing the hockey simulation we did Vpython.
This is what the original code would have looked like if we did not change the code that was given to use my Prof. Mason. It was very simple in practice. The code that made this image is below.
This code is what we made with some help from Mason during class. We changed the direction and the size of each arrow to best represent what we had.
from visual import *
## CONSTANTS
k = 9e9 ## OneOverFourPiEpsilonZero
q1 = 1.6e-19
## OBJECTS
particle = sphere(pos=vector(1e-10, 0, 0), radius = 2e-11, color=color.red)
xaxis = cylinder(pos=(-5e-10,0,0), axis=vector(10e-10,0,0),radius=.2e-11)
yaxis = cylinder(pos=(0,-5e-10,0), axis=vector(0,10e-10,0),radius=.2e-11)
zaxis = cylinder(pos=(0,0,-5e-10), axis=vector(0,0,10e-10),radius=.2e-11)
## the position of the arrow is the observation location:
Earrow1 = arrow(pos=vector(3.1e-10,-2.1e-10,0), axis = vector(1e-10,0,0), color=color.orange)
Earrow2 = arrow(pos=vector(3.1e-10,2.1e-10,0), axis = vector(1e-10,0,0), color=color.orange)
Earrow3 = arrow(pos=vector(-1.1e-10,-2.1e-10,0), axis = vector(1e-10,0,0), color=color.orange)
Earrow4 = arrow(pos=vector(-1.1e-10,2.1e-10,0), axis = vector(1e-10,0,0), color=color.orange)
Earrow5 = arrow(pos=vector(1e-10,0,3e-10), axis = vector(1e-10,0,0), color=color.orange)
Earrow6 = arrow(pos=vector(1e-10,0,-3e-10), axis = vector(1e-10,0,0), color=color.orange)
## CALCULATIONS
R1=Earrow1.pos-particle.pos
R2=Earrow2.pos-particle.pos
R3=Earrow3.pos-particle.pos
R4=Earrow4.pos-particle.pos
R5=Earrow5.pos-particle.pos
R6=Earrow6.pos-particle.pos
Ef1=((k*q1)/(mag(R1)**3))
Ef2=((k*q1)/(mag(R2)**3))
Ef3=((k*q1)/(mag(R3)**3))
Ef4=((k*q1)/(mag(R4)**3))
Ef5=((k*q1)/(mag(R5)**3))
Ef6=((k*q1)/(mag(R6)**3))
## write instructions below to tell the computer how to calculate the correct
## electric field E1 at the observation location (the position of Earrow1):
## change the axis of Earrow1 to point in the direction of the electric field at that location
## and scale it so it looks reasonable
scalefactor= 1e-20
Earrow1.axis= Ef1*R1*scalefactor
Earrow2.axis= Ef2*R2*scalefactor
Earrow3.axis= Ef3*R3*scalefactor
Earrow4.axis= Ef4*R4*scalefactor
Earrow5.axis= Ef5*R5*scalefactor
Earrow6.axis= Ef6*R6*scalefactor
print "Ef1: ", Ef1
print "Ef2: ", Ef2
print "Ef3: ", Ef3
print "Ef4: ", Ef4
print "Ef5: ", Ef5
print "Ef6: ", Ef6
## additional observation locations; do the same thing for each one
The output is such.
Our next time we use Vpython we had a cool picture both in 2D and 3D but we dont have the picture of it right now. Here is the code for it. We were just representing the motion that a small positive charge would move if it was near a charge. The image is really cool.
from __future__ import division
from visual import *
## constants
k = 9e9 # stands for One Over Four Pi Epsilon-Zero
qe = 1.6e-19 # proton charge
s = 4e-11 # charge separation
R = 3e-10 # display Enet on a circle of radius R
V = 2e-10
scalefactor = 1e-20 # for scaling arrows to represent electric field
## objects
## Represent the two charges of the dipole by red and blue spheres:
plus = sphere(pos=vector(s/2,0,0), radius=1e-11, color=color.red)
qplus = qe # charge of positive particle
neg = sphere(pos=vector(-s/2,0,0), radius=1e-11, color=color.blue)
qneg = -qplus # charge of negative particle
## calculations
theta = 0
while theta < 2*pi:
rate(50) # tell computer to go through loop slowly
## Calculate observation location (tail of arrow) using current value of theta:
Earrow1 = arrow(pos=R*vector(cos(theta),sin(theta),0), axis=vector(1e-10,0,0), color=color.orange)
R1= Earrow1.pos-plus.pos
R2= Earrow1.pos-neg.pos
Ef1=((k*qplus)/(mag(R1)**3))
Ef2=((k*qneg)/(mag(R2)**3))
Earrow1.axis= ((Ef1*R1)+(Ef2*R2))*scalefactor
print "Ef1: ", Ef1
## write instructions below to tell the computer how to calculate the correct
## net electric field Enet at the observation location (the position of Earrow):
## change the axis of Earrow to point in the direction of the electric field at that location
## and scale it so it looks reasonable
## Assign a new value to theta
theta = theta + pi/12
theta = 0
while theta < 2*pi:
rate(50) # tell computer to go through loop slowly
## Calculate observation location (tail of arrow) using current value of theta:
Earrow1 = arrow(pos=R*vector(cos(theta),0,sin(theta)), axis=vector(1e-10,0,0), color=color.orange)
R1= Earrow1.pos-plus.pos
R2= Earrow1.pos-neg.pos
Ef1=((k*qplus)/(mag(R1)**3))
Ef2=((k*qneg)/(mag(R2)**3))
Earrow1.axis= ((Ef1*R1)+(Ef2*R2))*scalefactor
print "Ef1: ", Ef1
## write instructions below to tell the computer how to calculate the correct
## net electric field Enet at the observation location (the position of Earrow):
## change the axis of Earrow to point in the direction of the electric field at that location
## and scale it so it looks reasonable
## Assign a new value to theta
theta = theta + pi/12
theta = 0
while theta < 2*pi:
rate(50) # tell computer to go through loop slowly
## Calculate observation location (tail of arrow) using current value of theta:
Earrow1 = arrow(pos=R*vector(0,cos(theta),sin(theta)), axis=vector(1e-10,0,0), color=color.orange)
R1= Earrow1.pos-plus.pos
R2= Earrow1.pos-neg.pos
Ef1=((k*qplus)/(mag(R1)**3))
Ef2=((k*qneg)/(mag(R2)**3))
Earrow1.axis= ((Ef1*R1)+(Ef2*R2))*scalefactor
print "Ef1: ", Ef1
## write instructions below to tell the computer how to calculate the correct
## net electric field Enet at the observation location (the position of Earrow):
## change the axis of Earrow to point in the direction of the electric field at that location
## and scale it so it looks reasonable
## Assign a new value to theta
theta = theta + pi/12
theta = 0
scalefactor= 1*(10**(-20.5))
while theta < 2*pi:
rate(50) # tell computer to go through loop slowly
## Calculate observation location (tail of arrow) using current value of theta:
Earrow1 = arrow(pos=V*vector(cos(theta),sin(theta),0), axis=vector(1e-10,0,0), color=color.red)
R1= Earrow1.pos-plus.pos
R2= Earrow1.pos-neg.pos
Ef1=((k*qplus)/(mag(R1)**3))
Ef2=((k*qneg)/(mag(R2)**3))
Earrow1.axis= ((Ef1*R1)+(Ef2*R2))*scalefactor
print "Ef1: ", Ef1
## write instructions below to tell the computer how to calculate the correct
## net electric field Enet at the observation location (the position of Earrow):
## change the axis of Earrow to point in the direction of the electric field at that location
## and scale it so it looks reasonable
## Assign a new value to theta
theta = theta + pi/12
theta = 0
while theta < 2*pi:
rate(50) # tell computer to go through loop slowly
## Calculate observation location (tail of arrow) using current value of theta:
Earrow1 = arrow(pos=V*vector(cos(theta),0,sin(theta)), axis=vector(1e-10,0,0), color=color.red)
R1= Earrow1.pos-plus.pos
R2= Earrow1.pos-neg.pos
Ef1=((k*qplus)/(mag(R1)**3))
Ef2=((k*qneg)/(mag(R2)**3))
Earrow1.axis= ((Ef1*R1)+(Ef2*R2))*scalefactor
print "Ef1: ", Ef1
## write instructions below to tell the computer how to calculate the correct
## net electric field Enet at the observation location (the position of Earrow):
## change the axis of Earrow to point in the direction of the electric field at that location
## and scale it so it looks reasonable
## Assign a new value to theta
theta = theta + pi/12
theta = 0
while theta < 2*pi:
rate(50) # tell computer to go through loop slowly
## Calculate observation location (tail of arrow) using current value of theta:
Earrow1 = arrow(pos=V*vector(0,cos(theta),sin(theta)), axis=vector(1e-10,0,0), color=color.red)
R1= Earrow1.pos-plus.pos
R2= Earrow1.pos-neg.pos
Ef1=((k*qplus)/(mag(R1)**3))
Ef2=((k*qneg)/(mag(R2)**3))
Earrow1.axis= ((Ef1*R1)+(Ef2*R2))*scalefactor
print "Ef1: ", Ef1
## write instructions below to tell the computer how to calculate the correct
## net electric field Enet at the observation location (the position of Earrow):
## change the axis of Earrow to point in the direction of the electric field at that location
## and scale it so it looks reasonable
## Assign a new value to theta
theta = theta + pi/12












No comments:
Post a Comment