; This phile is ungoverned by the Cypherpunks Anti-License
; Do with it as you will.
; This copyleft&ist; phile is in AutoLISP®
; Sorry.
; Momentarily stuck in Windows®
; Nice GCL code in kitchen for a change.
; Honest.
; Acc
; A path on a map can be represented by a cosine wave.
; draw cosine wave
; decimal precision of error
; amount of deflection actual wave can take
; its actual variance in linear rotation
; isn't much at all.
; w rect meas + sine wav
; more (less?) pitch (musical acoustical etc.)
(setq
section-corners
'((-83.0676 42.5203) (-83.0858 42.52) (-83.0852 42.5054) (-83.0674 42.5055))
pi
3.1415926535897932384626433
earth-radius
6.3662e+006
)
; This phile is in Revison 14's AutoLISP.
; The following routine
; translates from longitude and latitude (respectively)
; in degrees
; to (approximate) x, y, z
; in meters.
(defun spheric (pt / long lat rho theta phi x y z)
(setq
long
(car pt)
lat
(cadr pt)
rho
earth-radius
theta
(/ long (/ 180.0 pi))
phi
(/ (+ lat 90.0) (/ 180.0 pi))
x
( rho (cos theta) (sin phi))
y
( rho (sin theta) (sin phi))
z
(* rho (- (cos phi))))
(list x y z))
; This draws the section whose corners
; are given by longitude and latitude
; in degrees as the list section-corners
(defun draw-section (section-corners / comm left)
(setq
comm
'("3dpoly")
left
section-corners)
(while
left
(setq
comm
(cons (spheric (car left)) comm)
left
(cdr left)))
(setq comm (cons nil (cons "close" comm)))
(apply 'command (reverse comm)))
(draw-section section-corners)
; generate list of n s's
(defun list-of (n s / result)
(while
(not (zerop n))
(setq
result
(cons s result)
n
(1- n)))
result)
; calculate centroid of corner points
(defun section-center (section-corners)
(mapcar
'/
(apply
'mapcar
(cons
'+
(mapcar 'spheric section-corners)))
(list-of 3 (length section-corners))))
(setq map-center (section-center section-corners))
(command "vpoint" map-center nil)
(command "save" "section.dwg" nil)
(print "saved to section.dwg")
; packaging+engineering+lead
; http://alltheweb.com/search?q="packaging+engineering"+"Pb"">"packaging+engineering"+"Pb"
; 1248z 6 sept 2004
; wdiv channel 4
; nbc today show
; ilana
; [email protected]
; pubwan and distilled water
; pubwan and the game of tennis
; dolfrt
; piprgiyyrt
; planned unplanning
; credit-dauphine.com
; wikibooks portal physics
; information physics