diff options
author | Joe Hunkeler <jhunkeler@gmail.com> | 2015-08-11 16:51:37 -0400 |
---|---|---|
committer | Joe Hunkeler <jhunkeler@gmail.com> | 2015-08-11 16:51:37 -0400 |
commit | 40e5a5811c6ffce9b0974e93cdd927cbcf60c157 (patch) | |
tree | 4464880c571602d54f6ae114729bf62a89518057 /sys/vops/assq.gx | |
download | iraf-osx-40e5a5811c6ffce9b0974e93cdd927cbcf60c157.tar.gz |
Repatch (from linux) of OSX IRAF
Diffstat (limited to 'sys/vops/assq.gx')
-rw-r--r-- | sys/vops/assq.gx | 26 |
1 files changed, 26 insertions, 0 deletions
diff --git a/sys/vops/assq.gx b/sys/vops/assq.gx new file mode 100644 index 00000000..0189e01e --- /dev/null +++ b/sys/vops/assq.gx @@ -0,0 +1,26 @@ +# Copyright(c) 1986 Association of Universities for Research in Astronomy Inc. + +# ASSQ -- Vector sum of squares. + +$if (datatype == csir) +real procedure assq$t (a, npix) +real sum +$else $if (datatype == ld) +double procedure assq$t (a, npix) +double sum +$else +PIXEL procedure assq$t (a, npix) +PIXEL sum +$endif $endif + +PIXEL a[ARB] +int npix +int i + +begin + sum = 0$f + do i = 1, npix + sum = sum + (a[i] ** 2) + + return (sum) +end |