NTNUJAVA Virtual Physics Laboratory
Enjoy the fun of physics with simulations!
March 02, 2015, 06:17:37 am *
Welcome, Guest. Please login or register.
Did you miss your activation email?

Login with username, password and session length
   Home   Help Search Login Register  
Ask questions. Follow-up questions. ...Wisdom
Google Bookmarks Yahoo My Web MSN Live Netscape Del.icio.us FURL Stumble Upon Delirious Ask FaceBook

Pages: [1]   Go Down
Author Topic: how to simulate flow of particles in a wire?  (Read 5012 times)
0 Members and 1 Guest are viewing this topic. Click to toggle author information(expand message area).
Hero Member
Offline Offline

Posts: 1740


Embed this message
on: November 13, 2009, 05:04:23 pm » posted from:Singapore,,Singapore

how to simulate flow of particles in a wire?

i analyze the method used here

say for the loop wire
if(x2[j] else if(x2[j]>a-D*i)x2[j]-=D;

is used to trick the human eyes by telling when to disappear n appear a distance + or -D away.

i actually ran into some bug.
the codes works when the variables "lengthx" is 1.5 which is the same as your "D". perfect synchronization, the particles disappear n appear together of the visual effect of particle flow is achieved.

but when i create a slider, and move it,
the particles, dynamically re position but the spacing is funny, not equal.

the resultant new effect is not realistic enough to "trick" to human eye.

any tips for me to explore? my source is attached Smiley

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 list
Press 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!

*** There are 1 more attached files. You need to login to acces it!
« Last Edit: November 13, 2009, 05:09:31 pm by lookang » Logged
Hero Member
Offline Offline

Posts: 1740


Embed this message
Reply #1 on: November 13, 2009, 05:22:25 pm » posted from:Singapore,,Singapore

not to worry!
i fixed it! Grin

i changed the initialization page to
for(int i=0;i y1[i]=-lengthz/2+lengthz/n*i; // AD
 y3[i]=lengthz/2-lengthz/n*i; // BC
 x2[i]=a-lengthx/n*i; //AB
 x4[i]=a-lengthx/n*i; // DC

which then when the slider is moved
setparam ();

no problem now!!! cool!

really learnt a lot of (problem solving skills & critical thinking) from analyzing, making sense, remixing the virtual lab to suit my design ideas of how to finer customized the virtual lab.
fantastic pedagogy for learning problem solving skills & critical thinking Grin

my physics knowledge comes alive in the java applet. cool way to assess my learning by portfolio like what prof wolfgang is doing i think.
« Last Edit: November 13, 2009, 05:29:40 pm by lookang » Logged
Fu-Kwun Hwang
Hero Member
Offline Offline

Posts: 3060

Embed this message
Reply #2 on: November 13, 2009, 08:10:35 pm » posted from:Taipei,T\'ai-pei,Taiwan

Great! You are making it better and better.  Cheesy
Pages: [1]   Go Up
Ask questions. Follow-up questions. ...Wisdom
Jump to:  

Related Topics
Subject Started by Replies Views Last post
Simulate 1D collision with a virtual spring
Fu-Kwun Hwang 1 26191 Last post April 21, 2014, 02:39:57 pm
by lookang
Can we increase traffic flow rate by increasing maximum speed limit?
Fu-Kwun Hwang 4 16654 Last post May 15, 2013, 10:32:28 am
by Fu-Kwun Hwang
how simulate a len changing thickness for convex or concave len?
Question related to Physics or physics related simulation
lookang 5 7803 Last post June 22, 2009, 09:39:46 pm
by lookang
Simulate 1D collision with a virtual spring
ahmedelshfie 0 2433 Last post June 01, 2010, 12:08:13 am
by ahmedelshfie
need simulate program for fresnel biprism diffraction
Request for physics Simulations
milad 20 15614 Last post April 26, 2012, 11:21:43 am
by chrispaul3
Powered by MySQL Powered by PHP Powered by SMF 1.1.13 | SMF © 2006-2011, Simple Machines LLC Valid XHTML 1.0! Valid CSS!
Page created in 0.049 seconds with 22 queries.since 2011/06/15