NTNUJAVA Virtual Physics Laboratory
Physics Simulations to help you enjoy the fun of physics!
February 10, 2010, 06:00:51 AM *
Welcome, Guest. Please login or register.
Did you miss your activation email?

Login with username, password and session length
News: This site host hundreds of physics related java simulations under create common license. All registered user will be able to get files for offline use when user login and view the simulation. Switch to this new system on 2007/02/14. (previous system2001-2007, 1996-2001) ,Check out Chinese forum to find more simulations and resources in Chinese.
 
   Home   Help Search Login Register  
"There is nothing either good or bad, but thinking makes it so." ..."Shakespeare (154-1616, English dramatist and poet) "
Google Bookmarks Yahoo My Web MSN Live Netscape Del.icio.us FURL Stumble Upon Delirious Ask FaceBook

Pages: [1]   Go Down
  Print  
Author Topic: Vector Addition  (Read 164890 times)
0 Members and 7 Guests are viewing this topic. Click to toggle author information(expand message area).
Fu-Kwun Hwang
Administrator
Hero Member
*****
Offline Offline

Posts: 1966


WWW
« on: January 29, 2004, 11:16:34 PM »

Registed user can get files related to this applet for offline access.
If java program did not show up, please download and install latest Java RUN TIME
There are 3 translations,
Higher number at the end means more translation been done.
or




You are welcomed to check out EJS version of Vector addition (sum of two vectors),too!
This java applets try to show : How to add two vector A and Binto vector C
    C = A + B = B + A
How to play:
  1. There are two methods to form a vector
  2. 1. Vector A/B originate from center of the window
      
      Left click anywhere inside the window to form vector A or B
    2. Vector A/B originate from where you first click the button
      
      Drag and lift the left mouse button to form vector A or B Vector will move to center of the window.

  
  • The program will show you how to add two vector A and B into C

  •   
      
    C = A + BorC = B+ A
    C = A - BorC= -B + A
    A - B can be transformed to A + (-B)
  • press reset button or right click the mouse button to reset.
    1. Parameters are reset to default values.
  • select info checkbox to show more information.
    1. X,Y components of each vector ...
    How to process more than two vectors :
      
    SUM = A + B + C + D
    = (A + B) + (C+D)
    = E+ F
    E = A + B and F= C + D
    Could you figure out how to process SUM = A + B + C ?
    3-D version


    The following is a flash demo for the above java applet.


    How to form a 3_D vector
      Move the mouse with the window will establish a vector at X-Y plane. Left click the mouse, then drags it up/down to change the Z components. Then release the mouse button

     When you form two vector A and B
      Another vector C = A + B will show up.
    Drag the right mouse button to change the viewing angle. Drag near the origin to change the its position.(displacement)


    Registed user can get files related to this applet for offline access.
    If java program did not show up, please download and install latest Java RUN TIME
    There are 3 translations,
    Higher number at the end means more translation been done.
    or

    * vector2D.java (10.39 KB - downloaded 32 times.)
    * vector3D.java (13.1 KB - downloaded 26 times.)
    * Matrix3D.java (6.83 KB - downloaded 24 times.)
    Logged
    Guest
    « Reply #1 on: January 30, 2004, 11:18:43 AM »

    Subject: thanks!
    Date: Wed, 21 Oct 1998 21:21:49 -0400
    From: dgoodwin <dgoodwin@1st.net>
    To: hwang@phy03.phy.ntnu.edu.tw
    We were reviewing vector addition this evening at a study session.
    Someone asked about help from the internet, so we searched and happened
    to find your page. There were a few "ah-ha's" when the program showed
    the parallelogram method for adding vectors so clearly. Thanks.
    Logged
    Guest
    « Reply #2 on: January 30, 2004, 11:28:18 AM »

    Subject:
    Date: Tue, 2 Feb 1999 22:39:22 -0200
    From: "Marcilio Carneiro" <marcilio_roberto@uol.com.br>
    To: <hwang@phy03.phy.ntnu.edu.tw>
    Hi Mr Hwang:
     
      I?m from Brazil I worked as Physics about 10 years ago and since
    that time I had a desire : to make softwares for Physics teaching.
    The DOS interfaces I used to have forced me to give up. Last year
    (after spendig some time learning Windows based programming) I
     restarted the project but once again I didn?t like the results. I
    used Delphi 3.0 (Pascal Object Language) and made about 100 programs
    ( mechanics and eletricity) but when I saw your programs I felt even
    more disappointed with the ones i had done . Yours are brilliant ,
    fantastic . Don?t you sell them ? I?m interested in many of them.
    One : sugestion: Don?t use weak green colors I hardly can see them .
    For instance the one you used in Vactor addition,
    Thank you and congratulations for your excellent work (I wish I was
    talented as you are)
    Marcilio Carneiro
    Logged
    Fu-Kwun Hwang
    Administrator
    Hero Member
    *****
    Offline Offline

    Posts: 1966


    WWW
    « Reply #3 on: March 31, 2005, 04:52:05 PM »

    Registed user can get files related to this applet for offline access.
    If java program did not show up, please download and install latest Java RUN TIME


    You can change the number of vectors (drag the bar up and down),
      drag each vector (starting position, length, or direction)
    Click play to add those vectors automatically.
    Click "showsum" to view vector for the sum of those vectors.


    Registed user can get files related to this applet for offline access.
    If java program did not show up, please download and install latest Java RUN TIME
    Logged
    Ahmad
    Newbie
    *
    Offline Offline

    Posts: 1

    « Reply #4 on: October 23, 2005, 12:36:07 AM »

    Hi can i have the source code of the first applet
    [/b]
    Logged
    repsol_23
    Newbie
    *
    Offline Offline

    Posts: 2

    « Reply #5 on: November 13, 2005, 01:31:25 PM »

    I am a graduate student at New Mexico State University working on my PhD in Physics Education. I just came across your site and wanted to just make a comment. I found this site GREAT and I am sure there is a number of applets that you have created that I would like to make use of. I hope that this will be okay with you since you are the author of the applets. I have tried to make my own but have had some trouble getting them to function properly.

    Thanks
    Logged
    Fu-Kwun Hwang
    Administrator
    Hero Member
    *****
    Offline Offline

    Posts: 1966


    WWW
    « Reply #6 on: November 14, 2005, 09:49:41 AM »

    You are welcomed to use our java applets for non-profit educational purpose.
    You will be able to get files related to any java applets at our web site
    if you are a registered user at http://www.phy.ntnu.edu.tw/ntnujava/
    Just look for a button(with label: GET APPLET FILES) at the end of the first java applet message
    (You need to login to the forum).
    If you click the button, files related to that applet will be sent to your email account automatically.

    Fu-Kwun Hwang
    Logged
    repsol_23
    Newbie
    *
    Offline Offline

    Posts: 2

    « Reply #7 on: November 16, 2005, 08:05:48 AM »

    I finally was able to get the codes sent to my email, the problem was in the security that our university uses. But now, I am having some other issues. I unzipped the files to my computer and when I open them they look all garbled. The graphs and animations work perfectly fine, but the letters look like a bunch of gibberish. Is this something to do with the files or am I doing something incorrectly? I was hoping to just extract the vectors animation and write them into a practice quiz that I am working on but am unsure of what the code is due to the weird lettering?
    Logged
    Fu-Kwun Hwang
    Administrator
    Hero Member
    *****
    Offline Offline

    Posts: 1966


    WWW
    « Reply #8 on: November 16, 2005, 08:48:00 AM »

    There are several html files for different language version.
    Vector.html is the english version.

    If it is still not working, may be it is due to two lines I forgot to remove in the html file
    Please remove the following two lines:

      <meta http-equiv="Content-Type" content="text/html; charset=big5">
      <meta name="GENERATOR" content="Mozilla/4.7 [en] (Win98; I) [Netscape]">

    And it should work fine.

    I have change the ZIP files so there should be no problem if you ask the ZIP file again.
    Logged
    Sivasayanth
    Newbie
    *
    Offline Offline

    Posts: 3

    « Reply #9 on: July 14, 2007, 11:10:12 AM »

    dear Fu-Kwun Hwang

    i like your simulation
    Logged

    v.sivasayanth
    kinematix_playa
    Newbie
    *
    Offline Offline

    Posts: 1

    « Reply #10 on: October 31, 2007, 06:47:16 AM »

    This simulation completes me.

    *moist*
    Logged
    Physicsmaster
    Newbie
    *
    Offline Offline

    Posts: 2

    « Reply #11 on: October 31, 2007, 07:54:40 AM »

    Fu-Kwun Hwang, you are an inspiration to us all.
    Logged
    Physicsmaster
    Newbie
    *
    Offline Offline

    Posts: 2

    « Reply #12 on: October 31, 2007, 07:27:00 PM »

    I am a school teacher and have modeled this simulation with my students and they have learned lot from this.
    Logged
    Fu-Kwun Hwang
    Administrator
    Hero Member
    *****
    Offline Offline

    Posts: 1966


    WWW
    « Reply #13 on: November 01, 2007, 12:13:25 AM »

    I am glad to hear that it is useful.  Grin
    Logged
    lookang
    Hero Member
    *****
    Offline Offline

    Posts: 829

    http://sgeducation.co.nr


    WWW
    « Reply #14 on: April 15, 2008, 04:41:04 PM » posted from:Singapore,,Singapore

    change log.

    change the color for show component for better color association.

    change position of letters to the vector

    added tooltips for the buttons

    added autoscale for bigger view pleasure

    i will make some change , and post it back !
    Logged
    lookang
    Hero Member
    *****
    Offline Offline

    Posts: 829

    http://sgeducation.co.nr


    WWW
    « Reply #15 on: May 05, 2008, 04:34:17 PM » posted from:Singapore,,Singapore

    i have some work in progress.

    so difficult to make a powerful applet. need a lot of time
    Logged
    lookang
    Hero Member
    *****
    Offline Offline

    Posts: 829

    http://sgeducation.co.nr


    WWW
    « Reply #16 on: May 05, 2008, 05:18:13 PM » posted from:Singapore,,Singapore

    improving and adapting your applet to fit my teaching needs.
    Logged
    zeyad80
    Newbie
    *
    Offline Offline

    Posts: 1

    « Reply #17 on: May 31, 2008, 04:48:35 AM »

    I want to say thank you Mr Hwang

    God bless you
    Logged
    mavito
    Newbie
    *
    Offline Offline

    Posts: 3

    « Reply #18 on: July 05, 2008, 06:01:43 AM »

    Hello, professor.

    I really loved your java applets, especially the one's about mathematics (I'm student of mathematics).
    If you can, please send me java code for vector application on nidzge@gmail.com I would really be grateful.

    I have three other applets that I really like:
    1. sine and cosine (http://www.phy.ntnu.edu.tw/ntnujava/index.php?topic=634.0),
    2. quadratic function (http://www.phy.ntnu.edu.tw/ntnujava/index.php?topic=526.0)
    3. cross product (http://www.phy.ntnu.edu.tw/ntnujava/index.php?topic=406.0).

    So I would need java codes for that examples as well, if I'm not asking too much.

    Thanks in advance.
    Logged
    Fu-Kwun Hwang
    Administrator
    Hero Member
    *****
    Offline Offline

    Posts: 1966


    WWW
    « Reply #19 on: July 05, 2008, 09:23:20 AM » posted from:Taipei,T'ai-pei,Taiwan

    Source code for vector addition has been sent to your email address.
    Another 3 applets were created with EJS . The EJS source code are all available when you view those web page (just below the simulation if you login to this forum). If you want to check the java code , you can run EJS and open ejs source code, Click RUN to compile it  and you will find generated java code. EJS have many pre-build library for scientific simulation. I do not need to write code line by line. I just need to define variables, provide equation / differential equations and create graphic user interface with mouse drag an drop (then set up properties --related to variables) and EJS will generate java code and compile it. If you are interested in EJS please check out related forum at this web site  or visit EJS official web site.
    Logged
    mavito
    Newbie
    *
    Offline Offline

    Posts: 3

    « Reply #20 on: July 05, 2008, 04:30:05 PM »

    Thank you sir. You have been most helpful.
    Logged
    mavito
    Newbie
    *
    Offline Offline

    Posts: 3

    « Reply #21 on: July 08, 2008, 01:53:18 AM »

    I was trying to upgrade this applet so it can do scalar product of vectors, but I haven't had any luck nor knowledge. Is there anyone who figured this out how to do it? Professor Hwang, any ideas?
    Logged
    Fu-Kwun Hwang
    Administrator
    Hero Member
    *****
    Offline Offline

    Posts: 1966


    WWW
    « Reply #22 on: July 08, 2008, 08:01:05 AM »

    Registed user can get files related to this applet for offline access.
    If java program did not show up, please download and install latest Java RUN TIME

    I just created another applet to show the scalar product between two vector A, B.

    You can drag those vectors to change location and length (orientation).



    Registed user can get files related to this applet for offline access.
    If java program did not show up, please download and install latest Java RUN TIME
    Logged
    featherfriends4evr
    Newbie
    *
    Offline Offline

    Posts: 1

    « Reply #23 on: October 03, 2008, 10:42:00 PM »

     Huh Roll Eyes Smiley Wink Grin Angry Kiss howdy y'all
    Logged
    Fu-Kwun Hwang
    Administrator
    Hero Member
    *****
    Offline Offline

    Posts: 1966


    WWW
    « Reply #24 on: January 05, 2009, 04:28:24 PM » posted from:Taipei,T\'ai-pei,Taiwan

    Registed user can get files related to this applet for offline access.
    If java program did not show up, please download and install latest Java RUN TIME

    Someone sent me an email as following:
    Quote
    Enjoyed the vector models you provided on the website.  As you asked for suggestions - it would be very helpful if you could "rotate" the 3d version of the model from different angles.  Would give an enhanced perspective of the resultant vectors respective to each coordinate access.  Not a programmer myself so have no idea how much work would be involved but that feature would be very cool.
    So I created the following applets:




    Registed user can get files related to this applet for offline access.
    If java program did not show up, please download and install latest Java RUN TIME
    Logged
    alex45
    Newbie
    *
    Offline Offline

    Posts: 1

    « Reply #25 on: March 12, 2009, 09:52:58 PM »

    The other option for returning multiple parameters is that objects are passed by reference as parameters. This means if you pass the initialised Vector in as parameter you can add values to it, and the calling method will be able to access those values.
    -*-
    Logged
    janelavis
    Newbie
    *
    Offline Offline

    Posts: 5

    « Reply #26 on: September 22, 2009, 01:50:31 PM » posted from:Phagwara,Punjab,India

    I think that you need to think a little more about the design of your Vector class. You need to decide upon a minimal but complete interface for Vector. It looks like you could do with some member variables instead of creating local variables named size and degree
    Logged
    Fu-Kwun Hwang
    Administrator
    Hero Member
    *****
    Offline Offline

    Posts: 1966


    WWW
    « Reply #27 on: October 05, 2009, 10:59:25 AM » posted from:Taipei,T\'ai-pei,Taiwan

    Thank you for your comment. I am not a professional programmer. I am a physicist , I enjoy the fun of physics and I hope the simulations I have created can help users to enjoy the fun of physics, too!
    I hope you can create better simulation to help other, too! :-) You are welcomed to upload it here and share with others.
    Logged
    Pages: [1]   Go Up
      Print  
    "There is nothing either good or bad, but thinking makes it so." ..."Shakespeare (154-1616, English dramatist and poet) "
     
    Jump to:  


    Related Topics
    Subject Started by Replies Views Last post
    C=AXB cross product vector relations
    misc
    Fu-Kwun Hwang 0 6493 Last post February 23, 2007, 08:45:08 PM
    by Fu-Kwun Hwang
    Magnitude of a Vector
    misc
    lookang 5 3917 Last post April 29, 2008, 01:40:11 PM
    by lookang
    Represent a vector as horizontal and vertical components applet
    misc
    lookang 14 6626 Last post May 05, 2008, 07:13:12 PM
    by lookang
    Ejs Open source creative commons sg Magnitude of a vector Best java applet
    Collaborative Community of EJS
    lookang 1 4255 Last post November 04, 2008, 12:47:47 PM
    by lookang
    EJS version of Vector addition (sum of two vectors)
    misc
    Fu-Kwun Hwang 0 1500 Last post October 11, 2009, 02:59:59 PM
    by Fu-Kwun Hwang
    Powered by MySQL Powered by PHP Powered by SMF 1.1.11 | SMF © 2006-2009, Simple Machines LLC Valid XHTML 1.0! Valid CSS!
    Page created in 5.766 seconds with 23 queries.