English
Experimente

Gravi-Spirograph to that experiment

 

p.specht

one think itself one weight at a string, The through one vent in a senkrechten disk to a something schwereren Gegengewicht lead. something hochtrabend declared: The entstehende Figur is of Startort, the Anfangsgeschwindigkeit (in x- and y-direction) as well as from the Reibung on the disk tributary. to that terminate something longer The ESC pressing!
Window Title "Gravi-Spirograph"'(CL) CopyLeft 2014-03 by P.woodpecker, Wien
Windowstyle 24:Font 2:Randomize:Window 0,0-%maxx,%maxy-40
var xx&=width(%hwnd):var yy&=height(%hwnd):var xh&=xx&\2:var yh&=yy&*0.2'Nullpunktshöhe
set("decimals",15):set("numwidth",30):var g2r!=Pi()/180:var ende&=0

proc point :parameters x!,y!

    usepen 0,1,0:line xh&,0 - xh&,yy&:line 0,yh&-xx&,yh&
    usepen 0,24,rgb(100+rnd(156),100+rnd(156),100+0*rnd(156))
    line xh&+x!,(yh&-y!) - xh&+x!+1,yh&-y!-1

endproc

declare x!,y!,d!,a!,ax!,ay!,vx!,vy!,t!,g!
g!=9.80665' Erdbeschleunigung in -y direction
t!=0.1' = 1/FPS Simulierter Zeitschritt, 1/FPS = "Echtzeit"
'x!=200:y!=0:vy!=10:vx!=0  'Startpunkt and Initialgeschwindigkeit y=Nach obeb
'x!=200:y!=-100:vy!=8
x!=500:y!=-100:vy!=rnd(12)

repeat

    d!=sqrt(sqr(x!)+sqr(y!))

    if d!>1

        a!=d!*0.0001' Zentripetalbeschleunigung, here of stood off linear tributary
        ax!=-x!/d!
        ay!=-g!/17-y!/d!
        vx!=vx!+ax!/2*t!
        vx!=vx!*(1-0.002*t!)' Dämpfung the x-Komponente (2%/sek)
        vy!=vy!+ay!/2*t!
        vy!=vy!*(1-0.002*t!)'Dämpfung the y-Komponente
        x!=x!+vx!*t!
        y!=y!+vy!*t!
        point x!,y!

    endif

    if rnd()<0.01:waitinput 5:case %key=27:ende&=1:endif

    until ende&

    end
 
XProfan 11
Computer: Gerät, daß es in Mikrosekunden erlaubt, 50.000 Fehler zu machen, zB 'daß' statt 'das'...
05/11/21  
 



Zum Experiment


Topictitle, max. 100 characters.
 

Systemprofile:

no Systemprofil laid out. [anlegen]

XProfan:

 Posting  Font  Smilies  ▼ 

Please register circa a Posting To verfassen.
 

Topic-Options

620 Views

Themeninformationen

this Topic has 1 subscriber:

p.specht (1x)


Admins  |  AGB  |  Applications  |  Authors  |  Chat  |  Privacy Policy  |  Download  |  Entrance  |  Help  |  Merchantportal  |  Imprint  |  Mart  |  Interfaces  |  SDK  |  Services  |  Games  |  Search  |  Support

One proposition all XProfan, The there's!


My XProfan
Private Messages
Own Storage Forum
Topics-Remember-List
Own Posts
Own Topics
Clipboard
Log off
 Deutsch English Français Español Italia
Translations

Privacy Policy


we use Cookies only as Session-Cookies because of the technical necessity and with us there no Cookies of Drittanbietern.

If you here on our Website click or navigate, stimmst You ours registration of Information in our Cookies on XProfan.Net To.

further Information To our Cookies and moreover, How You The control above keep, find You in ours nachfolgenden Datenschutzerklärung.


all rightDatenschutzerklärung
i want none Cookie