products/Sources/formale Sprachen/VDM/VDMPP/TempoCollaborativePP image not shown  

Quellcode-Bibliothek

© Kompilation durch diese Firma

[Weder Korrektheit noch Funktionsfähigkeit der Software werden zugesichert.]

Datei: stau-p12.cob   Sprache: Unknown

       Identification Division.
       Program-Id. Planet.
      * from Stauffer/Stanley
      * From Newton to Mandelbrot
      * Springer 1996
       Data Division.
       Working-Storage Section.
         77 vx          pic S9(4)V9(4).
         77 vy          pic S9(4)V9(4).
         77 dt          pic S9(4)V9(4).
       Procedure Division.
        display "vx, vy,dt="
        accept vx,vy,dt
        move 0 to x
        move 1 to y
       L40.
        compute r2=x*x+y*y
        compute r3=dt/(r2*function sqrt(r2))
        compute vx=vx-x*r3
        compute vy=vy-y*r3
        compute x=x+dt*vx
        compute y=y+dt*vy
        display x, v
        go to L40.
       End-Program Planet.

[ Verzeichnis aufwärts0.17unsichere Verbindung  Übersetzung europäischer Sprachen durch Browser  ]