dear Prof,

i am wondering, can make a scalarField that is for doppler effect?

i am thinking with a template of your codes, i can try to make
http://www.falstad.com/ripple/ [img]http://www.phy.ntnu.edu.tw/ntnujava/index.php?action=dlattach;topic=873.0;attach=4439;image[/img]

with many options


currently, my attempt is not working

a summary of the codes is


for (i=0; i < number; i++)
{
xscalar = xmin+(xmax-xmin)*i/number;
for (j=0; j < number; j++)
{
 yscalar = ymin+(ymax-ymin)*j/number;
 d[ i ][ j ]=Math.sqrt((xscalar-x)*(xscalar-x)+(yscalar-y)*(yscalar-y));
//sum [ i ][ j ]= A1*Math.cos(omega*t-k*d[ i ][ j ]);
//sum[ i ][ j ]= A1*Math.cos(omega/4*t);
sum[ i ][ j ]= A1*Math.cos(-k*d [ i ][ j ]);
}
}


Thanks!  :D

/htdocs/ntnujava/ejsuser/14019/users/sgeducation/lookang/dopplerxywee01_pkg/dopplerxywee01.propertiesFull 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
Download EJS jar file(1060.3kB):double click downloaded file to run it. (14 times by 12 users) , Download EJS source (4 times by 4 users) View EJS source