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

## Easy Java Simulations (2001- ) => Collaborative Community of EJS => Topic started by: lookang on July 02, 2013, 09:32:35 pm

 Title: Young Double and Multi Slits Java Applet Ejs Open Source Physics Computer Model Post by: lookang on July 02, 2013, 09:32:35 pm Young Double and Multi Slits Java Applet Ejs Open Source Physics Computer Model by Fu-Kwun Hwang, Robert Mohr and Wolfgang Christian and now this remixed version lookang.i got ideas and codes from several sourceshttp://weelookang.blogspot.sg/2013/07/young-double-and-multi-slits-java.htmlhttp://weelookang.blogspot.sg/2013/06/ejs-open-source-young-double-slit-java.htmlandrew duffy work found here http://www.compadre.org/osp/document/ServeFile.cfm?ID=9988&DocID=1622&Attachment=1 took some ideas from tat leong point P, https://dl.dropboxusercontent.com/u/44365627/lookangEJSworkspace/export/ejs_wave_double_slit_LTL.jar Jose Ignacio Fernández Palop vcolor code from http://www.compadre.org/osp/items/detail.cfm?ID=10529enjoy![ejsapplet]Multiple Slit Diffraction The EJS Multiple Slit Diffraction model allows the user to simulate Fraunhofer diffraction through single or multiple slits. The user can modify the number of slits, the slit width, the slit separation and the wavelength of the incident light. The scale of the diffraction pattern can also be changed and a plot of the light intensity can be toggled on and off with a checkbox. The minima of single slit diffraction are determined by: D sin Ө = m λ ,  where m = 1,2,3,......where D is the single slit width.For double slit interference, constructive interference (bright spots) are found at: d sin Ө = m λ ,  where m = 1,2,3,......and destructive interference dark spots are located at: d sin Ө = (m+0.5) λ ,  where m = 1,2,3,......where d is the distance between slits. Multiple slits will sharpen (narrow) the regions of constructive interference. The overall pattern from multiple slits will be the two-slit pattern multiplied by the single slit diffraction envelope. References: Douglas Giancoli, Physics: Principles with Applications sixth edition, pages 664-675. Eugene Hecht, Optics fourth edition, pages 460-464. Credits: The Multiple Slit Diffraction model was created by Fu-Kwun Hwang using the Easy Java Simulations (EJS) modeling tool. It was adapted to EJS version 4.1 by Robert Mohr and Wolfgang Christian at Davidson College. You can examine and modify the model for this simulation if you have EJS installed by right-clicking within the diffraction frame and selecting "Open Ejs Model" from the pop-up menu. Information about EJS is available at: and in the OSP ComPADRE collection . this remixed model is by lookang based on the earlier EJS models by Fu-Kwun Hwang, Robert Mohr and Wolfgang Christian  and Andrew Duffy.Enjoy! Title: Re: Young Double and Multi Slits Java Applet Ejs Open Source Physics Computer Model Post by: lookang on July 02, 2013, 09:34:00 pm changes made:changes made:turn the screen to the right by doing a switch of the i and j arraysmade intensity graph and envelope work in the right panelscale the y to fix the 1 m instead of the older 200added a scale factor to make the display coincident with the other applet made by andrew duffy http://weelookang.blogspot.sg/2013/06/ejs-open-source-young-double-slit-java.htmladded source as triangle of laseradded λ slider with color indicated by adding colorlookang codesset default as double slit N = 2, the open input field technically allows for multiple slits up to 20 as previously designed by Fu-Kwun Hwangmade a, d, L and ymade intensity and different from the envelope redesign the layout to suit left to right with right panel showing the screenlaser redrawnadded backgroundslits added text of views addedadded point yp with reference made to tat leong yp http://www.phy.ntnu.edu.tw/ntnujava/index.php?topic=2778.0made the codes work under the new design space of x = -0.5,1 and y = -1 and 1