Chronology Current Month Current Thread Current Date
[Year List] [Month List (current year)] [Date Index] [Thread Index] [Thread Prev] [Thread Next] [Date Prev] [Date Next]

Re: Satelite Motion



I wrote a quick and dirty little program in True Basic to animate the
motion. I'll include the program below. IF you run it with ME = 5.975E24
you get the normal orbit. With the 2xME you get a severely elliptical orbit
with the closest approach at 1.31E8 m or .34 time the current orbital
radius. This assumes that the earth's mass SUDDENLY is increased by 2.

Rick

*********************************************************
Richard W. Tarara
Professor of Physics
Saint Mary's College
Notre Dame, Indiana
rtarara@saintmarys.edu
********************************************************
Free Physics Educational Software (Win & Mac)
NEW: Animations for PowerPoint
Animation updates
International Energy Management Simulator
www.saintmarys.edu/~rtarara/software.html
Energy 2100--class project
www.saintmarys.edu/~rtarara/ENERGY_PROJECT/ENERGY2100.htm
********************************************************



LIBRARY "truectrl.trc"

SET MODE "color256"
CALL TC_Init
CALL tc_setunitstopixels
CALL tc_show_default (0)
CALL TC_GETSCREENSIZE(XL,XR,YB,YT)

CALL TC_WIN_Create (DISPLAY,"title|close",0,XR-1,YB-1,0)
CALL tc_win_settitle (DISPLAY,"EARTH-MOON")
CALL TC_SHOW(DISPLAY)
CALL TC_win_Switch(DISPLAY)
CALL TC_Win_RealizePalette(DISPLAY)
CALL TC_WIN_NOHIDE(DISPLAY,1)
ASK PIXELS XM,YM
SET WINDOW -XM/2,XM/2-1,-YM/2,YM/2-1

SET COLOR "BLACK"
BOX CIRCLE -5,5,5,-5
FLOOD 0,0
BOX KEEP -5,5,5,-5 IN MOON$

LET ME = 2*5.975E24
LET MM = 7.35E22
LET G = 6.6726E-11
LET R = 3.85E8
LET SCALE = 6.21E-7
LET XE = 0
LET YE = 0
LET XM = 0
LET YM = R
LET xmp = xm*SCALE
LET ymp = ym*scale
BOX SHOW MOON$ AT XMp-5,YMp-5
LET VM = 1026
LET Vx = vm
LET vy = 0
OPTION ANGLE degrees
LET dt = 10
DO
LET ax = -(G*ME*XM/R^3)
LET ay = -(G*ME*YM/R^3)
LET vx = vx+ax*dt
LET xm = xm+vx*dt
LET vy = vy+ay*dt
LET ym = ym+vy*dt
LET r = (xm^2+ym^2)^.5
LET xmp = xm*scale
LET ymp = ym*scale
BOX SHOW moon$ at xmp-5,ymp-5
IF XMP < 1 AND XMP > -1 THEN ! display farthest and nearest approaches
BOX CLEAR -500,-300,-350,-300
PLOT TEXT, AT -500,-350:STR$(R)
END IF
IF key input then EXIT DO !press a key to exit
LOOP

CALL TC_CLEANUP
END