This is the web version of EJS interface
EJS version 4.1
  1. Author=Fu-Kwun Hwang - Dept. of Physics, National Taiwan Normal Univ.
  2. Abstract=hwang@phy.ntnu.edu.tw
  3. CaptureTools=true
  4. DataTools=true
  5. LanguageTools=true

Intro Page

Created by Fu-Kwun Hwang

Dept. of Physics

National Taiwan Normal University

Taipei, Taiwan

http://www.phy.ntnu.edu.tw/ntnujava/

    NameValueTypeDimension
    NameValueTypeDimension
    NameValueTypeDimension

    Init Page

    t=0; x=xs+L0; vx=0;

    Evol Page

    Indep. Var. Increment
    d cta /dt=omega
    d x /dt=vx
    d vx /dt=(-k*(x-xs-L0)-b*vx)/m
    SolverRungeKuttaTolerance=0.001

    FixRel Page

    xd=d*Math.cos(cta); yd=d*Math.sin(cta); xs=calX(xd); xd+=xc; xm=xs+L0+x;
    double dv; public double dvalue (double v) { if(v>0)dv=0.5; else if(v<0)dv=-0.5; else dv=0; return (int)(v*100+dv)/100.; }
    public double calX (double x) { return xc+x+Math.sqrt(x*x+L1*L1-d*d); }
    EJSVIEW: Click link to view it's content
    Control variables:(testing)
    double,double,double,double,double
    title="Frame"
    layout=border
    visible=true
    location="-1,-15"
    size="734,578"
    position=center
    layout=GRID:0,1,0,0
    position=center
    autoscaleX=false
    autoscaleY=false
    minimumX=xmin
    maximumX=xmax
    minimumY=ymin
    maximumY=ymax
    square=true
    x=xm
    y=ys
    sizeX=size*5
    sizeY=size*5
    x=xc
    y=yc
    sizeX=2*R
    sizeY=2*R
    transformation=cta
    style=WHEEL
    fillColor=LIGHTGRAY
    x=xd
    y=yd
    sizeX=size2
    sizeY=size2
    fillColor=GRAY
    x=xs
    y=ys
    sizeX=L0+x
    sizeY=0
    radius=R
    loops=8
    lineWidth=stroke
    x=xd
    y=yd
    sizeX=xs-xd
    sizeY=ys-yd
    lineColor=BLUE
    lineWidth=stroke
    x=xs
    y=ys
    sizeX=size2
    sizeY=size2
    fillColor=GRAY
    x=xm
    y=ys
    sizeX=vx
    sizeY=0
    lineColor=RED
    fillColor=RED
    autoscaleX=true
    autoscaleY=true
    title="x(t),vx(t)"
    x=t
    y=x-xs-L0
    memory=nt
    maxpoints=npt
    active=_isPlaying()
    norepeat=true
    connected=t>0
    x=t
    y=vx
    memory=nt
    maxpoints=npt
    active=_isPlaying()
    norepeat=true
    connected=t>0
    color=RED
    position=south
    layout=border
    position=east
    layout=HBOX
    borderType=LOWERED_ETCHED
    image=/org/opensourcephysics/resources/controls/images/reset.gif
    action=_reset()
    text="init"
    enabled=_isPaused()
    action=_initialize()
    variable=_isPaused
    imageOn=/org/opensourcephysics/resources/controls/images/play.gif
    actionOn=_play()
    imageOff=/org/opensourcephysics/resources/controls/images/pause.gif
    actionOff=_pause()
    position=center
    layout=HBOX
    variable=b
    minimum=0.0
    maximum=2.0
    format="b=0.0"
    ticks=21
    closest=true
    variable=m
    minimum=1.0
    maximum=20.0
    format="m=0.0"
    ticks=20
    closest=true
    enabled=_isPaused()
    dragaction=_initialize()
    variable=k
    minimum=1.0
    maximum=100.0
    format="k=0.0"
    ticks=100
    closest=true
    enabled=_isPaused()
    dragaction=_initialize()
    variable=T
    minimum=1.0
    maximum=10.0
    format="T=0.0"
    ticks=10
    closest=true
    enabled=_isPaused()
    dragaction=_initialize()
    variable=d
    minimum=R/20
    maximum=R/4
    format="d=0.00"
    enabled=_isPaused()
    dragaction=_initialize()