Project

General

Profile

Kaon LT Meetings » linux_suppl.inc

Garth Huber, 03/08/2026 12:59 PM

 
1
C --- linux_suppl.inc          
2
C
3
C     g77 does not have intrinsic sind, cosd....
4
C     They have to be declared external
5
C
6
C      real*8 sind, cosd, tand
7
C      real*8 asind, acosd, atand, atan2d
8
C      external sind, cosd, tand
9
C      external asind, acosd, atand, atan2d
10
C
11
C     linux supplemental fuctions
12
C
13
C sind
14
      real*8 function sind (x)
15
      implicit none
16
      real*8 x
17
      real*8 degrad
18
      parameter (degrad = 3.141592654 / 180.)
19

    
20
      sind = sin (degrad * x)
21
      return
22
      end
23
C
24
C cosd
25
      real*8 function cosd (x)
26
      implicit none
27
      real*8 x
28
      real*8 degrad
29
      parameter (degrad = 3.141592654 / 180.)
30

    
31
      cosd = cos (degrad * x)
32
      return
33
      end
34
C
35
C tand
36
      real*8 function tand (x)
37
      implicit none
38
      real*8 x
39
      real*8 degrad
40
      parameter (degrad = 3.141592654 / 180.)
41

    
42
      tand = tan (degrad * x)
43
      return
44
      end
45
C
46
C asind
47
      real*8 function asind (x)
48
      implicit none
49
      real*8 x
50
      real*8 raddeg
51
      parameter (raddeg =  180. / 3.141592654 )
52

    
53
      asind = raddeg * asin (x)
54
      return
55
      end
56
C
57
C acosd
58
      real*8 function acosd (x)
59
      implicit none
60
      real*8 x
61
      real*8 raddeg
62
      parameter (raddeg =  180. / 3.141592654 )
63

    
64
      acosd = raddeg * acos (x)
65
      return
66
      end
67
C
68
C atand
69
      real*8 function atand(x)
70
      implicit none
71
      real*8 x
72
      real*8 raddeg
73
      parameter (raddeg =  180. / 3.141592654 )
74

    
75
      atand = raddeg * atan (x)
76
      return
77
      end
78
C
79
C atan2d
80
      real*8 function atan2d (x, y)
81
      implicit none
82
      real*8 x, y
83
      real*8 raddeg
84
      parameter (raddeg =  180. / 3.141592654 )
85

    
86
      atan2d = raddeg * atan2 (x, y)
87
      return
88
      end
(863-863/863)