Repository navigation
Expand file tree
/
Copy pathRO3C.SHC
More file actions
67 lines (60 loc) · 1.35 KB
/
Copy pathRO3C.SHC
File metadata and controls
67 lines (60 loc) · 1.35 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
! RO3C.SHC
! 3-d rotation by computed real angles.
!
default 1 ;; first time in s
default 2 ;; second time in s
sdef cnt 1
sdef trmax $dsptrcs
sdef slat
sdef slon
sdef dist
sdef azim
sdef inci
sdef tazim
sdef tinci
sdef t1 #1
sdef t2 #2
settime:
if "t1 nes ;; goto/forward t1ok:
time ;; &t1
t1ok:
if "t2 nes ;; goto/forward t2ok:
time ;; &t2
t2ok:
if "t1 ltr "t2 goto/forward timeok:
echo >>>>>> error: reset time
calc s &t1 = ;;
calc s &t2 = ;;
goto settime:
timeok:
echo
echo
echo trace $hexchar09(1) r-baz $hexchar09(1) t-baz $hexchar09(1) r-inc $hexchar09(1) t-inc
nr
dtw
del h:all
loop_start:
if "cnt gti "trmax goto loop_exit:
! theoretical angles
call statloc ^station &slat &slon
call locdiff "slat "slon ^lat ^lon &dist &tazim
call inci "dist ^depth &tinci
calc/fmt=<%5.1@f> r &tazim = "tazim
calc/fmt=<%5.1@f> r &tinci = "tinci
! calc/fmt=<%5.1@f> r &tazim = ^azimuth
! calc/fmt=<%5.1@f> r &tinci = ^inci
! real angles
mdir 1-3 "t1 "t2 &azim &inci
calc/fmt=<%5.1@f> r &azim = "azim
calc/fmt=<%5.1@f> r &inci = "inci
echo "cnt $hexchar09(1) "azim $hexchar09(1) "tazim $hexchar09(1) "inci $hexchar09(1) "tinci
rot3 1-3 "azim "inci
hide 1-3
! set/file/mod 1-3 azimuth "azim
! set/file/mod 1-3 inci "inci
calc i &cnt = "cnt + 3
goto loop_start:
loop_exit:
echo
rd
return