Fu-Kwun Hwang
|
 |
«
Embed this message
on: October 01, 2007, 11:53:48 pm » |
|
 You can drag either charge and find out the new electric distribution. -*- The field line are calculated in real time. However, please remember field line is not the same as trajectory for a test charge move in the same field. You can add test charge if the check box were checked and watch the trajectory of test charge. It is easy to draw those vectors which represent electric field at different positions. Because we can calculate the electric field with  . However, do you know how those field lines were calculated? Hint: The tangential components of electric field line is the same as the firection of electric field at the same point. Embed a running copy of this simulation Embed a running copy link(show simulation in a popuped window) Full screen applet or Problem viewing java?Add http://www.phy.ntnu.edu.tw/ to exception site listPress the Alt key and the left mouse button to drag the applet off the browser and onto the desktop. This work is licensed under a Creative Commons Attribution 2.5 Taiwan License
- Please feel free to post your ideas about how to use the simulation for better teaching and learning.
- Post questions to be asked to help students to think, to explore.
- Upload worksheets as attached files to share with more users.
Let's work together. We can help more users understand physics conceptually and enjoy the fun of learning physics!
 
|
|
|
Logged
|
|
|
|
lookang
|
 |
«
Embed this message
Reply #1 on: November 11, 2008, 03:26:02 pm » posted from:SINGAPORE,SINGAPORE,SINGAPORE |
|
|
|
|
Logged
|
|
|
|
KezzaH
Newbie
Offline
Posts: 1
|
 |
«
Embed this message
Reply #2 on: June 02, 2009, 12:35:15 am » posted from:Sydney,New South Wales,Australia |
|
 It would be a great improvement if you could vary the charge on the particles in size and from positive to negative Kind Regards Kerry H
|
|
|
Logged
|
|
|
|
|
Fu-Kwun Hwang
|
 |
«
Embed this message
Reply #4 on: June 02, 2009, 10:28:45 am » posted from:Taipei,T'ai-pei,Taiwan |
|
 It would be a great improvement if you could vary the charge on the particles in size and from positive to negative Kind Regards Kerry H
The applets has been updated with the options you want. I also added option for equal-potential contours. Thank you for your suggestion.
|
|
|
Logged
|
|
|
|
lookang
|
 |
«
Embed this message
Reply #5 on: June 02, 2009, 05:27:47 pm » posted from:Singapore,,Singapore |
|
 Can make it almost like the physlets charge applet? I wish to study how to do it. I don't think i can figure out this one, simply too advance for me to redo in Ejs.  May i request more comments line to help others like me understand and learn how to model it in Ejs. Thanks!
|
|
|
Logged
|
|
|
|
Fu-Kwun Hwang
|
 |
«
Embed this message
Reply #6 on: June 02, 2009, 07:37:27 pm » posted from:Taipei,T\'ai-pei,Taiwan |
|
 Can make it almost like the physlets charge applet? What other features you want to add to the above applet? I just added more comments to the code.
|
|
|
Logged
|
|
|
|
lookang
|
 |
«
Embed this message
Reply #7 on: September 30, 2010, 09:41:49 pm » |
|
 awesome! the applet has been updated with physlet style function. will look at it asap. 
|
|
|
Logged
|
|
|
|
lookang
|
 |
«
Embed this message
Reply #8 on: October 05, 2010, 10:54:39 am » posted from:SINGAPORE,SINGAPORE,SINGAPORE |
|
 i been looking at the codes i have a question i notice the test mass uses evolution to move dvxc/dt = -getF(-1,xc,yc,0)/m dvyc/dt= -getF(-1,xc,yc,1)/m where getF double dx1,dy1,dx2,dy2,r12,r22,dx,dy,d,sign=-1; public double getF (int i, double xi,double yi, int mode) {//return electric field if(count>=n)return 0; // count >=n , do ntg dx1=xi-x1; dy1=yi-y1; dx2=xi-x2; dy2=yi-y2; r12=dx1*dx1+dy1*dy1; r22=dx2*dx2+dy2*dy2; if(i>-1){ if(add || out )return 0.; // if( (x>xmax && (y-ymax)*(y-ymin)>0) || (x<xmin && (y-ymax)*(y-ymin)>0) || //(y>ymax && (x-xmax)*(x-xmin)>0) || (y<ymin && (x-xmax)*(x-xmin)>0) || if(xi>scale*xmax || yi>scale*ymax || xi<scale*xmin || yi<scale*ymin || r12<size22 || r22<size22) { out=true;// if electric field line move outside the drawing region too far=> do not need to following the field line any more count++; return 0.; } } if(i<np)sign=q1/Math.abs(q1); // question sign mean sign of q1 ? else sign=q2/Math.abs(q2); // // question sign mean sign of q2 ? dx=q1*dx1/(r12*Math.sqrt(r12))+q2*dx2/(r22*Math.sqrt(r22)); dy=q1*dy1/(r12*Math.sqrt(r12))+q2*dy2/(r22*Math.sqrt(r22)); d=Math.sqrt(dx*dx+dy*dy); if(mode==0)return sign*dx/d; // question what does mode do? else return sign*dy/d; }
My thoughts: i tested the codes in the applet, i change the Q1 = + or - Q2 = 0 and the test particles goes in the out of the view direction regardless of the signs of Q1. it is a bug or i need to modify the codes more to reflect the sign of Q1 and Q2?
|
*** There are 1 more attached files. You need to login to acces it!
|
|
Logged
|
|
|
|
lookang
|
 |
«
Embed this message
Reply #9 on: October 06, 2010, 09:14:14 am » posted from:SINGAPORE,SINGAPORE,SINGAPORE |
|
 i suspect the original codes for the motion of the test mass is incorrectly modeled. assumption: test charge by default is positive, condition: When both q1 and q2 are negative, result: the path of the test charge defy the electric field vectors direction. request: chance to update the codes to reflect the physics of force correctly on the motion of the test charge? can you made it on a separate page say {Force} so that i can track the changes made. i been editing on the current version of your applet  My thoughts: i been trying to categorize the codes into {Field Lines} {Field Vectors} {Potential} for ease of open source sharing of codes! thanks! in case you are wondering, my source code is attached
|
*** There are 1 more attached files. You need to login to acces it!
|
« Last Edit: October 06, 2010, 09:22:29 am by lookang »
|
Logged
|
|
|
|
Fu-Kwun Hwang
|
 |
«
Embed this message
Reply #10 on: October 06, 2010, 04:48:47 pm » posted from:,,Taiwan |
|
 Thank you for the bug report. I modified the code and it is updated.
|
|
|
Logged
|
|
|
|
lookang
|
 |
«
Embed this message
Reply #11 on: October 07, 2010, 05:13:44 pm » posted from:SINGAPORE,SINGAPORE,SINGAPORE |
|
 fantastic! thanks for update. Can i request for another feature in your applet? arrows at the mid of charges to edge of applet to be position at midpoint and the direction of arrow is at direction of field lines at the mid point? the pedagogy reason is field lines are normally drawn with some indication of the direction. chance to help
|
|
|
Logged
|
|
|
|
Fu-Kwun Hwang
|
 |
«
Embed this message
Reply #12 on: October 07, 2010, 09:36:27 pm » posted from:,,Taiwan |
|
 Right now the arrows are draw as 20x20 matrix. Do you mean you want it to be draw as 21x21 matrix (Then the middle one is the the center of the drawingPanel)?
|
|
|
Logged
|
|
|
|
lookang
|
 |
«
Embed this message
Reply #13 on: October 08, 2010, 11:04:25 pm » posted from:Singapore,,Singapore |
|
 the picture says it all. i can't make sense of the variables controlling the field lines so cannot do it myself  when i can make sense of the codes, by observing the changes you made, i will learn more  thanks!
|
|
« Last Edit: October 08, 2010, 11:06:38 pm by lookang »
|
Logged
|
|
|
|
Fu-Kwun Hwang
|
 |
«
Embed this message
Reply #14 on: October 08, 2010, 11:22:14 pm » posted from:,,Taiwan |
|
 I think I know what you want now. It has been updated!
|
|
|
Logged
|
|
|
|
lookang
|
 |
«
Embed this message
Reply #15 on: October 09, 2010, 04:24:27 pm » posted from:Singapore,,Singapore |
|
 i tried to download and see it . it didn't look updated. did you check it? see my picture
|
|
|
|
Fu-Kwun Hwang
|
 |
«
Embed this message
Reply #16 on: October 09, 2010, 06:23:31 pm » posted from:,,Taiwan |
|
 I thought you were talking about the vector field. I changed it so that it re-present direction for the point at the center of of arrow (instead of the starting point). Now. I finally understand you want to add arrow for field lines. It is updated!
|
|
|
Logged
|
|
|
|
lookang
|
 |
«
Embed this message
Reply #17 on: October 09, 2010, 07:27:43 pm » posted from:Singapore,,Singapore |
|
 the file invalid or corrupt ? Download EJS jar file(376kB): the file size is too small and the web do not deploy 
|
|
|
Logged
|
|
|
|
Fu-Kwun Hwang
|
 |
«
Embed this message
Reply #18 on: October 09, 2010, 09:20:59 pm » posted from:,,Taiwan |
|
 Sorry! It is uploaded again.
|
|
|
Logged
|
|
|
|
lookang
|
 |
«
Embed this message
Reply #19 on: October 09, 2010, 10:09:00 pm » posted from:Singapore,,Singapore |
|
 that is what i wanted! the codes looks like different and amazingly difficult. fx and fy will study it soonest! thanks!
|
|
|
Logged
|
|
|
|
Fu-Kwun Hwang
|
 |
«
Embed this message
Reply #20 on: October 09, 2010, 10:37:18 pm » posted from:,,Taiwan |
|
 Because you asl for arrow for each field line, so fx,fy arrays are coordinnate where the arrow are drawn. fdx,fdy are vector for the arrow. Code are added to find fx,fy, fdx and fdy.
|
|
|
Logged
|
|
|
|
|