summaryrefslogtreecommitdiff
path: root/src/c/elementaryFunctions/pow
diff options
context:
space:
mode:
authorsiddhu89902015-11-28 11:55:38 +0530
committersiddhu89902015-11-28 11:55:38 +0530
commit28917732a0c500c5db111ed49dbd7755758f5f72 (patch)
tree1951c56a3a9971445399724bfdbbfd23987646ef /src/c/elementaryFunctions/pow
parent21f458fb84f08fa6a76d07a45a66233ceac4d531 (diff)
downloadScilab2C_fossee_old-28917732a0c500c5db111ed49dbd7755758f5f72.tar.gz
Scilab2C_fossee_old-28917732a0c500c5db111ed49dbd7755758f5f72.tar.bz2
Scilab2C_fossee_old-28917732a0c500c5db111ed49dbd7755758f5f72.zip
Merged 'master' with Mushir's work'
Diffstat (limited to 'src/c/elementaryFunctions/pow')
-rw-r--r--src/c/elementaryFunctions/pow/dpows.c~19
-rw-r--r--src/c/elementaryFunctions/pow/i16powa.c~25
-rw-r--r--src/c/elementaryFunctions/pow/i16pows.c~18
-rw-r--r--src/c/elementaryFunctions/pow/i8powa.c~25
-rw-r--r--src/c/elementaryFunctions/pow/i8pows.c~18
-rw-r--r--src/c/elementaryFunctions/pow/u16powa.c~25
-rw-r--r--src/c/elementaryFunctions/pow/u16pows.c~18
-rw-r--r--src/c/elementaryFunctions/pow/u8powa.c~25
-rw-r--r--src/c/elementaryFunctions/pow/u8pows.c~18
-rw-r--r--src/c/elementaryFunctions/pow/zpows.c~28
10 files changed, 0 insertions, 219 deletions
diff --git a/src/c/elementaryFunctions/pow/dpows.c~ b/src/c/elementaryFunctions/pow/dpows.c~
deleted file mode 100644
index cce8919..0000000
--- a/src/c/elementaryFunctions/pow/dpows.c~
+++ /dev/null
@@ -1,19 +0,0 @@
-/*
- * Scilab ( http://www.scilab.org/ ) - This file is part of Scilab
- * Copyright (C) 2006-2008 - 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
- *
- */
-
-#include <math.h>
-#include "pow.h"
-
-double dpows(double x, double p)
-{
- return pow(x, p);
-}
diff --git a/src/c/elementaryFunctions/pow/i16powa.c~ b/src/c/elementaryFunctions/pow/i16powa.c~
deleted file mode 100644
index e8e87fd..0000000
--- a/src/c/elementaryFunctions/pow/i16powa.c~
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * Scilab ( http://www.scilab.org/ ) - This file is part of Scilab
- * Copyright (C) 2006-2008 - 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
- *
- */
-
-#include "pow.h"
-
-void i16powa(int16* x, int size, int16* power, int16 *out) {
- /*
- Computes Scilab x.^power
- Computes power element by element
- x and power must have same size
- */
- int i = 0;
- for (i = 0; i < size; ++i) {
- out[i] = i16pows(x[i], power[i]);
- }
-}
diff --git a/src/c/elementaryFunctions/pow/i16pows.c~ b/src/c/elementaryFunctions/pow/i16pows.c~
deleted file mode 100644
index c8068c7..0000000
--- a/src/c/elementaryFunctions/pow/i16pows.c~
+++ /dev/null
@@ -1,18 +0,0 @@
-/*
- * Scilab ( http://www.scilab.org/ ) - This file is part of Scilab
- * Copyright (C) 2006-2008 - 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
- *
- */
-
-#include <math.h>
-#include "pow.h"
-
-int16 i16pows(int16 x, int16 p) {
- return pow(x, p);
-}
diff --git a/src/c/elementaryFunctions/pow/i8powa.c~ b/src/c/elementaryFunctions/pow/i8powa.c~
deleted file mode 100644
index e17b666..0000000
--- a/src/c/elementaryFunctions/pow/i8powa.c~
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * Scilab ( http://www.scilab.org/ ) - This file is part of Scilab
- * Copyright (C) 2006-2008 - 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
- *
- */
-
-#include "pow.h"
-
-void i8powa(int8* x, int size, int8* power, int8 *out) {
- /*
- Computes Scilab x.^power
- Computes power element by element
- x and power must have same size
- */
- int i = 0;
- for (i = 0; i < size; ++i) {
- out[i] = i8pows(x[i], power[i]);
- }
-}
diff --git a/src/c/elementaryFunctions/pow/i8pows.c~ b/src/c/elementaryFunctions/pow/i8pows.c~
deleted file mode 100644
index 3566c41..0000000
--- a/src/c/elementaryFunctions/pow/i8pows.c~
+++ /dev/null
@@ -1,18 +0,0 @@
-/*
- * Scilab ( http://www.scilab.org/ ) - This file is part of Scilab
- * Copyright (C) 2006-2008 - 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
- *
- */
-
-#include <math.h>
-#include "pow.h"
-
-int8 i8pows(int8 x, int8 p) {
- return pow(x, p);
-}
diff --git a/src/c/elementaryFunctions/pow/u16powa.c~ b/src/c/elementaryFunctions/pow/u16powa.c~
deleted file mode 100644
index 65ba77e..0000000
--- a/src/c/elementaryFunctions/pow/u16powa.c~
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * Scilab ( http://www.scilab.org/ ) - This file is part of Scilab
- * Copyright (C) 2006-2008 - 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
- *
- */
-
-#include "pow.h"
-
-void u16powa(uint16* x, int size, uint16* power, uint16 *out) {
- /*
- Computes Scilab x.^power
- Computes power element by element
- x and power must have same size
- */
- int i = 0;
- for (i = 0; i < size; ++i) {
- out[i] = u16pows(x[i], power[i]);
- }
-}
diff --git a/src/c/elementaryFunctions/pow/u16pows.c~ b/src/c/elementaryFunctions/pow/u16pows.c~
deleted file mode 100644
index 34672b0..0000000
--- a/src/c/elementaryFunctions/pow/u16pows.c~
+++ /dev/null
@@ -1,18 +0,0 @@
-/*
- * Scilab ( http://www.scilab.org/ ) - This file is part of Scilab
- * Copyright (C) 2006-2008 - 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
- *
- */
-
-#include <math.h>
-#include "pow.h"
-
-uint16 u16pows(uint16 x, uint16 p) {
- return pow(x, p);
-}
diff --git a/src/c/elementaryFunctions/pow/u8powa.c~ b/src/c/elementaryFunctions/pow/u8powa.c~
deleted file mode 100644
index b69431c..0000000
--- a/src/c/elementaryFunctions/pow/u8powa.c~
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * Scilab ( http://www.scilab.org/ ) - This file is part of Scilab
- * Copyright (C) 2006-2008 - 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
- *
- */
-
-#include "pow.h"
-
-void u8powa(uint8* x, int size, uint8* power, uint8 *out) {
- /*
- Computes Scilab x.^power
- Computes power element by element
- x and power must have same size
- */
- int i = 0;
- for (i = 0; i < size; ++i) {
- out[i] = u8pows(x[i], power[i]);
- }
-}
diff --git a/src/c/elementaryFunctions/pow/u8pows.c~ b/src/c/elementaryFunctions/pow/u8pows.c~
deleted file mode 100644
index 4b5042f..0000000
--- a/src/c/elementaryFunctions/pow/u8pows.c~
+++ /dev/null
@@ -1,18 +0,0 @@
-/*
- * Scilab ( http://www.scilab.org/ ) - This file is part of Scilab
- * Copyright (C) 2006-2008 - 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
- *
- */
-
-#include <math.h>
-#include "pow.h"
-
-uint8 u8pows(uint8 x, uint8 p) {
- return pow(x, p);
-}
diff --git a/src/c/elementaryFunctions/pow/zpows.c~ b/src/c/elementaryFunctions/pow/zpows.c~
deleted file mode 100644
index 1a7059b..0000000
--- a/src/c/elementaryFunctions/pow/zpows.c~
+++ /dev/null
@@ -1,28 +0,0 @@
-/*
- * Scilab ( http://www.scilab.org/ ) - This file is part of Scilab
- * Copyright (C) 2008-2008 - 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
- *
- */
-
-#include "pow.h"
-#include "log.h"
-#include "exp.h"
-
-doubleComplex zpows(doubleComplex z, doubleComplex power) {
- /*Cas z=0 */
- if ( (zreals(z)==0) && (zimags(z)==0) ){
- /* Cas 0^0 */
- if ( (zreals(power)==0) && (zimags(power)==0) ) return DoubleComplex(1,0);
- /* Cas 0^x, x!=0 */
- return DoubleComplex(0,0);
- }
-
- /* Cas z!=0 */
- return zexps(zmuls(zlogs(z), power));
-}