NTNUJAVA Virtual Physics Laboratory
Enjoy 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: engrg1 on September 09, 2012, 10:54:59 am



Title: Falling Magnetic Field Line
Post by: engrg1 on September 09, 2012, 10:54:59 am
Have done a simple magnet falling (under free fall) and how the magnetic field lines move along with it.

In order to change the number of field lines, please edit the variable NField in the variables page.


Thank to Wolfgang Christian Magnetic Dipole Field 3D Model at http://www.opensourcephysics.org/document/ServeFile.cfm?ID=12361&DocID=3083
I have modified the magnetic field line codes so that the magnetic field lines are drawn at the start and it is not drawn dynamically.


Please press the reset button if you can't see the magnetic field lines.


Title: Re: Falling Magnetic Field Line
Post by: lookang on September 10, 2012, 07:53:35 am
awesome!

area of improvement
can the lines are permanently drawn? i noticed the lines blink as it is redrawn every step.


Title: Re: Falling Magnetic Field Line
Post by: engrg1 on September 10, 2012, 08:27:31 pm
I am using Trail3D to plot the points.
Need to change the array to plot the moving magnetic field.

Seems can't really draw the lines peramanently


Title: Re: Falling Magnetic Field Line
Post by: lookang on September 10, 2012, 08:42:57 pm
I saw the source code and you are using one trail to draw all the lines on one side.

http://www.phy.ntnu.edu.tw/ntnujava/index.php?topic=2564.0
Has An array to draw each lines seems pretty permanent to me.

Even more permanent is the analytical lines but loses some accuracy in the line plots.

Each method can some problem.
Array hangs the simulation sometimes especially when drag the view.
Analytical is not accurate but seems like the best thing moving forward, for the time being.