Breadcrumbs

 

 

 

Download ModelDownload SourceembedLaunch Website ES WebEJS

About

Intro Page

The Wien (E x B) Filter

Developed by E. Behringer

This set of exercises guides the students to compute and analyze the behavior of a charged particle in a spatial region with mutually perpendicular electric and magnetic fields. It requires the student to determine the Cartesian components of hte forces acting on the particle and to obtain the corresponding equations of motion. The solutions to these equations are obtained through numerical integation, and the capstone exercise is the simulation of the Unexpected text node: 'style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-style: none; border-top-width: 0px; border-right-style: none; border-right-width: 0px; border-bottom-style: none; border-bottom-width: 0px; border-left-style: none; border-left-width: 0px; display: inline; margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; line-height: normal">'Unexpected text node: 'style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-style: none; border-top-width: 0px; border-right-style: none; border-right-width: 0px; border-bottom-style: none; border-bottom-width: 0px; border-left-style: none; border-left-width: 0px; display: inline; margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; line-height: normal">'style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-style: none; border-top-width: 0px; border-right-style: none; border-right-width: 0px; border-bottom-style: none; border-bottom-width: 0px; border-left-style: none; border-left-width: 0px; display: inline; margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; line-height: normal"> (Wien) filter.

Subject Area Electricity & Magnetism
Levels First Year and Beyond the First Year
Available Implementation Python
Learning Objectives

Students who complete this set of exercises will be able to:

  • generate equations predicting the Cartesian components of force acting on the charged particle and generate the equations of motion for the particle (Exercise 1);
  • calculate particle trajectories by solving the equations of motion (Exercise 2);
  • produce two-dimensional and three-dimensional plots of the trajectories (Exercise 2); and
  • simulate the operation of an [Math Processing Error]style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-style: none; border-top-width: 0px; border-right-style: none; border-right-width: 0px; border-bottom-style: none; border-bottom-width: 0px; border-left-style: none; border-left-width: 0px; display: inline; margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; line-height: normal"> (Wien) filter (Exercise 3) and determine the range of particle velocities transmitted by the filter, and how these are affected by the geometry of the filter (Exercise 4).
Time to Complete 120 min
Exercise 4

EXERCISE 4: THE [Math Processing Error]style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-style: none; border-top-width: 0px; border-right-style: none; border-right-width: 0px; border-bottom-style: none; border-bottom-width: 0px; border-left-style: none; border-left-width: 0px; display: inline; margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; line-height: normal"> (WIEN) FILTER, PART 2

As an extension of Exercise 3, now assume that the particles entering the field region at the origin have a normal distribution of velocities directed purely along the [Math Processing Error]style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-style: none; border-top-width: 0px; border-right-style: none; border-right-width: 0px; border-bottom-style: none; border-bottom-width: 0px; border-left-style: none; border-left-width: 0px; display: inline; margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; line-height: normal">-axis. The center of the distribution is [Math Processing Error]style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-style: none; border-top-width: 0px; border-right-style: none; border-right-width: 0px; border-bottom-style: none; border-bottom-width: 0px; border-left-style: none; border-left-width: 0px; display: inline; margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; line-height: normal"> and its width is Unexpected text node: 'style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-style: none; border-top-width: 0px; border-right-style: none; border-right-width: 0px; border-bottom-style: none; border-bottom-width: 0px; border-left-style: none; border-left-width: 0px; display: inline; margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; line-height: normal">'Unexpected text node: 'style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-style: none; border-top-width: 0px; border-right-style: none; border-right-width: 0px; border-bottom-style: none; border-bottom-width: 0px; border-left-style: none; border-left-width: 0px; display: inline; margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; line-height: normal">'style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-style: none; border-top-width: 0px; border-right-style: none; border-right-width: 0px; border-bottom-style: none; border-bottom-width: 0px; border-left-style: none; border-left-width: 0px; display: inline; margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; line-height: normal">.

(a) Allow Unexpected text node: 'style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-style: none; border-top-width: 0px; border-right-style: none; border-right-width: 0px; border-bottom-style: none; border-bottom-width: 0px; border-left-style: none; border-left-width: 0px; display: inline; margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; line-height: normal">'Unexpected text node: 'style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-style: none; border-top-width: 0px; border-right-style: none; border-right-width: 0px; border-bottom-style: none; border-bottom-width: 0px; border-left-style: none; border-left-width: 0px; display: inline; margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; line-height: normal">'style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-style: none; border-top-width: 0px; border-right-style: none; border-right-width: 0px; border-bottom-style: none; border-bottom-width: 0px; border-left-style: none; border-left-width: 0px; display: inline; margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; line-height: normal"> particles from this distribution to enter the field region at the origin. What is the resulting histogram of the scaled velocities Unexpected text node: 'style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-style: none; border-top-width: 0px; border-right-style: none; border-right-width: 0px; border-bottom-style: none; border-bottom-width: 0px; border-left-style: none; border-left-width: 0px; display: inline; margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; line-height: normal">'Unexpected text node: 'style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-style: none; border-top-width: 0px; border-right-style: none; border-right-width: 0px; border-bottom-style: none; border-bottom-width: 0px; border-left-style: none; border-left-width: 0px; display: inline; margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; line-height: normal">'style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-style: none; border-top-width: 0px; border-right-style: none; border-right-width: 0px; border-bottom-style: none; border-bottom-width: 0px; border-left-style: none; border-left-width: 0px; display: inline; margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; line-height: normal"> of the particles transmitted through a circular aperture of radius Unexpected text node: 'style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-style: none; border-top-width: 0px; border-right-style: none; border-right-width: 0px; border-bottom-style: none; border-bottom-width: 0px; border-left-style: none; border-left-width: 0px; display: inline; margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; line-height: normal">'Unexpected text node: 'style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-style: none; border-top-width: 0px; border-right-style: none; border-right-width: 0px; border-bottom-style: none; border-bottom-width: 0px; border-left-style: none; border-left-width: 0px; display: inline; margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; line-height: normal">'style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-style: none; border-top-width: 0px; border-right-style: none; border-right-width: 0px; border-bottom-style: none; border-bottom-width: 0px; border-left-style: none; border-left-width: 0px; display: inline; margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; line-height: normal"> mm centered on the Unexpected text node: 'style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-style: none; border-top-width: 0px; border-right-style: none; border-right-width: 0px; border-bottom-style: none; border-bottom-width: 0px; border-left-style: none; border-left-width: 0px; display: inline; margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; line-height: normal">'Unexpected text node: 'style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-style: none; border-top-width: 0px; border-right-style: none; border-right-width: 0px; border-bottom-style: none; border-bottom-width: 0px; border-left-style: none; border-left-width: 0px; display: inline; margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; line-height: normal">'style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-style: none; border-top-width: 0px; border-right-style: none; border-right-width: 0px; border-bottom-style: none; border-bottom-width: 0px; border-left-style: none; border-left-width: 0px; display: inline; margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; line-height: normal">-axis? How does it compare to the histogram of the initial velocities?

(b) Repeat part (a) for an aperture of radius Unexpected text node: 'style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-style: none; border-top-width: 0px; border-right-style: none; border-right-width: 0px; border-bottom-style: none; border-bottom-width: 0px; border-left-style: none; border-left-width: 0px; display: inline; margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; line-height: normal">'Unexpected text node: 'style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-style: none; border-top-width: 0px; border-right-style: none; border-right-width: 0px; border-bottom-style: none; border-bottom-width: 0px; border-left-style: none; border-left-width: 0px; display: inline; margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; line-height: normal">'style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-style: none; border-top-width: 0px; border-right-style: none; border-right-width: 0px; border-bottom-style: none; border-bottom-width: 0px; border-left-style: none; border-left-width: 0px; display: inline; margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; line-height: normal"> mm.

It is worth noting that an actual source of ions will not only be characterized by a distribution of velocities, but also distribution of directions (no ion beam is strictly mono-directional, just like a laser beam is not strictly mono-directional). This is an additional fact that would have to be considered to accurately simulate the performance of a real Wien filter.

ExB_Filter_Exercise_4.py(with Bug Fix)

#

# ExB_Filter_Exercise_4.py

#

# This file is used to numerically integrate

# the second order linear differential equations

# that describe the trajectory of a charged particle through

# an E x B velocity filter.

#

# Here, it is assumed that the axis of the filter

# is aligned with the z-axis, that the magnetic field

# is along the +x-direction, and that the electric field

# is along the -y-direction.

#

# The numerical integration is done using the built-in

# routine odeint.

#

# Many particles selected from a normal distribution of

# z-velocities are sent through the filter and histograms

# of the z-velocities of the incident and transmitted particles

# are produced.

#

# By:

# Ernest R. Behringer

# Department of Physics and Astronomy

# Eastern Michigan University

# Ypsilanti, MI 48197

# (734) 487-8799 (Office)

# ebehringe@emich.edu

#

# Last updated:

#

# 20160624 ERB

#

from pylab import figure,xlim,xlabel,ylim,ylabel,grid,title,hist,show,text

from numpy import sqrt,array,arange,random,absolute,zeros,linspace

from scipy.integrate import odeint

#

# Initialize parameter values

#

q = 1.60e-19 # particle charge [C]

m = 7.0*1.67e-27 # particle mass [kg]

KE_eV = 100.0 # particle kinetic energy [eV]

Ex = 0.0 # Ex = electric field in the +x direction [N/C]

Ey = -105.0 # Ey = electric field in the +y direction [N/C]

Ez = 0.0 # Ez = electric field in the +z direction [N/C]

Bx = 0.002 # Bx = magnetic field in the +x direction [T]

By = 0.0 # By = magnetic field in the +x direction [T]

Bz = 0.0 # Bz = magnetic field in the +x direction [T]

R_mm = 0.5 # R = radius of the exit aperture [mm]

L = 0.25 # L = length of the crossed field region [mm]

Ntraj = 40000 # number of trajectories

transmitted_v = zeros(Ntraj) # array to save velocities of transmitted particles

n_transmitted = 0 # counter for the number of transmitted particles

# Derived quantities

qoverm = q/m # charge to mass ratio [C/kg]

KE = KE_eV*1.602e-19 # particle kinetic energy [J]

vmag = sqrt(2.0*KE/m) # particle velocity magnitude [m/s]

R = 0.001*R_mm # aperture radius [m]

vzpass = -Ey/Bx # z-velocity for zero deflection [m/s]

# Set up the distribution of incident velocities

mean = vzpass # the mean of the velocity distribution is vzpass

sigma = 0.1*vzpass # the width of the velocity distribution is 0.1*vzpass

vz = mean + sigma*random.randn(Ntraj) # the set of initial velocity magnitudes

scaled_vz = vz/vzpass # the set of scaled initial velocity magnitudes

# Set up the bins for the histograms

scaled_vz_min = 0.6

scaled_vz_max = 1.4

Nbins = 64

scaled_vz_bins = linspace(scaled_vz_min,scaled_vz_max,Nbins+1)

vz_bins = vzpass*scaled_vz_bins

#

# Over what time interval do we integrate?

#

tmax = L/vzpass;

#

# Specify the time steps at which to report the numerical solution

#

t1 = 0.0 # initial time

t2 = tmax # final scaled time

N = 1000 # number of time steps

h = (t2-t1)/N # time step size

# The array of time values at which to store the solution

tpoints = arange(t1,t2,h)

# Specify initial conditions that don't change

x0 = 0.0 # initial x-coordinate of the charged particle [m]

dxdt0 = 0.0 # initial x-velocity of the charged particle [m/s]

y0 = 0.0 # initial y-coordinate of the charged particle [m]

dydt0 = 0.0 # initial y-velocity of the charged particle [m/s]

z0 = 0.0 # initial z-coordinate of the charged particle [m]

#

# Here are the derivatives of position and velocity

def derivs(r,t):

# derivatives of position components

xp = r[1]

yp = r[3]

zp = r[5]

dx = xp

dy = yp

dz = zp

# derivatives of velocity components

ddx = qoverm*(Ex + yp*Bz - zp*By)

ddy = qoverm*(Ey + zp*Bx - xp*Bz)

ddz = qoverm*(Ez + xp*By - yp*Bx)

return array([dx,ddx,dy,ddy,dz,ddz],float)

# Start the loop over the initial velocities

for i in range (0,Ntraj-1):

# Specify initial conditions

dzdt0 = vz[i] # initial z-velocity of the charged particle [m/s]

r0 = array([x0,dxdt0,y0,dydt0,z0,dzdt0],float)

# Calculate the numerical solution using odeint

r = odeint(derivs,r0,tpoints)

# Extract the 1D matrices of position values

position_x = r[:,0]

position_y = r[:,2]

position_z = r[:,4]

# Extract the 1D matrices of velocity values and final velocity

v_x = r[:,1]

v_y = r[:,3]

v_z = r[:,5]

vxf = v_x[N-1]

vyf = v_y[N-1]

vzf = v_z[N-1]

vf = sqrt(vxf*vxf + vyf*vyf + vzf*vzf)

# If the particle made it through the aperture, save the velocity

if absolute(position_x[N-1]) < R:

if absolute(position_y[N-1]) < sqrt(R*R - position_x[N-1]*position_x[N-1]):

transmitted_v[n_transmitted] = vf

n_transmitted = n_transmitted + 1

# Only save the non-zero values for the histogram

transmitted_v_f = transmitted_v[0:n_transmitted]

scaled_transmitted_v_f = transmitted_v_f/vzpass

# Let the user know how many particles were transmitted

print("The number of incident particles is %d"%Ntraj) #Frem: Added Brackets

print("The number of transmitted particles is %d"%n_transmitted) #Frem: Added Brackets

# start a new figure

figure()

# plot the histogram of scaled initial velocities

n, bins, patches = hist(scaled_vz, scaled_vz_bins, normed=0, facecolor='orange', alpha=0.75)

xlabel('vz/vz,pass [m/s]',size = 16)

ylabel('N',size = 16)

title('Histogram of initial vz/vz,pass values')

xlim(scaled_vz_min,scaled_vz_max)

ylim(0,0.075*Ntraj)

grid(True)

show()

# start a new figure

figure()

# plot the histogram of scaled final velocities (transmitted particles)

n, bins, patches = hist(scaled_transmitted_v_f, scaled_vz_bins, normed=0, facecolor='purple', alpha=0.75)

xlabel('vz/vz,pass',size = 16)

ylabel('N',size = 16)

title('Histogram of vz/vz,pass values for transmitted particles')

xlim(scaled_vz_min,scaled_vz_max)

ylim(0,0.075*Ntraj)

grid(True)

text(0.65,2750,"R = %.2f mm"%R_mm,size=16)

show()

 

Translations

Code Language Translator Run

Credits

Fremont Teng; Loo Kang Wee

Questions & Answers about the Wien (E x B) Filter Simulation 1. What is the fundamental purpose of a Wien filter, and what physical principles does it utilize? A Wien filter is designed to selectively filter charged particles based on their velocity. It achieves this by employing mutually perpendicular electric and magnetic fields in a specific spatial region. The principle of operation relies on the forces exerted by these fields on moving charged particles. The electric field applies a force proportional to the charge and field strength in one direction, while the magnetic field applies a force proportional to the charge, velocity, and magnetic field strength, and in a direction perpendicular to both the velocity and the magnetic field. By carefully balancing the strengths of these fields, only particles with a specific velocity will experience zero net force and pass through undeflected. 2. What are the key learning objectives for students engaging with the Wien filter exercises described? Students who complete these exercises will learn to: Determine the Cartesian components of the electric and magnetic forces acting on a charged particle in perpendicular fields. Derive the equations of motion for a charged particle moving through these fields. Calculate the trajectory of a charged particle by numerically solving its equations of motion. Generate 2D and 3D plots to visualize these trajectories. Simulate the operation of a Wien filter. Identify the range of particle velocities that are transmitted by the filter. Analyze how the filter's geometry affects the range of transmitted velocities. 3. How does a Wien filter achieve velocity selection for charged particles? Velocity selection in a Wien filter occurs when the electric force (qE) on a charged particle is exactly balanced by the magnetic force (qv×B). For mutually perpendicular electric field (E in the y-direction) and magnetic field (B in the x-direction), a particle moving with a velocity v in the z-direction will experience an electric force in the y-direction (qEyˆj) and a magnetic force in the negative y-direction (qvzBxˆj). When these forces are equal in magnitude and opposite in direction (qEy=qvzBx), the net force in the y-direction is zero, and the particle passes through the filter undeflected. This occurs for particles with a specific velocity vpass=Ey/Bx. 4. What is the significance of numerical integration in analyzing the behavior of charged particles in a Wien filter? The equations of motion for a charged particle in a Wien filter, especially when considering particles with initial velocity components not perfectly aligned with the z-axis or when analyzing the transmission of particles with a range of velocities, can be complex and may not have simple analytical solutions. Numerical integration techniques are therefore essential to approximate the solutions to these differential equations. These methods allow for the calculation of the particle's position and velocity at discrete time steps, enabling the simulation and analysis of particle trajectories under the influence of the electric and magnetic fields. 5. What role does the exit aperture of the Wien filter play in determining the transmitted range of velocities? The exit aperture, typically a small circular opening placed along the intended path of undeflected particles, defines the spatial tolerance for a particle to be considered "transmitted" by the filter. Particles with velocities slightly different from the ideal vpass will experience a net force and thus a deflection in the y-direction. If this deflection is large enough that the particle's trajectory at the exit plane falls outside the bounds of the aperture, the particle is considered blocked. Therefore, the size (radius) of the exit aperture directly influences the range of velocities that can pass through the filter. A larger aperture will allow particles with a wider range of velocities (and thus greater deflections) to be transmitted, resulting in a broader velocity selection. Conversely, a smaller aperture will lead to a narrower range of transmitted velocities, providing finer velocity selection. 6. How can the simulation model be used to determine the range of particle velocities transmitted by the Wien filter? The simulation model works by launching a large number of charged particles with a distribution of initial z-velocities around the ideal passing velocity (vpass) and with initial x and y velocities typically set to zero in these exercises. For each particle, the equations of motion are numerically integrated as it travels through the region with perpendicular electric and magnetic fields. At the end of the field region (at z=L), the particle's x and y coordinates are checked against the dimensions of the exit aperture (radius R). If the particle's position falls within the aperture (x2+y2R), it is considered transmitted. By tracking which initial z-velocities result in transmission, and by systematically varying the range of initial velocities, the simulation can map out the "particle pass function" – a plot of transmission probability (or a binary pass/fail) versus initial z-velocity. The width of the velocity range for which particles are transmitted defines the velocity resolution of the filter. 7. How is the effect of the filter's geometry, such as the length of the crossed field region and the size of the exit aperture, investigated using the simulation? The simulation allows for the manipulation of various geometrical parameters of the Wien filter. For instance, the length of the crossed field region (L) can be changed in the simulation code (e.g., by modifying the L variable). Similarly, the radius of the exit aperture (R) can be adjusted (e.g., by changing R_mm). By running the simulation multiple times with different values for these parameters while keeping other factors constant (like the electric and magnetic field strengths, and the charge-to-mass ratio of the particle), the effect of each geometrical factor on the filter's performance can be studied. This includes analyzing how the transmitted velocity range and the resolution of the filter change with variations in L and R. For example, increasing the length of the filter might lead to greater deflection for off-velocity particles, potentially narrowing the transmitted velocity range for a given aperture size. Similarly, changing the aperture size directly impacts the accepted deflection and thus the range of transmitted velocities, as explored in Exercise 4a and 4b. 8. What are some of the specific parameters and initial conditions used in the provided Python code snippet for simulating a Wien filter with a Li+ ion? The Python code snippet provided includes the following key parameters and initial conditions: Electric Field: Ex=0.0, Ey=100.0 (in V/m), Ez=0.0. Magnetic Field: Bx=0.002 (in T), By=0.0, Bz=0.0. Charge to Mass Ratio: qoverm = q/m (in C/kg), where q is the charge of the Li+ ion and m is its mass. This would need to be defined elsewhere in the full code. Kinetic Energy: KE = KE_eV*1.602e-19 (in Joules), based on KE_eV (in electron volts), which is not explicitly defined in this snippet but would be set for the simulation. Exit Aperture Radius: R_mm = 1.0 or 2.0 (in mm), converted to meters as R = 0.001*R_mm. Length of Crossed Field Region: L = 0.25 (in mm), converted to meters. Initial Position: x0=0.0, y0=0.0, z0=0.0 (in meters). Initial Velocities (except z): dxdt0=0.0, dydt0=0.0 (in m/s). The initial z-velocity dzdt0=vz[i] is varied within a range around the ideal passing velocity vzpass=Ey/Bx to study the velocity selection. The range is set by vz = vzpass + linspace(-0.25*vzpass,0.25*vzpass,Ntraj+1), where Ntraj is the number of trajectories simulated (1000 in this case). Simulation Time: The simulation runs from t1=0.0 to t2=tmax=L/vzpass, with N = 1000 time steps. These parameters are used to define the forces acting on the Li+ ion and to numerically integrate its trajectory for different initial z-velocities, ultimately determining which velocities allow the ion to pass through the exit aperture. Briefing Document: PICUP Wien (E x B) Filter Simulation Date: October 26, 2023 Subject: Review of the PICUP Wien (E x B) Filter Exercise 4 JavaScript HTML5 Applet Simulation Model Source: Excerpts from "PICUP Wien (E x B) Filter Exercise 4 JavaScript HTML5 Applet Simulation Model need odeint to work - Open Educational Resources / Open Source Physics @ Singapore | Open Educational Resources / Open Source Physics @ Singapore" Overview: This document provides a briefing on the PICUP Wien (E x B) Filter Exercise 4, which utilizes a JavaScript HTML5 applet simulation model. The exercise, part of a larger set, aims to guide students in understanding the behavior of charged particles within mutually perpendicular electric and magnetic fields, characteristic of a Wien filter (also known as a velocity selector). Exercise 4 specifically focuses on simulating the filter's operation with a distribution of particle velocities and analyzing the range of velocities transmitted. The simulation relies on numerical integration (requiring odeint in its Python implementation, though the final model is in JavaScript). Main Themes and Important Ideas: Wien Filter Fundamentals: The core concept is the Wien filter, which employs perpendicular electric (E) and magnetic (B) fields to select charged particles based on their velocity. The force on a charged particle in these fields is given by the Lorentz force law: F=q(E+v×B). For a particle to pass undeflected, the electric and magnetic forces must balance each other out. Equations of Motion: The exercises leading up to Exercise 4 (mentioned as Exercise 1) involve deriving the equations of motion for a charged particle in these crossed fields by determining the Cartesian components of the forces acting on it. These equations are second-order linear differential equations. Numerical Integration: The solutions to these equations of motion are obtained through numerical integration. The provided Python code explicitly uses the odeint routine from the scipy.integrate library for this purpose. The JavaScript/HTML5 applet performs a similar numerical integration to simulate particle trajectories. Velocity Selection: The Wien filter acts as a velocity selector because only particles with a specific velocity (where the electric force qE is equal and opposite to the magnetic force q(v×B)) will pass through undeflected. For mutually perpendicular E, B, and v, this condition simplifies to E=vB, or v=E/B. The text mentions: "determine the range of particle velocities transmitted by the filter". The Python code defines vzpass = -Ey/Bx as the "z-velocity for zero deflection," aligning with the condition for velocity selection. Simulation of Velocity Distribution: Exercise 4 extends the analysis by considering particles entering the filter with a normal distribution of velocities directed along the z-axis. The simulation then tracks these particles and analyzes the velocities of those that are transmitted through an exit aperture. The source states: "As an extension of Exercise 3, now assume that the particles entering the field region at the origin have a normal distribution of velocities directed purely along the z-axis. The center of the distribution is vz,pass and its width is 0.1vz,pass." Analysis of Transmitted Velocities: The exercise requires students to generate histograms of the scaled velocities (vz/vz,pass) of the transmitted particles and compare them to the initial velocity distribution. This allows for the investigation of the filter's selectivity and how the geometry (specifically the radius of the exit aperture) affects the range of transmitted velocities. The questions posed in Exercise 4 are: "(a) Allow 40,000 particles from this distribution to enter the field region at the origin. What is the resulting histogram of the scaled velocities vz/vz,pass of the particles transmitted through a circular aperture of radius R=1.0 mm centered on the z-axis? How does it compare to the histogram of the initial velocities?" "(b) Repeat part (a) for an aperture of radius R=0.5 mm." Importance of Aperture Size: The exercise explicitly investigates the impact of the exit aperture radius (R_mm in the Python code) on the transmitted velocity distribution. Smaller apertures are expected to result in a narrower range of transmitted velocities, enhancing the filter's selectivity. Python Implementation (Underlying Model): The provided Python code (ExB_Filter_Exercise_4.py) demonstrates the numerical simulation process. It initializes parameters such as particle charge (q), mass (m), electric field (Ey), magnetic field (Bx), and aperture radius (R_mm). It then sets up a normal distribution of initial z-velocities around vzpass. The core of the simulation involves a loop that iterates through a large number of particle trajectories (Ntraj = 40000). For each particle, the odeint function is used to solve the equations of motion, and the final position is checked to see if the particle passes through the aperture. The velocities of the transmitted particles are then stored and used to generate histograms. JavaScript HTML5 Applet: While the underlying model development might involve Python (requiring odeint), the final deliverable for students is a JavaScript HTML5 applet, allowing for interactive simulation within a web browser. The embedded iframe code provides the means to embed this interactive model. Limitations of the Model: The text acknowledges a simplification in the model: "It is worth noting that an actual source of ions will not only be characterized by a distribution of velocities, but also distribution of directions (no ion beam is strictly mono-directional, just like a laser beam is not strictly mono-directional). This is an additional fact that would have to be considered to accurately simulate the performance of a real Wien filter." Key Learning Objectives: Students completing these exercises, particularly Exercise 4, are expected to: Understand the forces acting on a charged particle in crossed electric and magnetic fields. Comprehend the principle of velocity selection in a Wien filter. Be able to simulate particle trajectories numerically. Analyze the effect of a distribution of initial velocities on the output of a Wien filter. Determine how the geometry of the filter (e.g., aperture size) affects the range of transmitted velocities. Quotes: "This set of exercises guides the students to compute and analyze the behavior of a charged particle in a spatial region with mutually perpendicular electric and magnetic fields." "It requires the student to determine the Cartesian components of hte forces acting on the particle and to obtain the corresponding equations of motion. The solutions to these equations are obtained through numerical integation..." "The capstone exercise is the simulation of the E×B (Wien) filter." "Students who complete this set of exercises will be able to: ... simulate the operation of an E×B (Wien) filter (Exercise 3) and determine the range of particle velocities transmitted by the filter, and how these are affected by the geometry of the filter (Exercise 4)." "As an extension of Exercise 3, now assume that the particles entering the field region at the origin have a normal distribution of velocities directed purely along the z-axis. The center of the distribution is vz,pass and its width is 0.1vz,pass." "What is the resulting histogram of the scaled velocities vz/vz,pass of the particles transmitted through a circular aperture of radius R=1.0 mm centered on the z-axis? How does it compare to the histogram of the initial velocities?" "vzpass = -Ey/Bx # z-velocity for zero deflection [m/s]" Conclusion: The PICUP Wien (E x B) Filter Exercise 4 provides a valuable learning tool for students to explore the principles of velocity selection using a computational approach. By simulating the trajectories of a large number of particles with a distribution of initial velocities and analyzing the effect of the exit aperture, students can gain a deeper understanding of the Wien filter's operation and its dependence on electric and magnetic field strengths, as well as its physical geometry. The use of a JavaScript HTML5 applet makes the simulation accessible and interactive.

Sample Learning Goals

[text]

For Teachers

[text]

Research

[text]

Video

[text]

 Version:

  1. https://www.compadre.org/PICUP/exercises/Exercise.cfm?A=ExB_Filter&S=6
  2. http://weelookang.blogspot.com/2018/06/wien-e-x-b-filter-exercise-123-and-4.html

Other Resources

[text]

end faq

{accordionfaq faqid=accordion4 faqclass="lightnessfaq defaulticon headerbackground headerborder contentbackground contentborder round5"}

Study Guide: Wien Filter Simulation

Key Concepts

  • Wien Filter (E x B Filter): A device that uses perpendicular electric (E) and magnetic (B) fields to select charged particles based on their velocity.
  • Forces on a Charged Particle in Electromagnetic Fields: A charged particle moving in electric and magnetic fields experiences a Lorentz force, given by F=q(E+v×B), where q is the charge and v is the velocity of the particle.
  • Equations of Motion: Newton's second law (F=ma) applied to a charged particle in electromagnetic fields leads to differential equations describing its motion. These equations relate the particle's acceleration to the forces acting on it.
  • Velocity Selector: In a Wien filter, for a specific velocity, the electric and magnetic forces are equal and opposite, resulting in zero net force and allowing particles with this velocity to pass through undeflected. This occurs when qE=qvB, or v=E/B.
  • Numerical Integration: A method used to approximate the solution of differential equations when analytical solutions are not feasible. The odeint routine in Python is an example of a numerical integration technique.
  • Cartesian Components: The x, y, and z components of vectors, such as force, velocity, and position. Analyzing the forces and motion in terms of their Cartesian components simplifies the problem.
  • Particle Trajectory: The path followed by a charged particle as it moves through space under the influence of forces. In a Wien filter, the trajectory depends on the initial velocity of the particle and the strengths and directions of the electric and magnetic fields.
  • Normal Distribution of Velocities: A common probability distribution where values are clustered around the mean, with fewer values occurring further away from the mean. This is characterized by a mean (μ) and a standard deviation (σ).
  • Histogram: A graphical representation of the distribution of numerical data, where the data is grouped into bins, and the height of each bar corresponds to the frequency of data within that bin.
  • Aperture: An opening that restricts the passage of particles. In the Wien filter simulation, a circular aperture at the exit determines which particles are transmitted.

Quiz

  1. Describe the orientation of the electric and magnetic fields in the Wien filter simulation model based on the provided Python code comments. What is the consequence of this configuration on a positively charged particle moving along the z-axis?
  2. Explain the condition required for a charged particle to pass through the Wien filter undeflected. How is this condition mathematically expressed in terms of the electric field (Ey) and magnetic field (Bx) in the given simulation?
  3. What is the purpose of numerically integrating the equations of motion for the charged particles in this simulation? Why is a numerical method like odeint necessary here?
  4. According to Exercise 4, what is the initial condition for the velocities of the particles entering the Wien filter? How are these velocities characterized in the simulation?
  5. Explain the role of the parameters mean and sigma in setting up the distribution of incident velocities in the Python code. How do these parameters affect the range of initial velocities?
  6. What physical quantity does the code variable vzpass represent? How is it calculated from the electric and magnetic field parameters?
  7. Describe the criteria used in the Python code to determine whether a particle is transmitted through the Wien filter. What conditions must be met at the end of the simulation time?
  8. What is the purpose of generating histograms of the scaled velocities in Exercise 4? What two sets of velocities are compared using these histograms?
  9. How does changing the radius of the exit aperture affect the number and range of particle velocities that are transmitted through the Wien filter, as explored in parts (a) and (b) of Exercise 4?
  10. What additional factor, beyond the distribution of velocities, could affect the performance of a real Wien filter, as mentioned in the text?

Quiz Answer Key

  1. The magnetic field is along the +x-direction (Bx > 0), and the electric field is along the -y-direction (Ey < 0). For a positively charged particle moving along the +z-axis, the electric force will be in the -y direction, and the magnetic force (v×B) will be in the +y direction.
  2. For a charged particle to pass undeflected, the net force in the x and y directions must be zero. In this configuration, this primarily means the electric force and the magnetic force in the y-direction must cancel out. Mathematically, this occurs when vzpass=Ey/Bx.
  3. Numerical integration is necessary to find the trajectories of the charged particles because the equations of motion, which involve both electric and magnetic forces dependent on velocity, can be complex to solve analytically, especially for a distribution of initial velocities. odeint provides an algorithm to approximate the particle's position and velocity over time by taking small time steps.
  4. The particles entering the field region at the origin have a normal distribution of velocities directed purely along the z-axis. This distribution is characterized by a mean velocity (vz,pass) and a width (related to the standard deviation, 0.1 * vz,pass).
  5. The mean parameter sets the average value of the z-velocity distribution, which is equal to vzpass (the velocity for zero deflection). The sigma parameter defines the standard deviation of the distribution, which determines the spread or width of the velocities around the mean.
  6. The code variable vzpass represents the z-velocity at which a charged particle experiences zero net deflection in the Wien filter due to the balanced electric and magnetic forces. It is calculated as vzpass = -Ey/Bx.
  7. A particle is considered transmitted if, at the final time step (when it should have exited the field region), its x-coordinate and y-coordinate are both within the bounds of the circular aperture of radius R centered on the z-axis. The conditions are absolute(position_x[N-1]) < R and absolute(position_y[N-1]) < sqrt(R*R - position_x[N-1]*position_x[N-1]).
  8. The histograms of the scaled velocities (vz/vz,pass) are generated to visualize the distribution of initial z-velocities of all the particles and to compare it with the distribution of z-velocities of only those particles that successfully passed through the filter. This helps determine the filter's velocity selection properties.
  9. A smaller aperture radius (R = 0.5 mm compared to R = 1.0 mm) will likely result in fewer particles being transmitted, as the spatial constraint at the exit is tighter. It might also lead to a narrower range of transmitted velocities, as only particles with trajectories closer to the z-axis will be able to pass through the smaller opening.
  10. An actual source of ions will also have a distribution of directions, meaning the initial velocities will not be perfectly aligned along the z-axis. This angular spread of the ion beam would need to be considered for a more accurate simulation of a real Wien filter's performance.

Essay Format Questions

  1. Discuss the fundamental principles behind the operation of a Wien filter as a velocity selector for charged particles. Explain how the perpendicular electric and magnetic fields interact with moving charges and under what conditions a specific velocity is selected.
  2. Explain the process of setting up and executing a simulation to model the behavior of charged particles in a Wien filter. Describe the key steps involved, including defining the fields, setting initial conditions for a distribution of particles, and numerically integrating the equations of motion.
  3. Analyze the factors that influence the velocity resolution of a Wien filter. How do the strengths of the electric and magnetic fields, the geometry of the filter (length, aperture size), and the initial velocity distribution of the particles affect the range of velocities that are transmitted?
  4. The provided exercise investigates the transmission of particles with a normal distribution of initial velocities through a Wien filter with different aperture sizes. Discuss the expected outcomes of this investigation and how the histograms of initial and transmitted velocities would differ. What conclusions can be drawn about the filter's selectivity from these results?
  5. Evaluate the limitations of the simulation model described in the excerpts in representing a real-world Wien filter. What additional physical factors or complexities might need to be considered for a more comprehensive and accurate simulation of such a device?

Glossary of Key Terms

  • Charged Particle: A subatomic particle, such as an electron or ion, that carries an electric charge.
  • Electric Field (E): A region of space around an electrically charged particle or object in which a force would be exerted on other electrically charged particles or objects. Measured in Newtons per Coulomb (N/C).
  • Magnetic Field (B): A field of force produced by moving electric charges and intrinsic magnetic moments of elementary particles that exerts a force on other moving charges. Measured in Tesla (T).
  • Lorentz Force: The force exerted on a charged particle in an electromagnetic field, given by F=q(E+v×B).
  • Velocity (v): The rate of change of an object's position with respect to a frame of reference, and is a function of time. It is a vector quantity, having both magnitude (speed) and direction. Measured in meters per second (m/s).
  • Trajectory: The path traced by a moving object in space as a function of time.
  • Numerical Integration: A set of algorithms for calculating the numerical value of a definite integral, and more broadly, for solving differential equations numerically.
  • Cartesian Coordinates: A coordinate system that specifies each point uniquely in a plane by a set of numerical coordinates, which are the signed distances to the point from two fixed perpendicular oriented lines, measured in the same unit of length. In three dimensions, three perpendicular planes are used.
  • Normal Distribution: A probability distribution that is symmetric about the mean, showing that data near the mean are more frequent in occurrence than data far from the mean. Also known as the Gaussian distribution or bell curve.
  • Histogram: A graphical representation of the distribution of numerical data.
  • Aperture: An opening or hole, often used to control the amount of something (like particles or light) that passes through.
  • Simulation Model: A representation or imitation of a real-world system, used to study its behavior without actually experimenting with the real system.
  • Equations of Motion: Mathematical equations that describe the physical movement of a system of physical entities as a function of time.
  • Deflection: The act or state of being turned aside from a straight course or fixed direction.
  • Velocity Selector: A device using orthogonal electric and magnetic fields to select charged particles with a specific velocity.
1 1 1 1 1 1 1 1 1 1 Rating 0.00 (0 Votes)