summaryrefslogtreecommitdiff
path: root/src/c/elementaryFunctions/Trigonometry/csch
diff options
context:
space:
mode:
Diffstat (limited to 'src/c/elementaryFunctions/Trigonometry/csch')
-rw-r--r--src/c/elementaryFunctions/Trigonometry/csch/ccscha.c23
-rw-r--r--src/c/elementaryFunctions/Trigonometry/csch/ccschs.c26
-rw-r--r--src/c/elementaryFunctions/Trigonometry/csch/dcscha.c20
-rw-r--r--src/c/elementaryFunctions/Trigonometry/csch/dcschs.c21
-rw-r--r--src/c/elementaryFunctions/Trigonometry/csch/scscha.c20
-rw-r--r--src/c/elementaryFunctions/Trigonometry/csch/scschs.c21
-rw-r--r--src/c/elementaryFunctions/Trigonometry/csch/zcscha.c23
-rw-r--r--src/c/elementaryFunctions/Trigonometry/csch/zcschs.c26
8 files changed, 180 insertions, 0 deletions
diff --git a/src/c/elementaryFunctions/Trigonometry/csch/ccscha.c b/src/c/elementaryFunctions/Trigonometry/csch/ccscha.c
new file mode 100644
index 0000000..a95da20
--- /dev/null
+++ b/src/c/elementaryFunctions/Trigonometry/csch/ccscha.c
@@ -0,0 +1,23 @@
+/* Copyright (C) 2016 - 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
+ Author: Shamik Guha
+ Organization: FOSSEE, IIT Bombay
+ Email: toolbox@scilab.in
+*/
+
+#include "csch.h"
+#include <math.h>
+
+void ccscha(floatComplex* in, int size,floatComplex* out)
+{
+ int i = 0;
+ for (i=0;i<size;i++)
+ {
+ out[i] = ccschs(in[i]);
+ }
+}
diff --git a/src/c/elementaryFunctions/Trigonometry/csch/ccschs.c b/src/c/elementaryFunctions/Trigonometry/csch/ccschs.c
new file mode 100644
index 0000000..ddcc733
--- /dev/null
+++ b/src/c/elementaryFunctions/Trigonometry/csch/ccschs.c
@@ -0,0 +1,26 @@
+/* Copyright (C) 2016 - 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
+ Author: Shamik Guha
+ Organization: FOSSEE, IIT Bombay
+ Email: toolbox@scilab.in
+*/
+
+#include "csch.h"
+#include "sinh.h"
+#include "sin.h"
+#include <math.h>
+#include "floatComplex.h"
+#include "division.h"
+
+floatComplex ccschs(floatComplex z)
+{
+
+ floatComplex out;
+ out = crdivs(FloatComplex(1,0),csinhs(z));
+ return out;
+}
diff --git a/src/c/elementaryFunctions/Trigonometry/csch/dcscha.c b/src/c/elementaryFunctions/Trigonometry/csch/dcscha.c
new file mode 100644
index 0000000..3248905
--- /dev/null
+++ b/src/c/elementaryFunctions/Trigonometry/csch/dcscha.c
@@ -0,0 +1,20 @@
+/* Copyright (C) 2016 - 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
+ Author: Shamik Guha
+ Organization: FOSSEE, IIT Bombay
+ Email: toolbox@scilab.in
+*/
+
+#include "csch.h"
+
+void dcscha(double* in, int size, double* out) {
+ int i = 0;
+ for (i = 0; i < size; ++i) {
+ out[i] = dcschs(in[i]);
+ }
+}
diff --git a/src/c/elementaryFunctions/Trigonometry/csch/dcschs.c b/src/c/elementaryFunctions/Trigonometry/csch/dcschs.c
new file mode 100644
index 0000000..7b1f15a
--- /dev/null
+++ b/src/c/elementaryFunctions/Trigonometry/csch/dcschs.c
@@ -0,0 +1,21 @@
+/* Copyright (C) 2016 - 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
+ Author: Shamik Guha
+ Organization: FOSSEE, IIT Bombay
+ Email: toolbox@scilab.in
+*/
+
+#include "csch.h"
+#include <math.h>
+
+double dcschs(double in)
+{
+ double out;
+ out=1/sinh(in);
+ return out;
+}
diff --git a/src/c/elementaryFunctions/Trigonometry/csch/scscha.c b/src/c/elementaryFunctions/Trigonometry/csch/scscha.c
new file mode 100644
index 0000000..18d5ea7
--- /dev/null
+++ b/src/c/elementaryFunctions/Trigonometry/csch/scscha.c
@@ -0,0 +1,20 @@
+/* Copyright (C) 2016 - 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
+ Author: Shamik Guha
+ Organization: FOSSEE, IIT Bombay
+ Email: toolbox@scilab.in
+*/
+
+#include "csch.h"
+
+void scscha(float* in, int size, float* out) {
+ int i = 0;
+ for (i = 0; i < size; ++i) {
+ out[i] = scschs(in[i]);
+ }
+}
diff --git a/src/c/elementaryFunctions/Trigonometry/csch/scschs.c b/src/c/elementaryFunctions/Trigonometry/csch/scschs.c
new file mode 100644
index 0000000..ec55085
--- /dev/null
+++ b/src/c/elementaryFunctions/Trigonometry/csch/scschs.c
@@ -0,0 +1,21 @@
+/* Copyright (C) 2016 - 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
+ Author: Shamik Guha
+ Organization: FOSSEE, IIT Bombay
+ Email: toolbox@scilab.in
+*/
+
+#include "csch.h"
+#include <math.h>
+
+float scschs(float in)
+{
+ float out;
+ out=1/sinh(in);
+ return out;
+}
diff --git a/src/c/elementaryFunctions/Trigonometry/csch/zcscha.c b/src/c/elementaryFunctions/Trigonometry/csch/zcscha.c
new file mode 100644
index 0000000..fab5cc4
--- /dev/null
+++ b/src/c/elementaryFunctions/Trigonometry/csch/zcscha.c
@@ -0,0 +1,23 @@
+/* Copyright (C) 2016 - 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
+ Author: Shamik Guha
+ Organization: FOSSEE, IIT Bombay
+ Email: toolbox@scilab.in
+*/
+
+#include "csch.h"
+#include <math.h>
+
+void zcscha(doubleComplex* in, int size,doubleComplex* out)
+{
+ int i = 0;
+ for (i=0;i<size;i++)
+ {
+ out[i] = zcschs(in[i]);
+ }
+}
diff --git a/src/c/elementaryFunctions/Trigonometry/csch/zcschs.c b/src/c/elementaryFunctions/Trigonometry/csch/zcschs.c
new file mode 100644
index 0000000..33a4fcc
--- /dev/null
+++ b/src/c/elementaryFunctions/Trigonometry/csch/zcschs.c
@@ -0,0 +1,26 @@
+/* Copyright (C) 2016 - 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
+ Author: Shamik Guha
+ Organization: FOSSEE, IIT Bombay
+ Email: toolbox@scilab.in
+*/
+
+#include "csch.h"
+#include "sinh.h"
+#include "sin.h"
+#include <math.h>
+#include "doubleComplex.h"
+#include "division.h"
+
+doubleComplex zcschs(doubleComplex z)
+{
+
+ doubleComplex out;
+ out = zrdivs(DoubleComplex(1,0),zsinhs(z));
+ return out;
+}