aboutsummaryrefslogtreecommitdiff
path: root/sys/etc/gmtcnv.x
diff options
context:
space:
mode:
authorJoe Hunkeler <jhunkeler@gmail.com>2015-08-11 16:51:37 -0400
committerJoe Hunkeler <jhunkeler@gmail.com>2015-08-11 16:51:37 -0400
commit40e5a5811c6ffce9b0974e93cdd927cbcf60c157 (patch)
tree4464880c571602d54f6ae114729bf62a89518057 /sys/etc/gmtcnv.x
downloadiraf-osx-40e5a5811c6ffce9b0974e93cdd927cbcf60c157.tar.gz
Repatch (from linux) of OSX IRAF
Diffstat (limited to 'sys/etc/gmtcnv.x')
-rw-r--r--sys/etc/gmtcnv.x35
1 files changed, 35 insertions, 0 deletions
diff --git a/sys/etc/gmtcnv.x b/sys/etc/gmtcnv.x
new file mode 100644
index 00000000..7713c9c0
--- /dev/null
+++ b/sys/etc/gmtcnv.x
@@ -0,0 +1,35 @@
+# Copyright(c) 1986 Association of Universities for Research in Astronomy Inc.
+
+# GMTCNV.X -- GMT (Greenwich mean time) to LST (local standard time, or clock
+# time) conversions.
+#
+# gmt = lsttogmt (lst) # lst/gmt are in seconds
+# lst = gmttolst (gmt) # lst/gmt are in seconds
+
+
+
+# GMTTOLST -- Convert a long integer value in GMT seconds to LST seconds.
+
+long procedure gmttolst (gmt)
+
+long gmt # GMT in seconds
+int gmtco
+
+begin
+ call zgmtco (gmtco)
+ return (gmt - gmtco)
+end
+
+
+
+# LSTTOGMT -- Convert a long integer value in LST seconds to GMT seconds.
+
+long procedure lsttogmt (lst)
+
+long lst # LST in seconds
+int gmtco
+
+begin
+ call zgmtco (gmtco)
+ return (lst + gmtco)
+end