[project @ 2000-10-03 18:25:28 by andy]
[ghc-hetmet.git] / ghc / tests / programs / galois_raytrace / Primitives.hs
1 -- Copyright (c) 2000 Galois Connections, Inc.
2 -- All rights reserved.  This software is distributed as
3 -- free software under the license in the file "LICENSE",
4 -- which is included in the distribution.
5
6 module Primitives where
7
8 rad2deg :: Double -> Double
9 rad2deg r = r * 180 / pi
10
11 deg2rad :: Double -> Double
12 deg2rad d = d * pi / 180
13
14 addi :: Int -> Int -> Int
15 addi = (+)
16
17 addf :: Double -> Double -> Double
18 addf = (+)
19
20 acosD :: Double -> Double
21 acosD x = acos x * 180 / pi
22
23 asinD :: Double -> Double
24 asinD x = asin x * 180 / pi