15Oct/100

## Speed of light in a vacuum

Electric fields travel at the speed of light - a constant 299,792,458 meters per second regardless of wavelength.  However, this fact is only true for the ideal case where the waves are traveling through vacuum away from any other charge sources.  In non-ideal situations, where an electric field is traveling through another medium, the speed of the field is slowed.  But how slow?

In order to understand how different mediums effect an electric field's velocity, we first need to understand why the speed of light travels at the velocity it does in that idealized case.  The first part of this multi-part series is going to discuss the general form of the wave equation followed by a derivation of the speed of light in vacuum.

30Sep/100

## The Hall effect

Since i have found a position with Carnegie Mellon, i now have the time to reflect on my job search and more to the point, the interviews.  While most of the time was spent discussing the experience listed on my resume, the question i remember hearing the most was if i could explain what the Hall effect is.  Now, i have designed circuits leveraging Hall effect sensors in the past - in motor controllers as angular position sensors, in magnetic switches, and in scroll wheels as linear position sensors, but i never took the time to dig in and understand how the sensors worked.  For all i cared it could have been voodoo, black magic, or a combination of the two - one way or another the sensor is able to tell me where it is in relation to a nearby magnetic field.  That only gets you so far, so i guess it's time to demystify these little ICs.

What is the Hall effect:
The Hall effect, named after the scientist who first detected it Edwin Hall, is the opposing force a flow of charge carriers (current) induces to cancel out a Lorentz force acting upon it.  This opposing  forces is equal in magnitude and opposite in sign to the Lorentz force in order for the steady state net force on the carries to be zero, satisfying Newtons 3rd law.  This answer requires a basic understanding of the fundamental laws of classical electromagnetic fields - Maxwell's equations, and  the Lorentz force where Maxwell's equations describe how moving charge carriers induce EM fields and the Lorentz force is how EM fields effect moving charge carriers.

How to leverage the Hall effect:
One generally uses Hall effect sensors to sense the position of a magnet, or the magnitude of a current.  There are 3 main types of position sensors - binary, linear and radial.  For each, it is assumed that there is a magnetic field (generally generated by a magnet) that is a part of the component you want to sense the position of, in a location where it will pass over the sensor's active area.

• For a binary sensor, it will switch logic states when the active area is in proximity of a north or south pole (axially magnetized).
• For a linear sensor, it will give you an analog or multiple bit digital output corresponding to the distance the active area is away from a north or south pole.
• For a radial sensor, it will give you an analog or multiple bit digital output corresponding to the angle at which the north/south pole is to the active area.  Radial sensors require a diametrically magnetized magnet persistently centered on the sensors active area.
• For current sensing, the Hall sensor's active area is placed perpendicularly to the currents induced magnetic field and will output an analog or multiple bit digital signal corresponding to the current's magnitude.

How do Hall effect sensors work:
Internal to the IC, there is a rectangular plate that a small current travels through in the y-direction, with voltage sensing circuitry connected across the plate in the x-direction.  While there is no external magnetic field and therefore no Lorentz force, the current travels linearly through the plate and no voltage difference can be sensed at the sides of the plate.  However, in the presence of a magnetic field perpendicular to the current flow (through the large surface of the plate in the z-direction), an electric field is formed called the Hall field which when integrated across the length of the plate gives you the a voltage differential called the Hall voltage.

14Apr/104

When one talks about quantitative qualities of a light source, you generally subscribe to one of two schools of thought - Radiometric in SI units of Watts or Photometric in SI units of lumens, candelas or lux. In this post i am going to discuss these two different approaches.

Photometric
Photometric units are quasi-quantitative hand-wavey units; they are an attempt to quantify the qualitative aspects of a light source i.e. how bright a light source appears to the human eye. These units are useful for things like home lighting, vehicle headlights, or photography light meters.

A COTS Sylvania SoftWhite 100W incandescent light bulb advertises that it produces 122 candelas. If we were to convert that value into watts using the standard conversion factor of 1 lumen = 1/683 Watt (at 555nm as that is the accepted wavelength of peak sensitivity of the human eye), we get:

$122\left[cd\right]\cdot 4\pi\left[sr\right]=1530\left[cd\cdot sr\right]=1533\left[lm\right]\cdot\frac{1\left[W\right]}{683\left[lm\right]}=2.24\left[W\right]$

This tells us that a 100W incandescent bulb is only about 2.25% efficient in producing visible light and the rest of the power is wasted in producing NIR through LWIR (heat) photons.

Radiometric units are scientific in nature - absolute units based solely on the physical photonic quantities. Radiometric units address the entire spectral transmission of a light source regardless of detector. These units are useful for scientific applications like spectroscopy, detector characterization, optical communications, etc., essentially anything scientific that deals with light.

24Mar/100

## MS257 output divergence

the MS257's spec sheet calls out the input F/# in order to match the source to the monochrometer however it doesn't specify the output F/# or divergence which is extremely important to couple the monochromatic light into an optical system.  The spec sheet does instead specify the input and output focal lengths which we can use to back calculate the output divergence.
We first must find the F/# at the output, which is only possible if we assume the input and output apertures are the same. This is a reasonable assumption for a monochrometer as the instrument requires matching input and output slits to function properly. Using the definition of F/# we first solve for d:

$F/\#=\frac{fl}{d}\;\therefore \;d=\frac{fl}{F/\#}$

Once we have this standard equation, we plug it back into the F/# equation with the different focal lengths:

${F/\#}_o=\frac{fl_o}{d}=\frac{fl_o}{\left(\frac{fl_i}{{F/\#}_i}\right)}$

This equation can be rewritten to show that the ratio of the output F/# to the input F/# is equal to the ratio of the output focal length to the input focal length.

Now that we have a close form solution, we can plug-in the constants - the MS257 specification states the instrument has an input focal length of 220mm and an output focal length of 257.4mm; when we plug those values into the equation with the original input F/3.9 we get an output of F/4.56, and by using the equation from the previous post, that translates to a divergence of 12.51° from the exit slit.

24Mar/100

## F/# as an angle

i have recently come across an issue with designing an optical system to interface with an Oriel MS257 monochrometer and found people referring to the divergence of the instrument by the F/# listed in the MS257's spec sheet - an F/3.9 at the input slit.  This didn't make sense to me as F/# is defined as the ratio of a lens's focal length to its aperture.
After some digging, it turns out that optics people use F/# and numerical aperture (NA) as ways of expressing a cone angle which, for the rest of this post, i will refer to as θ.  If we define the half angle using tangent, θ/2 is defined by the ratio of its opposite length to its adjacent length which easily correlate to half a lens' aperture and its focal length respectively. Using basic trigonometry we get:

$\begin{matrix}\frac{\theta}{2}&=&\arctan\left(\frac{d/2}{fl}\right)\\\theta&=&2\cdot\arctan\left(\frac{d/2}{fl}\right)\end{matrix}$

where d is the length of the aperture and fl is the focal length.  We can then massage this equation such that it is in terms of F/#:

NOTE:  $F/\#=\frac{fl}{d}$

$\begin{matrix}\theta&=&2\cdot\arctan\left(\frac{d/2}{fl}\right)\\&=&2\cdot\arctan\left(\frac{1}{2}\cdot\frac{d}{fl}\right)\\&=&2\cdot\arctan\left(\frac{1}{2}\cdot F/\#^{-1}\right)\end{matrix}$

So drawing from the MS257 example where we have F/3.9 at the input, that translates to an input angle of 14.61°, and any source that we input into the monochrometer must be focusing at the input slit at an angle of 14.61°.

16Mar/101

i assume that i am not alone in opting out of paying \$10k more for the WRX STI and got the standard WRX instead.  Unfortunately, anything and everything online regarding upgrading or modifying the WRX is in terms of the STI model, so when i went to install my Pioneer AVIC-Z2 In-Dash DVD/GPS Navigation System, any vehicle specific installation instructions or diagrams were non existent.  The reason this would have been helpful is that the unit, like other similar systems, requires not only a standard wiring harness to interface the head unit to the vehicle, but also requires to be connected to the emergency parking break signal, reverse signal, and vehicle speed sensor (VSS).

Being that i intended to hack the system in order to watch DVDs while the car is not parked, i followed the directions to bypass the built-in security features. The first step is to ground the parking break signal wire, and then ground the bottom right most pin of connector 2 which will keep the unit unlocked when you start moving. This resolves the parking break signal issue, but we still have 2 to go.

The reverse signal is used to engage the backup camera (if you have one installed), and may or may not be used with the GPS functionality, i don't know.  After some searching i found the vehicles repair manual where chapter 7 section 23 discusses the back-up light system's wiring schematic which can be found here (Warning: PDF).  The reverse signal goes over the Brown/Yellow wire (the same for all models) and can be found under the passenger side kick-plate.

The last signal which the unit requires is the vehicle speed sensor.  Note: Even if the unit is bypassed and the VSS signal wont disable the unit, the signal is still important for the GPS functionality as it is not capable of solely running on the GPS signal for vehicle location.  My experience shows that without the VSS connected, the unit may assume your driving 65MPH down the highway... backwards.  Chapter 7 section 17 of the vehicles repair manual discusses the 3 WRX model's engine electrical systems and their various ECUs can be found here (Warning: PDF).  To cover all 3 WRX models: the VSS signal is the Green/Yellow wire connected to pin 1 of connector B134 of the turbo model's ECU (PDF page 4), the Green/Yellow wire connected to pin 10 of connector B147 of the SOHC model's ECU (PDF page 18), and the Green/Yellow wire connected to pin 27 of connector B135 of the STI model's ECU (PDF page 30).

16Mar/100

## Intro to imaging optics

If you’re like me, and not an optical engineer, the most interaction you'll have with optics is with either an aspheric collimating lenses or multielement imaging lenses.  This post is going to focus on the later while informing on the former.  We will briefly discuss the fundamentals of optical design, followed by a discussion of lens specification by defining Image Circle, Focal Length, Aperture, and Resolution.

Background:
Imaging lenses, be it for a telescope or a camera, can be designed using either mirrors which work by the reflection of light, or glass which work by refraction of light.  Reflective optical systems have the ideal quality that all light reflected by the surface bends at the same rate, and thus are inherently achromatic.  They also follow simple trigonometric rules where the excidence angle is equal but opposite in sign to its corresponding incidence angle.  These ray angles are referenced from the normal line which is perpendicular to the surface tangent at the particular point of incidence.  The only knob the designer has to turn is the mirror element shape and clever mechanical design.  These designs are quite large, and are ideal for systems which require long focal lengths; however they are unreasonable for designs which require small compact lenses.  Refractive optical systems are more conducive to smaller systems, which is why they are much more prevalent, yet their designs are more complex.

If you are one of the aforementioned optical engineers, back in the day one would do the entire design by hand using Snell’s law and a list of available glasses with their frequency dependent index of refractions; nowadays one would use an optical ray tracing software package like ZEMAX or Code V (pronounced "code 5") to aid in the design.  The advent of computer aided optical design opened the industry up for much more advanced, reduced distortion, achromatic lens designs.  However, to pay our respects to the past – Snell’s law states that the excidence angle of an incidence ray is proportional to the index of refraction of the two materials.

$\sin\left(\theta_e\right)=\frac{n_i}{n_e}\cdot\sin\left(\theta_i\right)$

Where 'θi' represents the angle off perpendicular to the surface tangent at the point of incidence, 'θe' represents the excidence angle while 'ni' and 'ne' represent the index of refraction of the two materials.  Note: index of refraction is defined as how much faster or slower light travels through a medium as compared to vacuum where the refractive index of vacuum = 1 while air ≈ 1.  Refractive index is also wavelength dependent which means that light bends at different rates when entering and exiting a medium, thus braking up into its component wavelengths.  There are graphs which can be found for different optical materials which plot their index of refraction vs. wavelength.  Snell’s equation gives the designer two knobs they can turn to develop their design - element material, and shape.  However, the fact that refractive index varies with wavelength adds complexity in producing an achromatic design.

15Mar/100

## 3dB point & FWHM

When someone refers to the 3dB point of a graph, they are referring to the 50% point.  This can be explained through its derivation:

$10\cdot\log\left(\frac{1}{2}\right)\approx3d\!B$

Going forward with this definition, the Full Width Half Max (FWHM) of a figure is defined by the 3dB point.  To find the FWHM of a graph, you find the 2 points at which the graph crosses the half-max point (0.5 x peak's max value) - the horizontal distance between the two points is the FWHM.

Filed under: Engineering, Math No Comments
26Jan/104

## MODTRAN

This post is going to discuss two pitfalls that i encountered while using MODTRAN via the PLEXUS GUI.  First is the conversion between Wavenumber to Wavelength, the second is using PLEXUS to perform night time lunar models.

Background:
The atmosphere, through its six layers, contains various particles and gases which attenuate impinging solar radiation.  The particles which contribute the most to this attenuation are water (H2O) in the troposphere (0-11Km), carbon dioxide (CO2) also in the troposphere, and ozone (O3) in the stratosphere (11-50Km).  While there is relatively little solar absorption through the visible bands (380nm - 750nm), there are strong absorption bands in the UVC and LWIR attributed to ozone, while H2O and CO2 absorb intermittently throughout the rest of the solar spectrum.  A Transmittance vs. Wavelength graph for two generic scenarios can be seen below.  Note: For larger absorption bands, the contributing particles are shown; the full Raytheon infrared wall chart can be found below under references. MODTRAN (MODerate spectral resolution atmospheric TRANSmittance algorithm and computer model) is an atmospheric spectral radiance modeling code developed by the Air Force Research Lab, Space Vehicles Directorate.  This code has been combined with several others (MODTRAN4 V2R1, SAMM 1.1, SAMM 1.82, FASCODE3 with HITRAN2K, SHARC Atmosphere Generator (SAG) V1 & V2, and Celestial Background Scene Descriptor (CBSD) V5) into a single software suite called PLEXUS (Phillips Laboratory EXpert-assisted User Software) which provides the user with an easier to use GUI for these atmospheric codes.  The most  recent version as of the publishing of this post is Release 3 Version 3A.  More information on PLEXUS as well as its constituent codes can be found on the AFRL software information page.

17Sep/090

## The Sustainable Energy Challenge with George Crabtree

Back in December i went to an interesting talk at MIT by George Crabtree - Argonne Distinguished Fellow and Director of the Materials Science Division at Argonne National Laboratory.  The talk was sponsored by the MIT Energy Initiative (MITEI) and can be watched online here.  The abstract of his talk was:

The global dependence on fossil fuel is among the greatest challenges facing our economic, social and political future. The uncertainty of imported oil threatens global energy security, the pollution of fossil combustion threatens human health, and the emission of greenhouse gases threatens global climate. Meeting the demand for double the current global energy use in the next 50 years without damaging security, environment or climate requires finding alternative sources of energy that are clean, abundant, accessible and sustainable. Electricity and hydrogen, once produced, meet these criteria and are among the most versatile of energy carriers. Research challenges that would enable the production, storage, and use of electricity and hydrogen as sustainable alternatives to fossil fuel will be presented.

It was a very interesting talk, and Dr. Crabtree was very responsive to questions from the audience.  The main messages i took home from the presentation is:

• Hydrogen should be our means of energy storage (slide 19)
• We should use super conductors as our transmission lines from coast to coast and continent to continent (slides 13,17,30,31)
• We should be harvesting all of our energy from the sun (slide 22,23)

However as he points out, the only thing standing in our way (and this is quite a big thing) is that we do not yet have any of these technologies nor materials that are mature enough for a solution (slide 25,34,35).

The referenced slides can be found in his presentation here. (Warning: Power Point)