how to make lenses in matlab?
이전 댓글 표시
Dear sir/madam,
I am working on optical lenses. I need to create lenses such as biconvex, biconcave, planoconvex and planoconcave for my project. How could I do this in matlab? Looking forward to hearing from you soon.
Thanking you, BSD
댓글 수: 1
PRAKASH JOSHI
2019년 3월 28일
How do I find the off focus points after the fft
답변 (1개)
Bjorn Gustavsson
2011년 8월 30일
0 개 추천
There is at least one tool for calculating ray-paths through optical systems on the file exchange: http://www.mathworks.co.uk/matlabcentral/fileexchange/27412-opticalbench
HTH
댓글 수: 12
bsd
2011년 8월 31일
Bjorn Gustavsson
2011년 8월 31일
If you look, there is 10 files with "example" in their names. Those surely should be examples of how to use the functions for this or that purpose.
bsd
2011년 9월 1일
Bjorn Gustavsson
2011년 9월 1일
Take a look in the opt_exempel*.m files. The .exmpl files are setup-files describing optical elements, with curvature of lens surfaces, glass type, lens position, diameter and other parameters.
bsd
2011년 9월 2일
Bjorn Gustavsson
2011년 9월 3일
The ray tracing is simply Snell's law, calculating the angle to the surface normal at the ray-entrance/exit, refraction for the glass-type at the wavelength of the ray. The plotting is just simple geometry.
bsd
2011년 9월 6일
Iain Robinson
2011년 9월 6일
The transmitted ray will leave surface 1 and travel to surface 2 along a straight line. You know the angle of this line (to the optical axis) from applying Snell's Law at surface 1. You also know the coordinates of one of the points on the line: the point where it was refracted at surface 1. This is enough information to calculate the equation of the straight line (using the angle to determine the gradient).
The spherical surface of the lens, surface 2, is described by the equation of a circle. You'll need to look up or calculate the radius of curvature.
By solving the equations of the ray (straight line) and the lens surface (circle) you can get the coordinates of the point of intersection between the ray and the surface. There will be two solutions, one for concave surfaces, one for convex.
After picking the right solution draw a line connecting the coordinates of transmitted ray leaving surface 1 to the coordinates of the point where the ray is incident on surface 2.
HTH.
bsd
2011년 9월 6일
Iain Robinson
2011년 9월 6일
If the lens is plano-convex and surface 1 is flat then the normal will be parellel to the optical axis. This is a special case, but it makes things slightly simpler.
If surface 1 is not flat then you need to convert the angle of refraction relative to the surface normal to an angle relative to the optical axis. The geometry required is given in, among other places, Nussbaum's "Contemporary Optics for Scientists and Engineers".
By the way, if the refraction angles are "small" then using the paraxial approximation could simplify the problem.
bsd
2011년 9월 13일
bsd
2011년 9월 23일
카테고리
도움말 센터 및 File Exchange에서 Optics에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!