Tutorial: Calculation of Image Rotation for a Scanning Optical System

advertisement
Tutorial:
Calculation of Image Rotation
for a Scanning Optical System
Sergio Guevara
OPTI 521 – Distance Learning
College of Optical Science
University of Arizona
Brief Overview of Scanning Optical
Systems

Uses:

Image Scanning


IR Imaging Systems
Laser Scanning


Laser Printers
Laser Projectors


Microvision’s SHOW
Projector
Artifacts


Image Distortion
Image Rotation
Figure from US Patent #4,106,845
Steps to Analyze Image Rotation
Sketch the system including:
1.
a)
b)
c)
d)
Choose a global coordinate system.
Define all objects in the global coordinate system.
2.
3.
a)
b)
4.
5.
6.
7.
8.
Mirror locations
Mirrors’ axis of rotation.
Input beam.
Image plane.
Define mirror matrices for mirrors in global coordinate system.
Define axis of rotation for mirrors in global coordinate system.
Find image for non-rotated case.
Add rotation to mirrors.
Find image in rotated case.
Project rotated and non-rotated images onto image plane.
Compare the projected images of the rotated case with the non-rotated case to
determine rotation of image.
Sketch the System
Top View
Figure from US Patent #4,106,845
Top View
Sketch the System
Front View
Figure from US Patent #4,106,845
Right View
Choose Global Coordinate System
Top View
Right View
Define Input Beam & Image Plane
in Global Coordinates


Input Beam is Parallel to Z-axis.
Image Plane lies on the X-Z plane.
Define Mirrors
in Global Coordinates


Find Mirror’s Normal Unit Vectors

Mirror 1 normal unit vector:

Mirror 2 normal unit vector:
1
1  
n̂ 
0
2 
1
 1
1  
n̂ 
1
2 
 0 
Create Mirror Matrices M  I  2nˆ  nˆ T

Mirror 1 Matrix:

Mirror 2 Matrix:
0
M1   0
 1
0
M 2   1
 0
0  1
1 0 
0 0 
 1 0
0 0
0 1
Define Rotation of Mirrors
in Global Coordinates


Mirror Rotation
T
 MR  R  M  R
Rotation Matrices

Mirror 1 Rotation Matrix:
(where α is the angle of rotation)

Mirror 2 Rotation Matrix:
(where β is the angle of rotation)
 cos  0
R1   0
1
 sin   0
0
1
R2  0 cos 
0 sin  
sin  
0 
cos 
0 
 sin  
cos  
System Model

Input thru Mirror

img  R 2 M 2 R T2 R 1 M 1 R 1T obj

For no image rotation
img nr  M 2 M1obj

Projection onto Image Plane

pimg  proj image_plane img   img  img  nˆ img 
Calculation of Rotation


Is a comparison of the initial image with no
mirror rotation to an image with mirror
rotation.
Use the definition of the cross product:
pimg nr  pimg rot  pimg nr pimg rot sin  

Rotation Equation:
 pimg nr  pimg rot
  sin 
 pimg nr pimg rot
1




Calculations
x
y
z
Object
vector
0
1
0
Mirror 1
normal vector
0.707106781
0
0.707106781
No Rotation
Object
x
0
y
1
z
0
0
0
-1
Mirror 2
normal vector
-0.70710678
-0.70710678
0
Mirror Matrix 1
0
1
0
Ray
-1
0
0
0
1
0
0
-1
0
Mirror Matrix 2
-1
0
0
Image
0
0
1
Length
Angle
Rotation Matrix about y
0.999390827
0
-0.034899497
Transpose Rotation Matrix
0.999390827
0
0.034899497
2 degrees
0 0.034899497
1
0
0 0.999390827
Angle
5 degrees
Rotation Matrix about x
1
0
0
0 0.996194698 -0.08715574
0 0.087155743 0.996194698
about y
0 -0.034899497
1
0
0 0.999390827
Transposed Rotation Matrix about x
1
0
0
0 0.996194698 0.087155743
0 -0.08715574 0.996194698
Rotation
Object
Rotated Mirror Matrix 1
Ray
x
0 -0.069756474
0 -0.99756405
y
1
0
1
0
z
0 -0.99756405
0 0.069756474
No Rotation
Image
Lengths
x
y
z
Image
Lengths
Rotated Mirror Matrix 2
Image
0
0 -0.9961947 -0.08715574 -0.99619
1 -0.9961947 0.007596123 -0.08682409 0.007596
0 -0.08715574 -0.08682409 0.992403877 -0.08682
Rotated
Axis of
Rotation
Image
Cross Product
-1 -0.996194698
0
0
0 0.007596123 -0.086824089
-0.9961947
0 -0.086824089 -0.007596123 sin(theta)
Angle, theta -0.08715574
1
1 0.087155743 0.087155743
5
Dot product of
Normal
Image Plane Normal
Vector and
Vector
Image
Ray
0
-0.996194698 -0.086824089
0
0.007596123
1
-0.086824089
Ray
projected
onto Normal Ray on
Vector
Image Plane
0 -0.9961947
0 0.007596123
-0.08682409
0
length
0.996223658
magnification 0.996223658
Ray on Image Cross
Axis of
Plane
Product
Rotation
-1 -0.996194698
0
0 0.007596123
0
0
0 -0.007596123 sin(theta)
Angle, theta
1 0.996223658 0.007596123 0.007624918 0.436879842
Note: All angles in degrees.
-1
0
0
1
0
0
-1
Questions?
Rotation Matrices
via Euler Parameters

Euler Parameters
where the axis of rotation is a unit vector, n̂, and the angle of rotation
about that axis is, .
 e1 




e  e 2   nˆ sin  
2
e 3 
 
e0  cos 
2

Rotation Matrix in Einstein Notation
where δij is the Kronecker delta, and εijk is the permutation symbol.


rij   ij e02  ek ek  2ei e j  2 ijke0ek
Further Resources

How to perform mirror rotations in Zemax


Euler Parameters


http://www.zemax.com/kb/articles/25/1/How-To-Modela-Scanning-Mirror/Page1.html
http://mathworld.wolfram.com/EulerParameters.html
Line onto Plane Projection


http://www.euclideanspace.com/maths/geometry/elements
/plane/lineOnPlane/index.htm
http://www.euclideanspace.com/maths/geometry/elements
/line/projections/index.htm.
Download