This file is indexed.

/usr/lib/ats-anairiats-0.2.11/prelude/SATS/number.sats is in ats-lang-anairiats 0.2.11-1.

This file is owned by root:root, with mode 0o644.

The actual contents of the file can be viewed below.

  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
 66
 67
 68
 69
 70
 71
 72
 73
 74
 75
 76
 77
 78
 79
 80
 81
 82
 83
 84
 85
 86
 87
 88
 89
 90
 91
 92
 93
 94
 95
 96
 97
 98
 99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
(***********************************************************************)
(*                                                                     *)
(*                         Applied Type System                         *)
(*                                                                     *)
(*                              Hongwei Xi                             *)
(*                                                                     *)
(***********************************************************************)

(*
** ATS - Unleashing the Potential of Types!
** Copyright (C) 2002-2009 Hongwei Xi, Boston University
** All rights reserved
**
** ATS is free software;  you can  redistribute it and/or modify it under
** the terms of the GNU LESSER GENERAL PUBLIC LICENSE as published by the
** Free Software Foundation; either version 2.1, or (at your option)  any
** later version.
** 
** ATS is distributed in the hope that it will be useful, but WITHOUT ANY
** WARRANTY; without  even  the  implied  warranty  of MERCHANTABILITY or
** FITNESS FOR A PARTICULAR PURPOSE.  See the  GNU General Public License
** for more details.
** 
** You  should  have  received  a  copy of the GNU General Public License
** along  with  ATS;  see the  file COPYING.  If not, please write to the
** Free Software Foundation,  51 Franklin Street, Fifth Floor, Boston, MA
** 02110-1301, USA.
*)

(* ****** ****** *)

(*
**
** An interface for various common funtion on numbers
**
** Contributed by Hongwei Xi (hwxi AT cs DOT bu DOT edu)
** Contributed by Shivkumar Chandrasekaran (shiv AT ece DOT ucsb DOT edu)
**
** Time: Summer, 2009
**
*)

(* ****** ****** *)

// this is originally done for the ATS/CBLAS package

(* ****** ****** *)
//
// legend:
// S: single precision float (float)
// D: double precision float (double)
// C: single precision complex (ccmplx)
// Z: double precision complex (zcmplx)
//
(* ****** ****** *)

// S, D, C, Z
fun{a:t@ype} print_typ (): void
fun{a:t@ype} print_elt (x: a): void

(* ****** ****** *)

// S, D, C, Z
fun{a:t@ype} of_int (x: int):<> a

(* ****** ****** *)

// S, D
fun{a:t@ype} of_size (x: size_t):<> a

(* ****** ****** *)

// S, D, C, Z
fun{a:t@ype} of_double (x: double):<> a

(* ****** ****** *)

// S, D
fun{a:t@ype} to_int (x:a):<> int
fun{a:t@ype} to_float (x: a):<> float
fun{a:t@ype} to_double (x: a):<> double

(* ****** ****** *)

// S, D, C, Z
fun{a1,a2:t@ype} abs (x: a1):<> a2

(* ****** ****** *)

// S, D, C, Z
fun{a:t@ype} neg (x: a):<> a

(* ****** ****** *)

// S, D, C, Z
fun{a:t@ype} add (x1: a, x2: a):<> a
fun{a:t@ype} sub (x1: a, x2: a):<> a
fun{a:t@ype} mul (x1: a, x2: a):<> a
fun{a:t@ype} div (x1: a, x2: a):<> a

(* ****** ****** *)

// S, D, C, Z
fun{a:t@ype} pow (base: a, exp: a):<> a

(* ****** ****** *)

// S, D, C, Z
fun{a:t@ype} sqrt (x: a):<> a

(* ****** ****** *)

// S, D
fun{a:t@ype} ceil (x:a) :<> a
fun{a:t@ype} floor (x:a) :<> a

(* ****** ****** *)

// (S, S), (D, D)
// (S, C), (C, C), (D, Z), (Z, Z)
fun{a1,a2:t@ype} scal (x1: a1, x2: a2):<> a2

(* ****** ****** *)

// S, D
fun{a:t@ype} lt (x1: a, x2: a):<> bool
fun{a:t@ype} lte (x1: a, x2: a):<> bool
fun{a:t@ype} gt (x1: a, x2: a):<> bool
fun{a:t@ype} gte (x1: a, x2: a):<> bool

(* ****** ****** *)

// S, D, C, Z
fun{a:t@ype} eq (x1: a, x2: a):<> bool
fun{a:t@ype} neq (x1: a, x2: a):<> bool

(* ****** ****** *)

// S, D
fun{a:t@ype} signof (x: a):<> Sgn
fun{a:t@ype} compare (x1: a, x2: a):<> Sgn

(* ****** ****** *)

// S, D
fun{a:t@ype} min (x:a, y:a):<> a
fun{a:t@ype} max (x:a, y:a):<> a

(* ****** ****** *)

// (S, C), (D, Z)
// a1 = |a2|
fun{a1,a2:t@ype} cmplx_make_cart (real: a1, imag: a1):<> a2

(* ****** ****** *)

// (S, C), (D, Z)

fun {a1,a2:t@ype} creal (x: a2):<> a1
fun {a1,a2:t@ype} cimag (x: a2):<> a1

(* ****** ****** *)

// C, Z
fun{a:t@ype} conj (x: a):<> a

(* ****** ****** *)

// S, D, C, Z
fun{a:t@ype} sin (x: a):<> a
fun{a:t@ype} cos (x: a):<> a
fun{a:t@ype} tan (x: a):<> a

(* ****** ****** *)

// S, D, C, Z
fun{a:t@ype} asin (x: a):<> a
fun{a:t@ype} acos (x: a):<> a
fun{a:t@ype} atan (x: a):<> a
fun{a:t@ype} atan2 (x1: a, x2: a):<> a

(* ****** ****** *)

(* end of [number.sats] *)