summaryrefslogtreecommitdiff
path: root/src/c/elementaryFunctions
diff options
context:
space:
mode:
authorsiddhu89902017-04-19 14:28:34 +0530
committersiddhu89902017-04-19 14:28:34 +0530
commit9e506f48291533cba7b4c555b0d2e98f234bfbe3 (patch)
tree6ffe38eefea51cdb767493850b2ada0c098fe416 /src/c/elementaryFunctions
parent453598b49cb3d4a62b1797dbc90f0e3dd4521329 (diff)
downloadscilab2c-9e506f48291533cba7b4c555b0d2e98f234bfbe3.tar.gz
scilab2c-9e506f48291533cba7b4c555b0d2e98f234bfbe3.tar.bz2
scilab2c-9e506f48291533cba7b4c555b0d2e98f234bfbe3.zip
Merged Ashish's work
Diffstat (limited to 'src/c/elementaryFunctions')
-rw-r--r--src/c/elementaryFunctions/acosd/cacoss.c147
-rw-r--r--src/c/elementaryFunctions/acosd/dacosda.c22
-rw-r--r--src/c/elementaryFunctions/acosd/dacosds.c18
-rw-r--r--src/c/elementaryFunctions/acosd/sacosda.c22
-rw-r--r--src/c/elementaryFunctions/acosd/sacosds.c18
-rw-r--r--src/c/elementaryFunctions/acot/cacota.c21
-rw-r--r--src/c/elementaryFunctions/acot/cacots.c23
-rw-r--r--src/c/elementaryFunctions/acot/dacota.c20
-rw-r--r--src/c/elementaryFunctions/acot/dacots.c18
-rw-r--r--src/c/elementaryFunctions/acot/sacota.c20
-rw-r--r--src/c/elementaryFunctions/acot/sacots.c18
-rw-r--r--src/c/elementaryFunctions/acot/zacota.c21
-rw-r--r--src/c/elementaryFunctions/acot/zacots.c23
-rw-r--r--src/c/elementaryFunctions/acotd/dacotda.c20
-rw-r--r--src/c/elementaryFunctions/acotd/dacotds.c18
-rw-r--r--src/c/elementaryFunctions/acotd/sacotda.c20
-rw-r--r--src/c/elementaryFunctions/acotd/sacotds.c18
-rw-r--r--src/c/elementaryFunctions/acoth/cacotha.c22
-rw-r--r--src/c/elementaryFunctions/acoth/cacoths.c23
-rw-r--r--src/c/elementaryFunctions/acoth/dacotha.c21
-rw-r--r--src/c/elementaryFunctions/acoth/dacoths.c19
-rw-r--r--src/c/elementaryFunctions/acoth/sacotha.c21
-rw-r--r--src/c/elementaryFunctions/acoth/sacoths.c18
-rw-r--r--src/c/elementaryFunctions/acoth/zacotha.c21
-rw-r--r--src/c/elementaryFunctions/acoth/zacoths.c23
-rw-r--r--src/c/elementaryFunctions/acsc/cacsca.c22
-rw-r--r--src/c/elementaryFunctions/acsc/cacscs.c22
-rw-r--r--src/c/elementaryFunctions/acsc/dacsca.c21
-rw-r--r--src/c/elementaryFunctions/acsc/dacscs.c17
-rw-r--r--src/c/elementaryFunctions/acsc/sacsca.c21
-rw-r--r--src/c/elementaryFunctions/acsc/sacscs.c17
-rw-r--r--src/c/elementaryFunctions/acsc/zacsca.c22
-rw-r--r--src/c/elementaryFunctions/acsc/zacscs.c23
-rw-r--r--src/c/elementaryFunctions/acscd/dacscda.c21
-rw-r--r--src/c/elementaryFunctions/acscd/dacscds.c17
-rw-r--r--src/c/elementaryFunctions/acscd/sacscda.c21
-rw-r--r--src/c/elementaryFunctions/acscd/sacscds.c17
-rw-r--r--src/c/elementaryFunctions/acsch/cacscha.c22
-rw-r--r--src/c/elementaryFunctions/acsch/cacschs.c30
-rw-r--r--src/c/elementaryFunctions/acsch/dacscha.c21
-rw-r--r--src/c/elementaryFunctions/acsch/dacschs.c17
-rw-r--r--src/c/elementaryFunctions/acsch/sacscha.c21
-rw-r--r--src/c/elementaryFunctions/acsch/sacschs.c17
-rw-r--r--src/c/elementaryFunctions/acsch/zacscha.c22
-rw-r--r--src/c/elementaryFunctions/acsch/zacschs.c22
-rw-r--r--src/c/elementaryFunctions/asec/daseca.c21
-rw-r--r--src/c/elementaryFunctions/asec/dasecs.c17
-rw-r--r--src/c/elementaryFunctions/asec/saseca.c21
-rw-r--r--src/c/elementaryFunctions/asec/sasecs.c27
-rw-r--r--src/c/elementaryFunctions/asecd/dasecda.c21
-rw-r--r--src/c/elementaryFunctions/asecd/dasecds.c17
-rw-r--r--src/c/elementaryFunctions/asecd/sasecda.c21
-rw-r--r--src/c/elementaryFunctions/asecd/sasecds.c17
-rw-r--r--src/c/elementaryFunctions/asech/dasecha.c21
-rw-r--r--src/c/elementaryFunctions/asech/dasechs.c18
-rw-r--r--src/c/elementaryFunctions/asech/sasecha.c21
-rw-r--r--src/c/elementaryFunctions/asech/sasechs.c18
-rw-r--r--src/c/elementaryFunctions/asind/dasinda.c21
-rw-r--r--src/c/elementaryFunctions/asind/dasinds.c18
-rw-r--r--src/c/elementaryFunctions/asind/sasinda.c21
-rw-r--r--src/c/elementaryFunctions/asind/sasinds.c18
-rw-r--r--src/c/elementaryFunctions/atan/datans.c3
-rw-r--r--src/c/elementaryFunctions/atand/datanda.c21
-rw-r--r--src/c/elementaryFunctions/atand/datands.c18
-rw-r--r--src/c/elementaryFunctions/atand/satanda.c21
-rw-r--r--src/c/elementaryFunctions/atand/satands.c18
-rw-r--r--src/c/elementaryFunctions/includes/acosd.h33
-rw-r--r--src/c/elementaryFunctions/includes/acot.h43
-rw-r--r--src/c/elementaryFunctions/includes/acotd.h37
-rw-r--r--src/c/elementaryFunctions/includes/acoth.h44
-rw-r--r--src/c/elementaryFunctions/includes/acsc.h44
-rw-r--r--src/c/elementaryFunctions/includes/acscd.h34
-rw-r--r--src/c/elementaryFunctions/includes/acsch.h32
-rw-r--r--src/c/elementaryFunctions/includes/asec.h34
-rw-r--r--src/c/elementaryFunctions/includes/asecd.h34
-rw-r--r--src/c/elementaryFunctions/includes/asech.h34
-rw-r--r--src/c/elementaryFunctions/includes/asind.h34
-rw-r--r--src/c/elementaryFunctions/includes/atand.h34
-rw-r--r--src/c/elementaryFunctions/interfaces/int_acosd.h34
-rw-r--r--src/c/elementaryFunctions/interfaces/int_acot.h42
-rw-r--r--src/c/elementaryFunctions/interfaces/int_acotd.h33
-rw-r--r--src/c/elementaryFunctions/interfaces/int_acoth.h43
-rw-r--r--src/c/elementaryFunctions/interfaces/int_acsc.h42
-rw-r--r--src/c/elementaryFunctions/interfaces/int_acscd.h34
-rw-r--r--src/c/elementaryFunctions/interfaces/int_acsch.h34
-rw-r--r--src/c/elementaryFunctions/interfaces/int_asec.h34
-rw-r--r--src/c/elementaryFunctions/interfaces/int_asecd.h34
-rw-r--r--src/c/elementaryFunctions/interfaces/int_asech.h34
-rw-r--r--src/c/elementaryFunctions/interfaces/int_asind.h34
-rw-r--r--src/c/elementaryFunctions/interfaces/int_atand.h34
-rw-r--r--src/c/elementaryFunctions/linspace/dlinspacea.c~39
-rw-r--r--src/c/elementaryFunctions/linspace/dlinspaces.c~25
-rw-r--r--src/c/elementaryFunctions/linspace/u8linspacea.c~39
-rw-r--r--src/c/elementaryFunctions/linspace/u8linspaces.c~25
94 files changed, 2315 insertions, 129 deletions
diff --git a/src/c/elementaryFunctions/acosd/cacoss.c b/src/c/elementaryFunctions/acosd/cacoss.c
new file mode 100644
index 00000000..97420313
--- /dev/null
+++ b/src/c/elementaryFunctions/acosd/cacoss.c
@@ -0,0 +1,147 @@
+/*
+ * Scilab ( http://www.scilab.org/ ) - This file is part of Scilab
+ * Copyright (C) 2007-2008 - INRIA - Bruno JOFRET
+ * Copyright (C) Bruno Pincon
+ *
+ * This file must be used under the terms of the CeCILL.
+ * This source file is licensed as described in the file COPYING, which
+ * you should have received as part of this distribution. The terms
+ * are also available at
+ * http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+ *
+ */
+
+/*
+ * This fonction is a translation of fortran wacos write by Bruno Pincon <Bruno.Pincon@iecn.u-nancy.fr>
+ * REFERENCE
+ * This is a Fortran-77 translation of an algorithm by
+ * T.E. Hull, T. F. Fairgrieve and P.T.P. Tang which
+ * appears in their article :
+ * "Implementing the Complex Arcsine and Arccosine
+ * Functions Using Exception Handling", ACM, TOMS,
+ * Vol 23, No. 3, Sept 1997, p. 299-335
+ */
+
+#include "acos.h"
+#include "atan.h"
+#include "log.h"
+#include "log1p.h"
+#include "sqrt.h"
+#include "abs.h"
+#include "lapack.h"
+#include "min.h"
+#include "max.h"
+
+#define localSign(x) (x>0 ? 1.0f : -1.0f)
+
+floatComplex cacoss(floatComplex z) {
+ static float sfltPi = 3.1415926535897932384626433f;
+ static float sfltPi_2 = 1.5707963267948966192313216f;
+ static float sfltLn2 = 0.6931471805599453094172321f;
+ static float sfltAcross = 1.5f;
+ static float sfltBcross = 0.6417f;
+
+ float fltLsup = ssqrts((float) getOverflowThreshold())/8.0f;
+ float fltLinf = 4.0f * ssqrts((float) getUnderflowThreshold());
+ float fltEpsm = ssqrts((float) getRelativeMachinePrecision());
+
+ float fltAbsReal = sabss(creals(z));
+ float fltAbsImg = sabss(cimags(z));
+ float fltSignReal = localSign(creals(z));
+ float fltSignImg = localSign(cimags(z));
+
+ float fltR = 0, fltS = 0, fltA = 0, fltB = 0;
+
+ float fltTemp = 0;
+
+ float _pfltReal = 0;
+ float _pfltImg = 0;
+
+ if( min(fltAbsReal, fltAbsImg) > fltLinf && max(fltAbsReal, fltAbsImg) <= fltLsup)
+ {/* we are in the safe region */
+ fltR = ssqrts( (fltAbsReal + 1 )*(fltAbsReal + 1 ) + fltAbsImg*fltAbsImg);
+ fltS = ssqrts( (fltAbsReal - 1 )*(fltAbsReal - 1 ) + fltAbsImg*fltAbsImg);
+ fltA = 0.5f * ( fltR + fltS );
+ fltB = fltAbsReal / fltA;
+
+
+ /* compute the real part */
+ if(fltB <= sfltBcross)
+ _pfltReal = sacoss(fltB);
+ else if( fltAbsReal <= 1)
+ _pfltReal = satans(ssqrts(0.5f * (fltA + fltAbsReal) * (fltAbsImg*fltAbsImg / (fltR + (fltAbsReal + 1)) + (fltS + (1 - fltAbsReal)))) / fltAbsReal);
+ else
+ _pfltReal = satans((fltAbsImg * ssqrts(0.5f * ((fltA + fltAbsReal) / (fltR + (fltAbsReal + 1)) + (fltA + fltAbsReal) / (fltS + (fltAbsReal - 1))))) / fltAbsReal);
+
+ /* compute the imaginary part */
+ if(fltA <= sfltAcross)
+ {
+ float fltImg1 = 0;
+
+ if(fltAbsReal < 1)
+ /* Am1 = 0.5d0*((y**2)/(R+(x+1.d0))+(y**2)/(S+(1.d0-x))) */
+ fltImg1 = 0.5f * (fltAbsImg*fltAbsImg / (fltR + (fltAbsReal + 1)) + fltAbsImg*fltAbsImg / (fltS + (1 - fltAbsReal)));
+ else
+ /* Am1 = 0.5d0*((y**2)/(R+(x+1.d0))+(S+(x-1.d0))) */
+ fltImg1 = 0.5f * (fltAbsImg*fltAbsImg / (fltR + (fltAbsReal + 1)) + (fltS + (fltAbsReal - 1)));
+ /* ai = logp1(Am1 + sqrt(Am1*(A+1.d0))) */
+ fltTemp = fltImg1 + ssqrts(fltImg1 *( fltA + 1));
+ _pfltImg = slog1ps(fltTemp);
+ }
+ else
+ /* ai = log(A + sqrt(A**2 - 1.d0)) */
+ _pfltImg = slogs(fltA + ssqrts(fltA*fltA - 1));
+ }
+ else
+ {/* evaluation in the special regions ... */
+ if(fltAbsImg <= fltEpsm * sabss(fltAbsReal - 1))
+ {
+ if(fltAbsReal < 1)
+ {
+ _pfltReal = sacoss(fltAbsReal);
+ _pfltImg = fltAbsImg / ssqrts((1 + fltAbsReal) * (1 - fltAbsReal));
+ }
+ else
+ {
+ _pfltReal = 0;
+ if(fltAbsReal <= fltLsup)
+ {
+ fltTemp = (fltAbsReal - 1) + ssqrts((fltAbsReal - 1) * (fltAbsReal + 1));
+ _pfltImg = slog1ps(fltTemp);
+ }
+ else
+ _pfltImg = sfltLn2 + slogs(fltAbsReal);
+ }
+ }
+ else if(fltAbsImg < fltLinf)
+ {
+ _pfltReal = ssqrts(fltAbsImg);
+ _pfltImg = _pfltReal;
+ }
+ else if((fltEpsm * fltAbsImg - 1 >= fltAbsReal))
+ {
+ _pfltReal = sfltPi_2;
+ _pfltImg = sfltLn2 + slogs(fltAbsImg);
+ }
+ else if(fltAbsReal > 1)
+ {
+ _pfltReal = satans(fltAbsImg / fltAbsReal);
+ fltTemp = (fltAbsReal / fltAbsImg)*(fltAbsReal / fltAbsImg);
+ _pfltImg = sfltLn2 + slogs(fltAbsImg) + 0.5f * slog1ps(fltTemp);
+ }
+ else
+ {
+ float fltTemp2 = ssqrts(1 + fltAbsImg*fltAbsImg);
+ _pfltReal = sfltPi_2;
+ fltTemp = 2 * fltAbsImg * (fltAbsImg + fltTemp2);
+ _pfltImg = 0.5f * slog1ps(fltTemp);
+ }
+ }
+ if(fltSignReal < 0)
+ _pfltReal = sfltPi - _pfltReal;
+
+ if(fltAbsImg != 0 || fltSignReal < 0)
+ _pfltImg = - fltSignImg * _pfltImg;
+
+ return FloatComplex(_pfltReal, _pfltImg);
+}
diff --git a/src/c/elementaryFunctions/acosd/dacosda.c b/src/c/elementaryFunctions/acosd/dacosda.c
new file mode 100644
index 00000000..2e95e9fc
--- /dev/null
+++ b/src/c/elementaryFunctions/acosd/dacosda.c
@@ -0,0 +1,22 @@
+// Copyright (C) 2017 - IIT Bombay - FOSSEE
+//
+// This file must be used under the terms of the CeCILL.
+// This source file is licensed as described in the file COPYING, which
+// you should have received as part of this distribution. The terms
+// are also available at
+// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+// Organization: FOSSEE, IIT Bombay
+// Author: Ashish Kamble
+// Email: toolbox@scilab.in
+
+#include <math.h>
+#include "acosd.h"
+
+void dacosda(double* x, int size, double* y)
+{
+ int i = 0;
+ for (i = 0; i < size; ++i)
+ {
+ y[i] = dacosds(x[i]);
+ }
+}
diff --git a/src/c/elementaryFunctions/acosd/dacosds.c b/src/c/elementaryFunctions/acosd/dacosds.c
new file mode 100644
index 00000000..8f59dab6
--- /dev/null
+++ b/src/c/elementaryFunctions/acosd/dacosds.c
@@ -0,0 +1,18 @@
+// Copyright (C) 2017 - IIT Bombay - FOSSEE
+//
+// This file must be used under the terms of the CeCILL.
+// This source file is licensed as described in the file COPYING, which
+// you should have received as part of this distribution. The terms
+// are also available at
+// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+// Organization: FOSSEE, IIT Bombay
+// Author: Ashish Kamble
+// Email: toolbox@scilab.in
+
+#include <math.h>
+#include "acosd.h"
+
+double dacosds(double x)
+{
+ return ((acos(x)*180)/3.14159265359);
+}
diff --git a/src/c/elementaryFunctions/acosd/sacosda.c b/src/c/elementaryFunctions/acosd/sacosda.c
new file mode 100644
index 00000000..440d9dc3
--- /dev/null
+++ b/src/c/elementaryFunctions/acosd/sacosda.c
@@ -0,0 +1,22 @@
+// Copyright (C) 2017 - IIT Bombay - FOSSEE
+//
+// This file must be used under the terms of the CeCILL.
+// This source file is licensed as described in the file COPYING, which
+// you should have received as part of this distribution. The terms
+// are also available at
+// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+// Organization: FOSSEE, IIT Bombay
+// Author: Ashish Kamble
+// Email: toolbox@scilab.in
+
+#include <math.h>
+#include "acosd.h"
+
+void sacosda(float* x, int size, float* y)
+{
+ int i = 0;
+ for (i = 0; i < size; ++i)
+ {
+ y[i] = sacosds(x[i]);
+ }
+}
diff --git a/src/c/elementaryFunctions/acosd/sacosds.c b/src/c/elementaryFunctions/acosd/sacosds.c
new file mode 100644
index 00000000..c166ff0e
--- /dev/null
+++ b/src/c/elementaryFunctions/acosd/sacosds.c
@@ -0,0 +1,18 @@
+// Copyright (C) 2017 - IIT Bombay - FOSSEE
+//
+// This file must be used under the terms of the CeCILL.
+// This source file is licensed as described in the file COPYING, which
+// you should have received as part of this distribution. The terms
+// are also available at
+// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+// Organization: FOSSEE, IIT Bombay
+// Author: Ashish Kamble
+// Email: toolbox@scilab.in
+
+#include <math.h>
+#include "acosd.h"
+
+double sacosds(float x)
+{
+ return ((acos(x)*180)/3.14159265359);
+}
diff --git a/src/c/elementaryFunctions/acot/cacota.c b/src/c/elementaryFunctions/acot/cacota.c
new file mode 100644
index 00000000..64e82b21
--- /dev/null
+++ b/src/c/elementaryFunctions/acot/cacota.c
@@ -0,0 +1,21 @@
+// Copyright (C) 2017 - IIT Bombay - FOSSEE
+//
+// This file must be used under the terms of the CeCILL.
+// This source file is licensed as described in the file COPYING, which
+// you should have received as part of this distribution. The terms
+// are also available at
+// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+// Organization: FOSSEE, IIT Bombay
+// Author: Ashish Kamble
+// Email: toolbox@scilab.in
+
+#include "acot.h"
+#include "floatComplex.h"
+
+void cacota(floatComplex* x, int size, floatComplex* y)
+{
+ int i = 0;
+ for (i = 0; i < size; ++i) {
+ y[i] = cacots(x[i]);
+ }
+}
diff --git a/src/c/elementaryFunctions/acot/cacots.c b/src/c/elementaryFunctions/acot/cacots.c
new file mode 100644
index 00000000..f4c6236e
--- /dev/null
+++ b/src/c/elementaryFunctions/acot/cacots.c
@@ -0,0 +1,23 @@
+// Copyright (C) 2017 - IIT Bombay - FOSSEE
+//
+// This file must be used under the terms of the CeCILL.
+// This source file is licensed as described in the file COPYING, which
+// you should have received as part of this distribution. The terms
+// are also available at
+// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+// Organization: FOSSEE, IIT Bombay
+// Author: Ashish Kamble
+// Email: toolbox@scilab.in
+
+#include <math.h>
+#include "acot.h"
+#include "division.h"
+#include "floatComplex.h"
+#include "atan.h"
+
+floatComplex cacots(floatComplex x)
+{
+ floatComplex xinv;
+ xinv = crdivs(FloatComplex(1,0),x);
+ return catans(xinv);
+}
diff --git a/src/c/elementaryFunctions/acot/dacota.c b/src/c/elementaryFunctions/acot/dacota.c
new file mode 100644
index 00000000..794d0817
--- /dev/null
+++ b/src/c/elementaryFunctions/acot/dacota.c
@@ -0,0 +1,20 @@
+// Copyright (C) 2017 - IIT Bombay - FOSSEE
+//
+// This file must be used under the terms of the CeCILL.
+// This source file is licensed as described in the file COPYING, which
+// you should have received as part of this distribution. The terms
+// are also available at
+// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+// Organization: FOSSEE, IIT Bombay
+// Author: Ashish Kamble
+// Email: toolbox@scilab.in
+
+#include "acot.h"
+
+void dacota(double* x, int size, double* y)
+{
+ int i = 0;
+ for (i = 0; i < size; ++i) {
+ y[i] = dacots(x[i]);
+ }
+}
diff --git a/src/c/elementaryFunctions/acot/dacots.c b/src/c/elementaryFunctions/acot/dacots.c
new file mode 100644
index 00000000..42ce7b57
--- /dev/null
+++ b/src/c/elementaryFunctions/acot/dacots.c
@@ -0,0 +1,18 @@
+// Copyright (C) 2017 - IIT Bombay - FOSSEE
+//
+// This file must be used under the terms of the CeCILL.
+// This source file is licensed as described in the file COPYING, which
+// you should have received as part of this distribution. The terms
+// are also available at
+// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+// Organization: FOSSEE, IIT Bombay
+// Author: Ashish Kamble
+// Email: toolbox@scilab.in
+
+#include <math.h>
+#include "acot.h"
+
+double dacots(double x)
+{
+ return ((3.14159265359/2)-atan(x));
+}
diff --git a/src/c/elementaryFunctions/acot/sacota.c b/src/c/elementaryFunctions/acot/sacota.c
new file mode 100644
index 00000000..b99a7739
--- /dev/null
+++ b/src/c/elementaryFunctions/acot/sacota.c
@@ -0,0 +1,20 @@
+// Copyright (C) 2017 - IIT Bombay - FOSSEE
+//
+// This file must be used under the terms of the CeCILL.
+// This source file is licensed as described in the file COPYING, which
+// you should have received as part of this distribution. The terms
+// are also available at
+// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+// Organization: FOSSEE, IIT Bombay
+// Author: Ashish Kamble
+// Email: toolbox@scilab.in
+
+#include "acot.h"
+
+void sacota(float* x, int size, float* y)
+{
+ int i = 0;
+ for (i = 0; i < size; ++i) {
+ y[i] = sacots(x[i]);
+ }
+}
diff --git a/src/c/elementaryFunctions/acot/sacots.c b/src/c/elementaryFunctions/acot/sacots.c
new file mode 100644
index 00000000..db6dca2f
--- /dev/null
+++ b/src/c/elementaryFunctions/acot/sacots.c
@@ -0,0 +1,18 @@
+// Copyright (C) 2017 - IIT Bombay - FOSSEE
+//
+// This file must be used under the terms of the CeCILL.
+// This source file is licensed as described in the file COPYING, which
+// you should have received as part of this distribution. The terms
+// are also available at
+// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+// Organization: FOSSEE, IIT Bombay
+// Author: Ashish Kamble
+// Email: toolbox@scilab.in
+
+#include <math.h>
+#include "acot.h"
+
+float sacots(float x)
+{
+ return ((3.14159265359/2)-atanf(x));
+}
diff --git a/src/c/elementaryFunctions/acot/zacota.c b/src/c/elementaryFunctions/acot/zacota.c
new file mode 100644
index 00000000..d08ebddd
--- /dev/null
+++ b/src/c/elementaryFunctions/acot/zacota.c
@@ -0,0 +1,21 @@
+// Copyright (C) 2017 - IIT Bombay - FOSSEE
+//
+// This file must be used under the terms of the CeCILL.
+// This source file is licensed as described in the file COPYING, which
+// you should have received as part of this distribution. The terms
+// are also available at
+// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+// Organization: FOSSEE, IIT Bombay
+// Author: Ashish Kamble
+// Email: toolbox@scilab.in
+
+#include "acot.h"
+#include "doubleComplex.h"
+
+void zacota(doubleComplex* x, int size, doubleComplex* y)
+{
+ int i = 0;
+ for (i = 0; i < size; ++i) {
+ y[i] = zacots(x[i]);
+ }
+}
diff --git a/src/c/elementaryFunctions/acot/zacots.c b/src/c/elementaryFunctions/acot/zacots.c
new file mode 100644
index 00000000..3bf99b2c
--- /dev/null
+++ b/src/c/elementaryFunctions/acot/zacots.c
@@ -0,0 +1,23 @@
+// Copyright (C) 2017 - IIT Bombay - FOSSEE
+//
+// This file must be used under the terms of the CeCILL.
+// This source file is licensed as described in the file COPYING, which
+// you should have received as part of this distribution. The terms
+// are also available at
+// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+// Organization: FOSSEE, IIT Bombay
+// Author: Ashish Kamble
+// Email: toolbox@scilab.in
+
+#include <math.h>
+#include "acot.h"
+#include "division.h"
+#include "doubleComplex.h"
+#include "atan.h"
+
+doubleComplex zacots(doubleComplex x)
+{
+ doubleComplex xinv;
+ xinv = zrdivs(DoubleComplex(1,0),x);
+ return zatans(xinv);
+}
diff --git a/src/c/elementaryFunctions/acotd/dacotda.c b/src/c/elementaryFunctions/acotd/dacotda.c
new file mode 100644
index 00000000..a2b64856
--- /dev/null
+++ b/src/c/elementaryFunctions/acotd/dacotda.c
@@ -0,0 +1,20 @@
+// Copyright (C) 2017 - IIT Bombay - FOSSEE
+//
+// This file must be used under the terms of the CeCILL.
+// This source file is licensed as described in the file COPYING, which
+// you should have received as part of this distribution. The terms
+// are also available at
+// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+// Organization: FOSSEE, IIT Bombay
+// Author: Ashish Kamble
+// Email: toolbox@scilab.in
+
+#include "acotd.h"
+
+void dacotda(double* x, int size, double* y)
+{
+ int i = 0;
+ for (i = 0; i < size; ++i) {
+ y[i] = dacotds(x[i]);
+ }
+}
diff --git a/src/c/elementaryFunctions/acotd/dacotds.c b/src/c/elementaryFunctions/acotd/dacotds.c
new file mode 100644
index 00000000..f149ac23
--- /dev/null
+++ b/src/c/elementaryFunctions/acotd/dacotds.c
@@ -0,0 +1,18 @@
+// Copyright (C) 2017 - IIT Bombay - FOSSEE
+//
+// This file must be used under the terms of the CeCILL.
+// This source file is licensed as described in the file COPYING, which
+// you should have received as part of this distribution. The terms
+// are also available at
+// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+// Organization: FOSSEE, IIT Bombay
+// Author: Ashish Kamble
+// Email: toolbox@scilab.in
+
+#include <math.h>
+#include "acotd.h"
+
+double dacotds(double x)
+{
+ return ((((3.14159265359/2)-atan(x))*180)/3.14159265359);
+}
diff --git a/src/c/elementaryFunctions/acotd/sacotda.c b/src/c/elementaryFunctions/acotd/sacotda.c
new file mode 100644
index 00000000..39503044
--- /dev/null
+++ b/src/c/elementaryFunctions/acotd/sacotda.c
@@ -0,0 +1,20 @@
+// Copyright (C) 2017 - IIT Bombay - FOSSEE
+//
+// This file must be used under the terms of the CeCILL.
+// This source file is licensed as described in the file COPYING, which
+// you should have received as part of this distribution. The terms
+// are also available at
+// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+// Organization: FOSSEE, IIT Bombay
+// Author: Ashish Kamble
+// Email: toolbox@scilab.in
+
+#include "acotd.h"
+
+void sacotda(float* x, int size, float* y)
+{
+ int i = 0;
+ for (i = 0; i < size; ++i) {
+ y[i] = sacotds(x[i]);
+ }
+}
diff --git a/src/c/elementaryFunctions/acotd/sacotds.c b/src/c/elementaryFunctions/acotd/sacotds.c
new file mode 100644
index 00000000..25797532
--- /dev/null
+++ b/src/c/elementaryFunctions/acotd/sacotds.c
@@ -0,0 +1,18 @@
+// Copyright (C) 2017 - IIT Bombay - FOSSEE
+//
+// This file must be used under the terms of the CeCILL.
+// This source file is licensed as described in the file COPYING, which
+// you should have received as part of this distribution. The terms
+// are also available at
+// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+// Organization: FOSSEE, IIT Bombay
+// Author: Ashish Kamble
+// Email: toolbox@scilab.in
+
+#include <math.h>
+#include "acotd.h"
+
+float sacotds(float x)
+{
+ return ((((3.14159265359/2)-atanf(x))*180)/3.14159265359);
+}
diff --git a/src/c/elementaryFunctions/acoth/cacotha.c b/src/c/elementaryFunctions/acoth/cacotha.c
new file mode 100644
index 00000000..f4e72dc6
--- /dev/null
+++ b/src/c/elementaryFunctions/acoth/cacotha.c
@@ -0,0 +1,22 @@
+// Copyright (C) 2017 - IIT Bombay - FOSSEE
+//
+// This file must be used under the terms of the CeCILL.
+// This source file is licensed as described in the file COPYING, which
+// you should have received as part of this distribution. The terms
+// are also available at
+// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+// Organization: FOSSEE, IIT Bombay
+// Author: Ashish Kamble
+// Email: toolbox@scilab.in
+
+#include "acoth.h"
+#include "floatComplex.h"
+
+void cacotha(floatComplex* x, int size, floatComplex* y)
+{
+ int i = 0;
+ for (i = 0; i < size; ++i)
+ {
+ y[i] = cacoths(x[i]);
+ }
+}
diff --git a/src/c/elementaryFunctions/acoth/cacoths.c b/src/c/elementaryFunctions/acoth/cacoths.c
new file mode 100644
index 00000000..658c227a
--- /dev/null
+++ b/src/c/elementaryFunctions/acoth/cacoths.c
@@ -0,0 +1,23 @@
+// Copyright (C) 2017 - IIT Bombay - FOSSEE
+//
+// This file must be used under the terms of the CeCILL.
+// This source file is licensed as described in the file COPYING, which
+// you should have received as part of this distribution. The terms
+// are also available at
+// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+// Organization: FOSSEE, IIT Bombay
+// Author: Ashish Kamble
+// Email: toolbox@scilab.in
+
+#include <math.h>
+#include "acoth.h"
+#include "division.h"
+#include "floatComplex.h"
+#include "atanh.h"
+
+floatComplex cacoths(floatComplex x)
+{
+ floatComplex xinv;
+ xinv = crdivs(FloatComplex(1,0),x);
+ return catanhs(xinv);
+}
diff --git a/src/c/elementaryFunctions/acoth/dacotha.c b/src/c/elementaryFunctions/acoth/dacotha.c
new file mode 100644
index 00000000..b97b9039
--- /dev/null
+++ b/src/c/elementaryFunctions/acoth/dacotha.c
@@ -0,0 +1,21 @@
+// Copyright (C) 2017 - IIT Bombay - FOSSEE
+//
+// This file must be used under the terms of the CeCILL.
+// This source file is licensed as described in the file COPYING, which
+// you should have received as part of this distribution. The terms
+// are also available at
+// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+// Organization: FOSSEE, IIT Bombay
+// Author: Ashish Kamble
+// Email: toolbox@scilab.in
+
+#include "acoth.h"
+
+void dacotha(double* x, int size, double* y)
+{
+ int i = 0;
+ for (i = 0; i < size; ++i)
+ {
+ y[i] = dacoths(x[i]);
+ }
+}
diff --git a/src/c/elementaryFunctions/acoth/dacoths.c b/src/c/elementaryFunctions/acoth/dacoths.c
new file mode 100644
index 00000000..a2dd8750
--- /dev/null
+++ b/src/c/elementaryFunctions/acoth/dacoths.c
@@ -0,0 +1,19 @@
+// Copyright (C) 2017 - IIT Bombay - FOSSEE
+//
+// This file must be used under the terms of the CeCILL.
+// This source file is licensed as described in the file COPYING, which
+// you should have received as part of this distribution. The terms
+// are also available at
+// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+// Organization: FOSSEE, IIT Bombay
+// Author: Ashish Kamble
+// Email: toolbox@scilab.in
+
+#include "acoth.h"
+#include "log.h"
+
+
+double dacoths(double x)
+{
+ return (log((1+x)/(x-1))/2);
+}
diff --git a/src/c/elementaryFunctions/acoth/sacotha.c b/src/c/elementaryFunctions/acoth/sacotha.c
new file mode 100644
index 00000000..383f1882
--- /dev/null
+++ b/src/c/elementaryFunctions/acoth/sacotha.c
@@ -0,0 +1,21 @@
+// Copyright (C) 2017 - IIT Bombay - FOSSEE
+//
+// This file must be used under the terms of the CeCILL.
+// This source file is licensed as described in the file COPYING, which
+// you should have received as part of this distribution. The terms
+// are also available at
+// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+// Organization: FOSSEE, IIT Bombay
+// Author: Ashish Kamble
+// Email: toolbox@scilab.in
+
+#include "acoth.h"
+
+void sacotha(float* x, int size, float* y)
+{
+ int i = 0;
+ for (i = 0; i < size; ++i)
+ {
+ y[i] = sacoths(x[i]);
+ }
+}
diff --git a/src/c/elementaryFunctions/acoth/sacoths.c b/src/c/elementaryFunctions/acoth/sacoths.c
new file mode 100644
index 00000000..12f5381d
--- /dev/null
+++ b/src/c/elementaryFunctions/acoth/sacoths.c
@@ -0,0 +1,18 @@
+// Copyright (C) 2017 - IIT Bombay - FOSSEE
+//
+// This file must be used under the terms of the CeCILL.
+// This source file is licensed as described in the file COPYING, which
+// you should have received as part of this distribution. The terms
+// are also available at
+// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+// Organization: FOSSEE, IIT Bombay
+// Author: Ashish Kamble
+// Email: toolbox@scilab.in
+
+#include "acoth.h"
+#include "log.h"
+
+float sacoths(float x)
+{
+ return (log((1+x)/(x-1))/2);
+}
diff --git a/src/c/elementaryFunctions/acoth/zacotha.c b/src/c/elementaryFunctions/acoth/zacotha.c
new file mode 100644
index 00000000..3eb335ea
--- /dev/null
+++ b/src/c/elementaryFunctions/acoth/zacotha.c
@@ -0,0 +1,21 @@
+// Copyright (C) 2017 - IIT Bombay - FOSSEE
+//
+// This file must be used under the terms of the CeCILL.
+// This source file is licensed as described in the file COPYING, which
+// you should have received as part of this distribution. The terms
+// are also available at
+// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+// Organization: FOSSEE, IIT Bombay
+// Author: Ashish Kamble
+// Email: toolbox@scilab.in
+
+#include "acoth.h"
+#include "doubleComplex.h"
+
+void zacotha(doubleComplex* x, int size, doubleComplex* y)
+{
+ int i = 0;
+ for (i = 0; i < size; ++i) {
+ y[i] = zacoths(x[i]);
+ }
+}
diff --git a/src/c/elementaryFunctions/acoth/zacoths.c b/src/c/elementaryFunctions/acoth/zacoths.c
new file mode 100644
index 00000000..bbb387b0
--- /dev/null
+++ b/src/c/elementaryFunctions/acoth/zacoths.c
@@ -0,0 +1,23 @@
+// Copyright (C) 2017 - IIT Bombay - FOSSEE
+//
+// This file must be used under the terms of the CeCILL.
+// This source file is licensed as described in the file COPYING, which
+// you should have received as part of this distribution. The terms
+// are also available at
+// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+// Organization: FOSSEE, IIT Bombay
+// Author: Ashish Kamble
+// Email: toolbox@scilab.in
+
+#include <math.h>
+#include "acoth.h"
+#include "division.h"
+#include "doubleComplex.h"
+#include "atanh.h"
+
+doubleComplex zacoths(doubleComplex x)
+{
+ doubleComplex xinv;
+ xinv = zrdivs(DoubleComplex(1,0),x);
+ return zatanhs(xinv);
+}
diff --git a/src/c/elementaryFunctions/acsc/cacsca.c b/src/c/elementaryFunctions/acsc/cacsca.c
new file mode 100644
index 00000000..0512a20f
--- /dev/null
+++ b/src/c/elementaryFunctions/acsc/cacsca.c
@@ -0,0 +1,22 @@
+// Copyright (C) 2017 - IIT Bombay - FOSSEE
+//
+// This file must be used under the terms of the CeCILL.
+// This source file is licensed as described in the file COPYING, which
+// you should have received as part of this distribution. The terms
+// are also available at
+// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+// Organization: FOSSEE, IIT Bombay
+// Author: Ashish Kamble
+// Email: toolbox@scilab.in
+#include <math.h>
+#include "acsc.h"
+#include "floatComplex.h"
+
+void cacsca(floatComplex* x, int size, floatComplex* y)
+{
+ int i = 0;
+ for (i = 0; i < size; ++i)
+ {
+ y[i] = cacscs(x[i]);
+ }
+}
diff --git a/src/c/elementaryFunctions/acsc/cacscs.c b/src/c/elementaryFunctions/acsc/cacscs.c
new file mode 100644
index 00000000..9eea94e5
--- /dev/null
+++ b/src/c/elementaryFunctions/acsc/cacscs.c
@@ -0,0 +1,22 @@
+// Copyright (C) 2017 - IIT Bombay - FOSSEE
+//
+// This file must be used under the terms of the CeCILL.
+// This source file is licensed as described in the file COPYING, which
+// you should have received as part of this distribution. The terms
+// are also available at
+// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+// Organization: FOSSEE, IIT Bombay
+// Author: Ashish Kamble
+// Email: toolbox@scilab.in
+#include <math.h>
+#include "acsc.h"
+#include "floatComplex.h"
+#include "asin.h"
+#include "division.h"
+
+floatComplex cacscs(floatComplex x)
+{
+ floatComplex xinv;
+ xinv = crdivs(FloatComplex(1,0),x);
+ return casins(xinv);
+}
diff --git a/src/c/elementaryFunctions/acsc/dacsca.c b/src/c/elementaryFunctions/acsc/dacsca.c
new file mode 100644
index 00000000..3f00d216
--- /dev/null
+++ b/src/c/elementaryFunctions/acsc/dacsca.c
@@ -0,0 +1,21 @@
+// Copyright (C) 2017 - IIT Bombay - FOSSEE
+//
+// This file must be used under the terms of the CeCILL.
+// This source file is licensed as described in the file COPYING, which
+// you should have received as part of this distribution. The terms
+// are also available at
+// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+// Organization: FOSSEE, IIT Bombay
+// Author: Ashish Kamble
+// Email: toolbox@scilab.in
+#include <math.h>
+#include "acsc.h"
+
+void dacsca(double* x, int size, double* y)
+{
+ int i = 0;
+ for (i = 0; i < size; ++i)
+ {
+ y[i] = dacscs(x[i]);
+ }
+}
diff --git a/src/c/elementaryFunctions/acsc/dacscs.c b/src/c/elementaryFunctions/acsc/dacscs.c
new file mode 100644
index 00000000..4b5ac25d
--- /dev/null
+++ b/src/c/elementaryFunctions/acsc/dacscs.c
@@ -0,0 +1,17 @@
+// Copyright (C) 2017 - IIT Bombay - FOSSEE
+//
+// This file must be used under the terms of the CeCILL.
+// This source file is licensed as described in the file COPYING, which
+// you should have received as part of this distribution. The terms
+// are also available at
+// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+// Organization: FOSSEE, IIT Bombay
+// Author: Ashish Kamble
+// Email: toolbox@scilab.in
+#include <math.h>
+#include "acsc.h"
+
+double dacscs(double x)
+{
+ return asin(1/x);
+}
diff --git a/src/c/elementaryFunctions/acsc/sacsca.c b/src/c/elementaryFunctions/acsc/sacsca.c
new file mode 100644
index 00000000..79e6bf95
--- /dev/null
+++ b/src/c/elementaryFunctions/acsc/sacsca.c
@@ -0,0 +1,21 @@
+// Copyright (C) 2017 - IIT Bombay - FOSSEE
+//
+// This file must be used under the terms of the CeCILL.
+// This source file is licensed as described in the file COPYING, which
+// you should have received as part of this distribution. The terms
+// are also available at
+// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+// Organization: FOSSEE, IIT Bombay
+// Author: Ashish Kamble
+// Email: toolbox@scilab.in
+#include <math.h>
+#include "acsc.h"
+
+void sacsca(float* x, int size, float* y)
+{
+ int i = 0;
+ for (i = 0; i < size; ++i)
+ {
+ y[i] = sacscs(x[i]);
+ }
+}
diff --git a/src/c/elementaryFunctions/acsc/sacscs.c b/src/c/elementaryFunctions/acsc/sacscs.c
new file mode 100644
index 00000000..e91fa398
--- /dev/null
+++ b/src/c/elementaryFunctions/acsc/sacscs.c
@@ -0,0 +1,17 @@
+// Copyright (C) 2017 - IIT Bombay - FOSSEE
+//
+// This file must be used under the terms of the CeCILL.
+// This source file is licensed as described in the file COPYING, which
+// you should have received as part of this distribution. The terms
+// are also available at
+// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+// Organization: FOSSEE, IIT Bombay
+// Author: Ashish Kamble
+// Email: toolbox@scilab.in
+#include <math.h>
+#include "acsc.h"
+
+float sacscs(float x)
+{
+ return asin(1/x);
+}
diff --git a/src/c/elementaryFunctions/acsc/zacsca.c b/src/c/elementaryFunctions/acsc/zacsca.c
new file mode 100644
index 00000000..164406f6
--- /dev/null
+++ b/src/c/elementaryFunctions/acsc/zacsca.c
@@ -0,0 +1,22 @@
+// Copyright (C) 2017 - IIT Bombay - FOSSEE
+//
+// This file must be used under the terms of the CeCILL.
+// This source file is licensed as described in the file COPYING, which
+// you should have received as part of this distribution. The terms
+// are also available at
+// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+// Organization: FOSSEE, IIT Bombay
+// Author: Ashish Kamble
+// Email: toolbox@scilab.in
+#include <math.h>
+#include "acsc.h"
+#include "doubleComplex.h"
+
+void zacsca(doubleComplex* x, int size, doubleComplex* y)
+{
+ int i = 0;
+ for (i = 0; i < size; ++i)
+ {
+ y[i] = zacscs(x[i]);
+ }
+}
diff --git a/src/c/elementaryFunctions/acsc/zacscs.c b/src/c/elementaryFunctions/acsc/zacscs.c
new file mode 100644
index 00000000..91bb6c8c
--- /dev/null
+++ b/src/c/elementaryFunctions/acsc/zacscs.c
@@ -0,0 +1,23 @@
+// Copyright (C) 2017 - IIT Bombay - FOSSEE
+//
+// This file must be used under the terms of the CeCILL.
+// This source file is licensed as described in the file COPYING, which
+// you should have received as part of this distribution. The terms
+// are also available at
+// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+// Organization: FOSSEE, IIT Bombay
+// Author: Ashish Kamble
+// Email: toolbox@scilab.in
+
+#include <math.h>
+#include "acsc.h"
+#include "doubleComplex.h"
+#include "division.h"
+#include "asin.h"
+
+doubleComplex zacscs(doubleComplex x)
+{
+ doubleComplex xinv;
+ xinv = zrdivs(DoubleComplex(1,0),x);
+ return zasins(xinv);
+}
diff --git a/src/c/elementaryFunctions/acscd/dacscda.c b/src/c/elementaryFunctions/acscd/dacscda.c
new file mode 100644
index 00000000..84eeaed2
--- /dev/null
+++ b/src/c/elementaryFunctions/acscd/dacscda.c
@@ -0,0 +1,21 @@
+// Copyright (C) 2017 - IIT Bombay - FOSSEE
+//
+// This file must be used under the terms of the CeCILL.
+// This source file is licensed as described in the file COPYING, which
+// you should have received as part of this distribution. The terms
+// are also available at
+// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+// Organization: FOSSEE, IIT Bombay
+// Author: Ashish Kamble
+// Email: toolbox@scilab.in
+#include <math.h>
+#include "acscd.h"
+
+void dacscda(double* x, int size, double* y)
+{
+ int i = 0;
+ for (i = 0; i < size; ++i)
+ {
+ y[i] = dacscds(x[i]);
+ }
+}
diff --git a/src/c/elementaryFunctions/acscd/dacscds.c b/src/c/elementaryFunctions/acscd/dacscds.c
new file mode 100644
index 00000000..27512ada
--- /dev/null
+++ b/src/c/elementaryFunctions/acscd/dacscds.c
@@ -0,0 +1,17 @@
+// Copyright (C) 2017 - IIT Bombay - FOSSEE
+//
+// This file must be used under the terms of the CeCILL.
+// This source file is licensed as described in the file COPYING, which
+// you should have received as part of this distribution. The terms
+// are also available at
+// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+// Organization: FOSSEE, IIT Bombay
+// Author: Ashish Kamble
+// Email: toolbox@scilab.in
+#include <math.h>
+#include "acscd.h"
+
+double dacscds(double x)
+{
+ return ((asin(1/x)*180)/3.14159265359);
+}
diff --git a/src/c/elementaryFunctions/acscd/sacscda.c b/src/c/elementaryFunctions/acscd/sacscda.c
new file mode 100644
index 00000000..a5d130cf
--- /dev/null
+++ b/src/c/elementaryFunctions/acscd/sacscda.c
@@ -0,0 +1,21 @@
+// Copyright (C) 2017 - IIT Bombay - FOSSEE
+//
+// This file must be used under the terms of the CeCILL.
+// This source file is licensed as described in the file COPYING, which
+// you should have received as part of this distribution. The terms
+// are also available at
+// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+// Organization: FOSSEE, IIT Bombay
+// Author: Ashish Kamble
+// Email: toolbox@scilab.in
+#include <math.h>
+#include "acscd.h"
+
+void sacscda(float* x, int size, float* y)
+{
+ int i = 0;
+ for (i = 0; i < size; ++i)
+ {
+ y[i] = sacscds(x[i]);
+ }
+}
diff --git a/src/c/elementaryFunctions/acscd/sacscds.c b/src/c/elementaryFunctions/acscd/sacscds.c
new file mode 100644
index 00000000..1c820c2a
--- /dev/null
+++ b/src/c/elementaryFunctions/acscd/sacscds.c
@@ -0,0 +1,17 @@
+// Copyright (C) 2017 - IIT Bombay - FOSSEE
+//
+// This file must be used under the terms of the CeCILL.
+// This source file is licensed as described in the file COPYING, which
+// you should have received as part of this distribution. The terms
+// are also available at
+// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+// Organization: FOSSEE, IIT Bombay
+// Author: Ashish Kamble
+// Email: toolbox@scilab.in
+#include <math.h>
+#include "acscd.h"
+
+float sacscds(float x)
+{
+ return ((asin(1/x)*180)/3.14159265359);
+}
diff --git a/src/c/elementaryFunctions/acsch/cacscha.c b/src/c/elementaryFunctions/acsch/cacscha.c
new file mode 100644
index 00000000..0512a20f
--- /dev/null
+++ b/src/c/elementaryFunctions/acsch/cacscha.c
@@ -0,0 +1,22 @@
+// Copyright (C) 2017 - IIT Bombay - FOSSEE
+//
+// This file must be used under the terms of the CeCILL.
+// This source file is licensed as described in the file COPYING, which
+// you should have received as part of this distribution. The terms
+// are also available at
+// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+// Organization: FOSSEE, IIT Bombay
+// Author: Ashish Kamble
+// Email: toolbox@scilab.in
+#include <math.h>
+#include "acsc.h"
+#include "floatComplex.h"
+
+void cacsca(floatComplex* x, int size, floatComplex* y)
+{
+ int i = 0;
+ for (i = 0; i < size; ++i)
+ {
+ y[i] = cacscs(x[i]);
+ }
+}
diff --git a/src/c/elementaryFunctions/acsch/cacschs.c b/src/c/elementaryFunctions/acsch/cacschs.c
new file mode 100644
index 00000000..a250b9dc
--- /dev/null
+++ b/src/c/elementaryFunctions/acsch/cacschs.c
@@ -0,0 +1,30 @@
+// Copyright (C) 2017 - IIT Bombay - FOSSEE
+//
+// This file must be used under the terms of the CeCILL.
+// This source file is licensed as described in the file COPYING, which
+// you should have received as part of this distribution. The terms
+// are also available at
+// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+// Organization: FOSSEE, IIT Bombay
+// Author: Ashish Kamble
+// Email: toolbox@scilab.in
+#include <math.h>
+#include "acsch.h"
+#include "floatComplex.h"
+#include "asin.h"
+#include "division.h"
+
+floatComplex cacschs(floatComplex x)
+{
+ floatComplex xinv;
+ floatComplex temp;
+ xinv = crdivs(FloatComplex(1,0),x);
+ temp = sqrt(1+cmuls(xinv*xinv))
+
+}
+
+
+
+
+
+log(sqrt(1+(1/(x*x)))+(1/x));
diff --git a/src/c/elementaryFunctions/acsch/dacscha.c b/src/c/elementaryFunctions/acsch/dacscha.c
new file mode 100644
index 00000000..e7177105
--- /dev/null
+++ b/src/c/elementaryFunctions/acsch/dacscha.c
@@ -0,0 +1,21 @@
+// Copyright (C) 2017 - IIT Bombay - FOSSEE
+//
+// This file must be used under the terms of the CeCILL.
+// This source file is licensed as described in the file COPYING, which
+// you should have received as part of this distribution. The terms
+// are also available at
+// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+// Organization: FOSSEE, IIT Bombay
+// Author: Ashish Kamble
+// Email: toolbox@scilab.in
+#include <math.h>
+#include "acsch.h"
+
+void dacscha(double* x, int size, double* y)
+{
+ int i = 0;
+ for (i = 0; i < size; ++i)
+ {
+ y[i] = dacschs(x[i]);
+ }
+}
diff --git a/src/c/elementaryFunctions/acsch/dacschs.c b/src/c/elementaryFunctions/acsch/dacschs.c
new file mode 100644
index 00000000..b0a32291
--- /dev/null
+++ b/src/c/elementaryFunctions/acsch/dacschs.c
@@ -0,0 +1,17 @@
+// Copyright (C) 2017 - IIT Bombay - FOSSEE
+//
+// This file must be used under the terms of the CeCILL.
+// This source file is licensed as described in the file COPYING, which
+// you should have received as part of this distribution. The terms
+// are also available at
+// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+// Organization: FOSSEE, IIT Bombay
+// Author: Ashish Kamble
+// Email: toolbox@scilab.in
+#include <math.h>
+#include "acsch.h"
+
+double dacschs(double x)
+{
+ return log(sqrt(1+(1/(x*x)))+(1/x));
+}
diff --git a/src/c/elementaryFunctions/acsch/sacscha.c b/src/c/elementaryFunctions/acsch/sacscha.c
new file mode 100644
index 00000000..c2321c6d
--- /dev/null
+++ b/src/c/elementaryFunctions/acsch/sacscha.c
@@ -0,0 +1,21 @@
+// Copyright (C) 2017 - IIT Bombay - FOSSEE
+//
+// This file must be used under the terms of the CeCILL.
+// This source file is licensed as described in the file COPYING, which
+// you should have received as part of this distribution. The terms
+// are also available at
+// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+// Organization: FOSSEE, IIT Bombay
+// Author: Ashish Kamble
+// Email: toolbox@scilab.in
+#include <math.h>
+#include "acsch.h"
+
+void sacscha(float* x, int size, float* y)
+{
+ int i = 0;
+ for (i = 0; i < size; ++i)
+ {
+ y[i] = sacschs(x[i]);
+ }
+}
diff --git a/src/c/elementaryFunctions/acsch/sacschs.c b/src/c/elementaryFunctions/acsch/sacschs.c
new file mode 100644
index 00000000..031773b9
--- /dev/null
+++ b/src/c/elementaryFunctions/acsch/sacschs.c
@@ -0,0 +1,17 @@
+// Copyright (C) 2017 - IIT Bombay - FOSSEE
+//
+// This file must be used under the terms of the CeCILL.
+// This source file is licensed as described in the file COPYING, which
+// you should have received as part of this distribution. The terms
+// are also available at
+// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+// Organization: FOSSEE, IIT Bombay
+// Author: Ashish Kamble
+// Email: toolbox@scilab.in
+#include <math.h>
+#include "acsch.h"
+
+double sacschs(float x)
+{
+ return log(sqrt(1+(1/(x*x)))+(1/x));
+}
diff --git a/src/c/elementaryFunctions/acsch/zacscha.c b/src/c/elementaryFunctions/acsch/zacscha.c
new file mode 100644
index 00000000..164406f6
--- /dev/null
+++ b/src/c/elementaryFunctions/acsch/zacscha.c
@@ -0,0 +1,22 @@
+// Copyright (C) 2017 - IIT Bombay - FOSSEE
+//
+// This file must be used under the terms of the CeCILL.
+// This source file is licensed as described in the file COPYING, which
+// you should have received as part of this distribution. The terms
+// are also available at
+// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+// Organization: FOSSEE, IIT Bombay
+// Author: Ashish Kamble
+// Email: toolbox@scilab.in
+#include <math.h>
+#include "acsc.h"
+#include "doubleComplex.h"
+
+void zacsca(doubleComplex* x, int size, doubleComplex* y)
+{
+ int i = 0;
+ for (i = 0; i < size; ++i)
+ {
+ y[i] = zacscs(x[i]);
+ }
+}
diff --git a/src/c/elementaryFunctions/acsch/zacschs.c b/src/c/elementaryFunctions/acsch/zacschs.c
new file mode 100644
index 00000000..6e33e25b
--- /dev/null
+++ b/src/c/elementaryFunctions/acsch/zacschs.c
@@ -0,0 +1,22 @@
+// Copyright (C) 2017 - IIT Bombay - FOSSEE
+//
+// This file must be used under the terms of the CeCILL.
+// This source file is licensed as described in the file COPYING, which
+// you should have received as part of this distribution. The terms
+// are also available at
+// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+// Organization: FOSSEE, IIT Bombay
+// Author: Ashish Kamble
+// Email: toolbox@scilab.in
+#include <math.h>
+#include "acsc.h"
+#include "doubleComplex.h"
+#include "division.h"
+#include "asin.h"
+
+doubleComplex zacscs(doubleComplex x)
+{
+ doubleComplex xinv;
+ xinv = zrdivs(DoubleComplex(1,0),x);
+ return zasins(xinv);
+}
diff --git a/src/c/elementaryFunctions/asec/daseca.c b/src/c/elementaryFunctions/asec/daseca.c
new file mode 100644
index 00000000..2cf1dcd8
--- /dev/null
+++ b/src/c/elementaryFunctions/asec/daseca.c
@@ -0,0 +1,21 @@
+// Copyright (C) 2017 - IIT Bombay - FOSSEE
+//
+// This file must be used under the terms of the CeCILL.
+// This source file is licensed as described in the file COPYING, which
+// you should have received as part of this distribution. The terms
+// are also available at
+// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+// Organization: FOSSEE, IIT Bombay
+// Author: Ashish Kamble
+// Email: toolbox@scilab.in
+#include <math.h>
+#include "asec.h"
+
+void daseca(double* x, int size, double* y)
+{
+ int i = 0;
+ for (i = 0; i < size; ++i)
+ {
+ y[i] = dasecs(x[i]);
+ }
+}
diff --git a/src/c/elementaryFunctions/asec/dasecs.c b/src/c/elementaryFunctions/asec/dasecs.c
new file mode 100644
index 00000000..4f2f766e
--- /dev/null
+++ b/src/c/elementaryFunctions/asec/dasecs.c
@@ -0,0 +1,17 @@
+// Copyright (C) 2017 - IIT Bombay - FOSSEE
+//
+// This file must be used under the terms of the CeCILL.
+// This source file is licensed as described in the file COPYING, which
+// you should have received as part of this distribution. The terms
+// are also available at
+// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+// Organization: FOSSEE, IIT Bombay
+// Author: Ashish Kamble
+// Email: toolbox@scilab.in
+#include <math.h>
+#include "asec.h"
+
+double dasecs(double x)
+{
+ return acos(1/x);
+}
diff --git a/src/c/elementaryFunctions/asec/saseca.c b/src/c/elementaryFunctions/asec/saseca.c
new file mode 100644
index 00000000..3b0afd84
--- /dev/null
+++ b/src/c/elementaryFunctions/asec/saseca.c
@@ -0,0 +1,21 @@
+// Copyright (C) 2017 - IIT Bombay - FOSSEE
+//
+// This file must be used under the terms of the CeCILL.
+// This source file is licensed as described in the file COPYING, which
+// you should have received as part of this distribution. The terms
+// are also available at
+// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+// Organization: FOSSEE, IIT Bombay
+// Author: Ashish Kamble
+// Email: toolbox@scilab.in
+#include <math.h>
+#include "asec.h"
+
+void saseca(float* x, int size, float* y)
+{
+ int i = 0;
+ for (i = 0; i < size; ++i)
+ {
+ y[i] = sasecs(x[i]);
+ }
+}
diff --git a/src/c/elementaryFunctions/asec/sasecs.c b/src/c/elementaryFunctions/asec/sasecs.c
new file mode 100644
index 00000000..5db46a61
--- /dev/null
+++ b/src/c/elementaryFunctions/asec/sasecs.c
@@ -0,0 +1,27 @@
+// Copyright (C) 2017 - IIT Bombay - FOSSEE
+//
+// This file must be used under the terms of the CeCILL.
+// This source file is licensed as described in the file COPYING, which
+// you should have received as part of this distribution. The terms
+// are also available at
+// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+// Organization: FOSSEE, IIT Bombay
+// Author: Ashish Kamble
+// Email: toolbox@scilab.in
+// Copyright (C) 2017 - IIT Bombay - FOSSEE
+//
+// This file must be used under the terms of the CeCILL.
+// This source file is licensed as described in the file COPYING, which
+// you should have received as part of this distribution. The terms
+// are also available at
+// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+// Organization: FOSSEE, IIT Bombay
+// Author: Ashish Kamble
+// Email: toolbox@scilab.in
+#include <math.h>
+#include "asec.h"
+
+double sasecs(float x)
+{
+ return acos(1/x);
+}
diff --git a/src/c/elementaryFunctions/asecd/dasecda.c b/src/c/elementaryFunctions/asecd/dasecda.c
new file mode 100644
index 00000000..e692762c
--- /dev/null
+++ b/src/c/elementaryFunctions/asecd/dasecda.c
@@ -0,0 +1,21 @@
+// Copyright (C) 2017 - IIT Bombay - FOSSEE
+//
+// This file must be used under the terms of the CeCILL.
+// This source file is licensed as described in the file COPYING, which
+// you should have received as part of this distribution. The terms
+// are also available at
+// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+// Organization: FOSSEE, IIT Bombay
+// Author: Ashish Kamble
+// Email: toolbox@scilab.in
+#include <math.h>
+#include "asecd.h"
+
+void dasecda(double* x, int size, double* y)
+{
+ int i = 0;
+ for (i = 0; i < size; ++i)
+ {
+ y[i] = dasecds(x[i]);
+ }
+}
diff --git a/src/c/elementaryFunctions/asecd/dasecds.c b/src/c/elementaryFunctions/asecd/dasecds.c
new file mode 100644
index 00000000..dead3189
--- /dev/null
+++ b/src/c/elementaryFunctions/asecd/dasecds.c
@@ -0,0 +1,17 @@
+// Copyright (C) 2017 - IIT Bombay - FOSSEE
+//
+// This file must be used under the terms of the CeCILL.
+// This source file is licensed as described in the file COPYING, which
+// you should have received as part of this distribution. The terms
+// are also available at
+// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+// Organization: FOSSEE, IIT Bombay
+// Author: Ashish Kamble
+// Email: toolbox@scilab.in
+#include <math.h>
+#include "asecd.h"
+
+double dasecds(double x)
+{
+ return ((acos(1/x)*180)/3.14159265359);
+}
diff --git a/src/c/elementaryFunctions/asecd/sasecda.c b/src/c/elementaryFunctions/asecd/sasecda.c
new file mode 100644
index 00000000..5c9a42fd
--- /dev/null
+++ b/src/c/elementaryFunctions/asecd/sasecda.c
@@ -0,0 +1,21 @@
+// Copyright (C) 2017 - IIT Bombay - FOSSEE
+//
+// This file must be used under the terms of the CeCILL.
+// This source file is licensed as described in the file COPYING, which
+// you should have received as part of this distribution. The terms
+// are also available at
+// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+// Organization: FOSSEE, IIT Bombay
+// Author: Ashish Kamble
+// Email: toolbox@scilab.in
+#include <math.h>
+#include "asecd.h"
+
+void sasecda(float* x, int size, float* y)
+{
+ int i = 0;
+ for (i = 0; i < size; ++i)
+ {
+ y[i] = sasecds(x[i]);
+ }
+}
diff --git a/src/c/elementaryFunctions/asecd/sasecds.c b/src/c/elementaryFunctions/asecd/sasecds.c
new file mode 100644
index 00000000..2e265178
--- /dev/null
+++ b/src/c/elementaryFunctions/asecd/sasecds.c
@@ -0,0 +1,17 @@
+// Copyright (C) 2017 - IIT Bombay - FOSSEE
+//
+// This file must be used under the terms of the CeCILL.
+// This source file is licensed as described in the file COPYING, which
+// you should have received as part of this distribution. The terms
+// are also available at
+// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+// Organization: FOSSEE, IIT Bombay
+// Author: Ashish Kamble
+// Email: toolbox@scilab.in
+#include <math.h>
+#include "asecd.h"
+
+double sasecds(float x)
+{
+ return ((acos(1/x)*180)/3.14159265359);
+}
diff --git a/src/c/elementaryFunctions/asech/dasecha.c b/src/c/elementaryFunctions/asech/dasecha.c
new file mode 100644
index 00000000..7309e3f2
--- /dev/null
+++ b/src/c/elementaryFunctions/asech/dasecha.c
@@ -0,0 +1,21 @@
+// Copyright (C) 2017 - IIT Bombay - FOSSEE
+//
+// This file must be used under the terms of the CeCILL.
+// This source file is licensed as described in the file COPYING, which
+// you should have received as part of this distribution. The terms
+// are also available at
+// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+// Organization: FOSSEE, IIT Bombay
+// Author: Ashish Kamble
+// Email: toolbox@scilab.in
+#include <math.h>
+#include "asech.h"
+
+void dasecha(double* x, int size, double* y)
+{
+ int i = 0;
+ for (i = 0; i < size; ++i)
+ {
+ y[i] = dasechs(x[i]);
+ }
+}
diff --git a/src/c/elementaryFunctions/asech/dasechs.c b/src/c/elementaryFunctions/asech/dasechs.c
new file mode 100644
index 00000000..ad5756ae
--- /dev/null
+++ b/src/c/elementaryFunctions/asech/dasechs.c
@@ -0,0 +1,18 @@
+// Copyright (C) 2017 - IIT Bombay - FOSSEE
+//
+// This file must be used under the terms of the CeCILL.
+// This source file is licensed as described in the file COPYING, which
+// you should have received as part of this distribution. The terms
+// are also available at
+// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+// Organization: FOSSEE, IIT Bombay
+// Author: Ashish Kamble
+// Email: toolbox@scilab.in
+#include <math.h>
+#include "asech.h"
+#include "log.h"
+
+double dasechs(double x)
+{
+ return log(sqrt((1/x)+1)*sqrt((1/x)-1)+(1/x));
+}
diff --git a/src/c/elementaryFunctions/asech/sasecha.c b/src/c/elementaryFunctions/asech/sasecha.c
new file mode 100644
index 00000000..f28eace6
--- /dev/null
+++ b/src/c/elementaryFunctions/asech/sasecha.c
@@ -0,0 +1,21 @@
+// Copyright (C) 2017 - IIT Bombay - FOSSEE
+//
+// This file must be used under the terms of the CeCILL.
+// This source file is licensed as described in the file COPYING, which
+// you should have received as part of this distribution. The terms
+// are also available at
+// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+// Organization: FOSSEE, IIT Bombay
+// Author: Ashish Kamble
+// Email: toolbox@scilab.in
+#include <math.h>
+#include "asech.h"
+
+void sasecha(float* x, int size, float* y)
+{
+ int i = 0;
+ for (i = 0; i < size; ++i)
+ {
+ y[i] = sasechs(x[i]);
+ }
+}
diff --git a/src/c/elementaryFunctions/asech/sasechs.c b/src/c/elementaryFunctions/asech/sasechs.c
new file mode 100644
index 00000000..b1a1cab2
--- /dev/null
+++ b/src/c/elementaryFunctions/asech/sasechs.c
@@ -0,0 +1,18 @@
+// Copyright (C) 2017 - IIT Bombay - FOSSEE
+//
+// This file must be used under the terms of the CeCILL.
+// This source file is licensed as described in the file COPYING, which
+// you should have received as part of this distribution. The terms
+// are also available at
+// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+// Organization: FOSSEE, IIT Bombay
+// Author: Ashish Kamble
+// Email: toolbox@scilab.in
+#include <math.h>
+#include "asech.h"
+#include "log.h"
+
+double sasechs(float x)
+{
+ return log(sqrt((1/x)+1)*sqrt((1/x)-1)+(1/x));
+}
diff --git a/src/c/elementaryFunctions/asind/dasinda.c b/src/c/elementaryFunctions/asind/dasinda.c
new file mode 100644
index 00000000..4c7d9af7
--- /dev/null
+++ b/src/c/elementaryFunctions/asind/dasinda.c
@@ -0,0 +1,21 @@
+// Copyright (C) 2017 - IIT Bombay - FOSSEE
+//
+// This file must be used under the terms of the CeCILL.
+// This source file is licensed as described in the file COPYING, which
+// you should have received as part of this distribution. The terms
+// are also available at
+// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+// Organization: FOSSEE, IIT Bombay
+// Author: Ashish Kamble
+// Email: toolbox@scilab.in
+
+#include "asind.h"
+
+void dasinda(double* x, int size, double* y)
+{
+ int i = 0;
+ for (i = 0; i < size; ++i)
+ {
+ y[i] = dasinds(x[i]);
+ }
+}
diff --git a/src/c/elementaryFunctions/asind/dasinds.c b/src/c/elementaryFunctions/asind/dasinds.c
new file mode 100644
index 00000000..bc028a15
--- /dev/null
+++ b/src/c/elementaryFunctions/asind/dasinds.c
@@ -0,0 +1,18 @@
+// Copyright (C) 2017 - IIT Bombay - FOSSEE
+//
+// This file must be used under the terms of the CeCILL.
+// This source file is licensed as described in the file COPYING, which
+// you should have received as part of this distribution. The terms
+// are also available at
+// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+// Organization: FOSSEE, IIT Bombay
+// Author: Ashish Kamble
+// Email: toolbox@scilab.in
+
+#include <math.h>
+#include "asind.h"
+
+double dasinds(double x)
+{
+ return ((asin(x)*180)/3.14159265359);
+}
diff --git a/src/c/elementaryFunctions/asind/sasinda.c b/src/c/elementaryFunctions/asind/sasinda.c
new file mode 100644
index 00000000..100d09cb
--- /dev/null
+++ b/src/c/elementaryFunctions/asind/sasinda.c
@@ -0,0 +1,21 @@
+// Copyright (C) 2017 - IIT Bombay - FOSSEE
+//
+// This file must be used under the terms of the CeCILL.
+// This source file is licensed as described in the file COPYING, which
+// you should have received as part of this distribution. The terms
+// are also available at
+// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+// Organization: FOSSEE, IIT Bombay
+// Author: Ashish Kamble
+// Email: toolbox@scilab.in
+
+#include "asind.h"
+
+void sasinda(float* x, int size, float* y)
+{
+ int i = 0;
+ for (i = 0; i < size; ++i)
+ {
+ y[i] = sasinds(x[i]);
+ }
+}
diff --git a/src/c/elementaryFunctions/asind/sasinds.c b/src/c/elementaryFunctions/asind/sasinds.c
new file mode 100644
index 00000000..1bbb3624
--- /dev/null
+++ b/src/c/elementaryFunctions/asind/sasinds.c
@@ -0,0 +1,18 @@
+// Copyright (C) 2017 - IIT Bombay - FOSSEE
+//
+// This file must be used under the terms of the CeCILL.
+// This source file is licensed as described in the file COPYING, which
+// you should have received as part of this distribution. The terms
+// are also available at
+// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+// Organization: FOSSEE, IIT Bombay
+// Author: Ashish Kamble
+// Email: toolbox@scilab.in
+
+#include <math.h>
+#include "asind.h"
+
+double sasinds(float x)
+{
+ return ((asin(x)*180)/3.14159265359);
+}
diff --git a/src/c/elementaryFunctions/atan/datans.c b/src/c/elementaryFunctions/atan/datans.c
index a16df82d..11785c04 100644
--- a/src/c/elementaryFunctions/atan/datans.c
+++ b/src/c/elementaryFunctions/atan/datans.c
@@ -13,6 +13,7 @@
#include <math.h>
#include "atan.h"
-double datans(double x) {
+double datans(double x)
+{
return (atan(x));
}
diff --git a/src/c/elementaryFunctions/atand/datanda.c b/src/c/elementaryFunctions/atand/datanda.c
new file mode 100644
index 00000000..5bf8cd9c
--- /dev/null
+++ b/src/c/elementaryFunctions/atand/datanda.c
@@ -0,0 +1,21 @@
+// Copyright (C) 2017 - IIT Bombay - FOSSEE
+//
+// This file must be used under the terms of the CeCILL.
+// This source file is licensed as described in the file COPYING, which
+// you should have received as part of this distribution. The terms
+// are also available at
+// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+// Organization: FOSSEE, IIT Bombay
+// Author: Ashish Kamble
+// Email: toolbox@scilab.in
+
+#include "atand.h"
+
+void datanda(double* x, int size, double* y)
+{
+ int i = 0;
+ for (i = 0; i < size; ++i)
+ {
+ y[i] = datands(x[i]);
+ }
+}
diff --git a/src/c/elementaryFunctions/atand/datands.c b/src/c/elementaryFunctions/atand/datands.c
new file mode 100644
index 00000000..8346ebe9
--- /dev/null
+++ b/src/c/elementaryFunctions/atand/datands.c
@@ -0,0 +1,18 @@
+// Copyright (C) 2017 - IIT Bombay - FOSSEE
+//
+// This file must be used under the terms of the CeCILL.
+// This source file is licensed as described in the file COPYING, which
+// you should have received as part of this distribution. The terms
+// are also available at
+// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+// Organization: FOSSEE, IIT Bombay
+// Author: Ashish Kamble
+// Email: toolbox@scilab.in
+
+#include <math.h>
+#include "atand.h"
+
+double datands(double x)
+{
+ return ((atan(x)*180)/3.14159265359);
+}
diff --git a/src/c/elementaryFunctions/atand/satanda.c b/src/c/elementaryFunctions/atand/satanda.c
new file mode 100644
index 00000000..1669d69b
--- /dev/null
+++ b/src/c/elementaryFunctions/atand/satanda.c
@@ -0,0 +1,21 @@
+// Copyright (C) 2017 - IIT Bombay - FOSSEE
+//
+// This file must be used under the terms of the CeCILL.
+// This source file is licensed as described in the file COPYING, which
+// you should have received as part of this distribution. The terms
+// are also available at
+// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+// Organization: FOSSEE, IIT Bombay
+// Author: Ashish Kamble
+// Email: toolbox@scilab.in
+
+#include "atand.h"
+
+void satanda(float* x, int size, float* y)
+{
+ int i = 0;
+ for (i = 0; i < size; ++i)
+ {
+ y[i] = satands(x[i]);
+ }
+}
diff --git a/src/c/elementaryFunctions/atand/satands.c b/src/c/elementaryFunctions/atand/satands.c
new file mode 100644
index 00000000..49ee6286
--- /dev/null
+++ b/src/c/elementaryFunctions/atand/satands.c
@@ -0,0 +1,18 @@
+// Copyright (C) 2017 - IIT Bombay - FOSSEE
+//
+// This file must be used under the terms of the CeCILL.
+// This source file is licensed as described in the file COPYING, which
+// you should have received as part of this distribution. The terms
+// are also available at
+// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+// Organization: FOSSEE, IIT Bombay
+// Author: Ashish Kamble
+// Email: toolbox@scilab.in
+
+#include <math.h>
+#include "atand.h"
+
+double satands(float x)
+{
+ return ((atan(x)*180)/3.14159265359);
+}
diff --git a/src/c/elementaryFunctions/includes/acosd.h b/src/c/elementaryFunctions/includes/acosd.h
new file mode 100644
index 00000000..96dae80a
--- /dev/null
+++ b/src/c/elementaryFunctions/includes/acosd.h
@@ -0,0 +1,33 @@
+// Copyright (C) 2017 - IIT Bombay - FOSSEE
+//
+// This file must be used under the terms of the CeCILL.
+// This source file is licensed as described in the file COPYING, which
+// you should have received as part of this distribution. The terms
+// are also available at
+// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+// Organization: FOSSEE, IIT Bombay
+// Author: Ashish Kamble
+// Email: toolbox@scilab.in
+
+#ifndef __ACOSD_H__
+#define __ACOSD_H__
+#include "types.h"
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+double dacosds(double x);
+
+void dacosda(double* x, int size, double* y);
+
+double sacosds(float x);
+
+void sacosda(float* x, int size, float* y);
+
+#ifdef __cplusplus
+} /* extern "C" */
+#endif
+
+#endif /* !__ACOSD_H__ */
+
diff --git a/src/c/elementaryFunctions/includes/acot.h b/src/c/elementaryFunctions/includes/acot.h
new file mode 100644
index 00000000..430be12d
--- /dev/null
+++ b/src/c/elementaryFunctions/includes/acot.h
@@ -0,0 +1,43 @@
+// Copyright (C) 2017 - IIT Bombay - FOSSEE
+//
+// This file must be used under the terms of the CeCILL.
+// This source file is licensed as described in the file COPYING, which
+// you should have received as part of this distribution. The terms
+// are also available at
+// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+// Organization: FOSSEE, IIT Bombay
+// Author: Ashish Kamble
+// Email: toolbox@scilab.in
+
+#ifndef __ACOT_H__
+#define __ACOT_H__
+#include "types.h"
+#include "floatComplex.h"
+#include "doubleComplex.h"
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+double dacots(double x);
+
+void dacota(double* x, int size, double* y);
+
+float sacots(float x);
+
+void sacota(float* x, int size, float* y);
+
+floatComplex cacots(floatComplex x);
+
+void cacota(floatComplex* x, int size, floatComplex* y);
+
+doubleComplex zacots(doubleComplex x);
+
+void zacota(doubleComplex* x, int size, doubleComplex* y);
+
+#ifdef __cplusplus
+} /* extern "C" */
+#endif
+
+#endif /* !__ACOT_H__ */
+
diff --git a/src/c/elementaryFunctions/includes/acotd.h b/src/c/elementaryFunctions/includes/acotd.h
new file mode 100644
index 00000000..3be05ccf
--- /dev/null
+++ b/src/c/elementaryFunctions/includes/acotd.h
@@ -0,0 +1,37 @@
+// Copyright (C) 2017 - IIT Bombay - FOSSEE
+//
+// This file must be used under the terms of the CeCILL.
+// This source file is licensed as described in the file COPYING, which
+// you should have received as part of this distribution. The terms
+// are also available at
+// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+// Organization: FOSSEE, IIT Bombay
+// Author: Ashish Kamble
+// Email: toolbox@scilab.in
+
+#ifndef __ACOTD_H__
+#define __ACOTD_H__
+#include "types.h"
+#include "floatComplex.h"
+#include "doubleComplex.h"
+
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+double dacotds(double x);
+
+void dacotda(double* x, int size, double* y);
+
+float sacotds(float x);
+
+void sacotda(float* x, int size, float* y);
+
+
+#ifdef __cplusplus
+} /* extern "C" */
+#endif
+
+#endif /* !__ACOTD_H__ */
+
diff --git a/src/c/elementaryFunctions/includes/acoth.h b/src/c/elementaryFunctions/includes/acoth.h
new file mode 100644
index 00000000..975182fe
--- /dev/null
+++ b/src/c/elementaryFunctions/includes/acoth.h
@@ -0,0 +1,44 @@
+// Copyright (C) 2017 - IIT Bombay - FOSSEE
+//
+// This file must be used under the terms of the CeCILL.
+// This source file is licensed as described in the file COPYING, which
+// you should have received as part of this distribution. The terms
+// are also available at
+// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+// Organization: FOSSEE, IIT Bombay
+// Author: Ashish Kamble
+// Email: toolbox@scilab.in
+
+#ifndef __ACOTH_H__
+#define __ACOTH_H__
+#include "types.h"
+#include "floatComplex.h"
+#include "doubleComplex.h"
+
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+double dacoths(double x);
+
+void dacotha(double* x, int size, double* y);
+
+float sacoths(float x);
+
+void sacotha(float* x, int size, float* y);
+
+floatComplex cacoths(floatComplex x);
+
+void cacotha(floatComplex* x, int size, floatComplex* y);
+
+doubleComplex zacoths(doubleComplex x);
+
+void zacotha(doubleComplex* x, int size, doubleComplex* y);
+
+#ifdef __cplusplus
+} /* extern "C" */
+#endif
+
+#endif /* !__ACOTH_H__ */
+
diff --git a/src/c/elementaryFunctions/includes/acsc.h b/src/c/elementaryFunctions/includes/acsc.h
new file mode 100644
index 00000000..be6455a4
--- /dev/null
+++ b/src/c/elementaryFunctions/includes/acsc.h
@@ -0,0 +1,44 @@
+// Copyright (C) 2017 - IIT Bombay - FOSSEE
+//
+// This file must be used under the terms of the CeCILL.
+// This source file is licensed as described in the file COPYING, which
+// you should have received as part of this distribution. The terms
+// are also available at
+// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+// Organization: FOSSEE, IIT Bombay
+// Author: Ashish Kamble
+// Email: toolbox@scilab.in
+#ifndef __ACSC_H__
+#define __ACSC_H__
+#include "types.h"
+#include "floatComplex.h"
+#include "doubleComplex.h"
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+double dacscs(double x);
+
+void dacsca(double* x, int size, double* y);
+
+float sacscs(float x);
+
+void sacsca(float* x, int size, float* y);
+
+floatComplex cacscs(floatComplex x);
+
+void cacsca(floatComplex* x, int size, floatComplex* y);
+
+doubleComplex zacscs(doubleComplex x);
+
+void zacsca(doubleComplex* x, int size, doubleComplex* y);
+
+
+
+#ifdef __cplusplus
+} /* extern "C" */
+#endif
+
+#endif /* !__ACSC_H__ */
+
diff --git a/src/c/elementaryFunctions/includes/acscd.h b/src/c/elementaryFunctions/includes/acscd.h
new file mode 100644
index 00000000..3c5bb18d
--- /dev/null
+++ b/src/c/elementaryFunctions/includes/acscd.h
@@ -0,0 +1,34 @@
+// Copyright (C) 2017 - IIT Bombay - FOSSEE
+//
+// This file must be used under the terms of the CeCILL.
+// This source file is licensed as described in the file COPYING, which
+// you should have received as part of this distribution. The terms
+// are also available at
+// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+// Organization: FOSSEE, IIT Bombay
+// Author: Ashish Kamble
+// Email: toolbox@scilab.in
+#ifndef __ACSCD_H__
+#define __ACSCD_H__
+#include "types.h"
+#include "floatComplex.h"
+#include "doubleComplex.h"
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+double dacscds(double x);
+
+void dacscda(double* x, int size, double* y);
+
+float sacscds(float x);
+
+void sacscda(float* x, int size, float* y);
+
+#ifdef __cplusplus
+} /* extern "C" */
+#endif
+
+#endif /* !__ACSCD_H__ */
+
diff --git a/src/c/elementaryFunctions/includes/acsch.h b/src/c/elementaryFunctions/includes/acsch.h
new file mode 100644
index 00000000..ba2b1e1d
--- /dev/null
+++ b/src/c/elementaryFunctions/includes/acsch.h
@@ -0,0 +1,32 @@
+// Copyright (C) 2017 - IIT Bombay - FOSSEE
+//
+// This file must be used under the terms of the CeCILL.
+// This source file is licensed as described in the file COPYING, which
+// you should have received as part of this distribution. The terms
+// are also available at
+// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+// Organization: FOSSEE, IIT Bombay
+// Author: Ashish Kamble
+// Email: toolbox@scilab.in
+#ifndef __ACSCH_H__
+#define __ACSCH_H__
+#include "types.h"
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+double dacschs(double x);
+
+void dacscha(double* x, int size, double* y);
+
+double sacschs(float x);
+
+void sacscha(float* x, int size, float* y);
+
+#ifdef __cplusplus
+} /* extern "C" */
+#endif
+
+#endif /* !__ACSCH_H__ */
+
diff --git a/src/c/elementaryFunctions/includes/asec.h b/src/c/elementaryFunctions/includes/asec.h
new file mode 100644
index 00000000..8d1a65d1
--- /dev/null
+++ b/src/c/elementaryFunctions/includes/asec.h
@@ -0,0 +1,34 @@
+// Copyright (C) 2017 - IIT Bombay - FOSSEE
+//
+// This file must be used under the terms of the CeCILL.
+// This source file is licensed as described in the file COPYING, which
+// you should have received as part of this distribution. The terms
+// are also available at
+// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+// Organization: FOSSEE, IIT Bombay
+// Author: Ashish Kamble
+// Email: toolbox@scilab.in
+
+#ifndef __ASEC_H__
+#define __ASEC_H__
+#include "types.h"
+
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+double dasecs(double x);
+
+void daseca(double* x, int size, double* y);
+
+double sasecs(float x);
+
+void saseca(float* x, int size, float* y);
+
+#ifdef __cplusplus
+} /* extern "C" */
+#endif
+
+#endif /* !__ASEC_H__ */
+
diff --git a/src/c/elementaryFunctions/includes/asecd.h b/src/c/elementaryFunctions/includes/asecd.h
new file mode 100644
index 00000000..104677bd
--- /dev/null
+++ b/src/c/elementaryFunctions/includes/asecd.h
@@ -0,0 +1,34 @@
+// Copyright (C) 2017 - IIT Bombay - FOSSEE
+//
+// This file must be used under the terms of the CeCILL.
+// This source file is licensed as described in the file COPYING, which
+// you should have received as part of this distribution. The terms
+// are also available at
+// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+// Organization: FOSSEE, IIT Bombay
+// Author: Ashish Kamble
+// Email: toolbox@scilab.in
+
+#ifndef __ASECD_H__
+#define __ASECD_H__
+#include "types.h"
+
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+double dasecds(double x);
+
+void dasecda(double* x, int size, double* y);
+
+double sasecds(float x);
+
+void sasecda(float* x, int size, float* y);
+
+#ifdef __cplusplus
+} /* extern "C" */
+#endif
+
+#endif /* !__ASECD_H__ */
+
diff --git a/src/c/elementaryFunctions/includes/asech.h b/src/c/elementaryFunctions/includes/asech.h
new file mode 100644
index 00000000..5e6c5e9c
--- /dev/null
+++ b/src/c/elementaryFunctions/includes/asech.h
@@ -0,0 +1,34 @@
+// Copyright (C) 2017 - IIT Bombay - FOSSEE
+//
+// This file must be used under the terms of the CeCILL.
+// This source file is licensed as described in the file COPYING, which
+// you should have received as part of this distribution. The terms
+// are also available at
+// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+// Organization: FOSSEE, IIT Bombay
+// Author: Ashish Kamble
+// Email: toolbox@scilab.in
+
+#ifndef __ASECH_H__
+#define __ASECH_H__
+#include "types.h"
+
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+double dasechs(double x);
+
+void dasecha(double* x, int size, double* y);
+
+double sasechs(float x);
+
+void sasecha(float* x, int size, float* y);
+
+#ifdef __cplusplus
+} /* extern "C" */
+#endif
+
+#endif /* !__ASECH_H__ */
+
diff --git a/src/c/elementaryFunctions/includes/asind.h b/src/c/elementaryFunctions/includes/asind.h
new file mode 100644
index 00000000..8f7d7102
--- /dev/null
+++ b/src/c/elementaryFunctions/includes/asind.h
@@ -0,0 +1,34 @@
+// Copyright (C) 2017 - IIT Bombay - FOSSEE
+//
+// This file must be used under the terms of the CeCILL.
+// This source file is licensed as described in the file COPYING, which
+// you should have received as part of this distribution. The terms
+// are also available at
+// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+// Organization: FOSSEE, IIT Bombay
+// Author: Ashish Kamble
+// Email: toolbox@scilab.in
+
+#ifndef __ASIND_H__
+#define __ASIND_H__
+#include "types.h"
+
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+double dasinds(double x);
+
+void dasinda(double* x, int size, double* y);
+
+double sasinds(float x);
+
+void sasinda(float* x, int size, float* y);
+
+#ifdef __cplusplus
+} /* extern "C" */
+#endif
+
+#endif /* !__ASIND_H__ */
+
diff --git a/src/c/elementaryFunctions/includes/atand.h b/src/c/elementaryFunctions/includes/atand.h
new file mode 100644
index 00000000..ed10f09f
--- /dev/null
+++ b/src/c/elementaryFunctions/includes/atand.h
@@ -0,0 +1,34 @@
+// Copyright (C) 2017 - IIT Bombay - FOSSEE
+//
+// This file must be used under the terms of the CeCILL.
+// This source file is licensed as described in the file COPYING, which
+// you should have received as part of this distribution. The terms
+// are also available at
+// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+// Organization: FOSSEE, IIT Bombay
+// Author: Ashish Kamble
+// Email: toolbox@scilab.in
+
+#ifndef __ATAND_H__
+#define __ATAND_H__
+#include "types.h"
+
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+double datands(double x);
+
+void datanda(double* x, int size, double* y);
+
+double satands(float x);
+
+void satanda(float* x, int size, float* y);
+
+#ifdef __cplusplus
+} /* extern "C" */
+#endif
+
+#endif /* !__ATAND_H__ */
+
diff --git a/src/c/elementaryFunctions/interfaces/int_acosd.h b/src/c/elementaryFunctions/interfaces/int_acosd.h
new file mode 100644
index 00000000..ee188c98
--- /dev/null
+++ b/src/c/elementaryFunctions/interfaces/int_acosd.h
@@ -0,0 +1,34 @@
+// Copyright (C) 2017 - IIT Bombay - FOSSEE
+//
+// This file must be used under the terms of the CeCILL.
+// This source file is licensed as described in the file COPYING, which
+// you should have received as part of this distribution. The terms
+// are also available at
+// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+// Organization: FOSSEE, IIT Bombay
+// Author: Ashish Kamble
+// Email: toolbox@scilab.in
+#ifndef __INT_ACOSD_H__
+#define __INT_ACOSD_H__
+
+#include "acosd.h"
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+#define d0acosdd0(in1) dacosds(in1);
+
+#define d2acosdd2(in1,in2,in3) dacosda(in1,in2[0]*in2[1],in3);
+
+#define s0acosds0(in1) sacosds(in1);
+
+#define s2acosds2(in1,in2,in3) sacosda(in1,in2[0]*in2[1],in3);
+
+
+#ifdef __cplusplus
+} /* extern "C" */
+#endif
+
+#endif /* !__ACOSD_H__ */
+
diff --git a/src/c/elementaryFunctions/interfaces/int_acot.h b/src/c/elementaryFunctions/interfaces/int_acot.h
new file mode 100644
index 00000000..371e64b5
--- /dev/null
+++ b/src/c/elementaryFunctions/interfaces/int_acot.h
@@ -0,0 +1,42 @@
+// Copyright (C) 2017 - IIT Bombay - FOSSEE
+//
+// This file must be used under the terms of the CeCILL.
+// This source file is licensed as described in the file COPYING, which
+// you should have received as part of this distribution. The terms
+// are also available at
+// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+// Organization: FOSSEE, IIT Bombay
+// Author: Ashish Kamble
+// Email: toolbox@scilab.in
+#ifndef __INT_ACOT_H__
+#define __INT_ACOT_H__
+
+#include "acot.h"
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+#define d0acotd0(in1) dacots(in1);
+
+#define d2acotd2(in1,in2,in3) dacota(in1,in2[0]*in2[1],in3);
+
+#define s0acots0(in1) sacots(in1);
+
+#define s2acots2(in1,in2,in3) sacota(in1,in2[0]*in2[1],in3);
+
+#define c0acotd0(in1) cacots(in1);
+
+#define c2acotc2(in1,in2,in3) cacota(in1,in2[0]*in2[1],in3);
+
+#define z0acotz0(in1) zacots(in1);
+
+#define z2acotz2(in1,in2,in3) zacota(in1,in2[0]*in2[1],in3);
+
+
+#ifdef __cplusplus
+} /* extern "C" */
+#endif
+
+#endif /* !__ACOT_H__ */
+
diff --git a/src/c/elementaryFunctions/interfaces/int_acotd.h b/src/c/elementaryFunctions/interfaces/int_acotd.h
new file mode 100644
index 00000000..22367bee
--- /dev/null
+++ b/src/c/elementaryFunctions/interfaces/int_acotd.h
@@ -0,0 +1,33 @@
+// Copyright (C) 2017 - IIT Bombay - FOSSEE
+//
+// This file must be used under the terms of the CeCILL.
+// This source file is licensed as described in the file COPYING, which
+// you should have received as part of this distribution. The terms
+// are also available at
+// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+// Organization: FOSSEE, IIT Bombay
+// Author: Ashish Kamble
+// Email: toolbox@scilab.in
+#ifndef __INT_ACOTD_H__
+#define __INT_ACOTD_H__
+
+#include "acotd.h"
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+#define d0acotdd0(in1) dacotds(in1);
+
+#define d2acotdd2(in1,in2,in3) dacotda(in1,in2[0]*in2[1],in3);
+
+#define s0acotds0(in1) sacotds(in1);
+
+#define s2acotds2(in1,in2,in3) sacotda(in1,in2[0]*in2[1],in3);
+
+#ifdef __cplusplus
+} /* extern "C" */
+#endif
+
+#endif /* !__ACOTD_H__ */
+
diff --git a/src/c/elementaryFunctions/interfaces/int_acoth.h b/src/c/elementaryFunctions/interfaces/int_acoth.h
new file mode 100644
index 00000000..8ec51a77
--- /dev/null
+++ b/src/c/elementaryFunctions/interfaces/int_acoth.h
@@ -0,0 +1,43 @@
+// Copyright (C) 2017 - IIT Bombay - FOSSEE
+//
+// This file must be used under the terms of the CeCILL.
+// This source file is licensed as described in the file COPYING, which
+// you should have received as part of this distribution. The terms
+// are also available at
+// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+// Organization: FOSSEE, IIT Bombay
+// Author: Ashish Kamble
+// Email: toolbox@scilab.in
+
+#ifndef __INT_ACOTH_H__
+#define __INT_ACOTH_H__
+
+#include "acoth.h"
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+#define d0acothd0(in1) dacoths(in1);
+
+#define d2acothd2(in1,in2,in3) dacotha(in1,in2[0]*in2[1],in3);
+
+#define s0acoths0(in1) sacoths(in1);
+
+#define s2acoths2(in1,in2,in3) sacotha(in1,in2[0]*in2[1],in3);
+
+#define c0acothc0(in1) cacoths(in1);
+
+#define c2acothc2(in1,in2,in3) cacotha(in1,in2[0]*in2[1],in3);
+
+#define z0acothz0(in1) zacoths(in1);
+
+#define z2acothz2(in1,in2,in3) zacotha(in1,in2[0]*in2[1],in3);
+
+
+#ifdef __cplusplus
+} /* extern "C" */
+#endif
+
+#endif /* !__ACOTH_H__ */
+
diff --git a/src/c/elementaryFunctions/interfaces/int_acsc.h b/src/c/elementaryFunctions/interfaces/int_acsc.h
new file mode 100644
index 00000000..e16f7c99
--- /dev/null
+++ b/src/c/elementaryFunctions/interfaces/int_acsc.h
@@ -0,0 +1,42 @@
+// Copyright (C) 2017 - IIT Bombay - FOSSEE
+//
+// This file must be used under the terms of the CeCILL.
+// This source file is licensed as described in the file COPYING, which
+// you should have received as part of this distribution. The terms
+// are also available at
+// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+// Organization: FOSSEE, IIT Bombay
+// Author: Ashish Kamble
+// Email: toolbox@scilab.in
+#ifndef __INT_ACSC_H__
+#define __INT_ACSC_H__
+
+#include "acsc.h"
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+#define d0acscd0(in1) dacscs(in1);
+
+#define d2acscd2(in1,in2,in3) dacsca(in1,in2[0]*in2[1],in3);
+
+#define s0acscs0(in1) sacscs(in1);
+
+#define s2acscs2(in1,in2,in3) sacsca(in1,in2[0]*in2[1],in3);
+
+#define c0acscc0(in1) cacscs(in1);
+
+#define c2acscc2(in1,in2,in3) cacsca(in1,in2[0]*in2[1],in3);
+
+#define z0acscz0(in1) zacscs(in1);
+
+#define z2acscz2(in1,in2,in3) zacsca(in1,in2[0]*in2[1],in3);
+
+
+#ifdef __cplusplus
+} /* extern "C" */
+#endif
+
+#endif /* !__ACSC_H__ */
+
diff --git a/src/c/elementaryFunctions/interfaces/int_acscd.h b/src/c/elementaryFunctions/interfaces/int_acscd.h
new file mode 100644
index 00000000..fa13acb8
--- /dev/null
+++ b/src/c/elementaryFunctions/interfaces/int_acscd.h
@@ -0,0 +1,34 @@
+// Copyright (C) 2017 - IIT Bombay - FOSSEE
+//
+// This file must be used under the terms of the CeCILL.
+// This source file is licensed as described in the file COPYING, which
+// you should have received as part of this distribution. The terms
+// are also available at
+// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+// Organization: FOSSEE, IIT Bombay
+// Author: Ashish Kamble
+// Email: toolbox@scilab.in
+#ifndef __INT_ACSCD_H__
+#define __INT_ACSCD_H__
+
+#include "acscd.h"
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+#define d0acscdd0(in1) dacscds(in1);
+
+#define d2acscdd2(in1,in2,in3) dacscda(in1,in2[0]*in2[1],in3);
+
+#define s0acscds0(in1) sacscds(in1);
+
+#define s2acscds2(in1,in2,in3) sacscda(in1,in2[0]*in2[1],in3);
+
+
+#ifdef __cplusplus
+} /* extern "C" */
+#endif
+
+#endif /* !__ACSCD_H__ */
+
diff --git a/src/c/elementaryFunctions/interfaces/int_acsch.h b/src/c/elementaryFunctions/interfaces/int_acsch.h
new file mode 100644
index 00000000..2101abe2
--- /dev/null
+++ b/src/c/elementaryFunctions/interfaces/int_acsch.h
@@ -0,0 +1,34 @@
+// Copyright (C) 2017 - IIT Bombay - FOSSEE
+//
+// This file must be used under the terms of the CeCILL.
+// This source file is licensed as described in the file COPYING, which
+// you should have received as part of this distribution. The terms
+// are also available at
+// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+// Organization: FOSSEE, IIT Bombay
+// Author: Ashish Kamble
+// Email: toolbox@scilab.in
+#ifndef __INT_ACSCH_H__
+#define __INT_ACSCH_H__
+
+#include "acsch.h"
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+#define d0acschd0(in1) dacschs(in1);
+
+#define d2acschd2(in1,in2,in3) dacscha(in1,in2[0]*in2[1],in3);
+
+#define s0acschs0(in1) sacschs(in1);
+
+#define s2acschs2(in1,in2,in3) sacscha(in1,in2[0]*in2[1],in3);
+
+
+#ifdef __cplusplus
+} /* extern "C" */
+#endif
+
+#endif /* !__ACSCH_H__ */
+
diff --git a/src/c/elementaryFunctions/interfaces/int_asec.h b/src/c/elementaryFunctions/interfaces/int_asec.h
new file mode 100644
index 00000000..25a1f111
--- /dev/null
+++ b/src/c/elementaryFunctions/interfaces/int_asec.h
@@ -0,0 +1,34 @@
+// Copyright (C) 2017 - IIT Bombay - FOSSEE
+//
+// This file must be used under the terms of the CeCILL.
+// This source file is licensed as described in the file COPYING, which
+// you should have received as part of this distribution. The terms
+// are also available at
+// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+// Organization: FOSSEE, IIT Bombay
+// Author: Ashish Kamble
+// Email: toolbox@scilab.in
+#ifndef __INT_ASEC_H__
+#define __INT_ASEC_H__
+
+#include "asec.h"
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+#define d0asecd0(in1) dasecs(in1);
+
+#define d2asecd2(in1,in2,in3) daseca(in1,in2[0]*in2[1],in3);
+
+#define s0asecs0(in1) sasecs(in1);
+
+#define s2asecs2(in1,in2,in3) saseca(in1,in2[0]*in2[1],in3);
+
+
+#ifdef __cplusplus
+} /* extern "C" */
+#endif
+
+#endif /* !__ASEC_H__ */
+
diff --git a/src/c/elementaryFunctions/interfaces/int_asecd.h b/src/c/elementaryFunctions/interfaces/int_asecd.h
new file mode 100644
index 00000000..a722b6b8
--- /dev/null
+++ b/src/c/elementaryFunctions/interfaces/int_asecd.h
@@ -0,0 +1,34 @@
+// Copyright (C) 2017 - IIT Bombay - FOSSEE
+//
+// This file must be used under the terms of the CeCILL.
+// This source file is licensed as described in the file COPYING, which
+// you should have received as part of this distribution. The terms
+// are also available at
+// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+// Organization: FOSSEE, IIT Bombay
+// Author: Ashish Kamble
+// Email: toolbox@scilab.in
+#ifndef __INT_ASECD_H__
+#define __INT_ASECD_H__
+
+#include "asecd.h"
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+#define d0asecdd0(in1) dasecds(in1);
+
+#define d2asecdd2(in1,in2,in3) dasecda(in1,in2[0]*in2[1],in3);
+
+#define s0asecds0(in1) sasecds(in1);
+
+#define s2asecds2(in1,in2,in3) sasecda(in1,in2[0]*in2[1],in3);
+
+
+#ifdef __cplusplus
+} /* extern "C" */
+#endif
+
+#endif /* !__ASECD_H__ */
+
diff --git a/src/c/elementaryFunctions/interfaces/int_asech.h b/src/c/elementaryFunctions/interfaces/int_asech.h
new file mode 100644
index 00000000..c6830f5c
--- /dev/null
+++ b/src/c/elementaryFunctions/interfaces/int_asech.h
@@ -0,0 +1,34 @@
+// Copyright (C) 2017 - IIT Bombay - FOSSEE
+//
+// This file must be used under the terms of the CeCILL.
+// This source file is licensed as described in the file COPYING, which
+// you should have received as part of this distribution. The terms
+// are also available at
+// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+// Organization: FOSSEE, IIT Bombay
+// Author: Ashish Kamble
+// Email: toolbox@scilab.in
+#ifndef __INT_ASECH_H__
+#define __INT_ASECH_H__
+
+#include "asech.h"
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+#define d0asechd0(in1) dasechs(in1);
+
+#define d2asechd2(in1,in2,in3) dasecha(in1,in2[0]*in2[1],in3);
+
+#define s0asechs0(in1) sasechs(in1);
+
+#define s2asechs2(in1,in2,in3) sasecha(in1,in2[0]*in2[1],in3);
+
+
+#ifdef __cplusplus
+} /* extern "C" */
+#endif
+
+#endif /* !__ASECH_H__ */
+
diff --git a/src/c/elementaryFunctions/interfaces/int_asind.h b/src/c/elementaryFunctions/interfaces/int_asind.h
new file mode 100644
index 00000000..fe640ea5
--- /dev/null
+++ b/src/c/elementaryFunctions/interfaces/int_asind.h
@@ -0,0 +1,34 @@
+// Copyright (C) 2017 - IIT Bombay - FOSSEE
+//
+// This file must be used under the terms of the CeCILL.
+// This source file is licensed as described in the file COPYING, which
+// you should have received as part of this distribution. The terms
+// are also available at
+// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+// Organization: FOSSEE, IIT Bombay
+// Author: Ashish Kamble
+// Email: toolbox@scilab.in
+#ifndef __INT_ASIND_H__
+#define __INT_ASIND_H__
+
+#include "asind.h"
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+#define d0asindd0(in1) dasinds(in1);
+
+#define d2asindd2(in1,in2,in3) dasinda(in1,in2[0]*in2[1],in3);
+
+#define s0asinds0(in1) sasinds(in1);
+
+#define s2asinds2(in1,in2,in3) sasinda(in1,in2[0]*in2[1],in3);
+
+
+#ifdef __cplusplus
+} /* extern "C" */
+#endif
+
+#endif /* !__ASIND_H__ */
+
diff --git a/src/c/elementaryFunctions/interfaces/int_atand.h b/src/c/elementaryFunctions/interfaces/int_atand.h
new file mode 100644
index 00000000..0adc9065
--- /dev/null
+++ b/src/c/elementaryFunctions/interfaces/int_atand.h
@@ -0,0 +1,34 @@
+// Copyright (C) 2017 - IIT Bombay - FOSSEE
+//
+// This file must be used under the terms of the CeCILL.
+// This source file is licensed as described in the file COPYING, which
+// you should have received as part of this distribution. The terms
+// are also available at
+// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+// Organization: FOSSEE, IIT Bombay
+// Author: Ashish Kamble
+// Email: toolbox@scilab.in
+#ifndef __INT_ATAND_H__
+#define __INT_ATAND_H__
+
+#include "atand.h"
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+#define d0atandd0(in1) datands(in1);
+
+#define d2atandd2(in1,in2,in3) datanda(in1,in2[0]*in2[1],in3);
+
+#define s0atands0(in1) satands(in1);
+
+#define s2atands2(in1,in2,in3) satanda(in1,in2[0]*in2[1],in3);
+
+
+#ifdef __cplusplus
+} /* extern "C" */
+#endif
+
+#endif /* !__ATAND_H__ */
+
diff --git a/src/c/elementaryFunctions/linspace/dlinspacea.c~ b/src/c/elementaryFunctions/linspace/dlinspacea.c~
deleted file mode 100644
index f67968d6..00000000
--- a/src/c/elementaryFunctions/linspace/dlinspacea.c~
+++ /dev/null
@@ -1,39 +0,0 @@
-/*
- Scilab2C FOSSEE IIT Bombay
- */
-
-#include "linspace.h"
-void dlinspacea(double *low_limit,int _row,double *up_limit,double range_num,double *out)
-{
- int i,j,k;
- double temp;
- float step_iterate[_row]; // for each row the spacing between two values is different.
- for(i=0;i<_row;i++)
- {
-
- step_iterate[i] = (up_limit[i]-low_limit[i])/(range_num-1);
-
- }
- for(j=0;j < _row;j++)
- {
- out[j] = low_limit[j]; // For every row first element is the first value of low_limit array
- temp = low_limit[j];
- for(k=1;k < (double)range_num;k++ )
- {
- out[(_row*k)+j] = temp + step_iterate[j]; /* Output matrix positions for 3 X 5 matrix are [0 3 6 9 12;1 4 7 10 13;2 5 8 11 14] so (_row*k)+j) used*/
- temp = out[(_row*k)+j];
- if(k == (double)range_num-1 )
- {
- out[(_row*k)+j] = (double)up_limit[j]; // Last value of output is equal to first value of up_limit array
- }
-
- }
-
-
- }
-
-
-
-
-}
-
diff --git a/src/c/elementaryFunctions/linspace/dlinspaces.c~ b/src/c/elementaryFunctions/linspace/dlinspaces.c~
deleted file mode 100644
index 82b88e34..00000000
--- a/src/c/elementaryFunctions/linspace/dlinspaces.c~
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- Scilab2C FOSSEE IIT Bombay
- */
-
-#include "linspace.h"
-void dlinspaces(double low_limit,double up_limit,double range_num,double *out)
-{
- int j;
- double temp = low_limit;
- float step_iterate = (up_limit-low_limit)/(range_num-1);
- out[0] = low_limit; //First value of output is equal to low_limit value
- for(j=1; j<(double)range_num; j++)
- {
- out[j] = temp + step_iterate;
- temp = out[j];
- if(j == (double)range_num-1 )
- {
- out[j] = (double)up_limit; // Last value of output is equal to up_limit value
- }
- }
-
-
-
-}
-
diff --git a/src/c/elementaryFunctions/linspace/u8linspacea.c~ b/src/c/elementaryFunctions/linspace/u8linspacea.c~
deleted file mode 100644
index 2e623fa6..00000000
--- a/src/c/elementaryFunctions/linspace/u8linspacea.c~
+++ /dev/null
@@ -1,39 +0,0 @@
-/*
- Scilab2C FOSSEE IIT Bombay
- */
-
-#include "linspace.h"
-void u8linspacea(uint8 *low_limit,int _row,uint8 *up_limit,double range_num,uint8 *out)
-{
- int i,j,k;
- uint8 temp;
- float step_iterate[_row]; // for each row the spacing between two values is different.
- for(i=0;i<_row;i++)
- {
-
- step_iterate[i] = (up_limit[i]-low_limit[i])/(range_num-1);
-
- }
- for(j=0;j < _row;j++)
- {
- out[j] = low_limit[j]; // For every row first element is the first value of low_limit array
- temp = low_limit[j];
- for(k=1;k < (double)range_num;k++ )
- {
- out[(_row*k)+j] = temp + step_iterate[j]; /* Output matrix positions for 3 X 5 matrix are [0 3 6 9 12;1 4 7 10 13;2 5 8 11 14] so (_row*k)+j) used*/
- temp = out[(_row*k)+j];
- if(k == (double)range_num-1 )
- {
- out[(_row*k)+j] = (uint8)up_limit[j]; // Last value of output is equal to first value of up_limit array
- }
-
- }
-
-
- }
-
-
-
-
-}
-
diff --git a/src/c/elementaryFunctions/linspace/u8linspaces.c~ b/src/c/elementaryFunctions/linspace/u8linspaces.c~
deleted file mode 100644
index 0320a276..00000000
--- a/src/c/elementaryFunctions/linspace/u8linspaces.c~
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- Scilab2C FOSSEE IIT Bombay
- */
-
-#include "linspace.h"
-void u8linspaces(uint8 low_limit,uint8 up_limit,double range_num,uint8 *out)
-{
- int j;
- uint8 temp = low_limit;
- float step_iterate = (up_limit-low_limit)/(range_num-1);
- out[0] = low_limit; //First value of output is equal to low_limit value
- for(j=1; j<(double)range_num; j++)
- {
- out[j] = temp + step_iterate;
- temp = out[j];
- if(j == (double)range_num-1 )
- {
- out[j] = (uint8)up_limit; // Last value of output is equal to up_limit value
- }
- }
-
-
-
-}
-