s-expressions at the REPL prompt.
@example
- (load-option 'planetarium)
- (define t (make-tellurion))
+ (load-option 'planetarium)
+ (define t (make-tellurion))
@end example
A tellurion should pop up in a new window on your desktop.
For example, to center the globe on Fairbanks, Alaska, enter this:
@example
- (t 'turn-to 64.844 -147.723)
+ (t 'turn-to 64.844 -147.723)
@end example
You can also have the tellurion draw the terminator as it would appear
Time''.)
@example
- (t 'time-to
- ;; a recent vernal equinox
- (make-decoded-time 0 29 9 19 3 2016))
+ (t 'time-to
+ ;; a recent vernal equinox
+ (make-decoded-time 0 29 9 19 3 2016))
@end example
You can return the tellurion to the current time by applying it to the
symbols @code{time-to} and @code{current}.
@example
- (t 'time-to 'current)
+ (t 'time-to 'current)
@end example
The tellurion redraws every 15 minutes to show the terminator's crawl
you apply it to @code{go}.
@example
- (t 'stop)
- (t 'go)
+ (t 'stop)
+ (t 'go)
@end example
@node Terrain Viewer, GNU Free Documentation License, Introduction, Top
REPL prompt.
@example
- (load-option 'planetarium)
- (ge '(planetarium terrain))
- (write-function-terrain
- "sample-terrain.txt"
- -3 3 50
- -3 3 50
- (lambda (x y)
- (let ((d^2+1 (+ (* x x) (* y y) 1)))
- (* 1000 (/ (sin d^2+1) d^2+1)))))
+ (load-option 'planetarium)
+ (ge '(planetarium terrain))
+ (write-function-terrain
+ "sample-terrain.txt"
+ -3 3 50
+ -3 3 50
+ (lambda (x y)
+ (let ((d^2+1 (+ (* x x) (* y y) 1)))
+ (* 1000 (/ (sin d^2+1) d^2+1)))))
@end example
A @file{sample-terrain.txt} file will be created in the current
To view your sample terrain enter the following four s-expressions.
@example
- (define v (make-terrain
- 'filename "sample-terrain.txt"
- 'rows 50 'columns 50
- 'latitude 0. 'longitude 0.
- 'step .001))
- (v 'position -.02 -.02 4000.)
- (v 'heading 45.)
- (v 'tilt -40.)
+ (define v (make-terrain
+ 'filename "sample-terrain.txt"
+ 'rows 50 'columns 50
+ 'latitude 0. 'longitude 0.
+ 'step .001))
+ (v 'position -.02 -.02 4000.)
+ (v 'heading 45.)
+ (v 'tilt -40.)
@end example
A viewer window should appear and display an image like
Bay, California.
@example
- #!/bin/bash
- mit-scheme-pucked --batch-mode <<\EOF
- (begin
- (load-option 'planetarium)
- (request-google-elevations "monterey.txt"
- (make-latitudes/longitudes
- (iota 101 36. .01)
- (iota 101 -122.5 .01)))
- )
- EOF
+ #!/bin/bash
+ mit-scheme-pucked --batch-mode <<\EOF
+ (begin
+ (load-option 'planetarium)
+ (request-google-elevations "monterey.txt"
+ (make-latitudes/longitudes
+ (iota 101 36. .01)
+ (iota 101 -122.5 .01)))
+ )
+ EOF
@end example
You might name the script @file{~/job.sh} and run it in the background
you might wait an entire day for 10201 elevations to download.
@example
- $ chmod +x ~/job.sh
- $ echo "~/job.sh" | at now
+ $ chmod +x ~/job.sh
+ $ echo "~/job.sh" | at now
@end example
Tomorrow, after you get email saying your job has successfully
s-expressions.
@example
- (ge '(planetarium terrain))
- (define v (make-terrain
- 'filename "monterey.txt" 'rows 101 'columns 101
- 'latitude 36. 'longitude -122.5 'step .01
- 'color-function height-color))
- (v 'position 36.5 -122.7 15000.)
- (v 'heading 85.)
- (v 'tilt -25.)
+ (ge '(planetarium terrain))
+ (define v (make-terrain
+ 'filename "monterey.txt" 'rows 101 'columns 101
+ 'latitude 36. 'longitude -122.5 'step .01
+ 'color-function height-color))
+ (v 'position 36.5 -122.7 15000.)
+ (v 'heading 85.)
+ (v 'tilt -25.)
@end example
A viewer window should appear and display an image like