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 /math/nlfit/nlfreer.x | |
download | iraf-osx-40e5a5811c6ffce9b0974e93cdd927cbcf60c157.tar.gz |
Repatch (from linux) of OSX IRAF
Diffstat (limited to 'math/nlfit/nlfreer.x')
-rw-r--r-- | math/nlfit/nlfreer.x | 37 |
1 files changed, 37 insertions, 0 deletions
diff --git a/math/nlfit/nlfreer.x b/math/nlfit/nlfreer.x new file mode 100644 index 00000000..639c4ecc --- /dev/null +++ b/math/nlfit/nlfreer.x @@ -0,0 +1,37 @@ +include "nlfitdefr.h" + +# NLFREE -- Deallocate all assigned space + +procedure nlfreer (nl) + +pointer nl # pointer to non-linear fitting structure + +errchk mfree + +begin + if (nl == NULL) + return + if (NL_PARAM(nl) != NULL) + call mfree (NL_PARAM(nl), TY_REAL) + if (NL_OPARAM(nl) != NULL) + call mfree (NL_OPARAM(nl), TY_REAL) + if (NL_DPARAM(nl) != NULL) + call mfree (NL_DPARAM(nl), TY_REAL) + if (NL_DELPARAM(nl) != NULL) + call mfree (NL_DELPARAM(nl), TY_REAL) + if (NL_PLIST(nl) != NULL) + call mfree (NL_PLIST(nl), TY_INT) + if (NL_ALPHA(nl) != NULL) + call mfree (NL_ALPHA(nl), TY_REAL) + if (NL_CHOFAC(nl) != NULL) + call mfree (NL_CHOFAC(nl), TY_REAL) + if (NL_COVAR(nl) != NULL) + call mfree (NL_COVAR(nl), TY_REAL) + if (NL_BETA(nl) != NULL) + call mfree (NL_BETA(nl), TY_REAL) + if (NL_TRY(nl) != NULL) + call mfree (NL_TRY(nl), TY_REAL) + if (NL_DERIV(nl) != NULL) + call mfree (NL_DERIV(nl), TY_REAL) + call mfree (nl, TY_STRUCT) +end |