summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorjofret2009-06-05 15:31:48 +0000
committerjofret2009-06-05 15:31:48 +0000
commit74ee91efdd1d12cb6e224ecc87f0cc51a51bcbc1 (patch)
tree484736de55d5ce87a2503cb7024c1835f8073766 /src
parent462563271edd528e1785ed30beff1683f1859ac2 (diff)
downloadscilab2c-74ee91efdd1d12cb6e224ecc87f0cc51a51bcbc1.tar.gz
scilab2c-74ee91efdd1d12cb6e224ecc87f0cc51a51bcbc1.tar.bz2
scilab2c-74ee91efdd1d12cb6e224ecc87f0cc51a51bcbc1.zip
Enable order comparison
Diffstat (limited to 'src')
-rw-r--r--src/c/operations/interfaces/int_OpLogGe.h50
-rw-r--r--src/c/operations/interfaces/int_OpLogGt.h50
-rw-r--r--src/c/operations/interfaces/int_OpLogLe.h50
-rw-r--r--src/c/operations/interfaces/int_OpLogLt.h50
4 files changed, 200 insertions, 0 deletions
diff --git a/src/c/operations/interfaces/int_OpLogGe.h b/src/c/operations/interfaces/int_OpLogGe.h
new file mode 100644
index 00000000..0ce1ad81
--- /dev/null
+++ b/src/c/operations/interfaces/int_OpLogGe.h
@@ -0,0 +1,50 @@
+/*
+ * Scilab ( http://www.scilab.org/ ) - This file is part of Scilab
+ * Copyright (C) 2006-2007 - INRIA - Bruno JOFRET
+ *
+ * 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
+ *
+ */
+
+/*
+ Update 23/02/09 by Arnaud Torset : Add matrix comparaison, remove include(floatComplex and doubleComplex)
+*/
+
+#ifndef __OPLOGGE_H__
+#define __OPLOGGE_H__
+
+
+#define s0s0OpLogGes0(in1,in2) (float) (in1 >= in2)
+#define d0d0OpLogGed0(in1,in2) (double) (in1 >= in2)
+
+
+#define s2s0OpLogGes2(in1, size1, in2, out) {int i;\
+ for(i = 0 ; i < size1[0] * size1[1] ; ++i) out[i] = s0s0OpLogGes0(in1[i],in2);\
+ }
+
+#define s0s2OpLogGes2(in1, in2, size2, out) {int i; \
+ for(i = 0 ; i < size2[0] * size2[1] ; ++i) out[i] = s0s0OpLogGes0(in1,in2[i]);\
+ }
+
+/* we must have size1=size2 */
+#define s2s2OpLogGes2(in1, size1, in2, size2, out) {int i; \
+ for(i = 0 ; i < size1[0] * size1[1] ; ++i) out[i] = s0s0OpLogGes0(in1[i],in2[i]);\
+ }
+
+#define d2d0OpLogGed2(in1, size1, in2, out) {int i;\
+ for(i = 0 ; i < size1[0] * size1[1] ; ++i) out[i] = d0d0OpLogGed0(in1[i],in2);\
+ }
+
+#define d0d2OpLogGed2(in1, in2, size2, out) {int i; \
+ for(i = 0 ; i < size2[0] * size2[1] ; ++i) out[i] = d0d0OpLogGed0(in1,in2[i]);\
+ }
+
+/* we must have size1=size2 */
+#define d2d2OpLogGed2(in1, size1, in2, size2, out) {int i; \
+ for(i = 0 ; i < size1[0] * size1[1] ; ++i) out[i] = d0d0OpLogGed0(in1[i],in2[i]);\
+ }
+#endif /* !__OPLOGGE_H__ */
diff --git a/src/c/operations/interfaces/int_OpLogGt.h b/src/c/operations/interfaces/int_OpLogGt.h
new file mode 100644
index 00000000..161b654f
--- /dev/null
+++ b/src/c/operations/interfaces/int_OpLogGt.h
@@ -0,0 +1,50 @@
+/*
+ * Scilab ( http://www.scilab.org/ ) - This file is part of Scilab
+ * Copyright (C) 2006-2007 - INRIA - Bruno JOFRET
+ *
+ * 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
+ *
+ */
+
+/*
+ Update 23/02/09 by Arnaud Torset : Add matrix comparaison, remove include(floatComplex and doubleComplex)
+*/
+
+#ifndef __OPLOGGT_H__
+#define __OPLOGGT_H__
+
+
+#define s0s0OpLogGts0(in1,in2) (float) (in1 > in2)
+#define d0d0OpLogGtd0(in1,in2) (double) (in1 > in2)
+
+
+#define s2s0OpLogGts2(in1, size1, in2, out) {int i;\
+ for(i = 0 ; i < size1[0] * size1[1] ; ++i) out[i] = s0s0OpLogGts0(in1[i],in2);\
+ }
+
+#define s0s2OpLogGts2(in1, in2, size2, out) {int i; \
+ for(i = 0 ; i < size2[0] * size2[1] ; ++i) out[i] = s0s0OpLogGts0(in1,in2[i]);\
+ }
+
+/* we must have size1=size2 */
+#define s2s2OpLogGts2(in1, size1, in2, size2, out) {int i; \
+ for(i = 0 ; i < size1[0] * size1[1] ; ++i) out[i] = s0s0OpLogGts0(in1[i],in2[i]);\
+ }
+
+#define d2d0OpLogGtd2(in1, size1, in2, out) {int i;\
+ for(i = 0 ; i < size1[0] * size1[1] ; ++i) out[i] = d0d0OpLogGtd0(in1[i],in2);\
+ }
+
+#define d0d2OpLogGtd2(in1, in2, size2, out) {int i; \
+ for(i = 0 ; i < size2[0] * size2[1] ; ++i) out[i] = d0d0OpLogGtd0(in1,in2[i]);\
+ }
+
+/* we must have size1=size2 */
+#define d2d2OpLogGtd2(in1, size1, in2, size2, out) {int i; \
+ for(i = 0 ; i < size1[0] * size1[1] ; ++i) out[i] = d0d0OpLogGtd0(in1[i],in2[i]);\
+ }
+#endif /* !__OPLOGGT_H__ */
diff --git a/src/c/operations/interfaces/int_OpLogLe.h b/src/c/operations/interfaces/int_OpLogLe.h
new file mode 100644
index 00000000..ebb09c7b
--- /dev/null
+++ b/src/c/operations/interfaces/int_OpLogLe.h
@@ -0,0 +1,50 @@
+/*
+ * Scilab ( http://www.scilab.org/ ) - This file is part of Scilab
+ * Copyright (C) 2006-2007 - INRIA - Bruno JOFRET
+ *
+ * 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
+ *
+ */
+
+/*
+ Update 23/02/09 by Arnaud Torset : Add matrix comparaison, remove include(floatComplex and doubleComplex)
+*/
+
+#ifndef __OPLOGLE_H__
+#define __OPLOGLE_H__
+
+
+#define s0s0OpLogLes0(in1,in2) (float) (in1 <= in2)
+#define d0d0OpLogLed0(in1,in2) (double) (in1 <= in2)
+
+
+#define s2s0OpLogLes2(in1, size1, in2, out) {int i;\
+ for(i = 0 ; i < size1[0] * size1[1] ; ++i) out[i] = s0s0OpLogLes0(in1[i],in2);\
+ }
+
+#define s0s2OpLogLes2(in1, in2, size2, out) {int i; \
+ for(i = 0 ; i < size2[0] * size2[1] ; ++i) out[i] = s0s0OpLogLes0(in1,in2[i]);\
+ }
+
+/* we must have size1=size2 */
+#define s2s2OpLogLes2(in1, size1, in2, size2, out) {int i; \
+ for(i = 0 ; i < size1[0] * size1[1] ; ++i) out[i] = s0s0OpLogLes0(in1[i],in2[i]);\
+ }
+
+#define d2d0OpLogLed2(in1, size1, in2, out) {int i;\
+ for(i = 0 ; i < size1[0] * size1[1] ; ++i) out[i] = d0d0OpLogLed0(in1[i],in2);\
+ }
+
+#define d0d2OpLogLed2(in1, in2, size2, out) {int i; \
+ for(i = 0 ; i < size2[0] * size2[1] ; ++i) out[i] = d0d0OpLogLed0(in1,in2[i]);\
+ }
+
+/* we must have size1=size2 */
+#define d2d2OpLogLed2(in1, size1, in2, size2, out) {int i; \
+ for(i = 0 ; i < size1[0] * size1[1] ; ++i) out[i] = d0d0OpLogLed0(in1[i],in2[i]);\
+ }
+#endif /* !__OPLOGLE_H__ */
diff --git a/src/c/operations/interfaces/int_OpLogLt.h b/src/c/operations/interfaces/int_OpLogLt.h
new file mode 100644
index 00000000..2c5d8639
--- /dev/null
+++ b/src/c/operations/interfaces/int_OpLogLt.h
@@ -0,0 +1,50 @@
+/*
+ * Scilab ( http://www.scilab.org/ ) - This file is part of Scilab
+ * Copyright (C) 2006-2007 - INRIA - Bruno JOFRET
+ *
+ * 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
+ *
+ */
+
+/*
+ Update 23/02/09 by Arnaud Torset : Add matrix comparaison, remove include(floatComplex and doubleComplex)
+*/
+
+#ifndef __OPLOGLT_H__
+#define __OPLOGLT_H__
+
+
+#define s0s0OpLogLts0(in1,in2) (float) (in1 < in2)
+#define d0d0OpLogLtd0(in1,in2) (double) (in1 < in2)
+
+
+#define s2s0OpLogLts2(in1, size1, in2, out) {int i;\
+ for(i = 0 ; i < size1[0] * size1[1] ; ++i) out[i] = s0s0OpLogLts0(in1[i],in2);\
+ }
+
+#define s0s2OpLogLts2(in1, in2, size2, out) {int i; \
+ for(i = 0 ; i < size2[0] * size2[1] ; ++i) out[i] = s0s0OpLogLts0(in1,in2[i]);\
+ }
+
+/* we must have size1=size2 */
+#define s2s2OpLogLts2(in1, size1, in2, size2, out) {int i; \
+ for(i = 0 ; i < size1[0] * size1[1] ; ++i) out[i] = s0s0OpLogLts0(in1[i],in2[i]);\
+ }
+
+#define d2d0OpLogLtd2(in1, size1, in2, out) {int i;\
+ for(i = 0 ; i < size1[0] * size1[1] ; ++i) out[i] = d0d0OpLogLtd0(in1[i],in2);\
+ }
+
+#define d0d2OpLogLtd2(in1, in2, size2, out) {int i; \
+ for(i = 0 ; i < size2[0] * size2[1] ; ++i) out[i] = d0d0OpLogLtd0(in1,in2[i]);\
+ }
+
+/* we must have size1=size2 */
+#define d2d2OpLogLtd2(in1, size1, in2, size2, out) {int i; \
+ for(i = 0 ; i < size1[0] * size1[1] ; ++i) out[i] = d0d0OpLogLtd0(in1[i],in2[i]);\
+ }
+#endif /* !__OPLOGLT_H__ */