summaryrefslogtreecommitdiff
path: root/src/c/linearAlgebra/includes
diff options
context:
space:
mode:
Diffstat (limited to 'src/c/linearAlgebra/includes')
-rw-r--r--src/c/linearAlgebra/includes/balanc.h27
-rw-r--r--src/c/linearAlgebra/includes/fullrf.h26
-rw-r--r--src/c/linearAlgebra/includes/givens.h25
-rw-r--r--src/c/linearAlgebra/includes/hess.h26
-rw-r--r--src/c/linearAlgebra/includes/householder.h26
-rw-r--r--src/c/linearAlgebra/includes/lu.h33
-rw-r--r--src/c/linearAlgebra/includes/qr.h26
-rw-r--r--src/c/linearAlgebra/includes/range.h34
-rw-r--r--src/c/linearAlgebra/includes/rank.h29
-rw-r--r--src/c/linearAlgebra/includes/rcond.h26
-rw-r--r--src/c/linearAlgebra/includes/rowcomp.h26
-rw-r--r--src/c/linearAlgebra/includes/schur.h30
-rw-r--r--src/c/linearAlgebra/includes/spec.h59
-rw-r--r--src/c/linearAlgebra/includes/sqroot.h26
-rw-r--r--src/c/linearAlgebra/includes/sva.h29
-rw-r--r--src/c/linearAlgebra/includes/svd.h30
16 files changed, 478 insertions, 0 deletions
diff --git a/src/c/linearAlgebra/includes/balanc.h b/src/c/linearAlgebra/includes/balanc.h
new file mode 100644
index 00000000..dcc66b28
--- /dev/null
+++ b/src/c/linearAlgebra/includes/balanc.h
@@ -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
+ Author: Siddhesh Wani
+ Organization: FOSSEE, IIT Bombay
+ Email: toolbox@scilab.in
+ */
+#ifndef __BALANC_H__
+#define __BALANC_H__
+
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+void dbalanca(double* in1, int rows, double* in2, double* out1, \
+ double* out2, double* out3, double* out4);
+
+#ifdef __cplusplus
+} /* extern "C" */
+#endif
+
+#endif /*__BALANC_H__*/
diff --git a/src/c/linearAlgebra/includes/fullrf.h b/src/c/linearAlgebra/includes/fullrf.h
new file mode 100644
index 00000000..cc0a33d0
--- /dev/null
+++ b/src/c/linearAlgebra/includes/fullrf.h
@@ -0,0 +1,26 @@
+ /* 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
+ Author: Sandeep Gupta
+ Organization: FOSSEE, IIT Bombay
+ Email: toolbox@scilab.in
+ */
+#ifndef __FULLRF_H__
+#define __FULLRF_H__
+#include "types.h"
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+double dfullrfa(int ninp,double *in1,int row,int col,double tol,double *out1,double *out2);
+
+#ifdef __cplusplus
+} /* extern "C" */
+#endif
+
+#endif /*__FULLRF_H__*/
diff --git a/src/c/linearAlgebra/includes/givens.h b/src/c/linearAlgebra/includes/givens.h
new file mode 100644
index 00000000..4aac91b2
--- /dev/null
+++ b/src/c/linearAlgebra/includes/givens.h
@@ -0,0 +1,25 @@
+ /* 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
+ Author: Sandeep Gupta
+ Organization: FOSSEE, IIT Bombay
+ Email: toolbox@scilab.in
+ */
+#ifndef __GIVENS_H__
+#define __GIVENS_H__
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+void dgivensa(int ninp,double *inp1,int row,int col,double *inp2,int row1,int col1,int nout,double *out1,double *out2);
+
+#ifdef __cplusplus
+} /* extern "C" */
+#endif
+
+#endif /*__givens_H__*/
diff --git a/src/c/linearAlgebra/includes/hess.h b/src/c/linearAlgebra/includes/hess.h
new file mode 100644
index 00000000..b9c53ded
--- /dev/null
+++ b/src/c/linearAlgebra/includes/hess.h
@@ -0,0 +1,26 @@
+ /* 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
+ Author: Sandeep Gupta
+ Organization: FOSSEE, IIT Bombay
+ Email: toolbox@scilab.in
+ */
+#ifndef __HESS_H__
+#define __HESS_H__
+#include "types.h"
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+void dhessa(double *in1,int size,int nout,double *out1,double *out2);
+
+#ifdef __cplusplus
+} /* extern "C" */
+#endif
+
+#endif /*__HESS_H__*/
diff --git a/src/c/linearAlgebra/includes/householder.h b/src/c/linearAlgebra/includes/householder.h
new file mode 100644
index 00000000..64350a15
--- /dev/null
+++ b/src/c/linearAlgebra/includes/householder.h
@@ -0,0 +1,26 @@
+ /* 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
+ Author: Sandeep Gupta
+ Organization: FOSSEE, IIT Bombay
+ Email: toolbox@scilab.in
+ */
+#ifndef __HOUSEHOLDER_H__
+#define __HOUSEHOLDER_H__
+#include "types.h"
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+void dhouseholdera(int ninp,double *inp1,int row,double *inp2,double *out1);
+
+#ifdef __cplusplus
+} /* extern "C" */
+#endif
+
+#endif /*__HOUSEHOLDER_H__*/
diff --git a/src/c/linearAlgebra/includes/lu.h b/src/c/linearAlgebra/includes/lu.h
new file mode 100644
index 00000000..08f46637
--- /dev/null
+++ b/src/c/linearAlgebra/includes/lu.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
+ Author: Brijesh Gupta C R
+ Organization: FOSSEE, IIT Bombay
+ Email: toolbox@scilab.in
+ */
+#ifndef __LU_H__
+#define __LU_H__
+#include "types.h"
+#include "doubleComplex.h"
+#include <stdio.h>
+#include <stdlib.h>
+#include <math.h>
+#include "lapack.h"
+#include "string.h"
+#include "matrixTranspose.h"
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+void dlua(double*inp1, int size, double* out1, double* out2);
+
+#ifdef __cplusplus
+} /* extern "C" */
+#endif
+
+#endif /*__LU_H__*/
diff --git a/src/c/linearAlgebra/includes/qr.h b/src/c/linearAlgebra/includes/qr.h
new file mode 100644
index 00000000..2ed12e3a
--- /dev/null
+++ b/src/c/linearAlgebra/includes/qr.h
@@ -0,0 +1,26 @@
+ /* 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
+ Author: Sandeep Gupta
+ Organization: FOSSEE, IIT Bombay
+ Email: toolbox@scilab.in
+ */
+#ifndef __QR_H__
+#define __QR_H__
+#include "types.h"
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+double dqra(int ninp,int nout,double *inp1,int M,int N,double tol,double *out1,double *out2,double *out3);
+
+#ifdef __cplusplus
+} /* extern "C" */
+#endif
+
+#endif /*__QR_H__*/
diff --git a/src/c/linearAlgebra/includes/range.h b/src/c/linearAlgebra/includes/range.h
new file mode 100644
index 00000000..cb1d3a3e
--- /dev/null
+++ b/src/c/linearAlgebra/includes/range.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
+ Author: Brijesh Gupta C R
+ Organization: FOSSEE, IIT Bombay
+ Email: toolbox@scilab.in
+ */
+
+#ifndef __RANGE_H__
+#define __RANGE_H__
+#include "types.h"
+#include "eye.h"
+#include "rowcomp.h"
+#include "doubleComplex.h"
+#include "floatComplex.h"
+#include "matrixTranspose.h"
+#include "matrixMultiplication.h"
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+double drangea(double* inp1, int row, int col, double inp2, double* out1);
+
+
+#ifdef __cplusplus
+} /* extern "C" */
+#endif
+
+#endif /*__RANGE_H__*/
diff --git a/src/c/linearAlgebra/includes/rank.h b/src/c/linearAlgebra/includes/rank.h
new file mode 100644
index 00000000..0a21b4f8
--- /dev/null
+++ b/src/c/linearAlgebra/includes/rank.h
@@ -0,0 +1,29 @@
+ /* 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
+ Author: Abhinav Dronamraju
+ Organization: FOSSEE, IIT Bombay
+ Email: toolbox@scilab.in
+ */
+#ifndef __RANK_H__
+#define __RANK_H__
+#include "types.h"
+#include "doubleComplex.h"
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+double dranka(double* in1, int rows, int cols);
+
+doubleComplex zranka(doubleComplex* in1, int rows, int cols);
+
+#ifdef __cplusplus
+} /* extern "C" */
+#endif
+
+#endif /*__RANK_H__*/
diff --git a/src/c/linearAlgebra/includes/rcond.h b/src/c/linearAlgebra/includes/rcond.h
new file mode 100644
index 00000000..4796f029
--- /dev/null
+++ b/src/c/linearAlgebra/includes/rcond.h
@@ -0,0 +1,26 @@
+ /* 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
+ Author: Siddhesh Wani
+ Organization: FOSSEE, IIT Bombay
+ Email: toolbox@scilab.in
+ */
+#ifndef __RCOND_H__
+#define __RCOND_H__
+
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+double drconda(double* in1, int rows);
+
+#ifdef __cplusplus
+} /* extern "C" */
+#endif
+
+#endif /*__RCOND_H__*/
diff --git a/src/c/linearAlgebra/includes/rowcomp.h b/src/c/linearAlgebra/includes/rowcomp.h
new file mode 100644
index 00000000..faf5a2a7
--- /dev/null
+++ b/src/c/linearAlgebra/includes/rowcomp.h
@@ -0,0 +1,26 @@
+ /* 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
+ Author: Sandeep Gupta
+ Organization: FOSSEE, IIT Bombay
+ Email: toolbox@scilab.in
+ */
+#ifndef __ROWCOMP_H__
+#define __ROWCOMP_H__
+#include "types.h"
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+double drowcompa(int ninp,double *A,int row,int col,char *flag,double tol,double *w);
+
+#ifdef __cplusplus
+} /* extern "C" */
+#endif
+
+#endif /*__ROWCOMP_H__*/
diff --git a/src/c/linearAlgebra/includes/schur.h b/src/c/linearAlgebra/includes/schur.h
new file mode 100644
index 00000000..27b5c2aa
--- /dev/null
+++ b/src/c/linearAlgebra/includes/schur.h
@@ -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
+ Author: Siddhesh Wani
+ Organization: FOSSEE, IIT Bombay
+ Email: toolbox@scilab.in
+ */
+#ifndef __SCHUR_H__
+#define __SCHUR_H__
+
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+double dschura(double* in1, int size, int flag, int nout, double* out1, \
+ double* out2);
+
+double dgschura(double* in1, int size, double* in2, int flag, int nout, \
+ double* out1, double* out2, double* out3, double* out4);
+
+#ifdef __cplusplus
+} /* extern "C" */
+#endif
+
+#endif /*__SCHUR_H__*/
diff --git a/src/c/linearAlgebra/includes/spec.h b/src/c/linearAlgebra/includes/spec.h
new file mode 100644
index 00000000..3cd0b186
--- /dev/null
+++ b/src/c/linearAlgebra/includes/spec.h
@@ -0,0 +1,59 @@
+/*
+ * Scilab ( http://www.scilab.org/ ) - This file is part of Scilab
+ * Copyright (C) 2008 - INRIA - Arnaud TORSET
+ *
+ * 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
+ *
+ */
+
+
+#ifndef __SPEC_H__
+#define __SPEC_H__
+
+#include "dynlib_matrixoperations.h"
+#include "doubleComplex.h"
+#include "floatComplex.h"
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+/* spec gives only the eigenvalues
+ If you want the eigenvalues and the eigenvectors, use spec2 */
+
+/* spec */
+#define sspecs(in) in
+#define dspecs(in) in
+#define cspecs(in) in
+#define zspecs(in) in
+
+EXTERN_MATOPS void sspeca(float* in, int rows, float* out);
+EXTERN_MATOPS void dspeca(double* in, int rows, double* out);
+EXTERN_MATOPS void cspeca(floatComplex* in, int rows, floatComplex* out);
+EXTERN_MATOPS void zspeca(doubleComplex* in, int rows,doubleComplex* out);
+
+
+
+/* spec2 */
+#define sspec2s(in,out) sspecs(1);*out=in;
+#define dspec2s(in,out) dspecs(1);*out=in;
+#define cspec2s(in,out) cspecs(FloatComplex(1,0));*out=FloatComplex(creals(in),cimags(in));
+#define zspec2s(in,out) zspecs(DoubleComplex(1,0));*out=DoubleComplex(zreals(in),zimags(in));
+
+EXTERN_MATOPS void sspec2a(float* in, int rows, float* eigenvalues,float* eigenvectors);
+EXTERN_MATOPS void dspec2a(double* in, int rows, double* eigenvalues,double* eigenvectors);
+EXTERN_MATOPS void cspec2a(floatComplex* in, int rows, floatComplex* eigenvalues,floatComplex* eigenvectors);
+EXTERN_MATOPS void zspec2a(doubleComplex* in, int rows,doubleComplex* eigenvalues,doubleComplex* eigenvectors);
+
+/*Edited by - Sandeep Gupta, IITB FOSSEE*/
+void dspec1a(double *in1,double *in2,int size,int nout,doubleComplex *out1,double *out2,doubleComplex *out3,doubleComplex *out4);
+
+#ifdef __cplusplus
+} /* extern "C" */
+#endif
+
+#endif /* __SPEC_H__ */
diff --git a/src/c/linearAlgebra/includes/sqroot.h b/src/c/linearAlgebra/includes/sqroot.h
new file mode 100644
index 00000000..9c1d9652
--- /dev/null
+++ b/src/c/linearAlgebra/includes/sqroot.h
@@ -0,0 +1,26 @@
+ /* 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
+ Author: Sandeep Gupta
+ Organization: FOSSEE, IIT Bombay
+ Email: toolbox@scilab.in
+ */
+#ifndef __SQROOT_H__
+#define __SQROOT_H__
+#include "types.h"
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+void dsqroota(double *inp,int row,int col,double *out);
+
+#ifdef __cplusplus
+} /* extern "C" */
+#endif
+
+#endif /*__SQROOT_H__*/
diff --git a/src/c/linearAlgebra/includes/sva.h b/src/c/linearAlgebra/includes/sva.h
new file mode 100644
index 00000000..ea628a32
--- /dev/null
+++ b/src/c/linearAlgebra/includes/sva.h
@@ -0,0 +1,29 @@
+ /* 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
+ Author: Sandeep Gupta
+ Organization: FOSSEE, IIT Bombay
+ Email: toolbox@scilab.in
+ */
+
+#ifndef __SVA_H__
+#define __SVA_H__
+#include "types.h"
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+void dsvaa(int ninp,double *in1,int row,int col,double in2,double *out1, \
+ double *out2,double *out3);
+
+#ifdef __cplusplus
+} /* extern "C" */
+#endif
+
+#endif /*__SVA_H__*/
+
diff --git a/src/c/linearAlgebra/includes/svd.h b/src/c/linearAlgebra/includes/svd.h
new file mode 100644
index 00000000..dea681fc
--- /dev/null
+++ b/src/c/linearAlgebra/includes/svd.h
@@ -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
+ Author: Sandeep Gupta
+ Organization: FOSSEE, IIT Bombay
+ Email: toolbox@scilab.in
+ */
+#ifndef __SVD_H__
+#define __SVD_H__
+#include "types.h"
+#include "doubleComplex.h"
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+double dsvda(double tol,double *in1,int row,int col,double in2,double nout,double *out1, \
+ double *out2,double *out3);
+void zsvda(doubleComplex *in1,int row,int col,int in2,int nout, doubleComplex *out1,\
+ doubleComplex *out2,doubleComplex *out3);
+
+#ifdef __cplusplus
+} /* extern "C" */
+#endif
+
+#endif /*__SVD_H__*/