summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorjofret2008-04-21 08:32:37 +0000
committerjofret2008-04-21 08:32:37 +0000
commitac3ff3769d4abdc84c9bbf507fdafa3dbc137293 (patch)
tree7ca80bef612178c18fd7cd057e781ba6889f5d30
parent68eb0059d5b46791326e4e7625604da189b86e3d (diff)
downloadscilab2c-ac3ff3769d4abdc84c9bbf507fdafa3dbc137293.tar.gz
scilab2c-ac3ff3769d4abdc84c9bbf507fdafa3dbc137293.tar.bz2
scilab2c-ac3ff3769d4abdc84c9bbf507fdafa3dbc137293.zip
Double vs Float better management. Enable psycho warnings.
-rw-r--r--src/elementaryFunctions/atanh/Makefile.am24
-rw-r--r--src/elementaryFunctions/atanh/Makefile.in92
-rw-r--r--src/elementaryFunctions/atanh/catanhs.c26
-rw-r--r--src/elementaryFunctions/atanh/satanhs.c22
-rw-r--r--src/elementaryFunctions/atanh/testAtanh.c64
-rw-r--r--src/elementaryFunctions/atanh/testDoubleAtanh.c45
-rw-r--r--src/elementaryFunctions/atanh/testFloatAtanh.c45
-rw-r--r--src/elementaryFunctions/atanh/zatanhs.c22
8 files changed, 200 insertions, 140 deletions
diff --git a/src/elementaryFunctions/atanh/Makefile.am b/src/elementaryFunctions/atanh/Makefile.am
index b3172777..df8d31a3 100644
--- a/src/elementaryFunctions/atanh/Makefile.am
+++ b/src/elementaryFunctions/atanh/Makefile.am
@@ -37,16 +37,22 @@ HEAD = ../includes/atanh.h
check_INCLUDES = -I $(top_builddir)/elementaryFunctions/includes \
-I $(top_builddir)/type
-check_PROGRAMS = testAtanh
+check_LDADD = $(top_builddir)/type/libDoubleComplex.la \
+ $(top_builddir)/type/libFloatComplex.la \
+ $(top_builddir)/elementaryFunctions/atanh/libAtanh.la \
+ @LIBMATH@
+
+check_PROGRAMS = testFloatAtanh testDoubleAtanh
-TESTS = testAtanh
+TESTS = testFloatAtanh testDoubleAtanh
#
-# -*- Atanhgeant Tests -*-
+# -*- Hyperbolic ArcTangeant Tests -*-
#
-testAtanh_SOURCES = testAtanh.c
-testAtanh_CFLAGS = $(check_INCLUDES)
-testAtanh_LDADD = $(top_builddir)/type/libDoubleComplex.la \
- $(top_builddir)/type/libFloatComplex.la \
- $(top_builddir)/elementaryFunctions/atanh/libAtanh.la \
- @LIBMATH@
+testFloatAtanh_SOURCES = testFloatAtanh.c
+testFloatAtanh_CFLAGS = $(check_INCLUDES)
+testFloatAtanh_LDADD = $(check_LDADD)
+
+testDoubleAtanh_SOURCES = testDoubleAtanh.c
+testDoubleAtanh_CFLAGS = $(check_INCLUDES)
+testDoubleAtanh_LDADD = $(check_LDADD)
diff --git a/src/elementaryFunctions/atanh/Makefile.in b/src/elementaryFunctions/atanh/Makefile.in
index 588fcfd7..77bf5cdf 100644
--- a/src/elementaryFunctions/atanh/Makefile.in
+++ b/src/elementaryFunctions/atanh/Makefile.in
@@ -32,8 +32,8 @@ PRE_UNINSTALL = :
POST_UNINSTALL = :
build_triplet = @build@
host_triplet = @host@
-check_PROGRAMS = testAtanh$(EXEEXT)
-TESTS = testAtanh$(EXEEXT)
+check_PROGRAMS = testFloatAtanh$(EXEEXT) testDoubleAtanh$(EXEEXT)
+TESTS = testFloatAtanh$(EXEEXT) testDoubleAtanh$(EXEEXT)
subdir = elementaryFunctions/atanh
DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in
ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
@@ -63,13 +63,21 @@ libAtanh_la_OBJECTS = $(am_libAtanh_la_OBJECTS)
libAtanh_la_LINK = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) \
$(LIBTOOLFLAGS) --mode=link $(CCLD) $(libAtanh_la_CFLAGS) \
$(CFLAGS) $(AM_LDFLAGS) $(LDFLAGS) -o $@
-am_testAtanh_OBJECTS = testAtanh-testAtanh.$(OBJEXT)
-testAtanh_OBJECTS = $(am_testAtanh_OBJECTS)
-testAtanh_DEPENDENCIES = $(top_builddir)/type/libDoubleComplex.la \
+am_testDoubleAtanh_OBJECTS = \
+ testDoubleAtanh-testDoubleAtanh.$(OBJEXT)
+testDoubleAtanh_OBJECTS = $(am_testDoubleAtanh_OBJECTS)
+am__DEPENDENCIES_1 = $(top_builddir)/type/libDoubleComplex.la \
$(top_builddir)/type/libFloatComplex.la \
$(top_builddir)/elementaryFunctions/atanh/libAtanh.la
-testAtanh_LINK = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) \
- $(LIBTOOLFLAGS) --mode=link $(CCLD) $(testAtanh_CFLAGS) \
+testDoubleAtanh_DEPENDENCIES = $(am__DEPENDENCIES_1)
+testDoubleAtanh_LINK = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) \
+ $(LIBTOOLFLAGS) --mode=link $(CCLD) $(testDoubleAtanh_CFLAGS) \
+ $(CFLAGS) $(AM_LDFLAGS) $(LDFLAGS) -o $@
+am_testFloatAtanh_OBJECTS = testFloatAtanh-testFloatAtanh.$(OBJEXT)
+testFloatAtanh_OBJECTS = $(am_testFloatAtanh_OBJECTS)
+testFloatAtanh_DEPENDENCIES = $(am__DEPENDENCIES_1)
+testFloatAtanh_LINK = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) \
+ $(LIBTOOLFLAGS) --mode=link $(CCLD) $(testFloatAtanh_CFLAGS) \
$(CFLAGS) $(AM_LDFLAGS) $(LDFLAGS) -o $@
DEFAULT_INCLUDES = -I. -I$(top_builddir)/includes@am__isrc@
depcomp = $(SHELL) $(top_srcdir)/config/depcomp
@@ -83,8 +91,10 @@ CCLD = $(CC)
LINK = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
--mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) \
$(LDFLAGS) -o $@
-SOURCES = $(libAtanh_la_SOURCES) $(testAtanh_SOURCES)
-DIST_SOURCES = $(libAtanh_la_SOURCES) $(testAtanh_SOURCES)
+SOURCES = $(libAtanh_la_SOURCES) $(testDoubleAtanh_SOURCES) \
+ $(testFloatAtanh_SOURCES)
+DIST_SOURCES = $(libAtanh_la_SOURCES) $(testDoubleAtanh_SOURCES) \
+ $(testFloatAtanh_SOURCES)
ETAGS = etags
CTAGS = ctags
DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
@@ -219,17 +229,21 @@ HEAD = ../includes/atanh.h
check_INCLUDES = -I $(top_builddir)/elementaryFunctions/includes \
-I $(top_builddir)/type
-
-#
-# -*- Atanhgeant Tests -*-
-#
-testAtanh_SOURCES = testAtanh.c
-testAtanh_CFLAGS = $(check_INCLUDES)
-testAtanh_LDADD = $(top_builddir)/type/libDoubleComplex.la \
+check_LDADD = $(top_builddir)/type/libDoubleComplex.la \
$(top_builddir)/type/libFloatComplex.la \
$(top_builddir)/elementaryFunctions/atanh/libAtanh.la \
@LIBMATH@
+
+#
+# -*- Hyperbolic ArcTangeant Tests -*-
+#
+testFloatAtanh_SOURCES = testFloatAtanh.c
+testFloatAtanh_CFLAGS = $(check_INCLUDES)
+testFloatAtanh_LDADD = $(check_LDADD)
+testDoubleAtanh_SOURCES = testDoubleAtanh.c
+testDoubleAtanh_CFLAGS = $(check_INCLUDES)
+testDoubleAtanh_LDADD = $(check_LDADD)
all: all-am
.SUFFIXES:
@@ -299,9 +313,12 @@ clean-checkPROGRAMS:
echo " rm -f $$p $$f"; \
rm -f $$p $$f ; \
done
-testAtanh$(EXEEXT): $(testAtanh_OBJECTS) $(testAtanh_DEPENDENCIES)
- @rm -f testAtanh$(EXEEXT)
- $(testAtanh_LINK) $(testAtanh_OBJECTS) $(testAtanh_LDADD) $(LIBS)
+testDoubleAtanh$(EXEEXT): $(testDoubleAtanh_OBJECTS) $(testDoubleAtanh_DEPENDENCIES)
+ @rm -f testDoubleAtanh$(EXEEXT)
+ $(testDoubleAtanh_LINK) $(testDoubleAtanh_OBJECTS) $(testDoubleAtanh_LDADD) $(LIBS)
+testFloatAtanh$(EXEEXT): $(testFloatAtanh_OBJECTS) $(testFloatAtanh_DEPENDENCIES)
+ @rm -f testFloatAtanh$(EXEEXT)
+ $(testFloatAtanh_LINK) $(testFloatAtanh_OBJECTS) $(testFloatAtanh_LDADD) $(LIBS)
mostlyclean-compile:
-rm -f *.$(OBJEXT)
@@ -317,7 +334,8 @@ distclean-compile:
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libAtanh_la-satanhs.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libAtanh_la-zatanha.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libAtanh_la-zatanhs.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/testAtanh-testAtanh.Po@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/testDoubleAtanh-testDoubleAtanh.Po@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/testFloatAtanh-testFloatAtanh.Po@am__quote@
.c.o:
@am__fastdepCC_TRUE@ $(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
@@ -396,19 +414,33 @@ libAtanh_la-zatanha.lo: zatanha.c
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libAtanh_la_CFLAGS) $(CFLAGS) -c -o libAtanh_la-zatanha.lo `test -f 'zatanha.c' || echo '$(srcdir)/'`zatanha.c
-testAtanh-testAtanh.o: testAtanh.c
-@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(testAtanh_CFLAGS) $(CFLAGS) -MT testAtanh-testAtanh.o -MD -MP -MF $(DEPDIR)/testAtanh-testAtanh.Tpo -c -o testAtanh-testAtanh.o `test -f 'testAtanh.c' || echo '$(srcdir)/'`testAtanh.c
-@am__fastdepCC_TRUE@ mv -f $(DEPDIR)/testAtanh-testAtanh.Tpo $(DEPDIR)/testAtanh-testAtanh.Po
-@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='testAtanh.c' object='testAtanh-testAtanh.o' libtool=no @AMDEPBACKSLASH@
+testDoubleAtanh-testDoubleAtanh.o: testDoubleAtanh.c
+@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(testDoubleAtanh_CFLAGS) $(CFLAGS) -MT testDoubleAtanh-testDoubleAtanh.o -MD -MP -MF $(DEPDIR)/testDoubleAtanh-testDoubleAtanh.Tpo -c -o testDoubleAtanh-testDoubleAtanh.o `test -f 'testDoubleAtanh.c' || echo '$(srcdir)/'`testDoubleAtanh.c
+@am__fastdepCC_TRUE@ mv -f $(DEPDIR)/testDoubleAtanh-testDoubleAtanh.Tpo $(DEPDIR)/testDoubleAtanh-testDoubleAtanh.Po
+@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='testDoubleAtanh.c' object='testDoubleAtanh-testDoubleAtanh.o' libtool=no @AMDEPBACKSLASH@
+@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
+@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(testDoubleAtanh_CFLAGS) $(CFLAGS) -c -o testDoubleAtanh-testDoubleAtanh.o `test -f 'testDoubleAtanh.c' || echo '$(srcdir)/'`testDoubleAtanh.c
+
+testDoubleAtanh-testDoubleAtanh.obj: testDoubleAtanh.c
+@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(testDoubleAtanh_CFLAGS) $(CFLAGS) -MT testDoubleAtanh-testDoubleAtanh.obj -MD -MP -MF $(DEPDIR)/testDoubleAtanh-testDoubleAtanh.Tpo -c -o testDoubleAtanh-testDoubleAtanh.obj `if test -f 'testDoubleAtanh.c'; then $(CYGPATH_W) 'testDoubleAtanh.c'; else $(CYGPATH_W) '$(srcdir)/testDoubleAtanh.c'; fi`
+@am__fastdepCC_TRUE@ mv -f $(DEPDIR)/testDoubleAtanh-testDoubleAtanh.Tpo $(DEPDIR)/testDoubleAtanh-testDoubleAtanh.Po
+@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='testDoubleAtanh.c' object='testDoubleAtanh-testDoubleAtanh.obj' libtool=no @AMDEPBACKSLASH@
+@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
+@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(testDoubleAtanh_CFLAGS) $(CFLAGS) -c -o testDoubleAtanh-testDoubleAtanh.obj `if test -f 'testDoubleAtanh.c'; then $(CYGPATH_W) 'testDoubleAtanh.c'; else $(CYGPATH_W) '$(srcdir)/testDoubleAtanh.c'; fi`
+
+testFloatAtanh-testFloatAtanh.o: testFloatAtanh.c
+@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(testFloatAtanh_CFLAGS) $(CFLAGS) -MT testFloatAtanh-testFloatAtanh.o -MD -MP -MF $(DEPDIR)/testFloatAtanh-testFloatAtanh.Tpo -c -o testFloatAtanh-testFloatAtanh.o `test -f 'testFloatAtanh.c' || echo '$(srcdir)/'`testFloatAtanh.c
+@am__fastdepCC_TRUE@ mv -f $(DEPDIR)/testFloatAtanh-testFloatAtanh.Tpo $(DEPDIR)/testFloatAtanh-testFloatAtanh.Po
+@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='testFloatAtanh.c' object='testFloatAtanh-testFloatAtanh.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(testAtanh_CFLAGS) $(CFLAGS) -c -o testAtanh-testAtanh.o `test -f 'testAtanh.c' || echo '$(srcdir)/'`testAtanh.c
+@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(testFloatAtanh_CFLAGS) $(CFLAGS) -c -o testFloatAtanh-testFloatAtanh.o `test -f 'testFloatAtanh.c' || echo '$(srcdir)/'`testFloatAtanh.c
-testAtanh-testAtanh.obj: testAtanh.c
-@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(testAtanh_CFLAGS) $(CFLAGS) -MT testAtanh-testAtanh.obj -MD -MP -MF $(DEPDIR)/testAtanh-testAtanh.Tpo -c -o testAtanh-testAtanh.obj `if test -f 'testAtanh.c'; then $(CYGPATH_W) 'testAtanh.c'; else $(CYGPATH_W) '$(srcdir)/testAtanh.c'; fi`
-@am__fastdepCC_TRUE@ mv -f $(DEPDIR)/testAtanh-testAtanh.Tpo $(DEPDIR)/testAtanh-testAtanh.Po
-@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='testAtanh.c' object='testAtanh-testAtanh.obj' libtool=no @AMDEPBACKSLASH@
+testFloatAtanh-testFloatAtanh.obj: testFloatAtanh.c
+@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(testFloatAtanh_CFLAGS) $(CFLAGS) -MT testFloatAtanh-testFloatAtanh.obj -MD -MP -MF $(DEPDIR)/testFloatAtanh-testFloatAtanh.Tpo -c -o testFloatAtanh-testFloatAtanh.obj `if test -f 'testFloatAtanh.c'; then $(CYGPATH_W) 'testFloatAtanh.c'; else $(CYGPATH_W) '$(srcdir)/testFloatAtanh.c'; fi`
+@am__fastdepCC_TRUE@ mv -f $(DEPDIR)/testFloatAtanh-testFloatAtanh.Tpo $(DEPDIR)/testFloatAtanh-testFloatAtanh.Po
+@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='testFloatAtanh.c' object='testFloatAtanh-testFloatAtanh.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(testAtanh_CFLAGS) $(CFLAGS) -c -o testAtanh-testAtanh.obj `if test -f 'testAtanh.c'; then $(CYGPATH_W) 'testAtanh.c'; else $(CYGPATH_W) '$(srcdir)/testAtanh.c'; fi`
+@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(testFloatAtanh_CFLAGS) $(CFLAGS) -c -o testFloatAtanh-testFloatAtanh.obj `if test -f 'testFloatAtanh.c'; then $(CYGPATH_W) 'testFloatAtanh.c'; else $(CYGPATH_W) '$(srcdir)/testFloatAtanh.c'; fi`
mostlyclean-libtool:
-rm -f *.lo
diff --git a/src/elementaryFunctions/atanh/catanhs.c b/src/elementaryFunctions/atanh/catanhs.c
index 52f2d589..92af66b3 100644
--- a/src/elementaryFunctions/atanh/catanhs.c
+++ b/src/elementaryFunctions/atanh/catanhs.c
@@ -1,22 +1,18 @@
/*
-** -*- C -*-
-**
-** catanhs.c
-** Made by Bruno JOFRET <bruno.jofret@inria.fr>
-**
-** Started on Thu Dec 7 12:04:28 2006 jofret
-** Last update Thu Sep 6 15:12:27 2007 bruno
-**
-** Copyright INRIA 2006
-*/
+ * 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 "atanh.h"
floatComplex catanhs(floatComplex z) {
-
- double out_real = 0;
- double out_imag = 0;
/* FIXME : Let's code... */
-
- return FloatComplex(out_real, out_imag);
+ return z;
}
diff --git a/src/elementaryFunctions/atanh/satanhs.c b/src/elementaryFunctions/atanh/satanhs.c
index d179005c..36eeb99a 100644
--- a/src/elementaryFunctions/atanh/satanhs.c
+++ b/src/elementaryFunctions/atanh/satanhs.c
@@ -1,18 +1,18 @@
/*
-** -*- C -*-
-**
-** satanhs.c
-** Made by Bruno JOFRET <bruno.jofret@inria.fr>
-**
-** Started on Thu Dec 7 11:05:37 2006 jofret
-** Last update Thu Sep 6 15:10:17 2007 bruno
-**
-** Copyright INRIA 2006
-*/
+ * 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 <math.h>
#include "atanh.h"
float satanhs(float x) {
- return (atanh(x));
+ return (atanhf(x));
}
diff --git a/src/elementaryFunctions/atanh/testAtanh.c b/src/elementaryFunctions/atanh/testAtanh.c
deleted file mode 100644
index 97651729..00000000
--- a/src/elementaryFunctions/atanh/testAtanh.c
+++ /dev/null
@@ -1,64 +0,0 @@
-/*
-** -*- C -*-
-**
-** testAtanh.c
-** Made by Bruno JOFRET <bruno.jofret@inria.fr>
-**
-** Started on Fri Dec 8 15:05:44 2006 jofret
-** Last update Thu Sep 6 15:09:45 2007 bruno
-**
-** Copyright INRIA 2006
-*/
-
-#include "testAtanh.h"
-
-void satanhsTest() {
- printf(">> Float scalar\n");
- printf("satanhs(0) = %f\n", satanhs((float) 0));
- printf("satanhs(PI) = %f\n", satanhs(PI));
- printf("satanhs(PI/2) = %f\n", satanhs(PI/2));
- printf("satanhs(PI/3) = %f\n", satanhs(PI/3));
- printf("satanhs(PI/4) = %f\n", satanhs(PI/4));
- printf("satanhs(PI/6) = %f\n", satanhs(PI/6));
- printf("satanhs(-PI) = %f\n", satanhs(-PI));
- printf("satanhs(-PI/2) = %f\n", satanhs(-PI/2));
- printf("satanhs(-PI/3) = %f\n", satanhs(-PI/3));
- printf("satanhs(-PI/4) = %f\n", satanhs(-PI/4));
- printf("satanhs(-PI/6) = %f\n", satanhs(-PI/6));
-}
-
-void datanhsTest() {
- printf(">> Double scalar\n");
- printf("datanhs(0) = %e\n", datanhs((double) 0));
- printf("datanhs(PI) = %e\n", datanhs(PI));
- printf("datanhs(PI/2) = %e\n", datanhs(PI/2));
- printf("datanhs(PI/3) = %e\n", datanhs(PI/3));
- printf("datanhs(PI/4) = %e\n", datanhs(PI/4));
- printf("datanhs(PI/6) = %e\n", datanhs(PI/6));
- printf("datanhs(-PI) = %e\n", datanhs(-PI));
- printf("datanhs(-PI/2) = %e\n", datanhs(-PI/2));
- printf("datanhs(-PI/3) = %e\n", datanhs(-PI/3));
- printf("datanhs(-PI/4) = %e\n", datanhs(-PI/4));
- printf("datanhs(-PI/6) = %e\n", datanhs(-PI/6));
-}
-
-int testAtanh() {
- printf("\n>>>> Atanhgeant Tests\n");
- satanhsTest();
- datanhsTest();
- /* FIXME : Implement some test here ... */
- /*
- catanhsTest();
- zatanhsTest();
- satanhaTest();
- datanhaTest();
- catanhaTest();
- zatanhaTest();
- */
- return 0;
-}
-
-int main() {
- assert(testAtanh() == 0);
- return 0;
-}
diff --git a/src/elementaryFunctions/atanh/testDoubleAtanh.c b/src/elementaryFunctions/atanh/testDoubleAtanh.c
new file mode 100644
index 00000000..51810f01
--- /dev/null
+++ b/src/elementaryFunctions/atanh/testDoubleAtanh.c
@@ -0,0 +1,45 @@
+/*
+ * 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 "testAtanh.h"
+
+void datanhsTest() {
+ printf(">> Double scalar\n");
+ printf("datanhs(0) = %e\n", datanhs((double) 0));
+ printf("datanhs(PI) = %e\n", datanhs(DPI));
+ printf("datanhs(PI/2) = %e\n", datanhs(DPI/2));
+ printf("datanhs(PI/3) = %e\n", datanhs(DPI/3));
+ printf("datanhs(PI/4) = %e\n", datanhs(DPI/4));
+ printf("datanhs(PI/6) = %e\n", datanhs(DPI/6));
+ printf("datanhs(-PI) = %e\n", datanhs(-DPI));
+ printf("datanhs(-PI/2) = %e\n", datanhs(-DPI/2));
+ printf("datanhs(-PI/3) = %e\n", datanhs(-DPI/3));
+ printf("datanhs(-PI/4) = %e\n", datanhs(-DPI/4));
+ printf("datanhs(-PI/6) = %e\n", datanhs(-DPI/6));
+}
+
+int testAtanh() {
+ printf("\n>>>> Double Hyperbolic Arctangeant Tests\n");
+ datanhsTest();
+ /* FIXME : Implement some test here ... */
+ /*
+ zatanhsTest();
+ datanhaTest();
+ zatanhaTest();
+ */
+ return 0;
+}
+
+int main() {
+ assert(testAtanh() == 0);
+ return 0;
+}
diff --git a/src/elementaryFunctions/atanh/testFloatAtanh.c b/src/elementaryFunctions/atanh/testFloatAtanh.c
new file mode 100644
index 00000000..c9ae9f13
--- /dev/null
+++ b/src/elementaryFunctions/atanh/testFloatAtanh.c
@@ -0,0 +1,45 @@
+/*
+ * 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 "testAtanh.h"
+
+void satanhsTest() {
+ printf(">> Float scalar\n");
+ printf("satanhs(0) = %f\n", satanhs((float) 0));
+ printf("satanhs(PI) = %f\n", satanhs(FPI));
+ printf("satanhs(PI/2) = %f\n", satanhs(FPI/2));
+ printf("satanhs(PI/3) = %f\n", satanhs(FPI/3));
+ printf("satanhs(PI/4) = %f\n", satanhs(FPI/4));
+ printf("satanhs(PI/6) = %f\n", satanhs(FPI/6));
+ printf("satanhs(-PI) = %f\n", satanhs(-FPI));
+ printf("satanhs(-PI/2) = %f\n", satanhs(-FPI/2));
+ printf("satanhs(-PI/3) = %f\n", satanhs(-FPI/3));
+ printf("satanhs(-PI/4) = %f\n", satanhs(-FPI/4));
+ printf("satanhs(-PI/6) = %f\n", satanhs(-FPI/6));
+}
+
+int testAtanh() {
+ printf("\n>>>> Float Hyperbolic Arctangeant Tests\n");
+ satanhsTest();
+ /* FIXME : Implement some test here ... */
+ /*
+ catanhsTest();
+ satanhaTest();
+ catanhaTest();
+ */
+ return 0;
+}
+
+int main() {
+ assert(testAtanh() == 0);
+ return 0;
+}
diff --git a/src/elementaryFunctions/atanh/zatanhs.c b/src/elementaryFunctions/atanh/zatanhs.c
index df7d1903..1bb6c82d 100644
--- a/src/elementaryFunctions/atanh/zatanhs.c
+++ b/src/elementaryFunctions/atanh/zatanhs.c
@@ -1,18 +1,18 @@
/*
-** -*- C -*-
-**
-** zatanhs.c
-** Made by Bruno JOFRET <bruno.jofret@inria.fr>
-**
-** Started on Thu Dec 7 12:05:48 2006 jofret
-** Last update Thu Sep 6 15:08:38 2007 bruno
-**
-** Copyright INRIA 2006
-*/
+ * 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 "atanh.h"
doubleComplex zatanhs(doubleComplex z) {
/* FIXME: Dummy... */
- return (DoubleComplex(0,1));
+ return z;
}