NTNUJAVA Virtual Physics Laboratory
Enjoy the fun of physics with simulations!
Backup site http://enjoy.phy.ntnu.edu.tw/ntnujava/

Information about this web site => Question related to Physics or physics related simulation => Topic started by: lookang on June 22, 2009, 01:00:25 pm



Title: how simulate a len changing thickness for convex or concave len?
Post by: lookang on June 22, 2009, 01:00:25 pm
http://www.phy.ntnu.edu.tw/ntnujava/index.php?topic=1155msg4448;topicseen#msg4448

Hi prof,

I examine the physlet applet, it seems to have a good example of a thickness of lens changing with focus length f.

I look through many examples of optics here, but i don't see one that has a changing thickness lens.
i notice the lens usually don't change thickness or drawing


any chance of some tips how to make one realistically?

 


Title: Re: how simulate a len changing thickness for convex or concave len?
Post by: Fu-Kwun Hwang on June 22, 2009, 01:43:54 pm
Quote
I examine the physlet applet, it seems to have a good example of a thickness of lens changing with focus length f.
Could you provide the URL of the examples ?

I think if you use thin lens approximation in the simulation, the thickness of the lens is only visual effect.

If you want to simulate effect due to thick lens, you need to use Snell's Law to calculate all the refractions occurs at the boundary of lens. You are welcomed to check out Thick Lens (http://www.phy.ntnu.edu.tw/ntnujava/index.php?topic=46.0)

If you want to show how the thickness of a lens affect the focus, that is another story!

Many drawing in Physlet optical bench is only an approximation.
Please check out the attached image. It assumed thin mirror and thin lens case.
The space in the simulation is not the same as real world.
The mirror and lens will be almost like a thin/short line if you want to draw it according to real dimension.


Title: Re: how simulate a len changing thickness for convex or concave len?
Post by: lookang on June 22, 2009, 02:03:17 pm
Could you provide the URL of the examples ?
http://www.phy.ntnu.edu.tw/ntnujava/index.php?topic=1140.0


I think if you use thin lens approximation in the simulation, the thickness of the lens is only visual effect.

If you want to simulate effect due to thick lens, you need to use Snell's Law to calculate all the refractions occurs at the boundary of lens. You are welcomed to check out Thick Lens (http://www.phy.ntnu.edu.tw/ntnujava/index.php?topic=46.0)

If you want to show how the thickness of a lens affect the focus, that is another story!

Many drawing in Physlet optical bench is only an approximation.
Please check out the attached image. It assumed thin mirror and thin lens case.
The space in the simulation is not the same as real world.
The mirror and lens will be almost like a thin/short line if you want to draw it according to real dimension.

Yes! i only want a visual effect, like physlet ones.

I google and found your thick lens http://www.compadre.org/OSP/document/ServeFile.cfm?ID=8257&DocID=886
but the function to draw the polygon that represents the lens is complicated. I doubt i can copy it over to make it work.



Title: Re: how simulate a len changing thickness for convex or concave len?
Post by: Fu-Kwun Hwang on June 22, 2009, 02:45:34 pm
If you just need visual effect, you can change the width of shape (the GUI used to draw lens) and let it change with f.

EJS version of thick lens can be found at Lens (thick lens) and Mirror (http://www.phy.ntnu.edu.tw/ntnujava/index.php?topic=121.0). The snell's law were used to calculate all the refraction to simulate a real thick lens.


Title: Re: how simulate a len changing thickness for convex or concave len?
Post by: lookang on June 22, 2009, 09:12:09 pm
If you just need visual effect, you can change the width of shape (the GUI used to draw lens) and let it change with f.

i understand your suggestion,

any tips how i get get a suitable equation?

size X = size*2*(2- Math.sin(f)) doesn't look good
          = size*2*(1/f) is the correct relationship but it doesn't look nice.

i am stuck thinking of a eqn ;D


Title: Re: how simulate a len changing thickness for convex or concave len?
Post by: lookang on June 22, 2009, 09:39:46 pm
i used a simplified method

fixed relations
if ( f > 1 ) {
  fdraw = 1;
}
else {
  fdraw = f;
  }


Lens X size
= size*2*1/(fdraw+1)

looks better now ;D