diff options
Diffstat (limited to '2.3-1/src/c/statisticsFunctions/variancef')
18 files changed, 2781 insertions, 0 deletions
diff --git a/2.3-1/src/c/statisticsFunctions/variancef/Makefile.am b/2.3-1/src/c/statisticsFunctions/variancef/Makefile.am new file mode 100644 index 00000000..804025bf --- /dev/null +++ b/2.3-1/src/c/statisticsFunctions/variancef/Makefile.am @@ -0,0 +1,89 @@ +## +## Scilab ( http://www.scilab.org/ ) - This file is part of Scilab +## Copyright (C) 2008-2008 - INRIA - Allan SIMON +## +## 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 +## +## + +libvariancef_la_CFLAGS = -I $(top_builddir)/src/c/type \ + -I $(top_builddir)/src/c/elementaryFunctions/includes \ + -I $(top_builddir)/src/c/matrixOperations/includes \ + -I $(top_builddir)/src/c/operations/includes \ + -I ../includes + +instdir = $(top_builddir)/lib + +pkglib_LTLIBRARIES = libvariancef.la + +libvariancef_la_SOURCES = $(HEAD) $(SRC) + +SRC = svariancefa.c \ + scolumnvariancefa.c \ + dvariancefa.c \ + srowvariancefa.c \ + drowvariancefa.c \ + dcolumnvariancefa.c \ + cvariancefa.c \ + crowvariancefa.c \ + ccolumnvariancefa.c \ + zvariancefa.c \ + zrowvariancefa.c \ + zcolumnvariancefa.c + +HEAD = ../includes/variancef.h + +#### +# Checking Part +#### + +check_INCLUDES = -I $(top_builddir)/src/c/statisticsFunctions/includes \ + -I $(top_builddir)/src/c/elementaryFunctions/includes \ + -I $(top_builddir)/src/c/matrixOperations/includes \ + -I $(top_builddir)/src/c/operations/includes \ + -I $(top_builddir)/src/c/type + +check_LDADD = $(top_builddir)/src/c/type/libDoubleComplex.la \ + $(top_builddir)/src/c/type/libFloatComplex.la \ + $(top_builddir)/src/c/operations/addition/libAddition.la \ + $(top_builddir)/src/c/operations/subtraction/libSubtraction.la \ + $(top_builddir)/src/fortran/lapack/libscilapack.la \ + $(top_builddir)/src/c/statisticsFunctions/variancef/libvariancef.la \ + $(top_builddir)/src/c/statisticsFunctions/sum/libSum.la \ + $(top_builddir)/src/c/statisticsFunctions/meanf/libMeanf.la \ + $(top_builddir)/src/c/elementaryFunctions/pow/libPow.la \ + $(top_builddir)/src/c/elementaryFunctions/log/libLog.la \ + $(top_builddir)/src/c/elementaryFunctions/exp/libExp.la \ + $(top_builddir)/src/c/elementaryFunctions/cos/libCos.la \ + $(top_builddir)/src/c/elementaryFunctions/sin/libSin.la \ + $(top_builddir)/src/c/elementaryFunctions/cosh/libCosh.la \ + $(top_builddir)/src/c/elementaryFunctions/sinh/libSinh.la \ + $(top_builddir)/src/c/elementaryFunctions/sqrt/libSqrt.la \ + $(top_builddir)/src/c/elementaryFunctions/log1p/libLog1p.la \ + $(top_builddir)/src/c/elementaryFunctions/lnp1m1/libLnp1m1.la \ + $(top_builddir)/src/c/auxiliaryFunctions/pythag/libPythag.la \ + $(top_builddir)/src/c/auxiliaryFunctions/abs/libAbs.la \ + $(top_builddir)/src/c/matrixOperations/transpose/libMatrixTranspose.la \ + $(top_builddir)/src/c/operations/multiplication/libMultiplication.la \ + $(top_builddir)/src/c/operations/division/libDivision.la \ + $(top_builddir)/src/c/auxiliaryFunctions/conj/libConj.la \ + @LIBMATH@ + +check_PROGRAMS = testFloatVariancef testDoubleVariancef + +TESTS = testFloatVariancef testDoubleVariancef + +# +# -*- variancef Tests -*- +# +testFloatVariancef_SOURCES = testFloatVariancef.c +testFloatVariancef_CFLAGS = $(check_INCLUDES) +testFloatVariancef_LDADD = $(check_LDADD) + +testDoubleVariancef_SOURCES =testDoubleVariancef.c +testDoubleVariancef_CFLAGS = $(check_INCLUDES) +testDoubleVariancef_LDADD = $(check_LDADD) diff --git a/2.3-1/src/c/statisticsFunctions/variancef/Makefile.in b/2.3-1/src/c/statisticsFunctions/variancef/Makefile.in new file mode 100644 index 00000000..9cbd3dfa --- /dev/null +++ b/2.3-1/src/c/statisticsFunctions/variancef/Makefile.in @@ -0,0 +1,886 @@ +# Makefile.in generated by automake 1.11.1 from Makefile.am. +# @configure_input@ + +# Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, +# 2003, 2004, 2005, 2006, 2007, 2008, 2009 Free Software Foundation, +# Inc. +# This Makefile.in is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY, to the extent permitted by law; without +# even the implied warranty of MERCHANTABILITY or FITNESS FOR A +# PARTICULAR PURPOSE. + +@SET_MAKE@ + +VPATH = @srcdir@ +pkgdatadir = $(datadir)/@PACKAGE@ +pkgincludedir = $(includedir)/@PACKAGE@ +pkglibdir = $(libdir)/@PACKAGE@ +pkglibexecdir = $(libexecdir)/@PACKAGE@ +am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd +install_sh_DATA = $(install_sh) -c -m 644 +install_sh_PROGRAM = $(install_sh) -c +install_sh_SCRIPT = $(install_sh) -c +INSTALL_HEADER = $(INSTALL_DATA) +transform = $(program_transform_name) +NORMAL_INSTALL = : +PRE_INSTALL = : +POST_INSTALL = : +NORMAL_UNINSTALL = : +PRE_UNINSTALL = : +POST_UNINSTALL = : +build_triplet = @build@ +host_triplet = @host@ +check_PROGRAMS = testFloatVariancef$(EXEEXT) \ + testDoubleVariancef$(EXEEXT) +TESTS = testFloatVariancef$(EXEEXT) testDoubleVariancef$(EXEEXT) +subdir = src/c/statisticsFunctions/variancef +DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in +ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 +am__aclocal_m4_deps = $(top_srcdir)/configure.ac +am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ + $(ACLOCAL_M4) +mkinstalldirs = $(install_sh) -d +CONFIG_HEADER = $(top_builddir)/includes/machine.h +CONFIG_CLEAN_FILES = +CONFIG_CLEAN_VPATH_FILES = +am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; +am__vpath_adj = case $$p in \ + $(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \ + *) f=$$p;; \ + esac; +am__strip_dir = f=`echo $$p | sed -e 's|^.*/||'`; +am__install_max = 40 +am__nobase_strip_setup = \ + srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*|]/\\\\&/g'` +am__nobase_strip = \ + for p in $$list; do echo "$$p"; done | sed -e "s|$$srcdirstrip/||" +am__nobase_list = $(am__nobase_strip_setup); \ + for p in $$list; do echo "$$p $$p"; done | \ + sed "s| $$srcdirstrip/| |;"' / .*\//!s/ .*/ ./; s,\( .*\)/[^/]*$$,\1,' | \ + $(AWK) 'BEGIN { files["."] = "" } { files[$$2] = files[$$2] " " $$1; \ + if (++n[$$2] == $(am__install_max)) \ + { print $$2, files[$$2]; n[$$2] = 0; files[$$2] = "" } } \ + END { for (dir in files) print dir, files[dir] }' +am__base_list = \ + sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \ + sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g' +am__installdirs = "$(DESTDIR)$(pkglibdir)" +LTLIBRARIES = $(pkglib_LTLIBRARIES) +libvariancef_la_LIBADD = +am__objects_1 = +am__objects_2 = libvariancef_la-svariancefa.lo \ + libvariancef_la-scolumnvariancefa.lo \ + libvariancef_la-dvariancefa.lo \ + libvariancef_la-srowvariancefa.lo \ + libvariancef_la-drowvariancefa.lo \ + libvariancef_la-dcolumnvariancefa.lo \ + libvariancef_la-cvariancefa.lo \ + libvariancef_la-crowvariancefa.lo \ + libvariancef_la-ccolumnvariancefa.lo \ + libvariancef_la-zvariancefa.lo \ + libvariancef_la-zrowvariancefa.lo \ + libvariancef_la-zcolumnvariancefa.lo +am_libvariancef_la_OBJECTS = $(am__objects_1) $(am__objects_2) +libvariancef_la_OBJECTS = $(am_libvariancef_la_OBJECTS) +libvariancef_la_LINK = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) \ + $(LIBTOOLFLAGS) --mode=link $(CCLD) $(libvariancef_la_CFLAGS) \ + $(CFLAGS) $(AM_LDFLAGS) $(LDFLAGS) -o $@ +am_testDoubleVariancef_OBJECTS = \ + testDoubleVariancef-testDoubleVariancef.$(OBJEXT) +testDoubleVariancef_OBJECTS = $(am_testDoubleVariancef_OBJECTS) +am__DEPENDENCIES_1 = $(top_builddir)/src/c/type/libDoubleComplex.la \ + $(top_builddir)/src/c/type/libFloatComplex.la \ + $(top_builddir)/src/c/operations/addition/libAddition.la \ + $(top_builddir)/src/c/operations/subtraction/libSubtraction.la \ + $(top_builddir)/src/fortran/lapack/libscilapack.la \ + $(top_builddir)/src/c/statisticsFunctions/variancef/libvariancef.la \ + $(top_builddir)/src/c/statisticsFunctions/sum/libSum.la \ + $(top_builddir)/src/c/statisticsFunctions/meanf/libMeanf.la \ + $(top_builddir)/src/c/elementaryFunctions/pow/libPow.la \ + $(top_builddir)/src/c/elementaryFunctions/log/libLog.la \ + $(top_builddir)/src/c/elementaryFunctions/exp/libExp.la \ + $(top_builddir)/src/c/elementaryFunctions/cos/libCos.la \ + $(top_builddir)/src/c/elementaryFunctions/sin/libSin.la \ + $(top_builddir)/src/c/elementaryFunctions/cosh/libCosh.la \ + $(top_builddir)/src/c/elementaryFunctions/sinh/libSinh.la \ + $(top_builddir)/src/c/elementaryFunctions/sqrt/libSqrt.la \ + $(top_builddir)/src/c/elementaryFunctions/log1p/libLog1p.la \ + $(top_builddir)/src/c/elementaryFunctions/lnp1m1/libLnp1m1.la \ + $(top_builddir)/src/c/auxiliaryFunctions/pythag/libPythag.la \ + $(top_builddir)/src/c/auxiliaryFunctions/abs/libAbs.la \ + $(top_builddir)/src/c/matrixOperations/transpose/libMatrixTranspose.la \ + $(top_builddir)/src/c/operations/multiplication/libMultiplication.la \ + $(top_builddir)/src/c/operations/division/libDivision.la \ + $(top_builddir)/src/c/auxiliaryFunctions/conj/libConj.la +testDoubleVariancef_DEPENDENCIES = $(am__DEPENDENCIES_1) +testDoubleVariancef_LINK = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) \ + $(LIBTOOLFLAGS) --mode=link $(CCLD) \ + $(testDoubleVariancef_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) \ + $(LDFLAGS) -o $@ +am_testFloatVariancef_OBJECTS = \ + testFloatVariancef-testFloatVariancef.$(OBJEXT) +testFloatVariancef_OBJECTS = $(am_testFloatVariancef_OBJECTS) +testFloatVariancef_DEPENDENCIES = $(am__DEPENDENCIES_1) +testFloatVariancef_LINK = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) \ + $(LIBTOOLFLAGS) --mode=link $(CCLD) \ + $(testFloatVariancef_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) \ + $(LDFLAGS) -o $@ +DEFAULT_INCLUDES = -I.@am__isrc@ -I$(top_builddir)/includes +depcomp = $(SHELL) $(top_srcdir)/config/depcomp +am__depfiles_maybe = depfiles +am__mv = mv -f +COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \ + $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) +LTCOMPILE = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \ + --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \ + $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) +CCLD = $(CC) +LINK = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \ + --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) \ + $(LDFLAGS) -o $@ +SOURCES = $(libvariancef_la_SOURCES) $(testDoubleVariancef_SOURCES) \ + $(testFloatVariancef_SOURCES) +DIST_SOURCES = $(libvariancef_la_SOURCES) \ + $(testDoubleVariancef_SOURCES) $(testFloatVariancef_SOURCES) +ETAGS = etags +CTAGS = ctags +am__tty_colors = \ +red=; grn=; lgn=; blu=; std= +DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) +ACLOCAL = @ACLOCAL@ +AMTAR = @AMTAR@ +AR = @AR@ +AUTOCONF = @AUTOCONF@ +AUTOHEADER = @AUTOHEADER@ +AUTOMAKE = @AUTOMAKE@ +AWK = @AWK@ +CC = @CC@ +CCDEPMODE = @CCDEPMODE@ +CFLAGS = @CFLAGS@ +CPP = @CPP@ +CPPFLAGS = @CPPFLAGS@ +CXX = @CXX@ +CXXCPP = @CXXCPP@ +CXXDEPMODE = @CXXDEPMODE@ +CXXFLAGS = @CXXFLAGS@ +CYGPATH_W = @CYGPATH_W@ +DEFS = @DEFS@ +DEPDIR = @DEPDIR@ +DSYMUTIL = @DSYMUTIL@ +DUMPBIN = @DUMPBIN@ +ECHO_C = @ECHO_C@ +ECHO_N = @ECHO_N@ +ECHO_T = @ECHO_T@ +EGREP = @EGREP@ +EXEEXT = @EXEEXT@ +F77 = @F77@ +FFLAGS = @FFLAGS@ +FGREP = @FGREP@ +GREP = @GREP@ +INSTALL = @INSTALL@ +INSTALL_DATA = @INSTALL_DATA@ +INSTALL_PROGRAM = @INSTALL_PROGRAM@ +INSTALL_SCRIPT = @INSTALL_SCRIPT@ +INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ +LD = @LD@ +LDFLAGS = @LDFLAGS@ +LIBMATH = @LIBMATH@ +LIBOBJS = @LIBOBJS@ +LIBS = @LIBS@ +LIBTOOL = @LIBTOOL@ +LIPO = @LIPO@ +LN_S = @LN_S@ +LTLIBOBJS = @LTLIBOBJS@ +MAINT = @MAINT@ +MAKEINFO = @MAKEINFO@ +MKDIR_P = @MKDIR_P@ +NM = @NM@ +NMEDIT = @NMEDIT@ +OBJDUMP = @OBJDUMP@ +OBJEXT = @OBJEXT@ +OTOOL = @OTOOL@ +OTOOL64 = @OTOOL64@ +PACKAGE = @PACKAGE@ +PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ +PACKAGE_NAME = @PACKAGE_NAME@ +PACKAGE_STRING = @PACKAGE_STRING@ +PACKAGE_TARNAME = @PACKAGE_TARNAME@ +PACKAGE_URL = @PACKAGE_URL@ +PACKAGE_VERSION = @PACKAGE_VERSION@ +PATH_SEPARATOR = @PATH_SEPARATOR@ +RANLIB = @RANLIB@ +SED = @SED@ +SET_MAKE = @SET_MAKE@ +SHELL = @SHELL@ +STRIP = @STRIP@ +VERSION = @VERSION@ +abs_builddir = @abs_builddir@ +abs_srcdir = @abs_srcdir@ +abs_top_builddir = @abs_top_builddir@ +abs_top_srcdir = @abs_top_srcdir@ +ac_ct_CC = @ac_ct_CC@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_F77 = @ac_ct_F77@ +am__include = @am__include@ +am__leading_dot = @am__leading_dot@ +am__quote = @am__quote@ +am__tar = @am__tar@ +am__untar = @am__untar@ +bindir = @bindir@ +build = @build@ +build_alias = @build_alias@ +build_cpu = @build_cpu@ +build_os = @build_os@ +build_vendor = @build_vendor@ +builddir = @builddir@ +datadir = @datadir@ +datarootdir = @datarootdir@ +docdir = @docdir@ +dvidir = @dvidir@ +exec_prefix = @exec_prefix@ +host = @host@ +host_alias = @host_alias@ +host_cpu = @host_cpu@ +host_os = @host_os@ +host_vendor = @host_vendor@ +htmldir = @htmldir@ +includedir = @includedir@ +infodir = @infodir@ +install_sh = @install_sh@ +libdir = @libdir@ +libexecdir = @libexecdir@ +localedir = @localedir@ +localstatedir = @localstatedir@ +lt_ECHO = @lt_ECHO@ +mandir = @mandir@ +mkdir_p = @mkdir_p@ +oldincludedir = @oldincludedir@ +pdfdir = @pdfdir@ +prefix = @prefix@ +program_transform_name = @program_transform_name@ +psdir = @psdir@ +sbindir = @sbindir@ +sharedstatedir = @sharedstatedir@ +srcdir = @srcdir@ +sysconfdir = @sysconfdir@ +target_alias = @target_alias@ +top_build_prefix = @top_build_prefix@ +top_builddir = @top_builddir@ +top_srcdir = @top_srcdir@ +libvariancef_la_CFLAGS = -I $(top_builddir)/src/c/type \ + -I $(top_builddir)/src/c/elementaryFunctions/includes \ + -I $(top_builddir)/src/c/matrixOperations/includes \ + -I $(top_builddir)/src/c/operations/includes \ + -I ../includes + +instdir = $(top_builddir)/lib +pkglib_LTLIBRARIES = libvariancef.la +libvariancef_la_SOURCES = $(HEAD) $(SRC) +SRC = svariancefa.c \ + scolumnvariancefa.c \ + dvariancefa.c \ + srowvariancefa.c \ + drowvariancefa.c \ + dcolumnvariancefa.c \ + cvariancefa.c \ + crowvariancefa.c \ + ccolumnvariancefa.c \ + zvariancefa.c \ + zrowvariancefa.c \ + zcolumnvariancefa.c + +HEAD = ../includes/variancef.h + +#### +# Checking Part +#### +check_INCLUDES = -I $(top_builddir)/src/c/statisticsFunctions/includes \ + -I $(top_builddir)/src/c/elementaryFunctions/includes \ + -I $(top_builddir)/src/c/matrixOperations/includes \ + -I $(top_builddir)/src/c/operations/includes \ + -I $(top_builddir)/src/c/type + +check_LDADD = $(top_builddir)/src/c/type/libDoubleComplex.la \ + $(top_builddir)/src/c/type/libFloatComplex.la \ + $(top_builddir)/src/c/operations/addition/libAddition.la \ + $(top_builddir)/src/c/operations/subtraction/libSubtraction.la \ + $(top_builddir)/src/fortran/lapack/libscilapack.la \ + $(top_builddir)/src/c/statisticsFunctions/variancef/libvariancef.la \ + $(top_builddir)/src/c/statisticsFunctions/sum/libSum.la \ + $(top_builddir)/src/c/statisticsFunctions/meanf/libMeanf.la \ + $(top_builddir)/src/c/elementaryFunctions/pow/libPow.la \ + $(top_builddir)/src/c/elementaryFunctions/log/libLog.la \ + $(top_builddir)/src/c/elementaryFunctions/exp/libExp.la \ + $(top_builddir)/src/c/elementaryFunctions/cos/libCos.la \ + $(top_builddir)/src/c/elementaryFunctions/sin/libSin.la \ + $(top_builddir)/src/c/elementaryFunctions/cosh/libCosh.la \ + $(top_builddir)/src/c/elementaryFunctions/sinh/libSinh.la \ + $(top_builddir)/src/c/elementaryFunctions/sqrt/libSqrt.la \ + $(top_builddir)/src/c/elementaryFunctions/log1p/libLog1p.la \ + $(top_builddir)/src/c/elementaryFunctions/lnp1m1/libLnp1m1.la \ + $(top_builddir)/src/c/auxiliaryFunctions/pythag/libPythag.la \ + $(top_builddir)/src/c/auxiliaryFunctions/abs/libAbs.la \ + $(top_builddir)/src/c/matrixOperations/transpose/libMatrixTranspose.la \ + $(top_builddir)/src/c/operations/multiplication/libMultiplication.la \ + $(top_builddir)/src/c/operations/division/libDivision.la \ + $(top_builddir)/src/c/auxiliaryFunctions/conj/libConj.la \ + @LIBMATH@ + + +# +# -*- variancef Tests -*- +# +testFloatVariancef_SOURCES = testFloatVariancef.c +testFloatVariancef_CFLAGS = $(check_INCLUDES) +testFloatVariancef_LDADD = $(check_LDADD) +testDoubleVariancef_SOURCES = testDoubleVariancef.c +testDoubleVariancef_CFLAGS = $(check_INCLUDES) +testDoubleVariancef_LDADD = $(check_LDADD) +all: all-am + +.SUFFIXES: +.SUFFIXES: .c .lo .o .obj +$(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(am__configure_deps) + @for dep in $?; do \ + case '$(am__configure_deps)' in \ + *$$dep*) \ + ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \ + && { if test -f $@; then exit 0; else break; fi; }; \ + exit 1;; \ + esac; \ + done; \ + echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign src/c/statisticsFunctions/variancef/Makefile'; \ + $(am__cd) $(top_srcdir) && \ + $(AUTOMAKE) --foreign src/c/statisticsFunctions/variancef/Makefile +.PRECIOUS: Makefile +Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status + @case '$?' in \ + *config.status*) \ + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ + *) \ + echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \ + cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \ + esac; + +$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh + +$(top_srcdir)/configure: @MAINTAINER_MODE_TRUE@ $(am__configure_deps) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh +$(ACLOCAL_M4): @MAINTAINER_MODE_TRUE@ $(am__aclocal_m4_deps) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh +$(am__aclocal_m4_deps): +install-pkglibLTLIBRARIES: $(pkglib_LTLIBRARIES) + @$(NORMAL_INSTALL) + test -z "$(pkglibdir)" || $(MKDIR_P) "$(DESTDIR)$(pkglibdir)" + @list='$(pkglib_LTLIBRARIES)'; test -n "$(pkglibdir)" || list=; \ + list2=; for p in $$list; do \ + if test -f $$p; then \ + list2="$$list2 $$p"; \ + else :; fi; \ + done; \ + test -z "$$list2" || { \ + echo " $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL) $(INSTALL_STRIP_FLAG) $$list2 '$(DESTDIR)$(pkglibdir)'"; \ + $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL) $(INSTALL_STRIP_FLAG) $$list2 "$(DESTDIR)$(pkglibdir)"; \ + } + +uninstall-pkglibLTLIBRARIES: + @$(NORMAL_UNINSTALL) + @list='$(pkglib_LTLIBRARIES)'; test -n "$(pkglibdir)" || list=; \ + for p in $$list; do \ + $(am__strip_dir) \ + echo " $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=uninstall rm -f '$(DESTDIR)$(pkglibdir)/$$f'"; \ + $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=uninstall rm -f "$(DESTDIR)$(pkglibdir)/$$f"; \ + done + +clean-pkglibLTLIBRARIES: + -test -z "$(pkglib_LTLIBRARIES)" || rm -f $(pkglib_LTLIBRARIES) + @list='$(pkglib_LTLIBRARIES)'; for p in $$list; do \ + dir="`echo $$p | sed -e 's|/[^/]*$$||'`"; \ + test "$$dir" != "$$p" || dir=.; \ + echo "rm -f \"$${dir}/so_locations\""; \ + rm -f "$${dir}/so_locations"; \ + done +libvariancef.la: $(libvariancef_la_OBJECTS) $(libvariancef_la_DEPENDENCIES) + $(libvariancef_la_LINK) -rpath $(pkglibdir) $(libvariancef_la_OBJECTS) $(libvariancef_la_LIBADD) $(LIBS) + +clean-checkPROGRAMS: + @list='$(check_PROGRAMS)'; test -n "$$list" || exit 0; \ + echo " rm -f" $$list; \ + rm -f $$list || exit $$?; \ + test -n "$(EXEEXT)" || exit 0; \ + list=`for p in $$list; do echo "$$p"; done | sed 's/$(EXEEXT)$$//'`; \ + echo " rm -f" $$list; \ + rm -f $$list +testDoubleVariancef$(EXEEXT): $(testDoubleVariancef_OBJECTS) $(testDoubleVariancef_DEPENDENCIES) + @rm -f testDoubleVariancef$(EXEEXT) + $(testDoubleVariancef_LINK) $(testDoubleVariancef_OBJECTS) $(testDoubleVariancef_LDADD) $(LIBS) +testFloatVariancef$(EXEEXT): $(testFloatVariancef_OBJECTS) $(testFloatVariancef_DEPENDENCIES) + @rm -f testFloatVariancef$(EXEEXT) + $(testFloatVariancef_LINK) $(testFloatVariancef_OBJECTS) $(testFloatVariancef_LDADD) $(LIBS) + +mostlyclean-compile: + -rm -f *.$(OBJEXT) + +distclean-compile: + -rm -f *.tab.c + +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libvariancef_la-ccolumnvariancefa.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libvariancef_la-crowvariancefa.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libvariancef_la-cvariancefa.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libvariancef_la-dcolumnvariancefa.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libvariancef_la-drowvariancefa.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libvariancef_la-dvariancefa.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libvariancef_la-scolumnvariancefa.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libvariancef_la-srowvariancefa.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libvariancef_la-svariancefa.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libvariancef_la-zcolumnvariancefa.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libvariancef_la-zrowvariancefa.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libvariancef_la-zvariancefa.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/testDoubleVariancef-testDoubleVariancef.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/testFloatVariancef-testFloatVariancef.Po@am__quote@ + +.c.o: +@am__fastdepCC_TRUE@ $(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(COMPILE) -c $< + +.c.obj: +@am__fastdepCC_TRUE@ $(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'` +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(COMPILE) -c `$(CYGPATH_W) '$<'` + +.c.lo: +@am__fastdepCC_TRUE@ $(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(LTCOMPILE) -c -o $@ $< + +libvariancef_la-svariancefa.lo: svariancefa.c +@am__fastdepCC_TRUE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libvariancef_la_CFLAGS) $(CFLAGS) -MT libvariancef_la-svariancefa.lo -MD -MP -MF $(DEPDIR)/libvariancef_la-svariancefa.Tpo -c -o libvariancef_la-svariancefa.lo `test -f 'svariancefa.c' || echo '$(srcdir)/'`svariancefa.c +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/libvariancef_la-svariancefa.Tpo $(DEPDIR)/libvariancef_la-svariancefa.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='svariancefa.c' object='libvariancef_la-svariancefa.lo' libtool=yes @AMDEPBACKSLASH@ +@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) $(libvariancef_la_CFLAGS) $(CFLAGS) -c -o libvariancef_la-svariancefa.lo `test -f 'svariancefa.c' || echo '$(srcdir)/'`svariancefa.c + +libvariancef_la-scolumnvariancefa.lo: scolumnvariancefa.c +@am__fastdepCC_TRUE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libvariancef_la_CFLAGS) $(CFLAGS) -MT libvariancef_la-scolumnvariancefa.lo -MD -MP -MF $(DEPDIR)/libvariancef_la-scolumnvariancefa.Tpo -c -o libvariancef_la-scolumnvariancefa.lo `test -f 'scolumnvariancefa.c' || echo '$(srcdir)/'`scolumnvariancefa.c +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/libvariancef_la-scolumnvariancefa.Tpo $(DEPDIR)/libvariancef_la-scolumnvariancefa.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='scolumnvariancefa.c' object='libvariancef_la-scolumnvariancefa.lo' libtool=yes @AMDEPBACKSLASH@ +@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) $(libvariancef_la_CFLAGS) $(CFLAGS) -c -o libvariancef_la-scolumnvariancefa.lo `test -f 'scolumnvariancefa.c' || echo '$(srcdir)/'`scolumnvariancefa.c + +libvariancef_la-dvariancefa.lo: dvariancefa.c +@am__fastdepCC_TRUE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libvariancef_la_CFLAGS) $(CFLAGS) -MT libvariancef_la-dvariancefa.lo -MD -MP -MF $(DEPDIR)/libvariancef_la-dvariancefa.Tpo -c -o libvariancef_la-dvariancefa.lo `test -f 'dvariancefa.c' || echo '$(srcdir)/'`dvariancefa.c +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/libvariancef_la-dvariancefa.Tpo $(DEPDIR)/libvariancef_la-dvariancefa.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='dvariancefa.c' object='libvariancef_la-dvariancefa.lo' libtool=yes @AMDEPBACKSLASH@ +@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) $(libvariancef_la_CFLAGS) $(CFLAGS) -c -o libvariancef_la-dvariancefa.lo `test -f 'dvariancefa.c' || echo '$(srcdir)/'`dvariancefa.c + +libvariancef_la-srowvariancefa.lo: srowvariancefa.c +@am__fastdepCC_TRUE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libvariancef_la_CFLAGS) $(CFLAGS) -MT libvariancef_la-srowvariancefa.lo -MD -MP -MF $(DEPDIR)/libvariancef_la-srowvariancefa.Tpo -c -o libvariancef_la-srowvariancefa.lo `test -f 'srowvariancefa.c' || echo '$(srcdir)/'`srowvariancefa.c +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/libvariancef_la-srowvariancefa.Tpo $(DEPDIR)/libvariancef_la-srowvariancefa.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='srowvariancefa.c' object='libvariancef_la-srowvariancefa.lo' libtool=yes @AMDEPBACKSLASH@ +@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) $(libvariancef_la_CFLAGS) $(CFLAGS) -c -o libvariancef_la-srowvariancefa.lo `test -f 'srowvariancefa.c' || echo '$(srcdir)/'`srowvariancefa.c + +libvariancef_la-drowvariancefa.lo: drowvariancefa.c +@am__fastdepCC_TRUE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libvariancef_la_CFLAGS) $(CFLAGS) -MT libvariancef_la-drowvariancefa.lo -MD -MP -MF $(DEPDIR)/libvariancef_la-drowvariancefa.Tpo -c -o libvariancef_la-drowvariancefa.lo `test -f 'drowvariancefa.c' || echo '$(srcdir)/'`drowvariancefa.c +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/libvariancef_la-drowvariancefa.Tpo $(DEPDIR)/libvariancef_la-drowvariancefa.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='drowvariancefa.c' object='libvariancef_la-drowvariancefa.lo' libtool=yes @AMDEPBACKSLASH@ +@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) $(libvariancef_la_CFLAGS) $(CFLAGS) -c -o libvariancef_la-drowvariancefa.lo `test -f 'drowvariancefa.c' || echo '$(srcdir)/'`drowvariancefa.c + +libvariancef_la-dcolumnvariancefa.lo: dcolumnvariancefa.c +@am__fastdepCC_TRUE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libvariancef_la_CFLAGS) $(CFLAGS) -MT libvariancef_la-dcolumnvariancefa.lo -MD -MP -MF $(DEPDIR)/libvariancef_la-dcolumnvariancefa.Tpo -c -o libvariancef_la-dcolumnvariancefa.lo `test -f 'dcolumnvariancefa.c' || echo '$(srcdir)/'`dcolumnvariancefa.c +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/libvariancef_la-dcolumnvariancefa.Tpo $(DEPDIR)/libvariancef_la-dcolumnvariancefa.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='dcolumnvariancefa.c' object='libvariancef_la-dcolumnvariancefa.lo' libtool=yes @AMDEPBACKSLASH@ +@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) $(libvariancef_la_CFLAGS) $(CFLAGS) -c -o libvariancef_la-dcolumnvariancefa.lo `test -f 'dcolumnvariancefa.c' || echo '$(srcdir)/'`dcolumnvariancefa.c + +libvariancef_la-cvariancefa.lo: cvariancefa.c +@am__fastdepCC_TRUE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libvariancef_la_CFLAGS) $(CFLAGS) -MT libvariancef_la-cvariancefa.lo -MD -MP -MF $(DEPDIR)/libvariancef_la-cvariancefa.Tpo -c -o libvariancef_la-cvariancefa.lo `test -f 'cvariancefa.c' || echo '$(srcdir)/'`cvariancefa.c +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/libvariancef_la-cvariancefa.Tpo $(DEPDIR)/libvariancef_la-cvariancefa.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='cvariancefa.c' object='libvariancef_la-cvariancefa.lo' libtool=yes @AMDEPBACKSLASH@ +@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) $(libvariancef_la_CFLAGS) $(CFLAGS) -c -o libvariancef_la-cvariancefa.lo `test -f 'cvariancefa.c' || echo '$(srcdir)/'`cvariancefa.c + +libvariancef_la-crowvariancefa.lo: crowvariancefa.c +@am__fastdepCC_TRUE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libvariancef_la_CFLAGS) $(CFLAGS) -MT libvariancef_la-crowvariancefa.lo -MD -MP -MF $(DEPDIR)/libvariancef_la-crowvariancefa.Tpo -c -o libvariancef_la-crowvariancefa.lo `test -f 'crowvariancefa.c' || echo '$(srcdir)/'`crowvariancefa.c +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/libvariancef_la-crowvariancefa.Tpo $(DEPDIR)/libvariancef_la-crowvariancefa.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='crowvariancefa.c' object='libvariancef_la-crowvariancefa.lo' libtool=yes @AMDEPBACKSLASH@ +@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) $(libvariancef_la_CFLAGS) $(CFLAGS) -c -o libvariancef_la-crowvariancefa.lo `test -f 'crowvariancefa.c' || echo '$(srcdir)/'`crowvariancefa.c + +libvariancef_la-ccolumnvariancefa.lo: ccolumnvariancefa.c +@am__fastdepCC_TRUE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libvariancef_la_CFLAGS) $(CFLAGS) -MT libvariancef_la-ccolumnvariancefa.lo -MD -MP -MF $(DEPDIR)/libvariancef_la-ccolumnvariancefa.Tpo -c -o libvariancef_la-ccolumnvariancefa.lo `test -f 'ccolumnvariancefa.c' || echo '$(srcdir)/'`ccolumnvariancefa.c +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/libvariancef_la-ccolumnvariancefa.Tpo $(DEPDIR)/libvariancef_la-ccolumnvariancefa.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='ccolumnvariancefa.c' object='libvariancef_la-ccolumnvariancefa.lo' libtool=yes @AMDEPBACKSLASH@ +@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) $(libvariancef_la_CFLAGS) $(CFLAGS) -c -o libvariancef_la-ccolumnvariancefa.lo `test -f 'ccolumnvariancefa.c' || echo '$(srcdir)/'`ccolumnvariancefa.c + +libvariancef_la-zvariancefa.lo: zvariancefa.c +@am__fastdepCC_TRUE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libvariancef_la_CFLAGS) $(CFLAGS) -MT libvariancef_la-zvariancefa.lo -MD -MP -MF $(DEPDIR)/libvariancef_la-zvariancefa.Tpo -c -o libvariancef_la-zvariancefa.lo `test -f 'zvariancefa.c' || echo '$(srcdir)/'`zvariancefa.c +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/libvariancef_la-zvariancefa.Tpo $(DEPDIR)/libvariancef_la-zvariancefa.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='zvariancefa.c' object='libvariancef_la-zvariancefa.lo' libtool=yes @AMDEPBACKSLASH@ +@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) $(libvariancef_la_CFLAGS) $(CFLAGS) -c -o libvariancef_la-zvariancefa.lo `test -f 'zvariancefa.c' || echo '$(srcdir)/'`zvariancefa.c + +libvariancef_la-zrowvariancefa.lo: zrowvariancefa.c +@am__fastdepCC_TRUE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libvariancef_la_CFLAGS) $(CFLAGS) -MT libvariancef_la-zrowvariancefa.lo -MD -MP -MF $(DEPDIR)/libvariancef_la-zrowvariancefa.Tpo -c -o libvariancef_la-zrowvariancefa.lo `test -f 'zrowvariancefa.c' || echo '$(srcdir)/'`zrowvariancefa.c +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/libvariancef_la-zrowvariancefa.Tpo $(DEPDIR)/libvariancef_la-zrowvariancefa.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='zrowvariancefa.c' object='libvariancef_la-zrowvariancefa.lo' libtool=yes @AMDEPBACKSLASH@ +@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) $(libvariancef_la_CFLAGS) $(CFLAGS) -c -o libvariancef_la-zrowvariancefa.lo `test -f 'zrowvariancefa.c' || echo '$(srcdir)/'`zrowvariancefa.c + +libvariancef_la-zcolumnvariancefa.lo: zcolumnvariancefa.c +@am__fastdepCC_TRUE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libvariancef_la_CFLAGS) $(CFLAGS) -MT libvariancef_la-zcolumnvariancefa.lo -MD -MP -MF $(DEPDIR)/libvariancef_la-zcolumnvariancefa.Tpo -c -o libvariancef_la-zcolumnvariancefa.lo `test -f 'zcolumnvariancefa.c' || echo '$(srcdir)/'`zcolumnvariancefa.c +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/libvariancef_la-zcolumnvariancefa.Tpo $(DEPDIR)/libvariancef_la-zcolumnvariancefa.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='zcolumnvariancefa.c' object='libvariancef_la-zcolumnvariancefa.lo' libtool=yes @AMDEPBACKSLASH@ +@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) $(libvariancef_la_CFLAGS) $(CFLAGS) -c -o libvariancef_la-zcolumnvariancefa.lo `test -f 'zcolumnvariancefa.c' || echo '$(srcdir)/'`zcolumnvariancefa.c + +testDoubleVariancef-testDoubleVariancef.o: testDoubleVariancef.c +@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(testDoubleVariancef_CFLAGS) $(CFLAGS) -MT testDoubleVariancef-testDoubleVariancef.o -MD -MP -MF $(DEPDIR)/testDoubleVariancef-testDoubleVariancef.Tpo -c -o testDoubleVariancef-testDoubleVariancef.o `test -f 'testDoubleVariancef.c' || echo '$(srcdir)/'`testDoubleVariancef.c +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/testDoubleVariancef-testDoubleVariancef.Tpo $(DEPDIR)/testDoubleVariancef-testDoubleVariancef.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='testDoubleVariancef.c' object='testDoubleVariancef-testDoubleVariancef.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) $(testDoubleVariancef_CFLAGS) $(CFLAGS) -c -o testDoubleVariancef-testDoubleVariancef.o `test -f 'testDoubleVariancef.c' || echo '$(srcdir)/'`testDoubleVariancef.c + +testDoubleVariancef-testDoubleVariancef.obj: testDoubleVariancef.c +@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(testDoubleVariancef_CFLAGS) $(CFLAGS) -MT testDoubleVariancef-testDoubleVariancef.obj -MD -MP -MF $(DEPDIR)/testDoubleVariancef-testDoubleVariancef.Tpo -c -o testDoubleVariancef-testDoubleVariancef.obj `if test -f 'testDoubleVariancef.c'; then $(CYGPATH_W) 'testDoubleVariancef.c'; else $(CYGPATH_W) '$(srcdir)/testDoubleVariancef.c'; fi` +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/testDoubleVariancef-testDoubleVariancef.Tpo $(DEPDIR)/testDoubleVariancef-testDoubleVariancef.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='testDoubleVariancef.c' object='testDoubleVariancef-testDoubleVariancef.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) $(testDoubleVariancef_CFLAGS) $(CFLAGS) -c -o testDoubleVariancef-testDoubleVariancef.obj `if test -f 'testDoubleVariancef.c'; then $(CYGPATH_W) 'testDoubleVariancef.c'; else $(CYGPATH_W) '$(srcdir)/testDoubleVariancef.c'; fi` + +testFloatVariancef-testFloatVariancef.o: testFloatVariancef.c +@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(testFloatVariancef_CFLAGS) $(CFLAGS) -MT testFloatVariancef-testFloatVariancef.o -MD -MP -MF $(DEPDIR)/testFloatVariancef-testFloatVariancef.Tpo -c -o testFloatVariancef-testFloatVariancef.o `test -f 'testFloatVariancef.c' || echo '$(srcdir)/'`testFloatVariancef.c +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/testFloatVariancef-testFloatVariancef.Tpo $(DEPDIR)/testFloatVariancef-testFloatVariancef.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='testFloatVariancef.c' object='testFloatVariancef-testFloatVariancef.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) $(testFloatVariancef_CFLAGS) $(CFLAGS) -c -o testFloatVariancef-testFloatVariancef.o `test -f 'testFloatVariancef.c' || echo '$(srcdir)/'`testFloatVariancef.c + +testFloatVariancef-testFloatVariancef.obj: testFloatVariancef.c +@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(testFloatVariancef_CFLAGS) $(CFLAGS) -MT testFloatVariancef-testFloatVariancef.obj -MD -MP -MF $(DEPDIR)/testFloatVariancef-testFloatVariancef.Tpo -c -o testFloatVariancef-testFloatVariancef.obj `if test -f 'testFloatVariancef.c'; then $(CYGPATH_W) 'testFloatVariancef.c'; else $(CYGPATH_W) '$(srcdir)/testFloatVariancef.c'; fi` +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/testFloatVariancef-testFloatVariancef.Tpo $(DEPDIR)/testFloatVariancef-testFloatVariancef.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='testFloatVariancef.c' object='testFloatVariancef-testFloatVariancef.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) $(testFloatVariancef_CFLAGS) $(CFLAGS) -c -o testFloatVariancef-testFloatVariancef.obj `if test -f 'testFloatVariancef.c'; then $(CYGPATH_W) 'testFloatVariancef.c'; else $(CYGPATH_W) '$(srcdir)/testFloatVariancef.c'; fi` + +mostlyclean-libtool: + -rm -f *.lo + +clean-libtool: + -rm -rf .libs _libs + +ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES) + list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ + unique=`for i in $$list; do \ + if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ + done | \ + $(AWK) '{ files[$$0] = 1; nonempty = 1; } \ + END { if (nonempty) { for (i in files) print i; }; }'`; \ + mkid -fID $$unique +tags: TAGS + +TAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \ + $(TAGS_FILES) $(LISP) + set x; \ + here=`pwd`; \ + list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ + unique=`for i in $$list; do \ + if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ + done | \ + $(AWK) '{ files[$$0] = 1; nonempty = 1; } \ + END { if (nonempty) { for (i in files) print i; }; }'`; \ + shift; \ + if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \ + test -n "$$unique" || unique=$$empty_fix; \ + if test $$# -gt 0; then \ + $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ + "$$@" $$unique; \ + else \ + $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ + $$unique; \ + fi; \ + fi +ctags: CTAGS +CTAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \ + $(TAGS_FILES) $(LISP) + list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ + unique=`for i in $$list; do \ + if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ + done | \ + $(AWK) '{ files[$$0] = 1; nonempty = 1; } \ + END { if (nonempty) { for (i in files) print i; }; }'`; \ + test -z "$(CTAGS_ARGS)$$unique" \ + || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ + $$unique + +GTAGS: + here=`$(am__cd) $(top_builddir) && pwd` \ + && $(am__cd) $(top_srcdir) \ + && gtags -i $(GTAGS_ARGS) "$$here" + +distclean-tags: + -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags + +check-TESTS: $(TESTS) + @failed=0; all=0; xfail=0; xpass=0; skip=0; \ + srcdir=$(srcdir); export srcdir; \ + list=' $(TESTS) '; \ + $(am__tty_colors); \ + if test -n "$$list"; then \ + for tst in $$list; do \ + if test -f ./$$tst; then dir=./; \ + elif test -f $$tst; then dir=; \ + else dir="$(srcdir)/"; fi; \ + if $(TESTS_ENVIRONMENT) $${dir}$$tst; then \ + all=`expr $$all + 1`; \ + case " $(XFAIL_TESTS) " in \ + *[\ \ ]$$tst[\ \ ]*) \ + xpass=`expr $$xpass + 1`; \ + failed=`expr $$failed + 1`; \ + col=$$red; res=XPASS; \ + ;; \ + *) \ + col=$$grn; res=PASS; \ + ;; \ + esac; \ + elif test $$? -ne 77; then \ + all=`expr $$all + 1`; \ + case " $(XFAIL_TESTS) " in \ + *[\ \ ]$$tst[\ \ ]*) \ + xfail=`expr $$xfail + 1`; \ + col=$$lgn; res=XFAIL; \ + ;; \ + *) \ + failed=`expr $$failed + 1`; \ + col=$$red; res=FAIL; \ + ;; \ + esac; \ + else \ + skip=`expr $$skip + 1`; \ + col=$$blu; res=SKIP; \ + fi; \ + echo "$${col}$$res$${std}: $$tst"; \ + done; \ + if test "$$all" -eq 1; then \ + tests="test"; \ + All=""; \ + else \ + tests="tests"; \ + All="All "; \ + fi; \ + if test "$$failed" -eq 0; then \ + if test "$$xfail" -eq 0; then \ + banner="$$All$$all $$tests passed"; \ + else \ + if test "$$xfail" -eq 1; then failures=failure; else failures=failures; fi; \ + banner="$$All$$all $$tests behaved as expected ($$xfail expected $$failures)"; \ + fi; \ + else \ + if test "$$xpass" -eq 0; then \ + banner="$$failed of $$all $$tests failed"; \ + else \ + if test "$$xpass" -eq 1; then passes=pass; else passes=passes; fi; \ + banner="$$failed of $$all $$tests did not behave as expected ($$xpass unexpected $$passes)"; \ + fi; \ + fi; \ + dashes="$$banner"; \ + skipped=""; \ + if test "$$skip" -ne 0; then \ + if test "$$skip" -eq 1; then \ + skipped="($$skip test was not run)"; \ + else \ + skipped="($$skip tests were not run)"; \ + fi; \ + test `echo "$$skipped" | wc -c` -le `echo "$$banner" | wc -c` || \ + dashes="$$skipped"; \ + fi; \ + report=""; \ + if test "$$failed" -ne 0 && test -n "$(PACKAGE_BUGREPORT)"; then \ + report="Please report to $(PACKAGE_BUGREPORT)"; \ + test `echo "$$report" | wc -c` -le `echo "$$banner" | wc -c` || \ + dashes="$$report"; \ + fi; \ + dashes=`echo "$$dashes" | sed s/./=/g`; \ + if test "$$failed" -eq 0; then \ + echo "$$grn$$dashes"; \ + else \ + echo "$$red$$dashes"; \ + fi; \ + echo "$$banner"; \ + test -z "$$skipped" || echo "$$skipped"; \ + test -z "$$report" || echo "$$report"; \ + echo "$$dashes$$std"; \ + test "$$failed" -eq 0; \ + else :; fi + +distdir: $(DISTFILES) + @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ + topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ + list='$(DISTFILES)'; \ + dist_files=`for file in $$list; do echo $$file; done | \ + sed -e "s|^$$srcdirstrip/||;t" \ + -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ + case $$dist_files in \ + */*) $(MKDIR_P) `echo "$$dist_files" | \ + sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ + sort -u` ;; \ + esac; \ + for file in $$dist_files; do \ + if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ + if test -d $$d/$$file; then \ + dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ + if test -d "$(distdir)/$$file"; then \ + find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ + fi; \ + if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ + cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ + find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ + fi; \ + cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ + else \ + test -f "$(distdir)/$$file" \ + || cp -p $$d/$$file "$(distdir)/$$file" \ + || exit 1; \ + fi; \ + done +check-am: all-am + $(MAKE) $(AM_MAKEFLAGS) $(check_PROGRAMS) + $(MAKE) $(AM_MAKEFLAGS) check-TESTS +check: check-am +all-am: Makefile $(LTLIBRARIES) +installdirs: + for dir in "$(DESTDIR)$(pkglibdir)"; do \ + test -z "$$dir" || $(MKDIR_P) "$$dir"; \ + done +install: install-am +install-exec: install-exec-am +install-data: install-data-am +uninstall: uninstall-am + +install-am: all-am + @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am + +installcheck: installcheck-am +install-strip: + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + `test -z '$(STRIP)' || \ + echo "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'"` install +mostlyclean-generic: + +clean-generic: + +distclean-generic: + -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) + -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) + +maintainer-clean-generic: + @echo "This command is intended for maintainers to use" + @echo "it deletes files that may require special tools to rebuild." +clean: clean-am + +clean-am: clean-checkPROGRAMS clean-generic clean-libtool \ + clean-pkglibLTLIBRARIES mostlyclean-am + +distclean: distclean-am + -rm -rf ./$(DEPDIR) + -rm -f Makefile +distclean-am: clean-am distclean-compile distclean-generic \ + distclean-tags + +dvi: dvi-am + +dvi-am: + +html: html-am + +html-am: + +info: info-am + +info-am: + +install-data-am: + +install-dvi: install-dvi-am + +install-dvi-am: + +install-exec-am: install-pkglibLTLIBRARIES + +install-html: install-html-am + +install-html-am: + +install-info: install-info-am + +install-info-am: + +install-man: + +install-pdf: install-pdf-am + +install-pdf-am: + +install-ps: install-ps-am + +install-ps-am: + +installcheck-am: + +maintainer-clean: maintainer-clean-am + -rm -rf ./$(DEPDIR) + -rm -f Makefile +maintainer-clean-am: distclean-am maintainer-clean-generic + +mostlyclean: mostlyclean-am + +mostlyclean-am: mostlyclean-compile mostlyclean-generic \ + mostlyclean-libtool + +pdf: pdf-am + +pdf-am: + +ps: ps-am + +ps-am: + +uninstall-am: uninstall-pkglibLTLIBRARIES + +.MAKE: check-am install-am install-strip + +.PHONY: CTAGS GTAGS all all-am check check-TESTS check-am clean \ + clean-checkPROGRAMS clean-generic clean-libtool \ + clean-pkglibLTLIBRARIES ctags distclean distclean-compile \ + distclean-generic distclean-libtool distclean-tags distdir dvi \ + dvi-am html html-am info info-am install install-am \ + install-data install-data-am install-dvi install-dvi-am \ + install-exec install-exec-am install-html install-html-am \ + install-info install-info-am install-man install-pdf \ + install-pdf-am install-pkglibLTLIBRARIES install-ps \ + install-ps-am install-strip installcheck installcheck-am \ + installdirs maintainer-clean maintainer-clean-generic \ + mostlyclean mostlyclean-compile mostlyclean-generic \ + mostlyclean-libtool pdf pdf-am ps ps-am tags uninstall \ + uninstall-am uninstall-pkglibLTLIBRARIES + + +# Tell versions [3.59,3.63) of GNU make to not export all variables. +# Otherwise a system limit (for SysV at least) may be exceeded. +.NOEXPORT: diff --git a/2.3-1/src/c/statisticsFunctions/variancef/ccolumnvariancefa.c b/2.3-1/src/c/statisticsFunctions/variancef/ccolumnvariancefa.c new file mode 100644 index 00000000..4b00a087 --- /dev/null +++ b/2.3-1/src/c/statisticsFunctions/variancef/ccolumnvariancefa.c @@ -0,0 +1,35 @@ +/* + * Scilab ( http://www.scilab.org/ ) - This file is part of Scilab + * Copyright (C) 2008-2008 - INRIA - Allan SIMON + * + * 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 "variancef.h" +#include "matrixTranspose.h" + +void ccolumnvariancefa(floatComplex *in1, int lines, int columns,floatComplex *in2, floatComplex* out){ + + int i = 0 ; + + floatComplex* transp = (floatComplex*) malloc ( sizeof (double) *(unsigned int) (lines*columns)); + + + + ctransposea ( in1 , lines , columns , transp ) ; + + + for ( i = 0; i < lines ; i++) + out[i] = cvariancefa ( transp + i*columns , columns , in2 ) ; + + + free (transp); + + +} diff --git a/2.3-1/src/c/statisticsFunctions/variancef/crowvariancefa.c b/2.3-1/src/c/statisticsFunctions/variancef/crowvariancefa.c new file mode 100644 index 00000000..1e4f8549 --- /dev/null +++ b/2.3-1/src/c/statisticsFunctions/variancef/crowvariancefa.c @@ -0,0 +1,22 @@ +/* + * Scilab ( http://www.scilab.org/ ) - This file is part of Scilab + * Copyright (C) 2008-2008 - INRIA - Allan SIMON + * + * 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 "variancef.h" + +void crowvariancefa(floatComplex *in1, int lines, int columns,floatComplex *in2, floatComplex* out){ + + int i = 0 ; + + for ( i = 0; i < columns ; i++) + out[i] = cvariancefa ( in1 + i*lines , lines , in2) ; +} + diff --git a/2.3-1/src/c/statisticsFunctions/variancef/cvariancefa.c b/2.3-1/src/c/statisticsFunctions/variancef/cvariancefa.c new file mode 100644 index 00000000..4f4871c6 --- /dev/null +++ b/2.3-1/src/c/statisticsFunctions/variancef/cvariancefa.c @@ -0,0 +1,35 @@ +/* + * Scilab ( http://www.scilab.org/ ) - This file is part of Scilab + * Copyright (C) 2008-2008 - INRIA - Allan SIMON + * + * 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 "variancef.h" +#include "division.h" + +floatComplex cvariancefa(floatComplex *in1, int size, floatComplex *in2) + +{ + int i = 0 ; + floatComplex temp = FloatComplex (0.0f, 0.0f ); + floatComplex accumulate =FloatComplex (0.0f, 0.0f ); + floatComplex accumulateFre = FloatComplex (0.0f, 0.0f ); + + floatComplex meanf = cmeanfa (in1 , size , in2); + + for(i = 0 ; i < size ; ++i) + { + temp = cpows ( cdiffs (in1[i] , meanf ) ,FloatComplex (2.0f, 0.0f ) ); + temp = cmuls( in2[i] , temp); + + accumulate = cadds( temp , accumulate); + accumulateFre = cadds (in2[i] ,accumulateFre ); + } + return crdivs (accumulate , cdiffs (accumulateFre ,FloatComplex(1.0f,0.0f)) ); +} diff --git a/2.3-1/src/c/statisticsFunctions/variancef/dcolumnvariancefa.c b/2.3-1/src/c/statisticsFunctions/variancef/dcolumnvariancefa.c new file mode 100644 index 00000000..686e6de4 --- /dev/null +++ b/2.3-1/src/c/statisticsFunctions/variancef/dcolumnvariancefa.c @@ -0,0 +1,33 @@ +/* + * Scilab ( http://www.scilab.org/ ) - This file is part of Scilab + * Copyright (C) 2008-2008 - INRIA - Allan SIMON + * + * 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 "variancef.h" +#include "matrixTranspose.h" + +void dcolumnvariancefa(double *in1, int lines, int columns, double *in2, double* out){ + + int i = 0 ; + + double* transp = (double*) malloc ( sizeof (double) *(unsigned int) (lines*columns)); + + + + dtransposea ( in1 , lines , columns , transp ) ; + + + for ( i = 0; i < lines ; i++) + out[i] = dvariancefa ( transp + i*columns , columns , in2) ; + + + free (transp); +} + diff --git a/2.3-1/src/c/statisticsFunctions/variancef/drowvariancefa.c b/2.3-1/src/c/statisticsFunctions/variancef/drowvariancefa.c new file mode 100644 index 00000000..274e8281 --- /dev/null +++ b/2.3-1/src/c/statisticsFunctions/variancef/drowvariancefa.c @@ -0,0 +1,23 @@ +/* + * Scilab ( http://www.scilab.org/ ) - This file is part of Scilab + * Copyright (C) 2008-2008 - INRIA - Allan SIMON + * + * 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 "variancef.h" + +void drowvariancefa(double *in1, int lines, int columns,double *in2, double* out){ + + int i = 0 ; + + for ( i = 0; i < columns ; i++) + out[i] = dvariancefa ( in1 + i*lines , lines , in2 ) ; + +} diff --git a/2.3-1/src/c/statisticsFunctions/variancef/dvariancefa.c b/2.3-1/src/c/statisticsFunctions/variancef/dvariancefa.c new file mode 100644 index 00000000..32bd38ca --- /dev/null +++ b/2.3-1/src/c/statisticsFunctions/variancef/dvariancefa.c @@ -0,0 +1,35 @@ +/* + * Scilab ( http://www.scilab.org/ ) - This file is part of Scilab + * Copyright (C) 2008-2008 - INRIA - Allan SIMON + * + * 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 "variancef.h" + +double dvariancefa(double *in1, int size , double * in2) +{ + int i = 0 ; + double temp = 0.0; + double accumulate = 0.0 ; + double accumulateFre = 0.0 ; + + double meanf = dmeanfa (in1 , size , in2); + + for(i = 0 ; i < size ; ++i) + { + temp = dpows ( (in1[i] - meanf ) ,2 ); + temp *= in2[i]; + + accumulate += temp ; + accumulateFre += in2[i]; + } + + return accumulate / (accumulateFre -1); +} + diff --git a/2.3-1/src/c/statisticsFunctions/variancef/scolumnvariancefa.c b/2.3-1/src/c/statisticsFunctions/variancef/scolumnvariancefa.c new file mode 100644 index 00000000..a0283aa1 --- /dev/null +++ b/2.3-1/src/c/statisticsFunctions/variancef/scolumnvariancefa.c @@ -0,0 +1,47 @@ +/* + * Scilab ( http://www.scilab.org/ ) - This file is part of Scilab + * Copyright (C) 2008-2008 - INRIA - Allan SIMON + * + * 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 "variancef.h" +#include "meanf.h" + + +void scolumnvariancefa(float *in1, int lines, int columns, float *in2, float* out){ + int i = 0; + int j = 0; + float temp = 0.0f; + float accumulate = 0.0f; + float accumulateFre = 0.0f ; + + scolumnmeanfa(in1, lines, columns, in2, out ); + + + /*we first multiply each cell of the input matrix by its coefficient*/ + for (j = 0; j < lines; ++j) + { + accumulate = 0.0f; + accumulateFre= 0.0f; + temp = 0.0f; + + for ( i = 0 ; i < columns; ++i ) + { + temp = spows ( (in1[lines*i + j] - out[j] ) ,2 ); + temp *= in2[lines*i + j]; + + accumulate += temp ; + accumulateFre += in2[lines*i + j]; + } + out[j] = accumulate / (accumulateFre - 1) ; + } + +} + diff --git a/2.3-1/src/c/statisticsFunctions/variancef/srowvariancefa.c b/2.3-1/src/c/statisticsFunctions/variancef/srowvariancefa.c new file mode 100644 index 00000000..36c4783d --- /dev/null +++ b/2.3-1/src/c/statisticsFunctions/variancef/srowvariancefa.c @@ -0,0 +1,21 @@ +/* + * Scilab ( http://www.scilab.org/ ) - This file is part of Scilab + * Copyright (C) 2008-2008 - INRIA - Allan SIMON + * + * 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 "variancef.h" + +void srowvariancefa(float *in1, int lines, int columns, float *in2, float* out){ + + int i = 0 ; + + for ( i = 0; i < columns ; i++) + out[i] = svariancefa ( in1 + i*lines , lines,in2 + i*lines ) ; +} diff --git a/2.3-1/src/c/statisticsFunctions/variancef/svariancefa.c b/2.3-1/src/c/statisticsFunctions/variancef/svariancefa.c new file mode 100644 index 00000000..f49d2b38 --- /dev/null +++ b/2.3-1/src/c/statisticsFunctions/variancef/svariancefa.c @@ -0,0 +1,46 @@ +/* + * Scilab ( http://www.scilab.org/ ) - This file is part of Scilab + * Copyright (C) 2008-2008 - INRIA - Allan SIMON + * + * 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 "variancef.h" + +/* +s_moyennepond = meanf(x, fre) +s_ecartmoyenne = x - s_moyennepond +s_ecartcarre = s_ecartmoyenne.^2 +s_ecartcarrepondere = s_ecartcarre .* fre +s = sum( s_ecartcarrepondere )/(sumfre - 1), +*/ +float svariancefa(float *in1, int size, float* in2) +{ + int i = 0 ; + float temp = 0.0f; + float accumulate = 0.0f ; + float accumulateFre = 0.0f ; + + float meanf = smeanfa (in1 , size , in2); + /*printf ("\nmeanf %lf \n" ,meanf);*/ + for(i = 0 ; i < size ; ++i) + { + + temp = spows ( (in1[i] - meanf ) ,2 ); + temp *= in2[i]; + + accumulate += temp ; + accumulateFre += in2[i]; + + + } + + return accumulate / (accumulateFre - 1) ; +} + + diff --git a/2.3-1/src/c/statisticsFunctions/variancef/testDoubleVariance.c b/2.3-1/src/c/statisticsFunctions/variancef/testDoubleVariance.c new file mode 100644 index 00000000..b85a1571 --- /dev/null +++ b/2.3-1/src/c/statisticsFunctions/variancef/testDoubleVariance.c @@ -0,0 +1,335 @@ +/* + * 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 <assert.h> +#include <stdio.h> + +#include "variance.h" + +#define SINGLE 1.323312455 +#define LINES 7 +#define COLUMNS 10 +#define MATRIX {0.102326436434,0.939044147730,0.638607255649,0.059883427806,0.311199211050,\ + 0.377510951832,0.909709410276,0.928138985299,0.855155082885,0.308869514614,\ +0.729239261709,0.127006734256,0.242402311414,0.807912770193,0.621117659844,\ + 0.081452373881,0.088844371960,0.587072817143,0.068080495112,0.995457543526,\ +0.835322400089,0.656235548668,0.767905956600,0.706818781793,0.187699332368,\ + 0.568810169585,0.401039466728,0.397196868435,0.483212330844,0.161224133335,\ +0.932864250615,0.719208867755,0.262409000657,0.931377100293,0.596724558622,\ + 0.310327019077,0.350161732174,0.104841318447,0.830732351169,0.804621329065,\ +0.050784428138,0.551920620725,0.125952405389,0.083156193607,0.420623748098,\ + 0.168616071343,0.707545555662,0.104633864947,0.465604968835,0.489758284763,\ +0.167727907188,0.760689914692,0.454900974408,0.063926273491,0.87152507063,0.978668818716,\ + 0.135898929089,0.484713065904,0.785042577423,0.049412418623,\ +0.947593610268,0.884073690511,0.212796610314,0.654832502827,0.007690255996,\ + 0.031808692031,0.706323316786,0.008731670678,0.270014822017,0.153652121313} + + +#define MATRIXROW {0.1688249423502767021521 , 0.0729081225272336097554 , 0.0579879770921138057438 , 0.1499989757031960635469 , 0.0850863194040760717485 , 0.1085086384507867873772 , 0.0969379859569881041637 , 0.1072816602642319844252 , 0.0913638718167188862429 , 0.1285778184208021535095 } +#define MATRIXCOL { 0.1233078274276283442523, \ + 0.1232135941992091865416 , \ + 0.0540377259589001762707 , \ + 0.0925512303008872161403 , \ + 0.0555055644879708723338 , \ + 0.1276299219577190779962 , \ + 0.1385167433745558840386 } + + +#define IMATRIX {0.05826747464016080,0.99946373142302036,0.85600351681932807,0.62329693790525198,\ + 0.49792320514097810,0.44210509583353996,0.55833499459549785,0.09633230511099100,\ + 0.80100952507928014,0.34466254524886608,\ +0.48831309471279383,0.95087061496451497,0.01332767866551876,0.76261807000264525,\ + 0.74346329551190138,0.65157829830422997,0.57006288319826126,0.70580983115360141,\ + 0.51323400903493166,0.64977857517078519,\ +0.80352442665025592,0.69910932797938585,0.69258948462083936,0.91169391758739948,\ + 0.92454590043053031,0.27637310232967138,0.31692579621449113,0.86305770650506020,\ + 0.20109100220724940,0.01225362811237574,\ +0.38199013099074364,0.96006405679509044,0.16440964583307505,0.59608811559155583,\ + 0.72101737372577190,0.58661046391353011,0.99326277803629637,0.00761850038543344,\ + 0.78608208894729614,0.89965870184823871,\ +0.43115562805905938,0.81857266277074814,0.83410377753898501,0.55516970623284578,\ + 0.51345925079658628,0.04770902730524540,0.80747798969969153,0.80489510949701071,\ + 0.78650354826822877,0.30791273340582848,\ +0.75731822755187750,0.53423820668831468,0.42618893459439278,0.85448804078623652,\ + 0.92601215932518244,0.94169309409335256,0.85547966323792934,0.59637623047456145,\ + 0.69515300076454878,0.18359116325154901,\ +0.01200280850753188,0.2255702270194888,0.34853330114856362,0.55313225090503693,\ + 0.63695094687864184,0.96132039744406939,0.50314606027677655,0.11768362112343311,\ + 0.42481321236118674,0.52963322307914495} + +#define RMATRIX {0.53868199465796351,0.65326874051243067,0.37497402401641011,0.60422550700604916,\ + 0.33622304117307067,0.03531436901539564,0.33213760564103723,0.39493087679147720,\ + 0.04170337272807956,0.87363853026181459,\ +0.65950810909271240,0.31221040291711688,0.15333442110568285,0.66478573577478528,\ + 0.44319023378193378,0.40884594758972526,0.94536898937076330,0.67733758920803666,\ + 0.18673646822571754,0.92331133363768458,\ +0.55921846115961671,0.75012728199362755,0.23257926432415843,0.57102064136415720,\ + 0.60969385923817754,0.67336730472743511,0.07624059682711959,0.10437540244311094,\ + 0.95672677317634225,0.19771346449851990,\ +0.05278092902153730,0.75808868417516351,0.17633479088544846,0.01146994484588504,\ + 0.36732212174683809,0.19948644982650876,0.52714426256716251,0.21445603063330054,\ + 0.94751045759767294,0.04272260749712586,\ +0.03257346292957664,0.53217577841132879,0.87635089689865708,0.15471007302403450,\ + 0.25448470888659358,0.91815057490020990,0.72509902389720082,0.87545845471322536,\ + 0.05635281419381499,0.01432112138718367,\ +0.57406943850219250,0.80984140699729323,0.01664119493216276,0.93888836959376931,\ + 0.11264799535274506,0.66036546928808093,0.76042845565825701,0.25908330874517560,\ + 0.88014078326523304,0.70332178613170981,\ +0.94614937948063016,0.78529163636267185,0.20241560926660895,0.10981105919927359,\ + 0.75415370846167207,0.15320260450243950,0.59521253732964396,0.71318271104246378,\ + 0.51107599260285497,0.52125945501029491} + + + + + + +#define IMATRIXROW {-0.0419293790250184,-0.05416405376783551,+0.11775191182077104,+0.08015791690354153,+0.00011032748454003,\ +-0.10124210045965254,0.06720614014223115,+0.02470873836336094,-0.07082037296251543,-0.00621987869853545} + +#define RMATRIXROW {0.01439621349781126,-0.04697393442028135,-0.03018604392150223,0.09765990436118642,0.01606884471097247,\ +-0.00604250542333471,0.02870576510687836,-0.04985742926427023,0.12356001472881707,0.05909180726174274} + +#define IMATRIXCOL {-0.01904810719805961,+0.04121453132770223,+0.00378553967089328,\ ++0.10307670507342410,+0.03497427750676810,+0.01761849804019567,-0.10182321471060848} + +#define RMATRIXCOL {-0.02739893277693160,0.01792852626358409,-0.02205084134302381,\ +-0.01012610864032573,0.07317682977907164,0.04762062457313784,0.00849011627117621} + + +static void dvariancesTest (void ) { + + double toTest = dvariances (SINGLE) ; + + assert ( fabs ( toTest - SINGLE ) / fabs( toTest) < 1e-16 ) ; +} + + +static void drowvariancesTest (void ) { + + double toTest = drowvariances (SINGLE) ; + + assert ( fabs ( toTest - SINGLE ) / fabs( toTest) < 1e-16 ) ; +} + +static void dcolumnvariancesTest (void) { + + double toTest = dcolumnvariances (SINGLE) ; + + assert ( fabs ( toTest - SINGLE ) / fabs( toTest) < 1e-16 ) ; +} + + +static void zvariancesTest (void ) { + + doubleComplex toTest = zvariances ( DoubleComplex ( SINGLE , SINGLE ) ); + + assert ( fabs ( zreals( toTest) - SINGLE ) / fabs( zreals( toTest)) < 1e-16 ) ; + assert ( fabs ( zimags( toTest) - SINGLE ) / fabs( zimags( toTest)) < 1e-16 ) ; +} + +static void zrowvariancesTest (void ) { + + doubleComplex toTest = zrowvariances ( DoubleComplex ( SINGLE , SINGLE ) ); + + assert ( fabs ( zreals( toTest) - SINGLE ) / fabs( zreals( toTest)) < 1e-16 ) ; + assert ( fabs ( zimags( toTest) - SINGLE ) / fabs( zimags( toTest)) < 1e-16 ) ; +} + +static void zcolumnvariancesTest (void ) { + + doubleComplex toTest = zrowvariances ( DoubleComplex ( SINGLE , SINGLE ) ); + + assert ( fabs ( zreals( toTest) - SINGLE ) / fabs( zreals( toTest)) < 1e-16 ) ; + assert ( fabs ( zimags( toTest) - SINGLE ) / fabs( zimags( toTest)) < 1e-16 ) ; +} + + + + + + +static void dvarianceaTest ( void){ + + double mtoTest[] = MATRIX ; + double result = 0.1007532974338590653352; + double out = dvariancea ( mtoTest , LINES*COLUMNS ); ; + + + + printf ( "out : %1.20f\t result : %1.20f\t\n" , out , result ) ; + + + + assert ( fabs ( out - result ) / fabs( out ) < 3e-16 ) ; + +} + + +static void drowvarianceaTest ( void ) +{ + int i = 0 ; + + double mtoTest[] = MATRIX ; + double result[LINES] = MATRIXCOL ; + double out[LINES] ; + + drowvariancea ( mtoTest , COLUMNS , LINES , out ) ; + + for ( i = 0 ; i < LINES ; i++) + { + printf ( "ROWout : %1.20f\t result : %1.20f\t\n" , out[i] , result [i] ) ; + assert ( fabs ( out[i] - result[i] ) / fabs( out[i] ) < 3e-16 ) ; + } + +} + +static void dcolumnvarianceaTest ( void ) +{ + int i = 0 ; + + double mtoTest[] = MATRIX ; + double result[COLUMNS] = MATRIXROW ; + double out[ COLUMNS] ; + + + + dcolumnvariancea ( mtoTest , COLUMNS, LINES , out ) ; + + for ( i = 0 ; i < COLUMNS; i++) + { + printf ( "%dCOLout : %1.20f\t result : %1.20f\t\n" ,i, out[i] , result [i] ) ; } + for ( i = 0 ; i < COLUMNS; i++) + { + assert ( fabs ( out[i] - result[i] ) / fabs( out[i] ) < 3e-16 ) ; + } + +} + + + + +static void zvarianceaTest ( void){ + + double rmtoTest [] = RMATRIX ; + double imtoTest [] = IMATRIX ; + doubleComplex Result = DoubleComplex ( 0.01225832057910708 , 0.01071188208687752 ); + + doubleComplex* mtoTest = DoubleComplexMatrix ( rmtoTest , imtoTest , LINES*COLUMNS ) ; + doubleComplex out = zvariancea ( mtoTest , LINES*COLUMNS ); ; + + assert ( fabs( zreals(out) - zreals (Result) ) / fabs (zreals (out)) < 3e-16 ); + assert( fabs( zimags(out) - zimags (Result )) / fabs (zimags (out)) < 3e-16 ); + + +} + +static void zrowvarianceaTest (void ) { + + int i = 0 ; + + double rmtoTest [] = RMATRIX ; + double imtoTest [] = IMATRIX ; + double rResult [] = RMATRIXROW; + double iResult [] = IMATRIXROW ; + + doubleComplex out[COLUMNS]; + doubleComplex* mtoTest = DoubleComplexMatrix ( rmtoTest , imtoTest , LINES*COLUMNS ) ; + doubleComplex* Result = DoubleComplexMatrix ( rResult , iResult , COLUMNS ); + + zrowvariancea ( mtoTest , LINES , COLUMNS , out ) ; + + /*FIXME test failed under 1-e04 precision */ + for ( i = 0 ; i < COLUMNS ; i++) + { + printf ( "%d out : %e %e \t result %e %e \n" , i , zreals(out[i]) , zimags(out[i]), zreals(Result[i]) ,zimags( Result[i])); + assert ( fabs( zreals(out[i]) - zreals (Result[i]) ) / fabs (zreals (out[i])) < 3e-16 ); + assert( fabs( zimags(out[i]) - zimags (Result[i])) / fabs (zimags (out[i])) < 3e-16); + + } +} + + + +static void zcolumnvarianceaTest ( void) { + int i = 0 ; + + double rmtoTest [] = RMATRIX ; + double imtoTest [] = IMATRIX ; + double rResult [] = RMATRIXCOL; + double iResult [] = IMATRIXCOL ; + + doubleComplex out[LINES]; + doubleComplex* mtoTest = DoubleComplexMatrix ( rmtoTest , imtoTest , LINES*COLUMNS ) ; + doubleComplex* Result = DoubleComplexMatrix ( rResult , iResult , LINES ); + + zcolumnvariancea ( mtoTest , LINES , COLUMNS , out ) ; + + + for ( i = 0 ; i < LINES ; i++) + { + printf ( "%d out : %e %e \t result %e %e \n" , i , zreals(out[i]) , zimags(out[i]), zreals(Result[i]) ,zimags( Result[i])); + assert ( fabs( zreals(out[i]) - zreals (Result[i]) ) / fabs (zreals (out[i])) < 3e-16 ); + assert( fabs( zimags(out[i]) - zimags (Result[i])) / fabs (zimags (out[i])) < 3e-16); + + } + + + +} + + + + + +static int testDoubleVariance (void) { + printf("\n\n\n\n*********************\n"); + printf("***** Double Tests ****\n"); + printf("*********************\n"); + + printf("\n\t>>>>singleton real Tests\n"); + dcolumnvariancesTest () ; + dvariancesTest () ; + drowvariancesTest () ; + + + printf("\n\t>>>>singleton complex Tests\n"); + + zrowvariancesTest () ; + zcolumnvariancesTest () ; + zvariancesTest () ; + + + + printf("\n\t>>>>array real Tests\n"); + + dvarianceaTest () ; + + dcolumnvarianceaTest () ; + drowvarianceaTest ( ); + + + printf("\n\t>>>>array complex Tests\n"); + + zvarianceaTest () ; + zrowvarianceaTest ( ); + zcolumnvarianceaTest () ; + + + return 0; +} + +int main(void) { + assert(testDoubleVariance () == 0); + return 0; +} + diff --git a/2.3-1/src/c/statisticsFunctions/variancef/testDoubleVariancef.c b/2.3-1/src/c/statisticsFunctions/variancef/testDoubleVariancef.c new file mode 100644 index 00000000..1102ae18 --- /dev/null +++ b/2.3-1/src/c/statisticsFunctions/variancef/testDoubleVariancef.c @@ -0,0 +1,373 @@ +/* + * Scilab ( http://www.scilab.org/ ) - This file is part of Scilab + * Copyright (C) 2008-2008 - INRIA - Allan SIMON + * + * 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 <assert.h> +#include <stdio.h> +#include <math.h> +#include "variancef.h" + + +/* #define LOCAL_DEBUG */ + +#define ERROR(x) printf("diff = %e\n", x) + +static int dvariancefsTest(void) { + + + printf("\n>>>> variancef Double Scalar Test\n"); + printf("result : %e " ,dvariancefs(value1,coef1)) ; + + assert( ( dvariancefs(3.0,56.0) ) == 0.0 ); + assert( ( dvariancefs( 1.123456789 ,2.0) ) == 0.0 ); + + + return 0; +} + +static int dvariancefaTest(void) { + double table1[3] = {3.0, 6.0, 9.0}; + double coef1[3] = {10.0, 2.0, 6.0}; + + double table2[5] = {3.186784563, + 4.186784563, + 5.186784563, + 6.186784563, + 7.186784563}; + + double coef2[5] = {3.0, + 4.0, + 5.0, + 6.0, + 7.0}; + + printf("\n>>>> variancef Double Array Test\n"); + printf("result1 : %e " ,dvariancefa(table1, 3, coef1)) ; + printf("result2 : %e " ,dvariancefa(table2, 5, coef2)) ; + assert((dvariancefa(table1, 3, coef1) - 8.000000000 )/ dvariancefa(table1, 3 ,coef1) < 1e-6); + assert((dvariancefa(table2, 5, coef2) - 1.916666666 )/ dvariancefa(table2, 5 ,coef2) < 1e-6); + return 0; +} + +/* +static int dcolumnvariancefaTest(void) { + int i = 0; + double table1[9] = {1.0, 4.0, 7.0, 2.0 , 5.0, 8.0, 3.0, 6.0, 9.0}; + double coef1[9] = {10.0, 1.0, 5.0,11.0 , 2.0, 6.0,12.0, 3.0, 7.0}; + double table2[10] = {1.0, 2.0, 3.0, 4.0 , 5.0, 6.0, 7.0, 8.0, 9.0, 10.0}; + double coef2[10] = {11.0, 12.0, 13.0, 14.0 , 15.0, 16.0, 17.0, 18.0, 19.0, 20.0}; + double columnMeanmedTable1_3_3[3] = {0}; + double columnMeanmedTable1_1_9[1] = {0}; + double columnMeanmedTable1_9_1[9] = {0}; + double columnMeanmedTable2_2_5[2] = {0}; + double columnMeanmedTable2_5_2[5] = {0}; + + printf("\n>>>> Column Variancef Double Array Test\n"); + + [ 1 2 3 ] [10 11 12 ] + [ 4 5 6 ].*[ 1 2 3 ] => [ 68 32 146 ] + [ 7 8 9 ] [ 5 6 7 ] + + dcolumnvariancefa(table1, 3, 3, coef1 ,columnMeanmedTable1_3_3); + assert( ( fabs(columnMeanmedTable1_3_3[0] ) - ( 68.0 / 33.0 ) ) / fabs ( columnMeanmedTable1_3_3[0] ) < 1e-6 ); + assert( ( fabs(columnMeanmedTable1_3_3[1] ) - ( 32.0 / 6.0 ) ) / fabs ( columnMeanmedTable1_3_3[1] ) < 1e-6 ); + assert( ( fabs(columnMeanmedTable1_3_3[2] ) - ( 146.0 / 18.0 ) ) / fabs ( columnMeanmedTable1_3_3[2] ) < 1e-6 ); + + + [ 1 2 3 4 5 6 7 8 9 ] => [ 45 ] + + dcolumnvariancefa(table1, 1, 9, coef1 ,columnMeanmedTable1_1_9); + printf("result qui foire : %e\n " ,columnMeanmedTable1_1_9[0]) ; + assert( ( fabs(columnMeanmedTable1_1_9[0] ) - ( 1.146666666f ) ) / fabs ( columnMeanmedTable1_1_9[0] ) < 1e-6 ); + + + [ 1 ] + [ 2 ] + [ 3 ] + [ 4 ] + [ 5 ] => [ 1 2 3 4 5 6 7 8 9 ] + [ 6 ] + [ 7 ] + [ 8 ] + [ 9 ] + + dcolumnvariancefa(table1, 9, 1, coef1, columnMeanmedTable1_9_1); + for ( i = 0 ; i < 9 ; ++i) { + printf("columnMeanmedTable1_9_1[%d] = %e\n", i, columnMeanmedTable1_9_1[i]); + assert(columnMeanmedTable1_9_1[i] == table1[i]); + } + + + [ 1 3 5 7 9 ] .* [ 11 13 15 17 19 ] + [ 2 4 6 8 10 ] [ 12 14 16 18 20 ]=> [ 415 520 ] + + dcolumnvariancefa(table2, 2, 5, coef2 , columnMeanmedTable2_2_5); + assert( ( fabs(columnMeanmedTable2_2_5[0] ) - ( 415.0 / 75.0 ) ) / fabs ( columnMeanmedTable2_2_5[0] ) < 1e-6 ); + assert( ( fabs(columnMeanmedTable2_2_5[1] ) - ( 520.0 / 80.0 ) ) / fabs ( columnMeanmedTable2_2_5[1] ) < 1e-6 ); + for ( i = 0 ; i < 2 ; ++i) { + printf("columnMeanmedTable2_2_5[%d] = %e\n", i, columnMeanmedTable2_2_5[i]); + } + + + [ 1 6 ] [ 11 16 ] + [ 2 7 ] [ 12 17 ] => [ 107 143 183 227 275 ] + [ 3 8 ].*[ 13 18 ] + [ 4 9 ] [ 14 19 ] + [ 5 10 ] [ 15 20 ] + + + dcolumnvariancefa(table2, 5, 2, coef2 ,columnMeanmedTable2_5_2); + assert( ( fabs(columnMeanmedTable2_5_2[0] ) - ( 107.0 / 27.0 ) ) / fabs ( columnMeanmedTable2_5_2[0] ) < 1e-6 ); + assert( ( fabs(columnMeanmedTable2_5_2[1] ) - ( 143.0 / 29.0 ) ) / fabs ( columnMeanmedTable2_5_2[1] ) < 1e-6 ); + assert( ( fabs(columnMeanmedTable2_5_2[2] ) - ( 183.0 / 31.0 ) ) / fabs ( columnMeanmedTable2_5_2[2] ) < 1e-6 ); + assert( ( fabs(columnMeanmedTable2_5_2[3] ) - ( 227.0 / 33.0 ) ) / fabs ( columnMeanmedTable2_5_2[3] ) < 1e-6 ); + assert( ( fabs(columnMeanmedTable2_5_2[4] ) - ( 275.0 / 35.0 ) ) / fabs ( columnMeanmedTable2_5_2[4] ) < 1e-6 ); + for ( i = 0 ; i < 5 ; ++i) { + printf("columnMeanmedTable2_5_2[%d] = %e\n", i, columnMeanmedTable2_5_2[i]); + } + + return 0; +} +*/ +/* +static int srowvariancefaTest(void) { + int i = 0; + double table1[9] = {1.0, 4.0, 7.0, 2.0 , 5.0, 8.0, 3.0, 6.0, 9.0}; + double coef1[9] = {10.0, 1.0, 5.0,11.0 , 2.0, 6.0,12.0, 3.0, 7.0}; + double table2[10] = {1.0, 2.0, 3.0, 4.0 , 5.0, 6.0, 7.0, 8.0, 9.0, 10.0}; + double coef2[10] = {11.0, 12.0, 13.0, 14.0 , 15.0, 16.0, 17.0, 18.0, 19.0, 20.0}; + double rowMeanmedTable1_3_3[3] = {0}; + double rowMeanmedTable1_1_9[9] = {0}; + double rowMeanmedTable1_9_1[1] = {0}; + double rowMeanmedTable2_2_5[5] = {0}; + double rowMeanmedTable2_5_2[2] = {0}; + + printf("\n>>>> Row Mean Double Array Test\n"); + + [ 1 2 3 ] [10 11 12 ] + [ 4 5 6 ].*[ 1 2 3 ] => [ 49 80 117 ] + [ 7 8 9 ] [ 5 6 7 ] + + srowvariancefa(table1, 3, 3, coef1 , rowMeanmedTable1_3_3); + for ( i = 0 ; i < 3 ; ++i) { + printf("rowMeanmedTable1_3_3[%d] = %e\n", i, rowMeanmedTable1_3_3[i]); + } + assert( ( fabs(rowMeanmedTable1_3_3[0] ) - ( 49.0 / 16.0 ) ) / fabs ( rowMeanmedTable1_3_3[0] ) < 1e-6 ); + assert( ( fabs(rowMeanmedTable1_3_3[1] ) - ( 80.0 / 19.0 ) ) / fabs ( rowMeanmedTable1_3_3[1] ) < 1e-6 ); + assert( ( fabs(rowMeanmedTable1_3_3[2] ) - ( 117.0 / 22.0 ) ) / fabs ( rowMeanmedTable1_3_3[2] ) < 1e-6 ); + + + [ 1 ] + [ 2 ] + [ 3 ] + [ 4 ] + [ 5 ] => [ 1 2 3 4 5 6 7 8 9 ] + [ 6 ] + [ 7 ] + [ 8 ] + [ 9 ] + + srowvariancefa(table1, 1, 9, coef1, rowMeanmedTable1_1_9); + for ( i = 0 ; i < 9 ; ++i) { + printf("rowMeanmedTable1_1_9[%d] = %e\n", i, rowMeanmedTable1_1_9[i]); + assert(rowMeanmedTable1_1_9[i] == table1[i]); + } + + + [ 1 2 3 4 5 6 7 8 9 ] => [ 246 ] + + srowvariancefa(table1, 9, 1, coef1, rowMeanmedTable1_9_1); + assert( ( fabs(rowMeanmedTable1_9_1[0] ) - ( 246.0 / 57.0 ) ) / fabs ( rowMeanmedTable1_9_1[0] ) < 1e-6 ); + + + [ 1 3 5 7 9 ] .* [ 11 13 15 17 19 ] + [ 2 4 6 8 10 ] [ 12 14 16 18 20 ] => [ 3 7 11 15 19 ] + + srowvariancefa(table2, 2, 5, coef2, rowMeanmedTable2_2_5); + for ( i = 0 ; i < 5 ; ++i) { + printf("rowMeanmedTable2_2_5[%d] = %e\n", i, rowMeanmedTable2_2_5[i]); + } + assert( ( fabs(rowMeanmedTable2_2_5[0] ) - ( 35.0 / 23.0 ) ) / fabs ( rowMeanmedTable2_2_5[0] ) < 1e-6 ); + assert( ( fabs(rowMeanmedTable2_2_5[1] ) - ( 95.0 / 27.0 ) ) / fabs ( rowMeanmedTable2_2_5[1] ) < 1e-6 ); + assert( ( fabs(rowMeanmedTable2_2_5[2] ) - ( 171.0 / 31.0 ) ) / fabs ( rowMeanmedTable2_2_5[2] ) < 1e-6 ); + assert( ( fabs(rowMeanmedTable2_2_5[3] ) - ( 263.0 / 35.0 ) ) / fabs ( rowMeanmedTable2_2_5[3] ) < 1e-6 ); + assert( ( fabs(rowMeanmedTable2_2_5[4] ) - ( 371.0 / 39.0 ) ) / fabs ( rowMeanmedTable2_2_5[4] ) < 1e-6 ); + + + return 0; +} +*/ + +static int zvariancefsTest(void) { + + printf("\n>>>> Mean Double Complex Scalar Test\n"); + assert( zreals(zvariancefs(DoubleComplex(3.0, 0.0),DoubleComplex(3.0, 0.0))) == 0.0 ); + assert( zimags(zvariancefs(DoubleComplex(3.0, 0.0),DoubleComplex(3.0, 0.0))) == 0.0 ); + assert( zreals(zvariancefs(DoubleComplex(1.123456789, 1.123456789),DoubleComplex(9.0, 0.0))) == 0.0 ); + assert( zimags(zvariancefs(DoubleComplex(1.123456789, 1.123456789),DoubleComplex(9.0, 0.0))) == 0.0 ); + + return 0; +} + + + +static int zvariancefaTest(void) { + + double tableR1[9] = {1.0, 4.0, 7.0, 2.0 , 5.0, 8.0, 3.0, 6.0, 9.0}; + double tableI1[9] = {1.0, 2.0, 3.0, 4.0 , 5.0, 6.0, 7.0, 8.0, 9.0}; + double coefR1[9] = {10.0, 1.0, 5.0,11.0 , 2.0, 6.0,12.0, 3.0, 7.0}; + double coefI1[9] = { 0.0, 0.0, 0.0, 0.0 , 0.0, 0.0, 0.0, 0.0, 0.0}; + + doubleComplex* table1 = DoubleComplexMatrix (tableR1, tableI1, 9); + doubleComplex* coef1 = DoubleComplexMatrix (coefR1, coefI1, 9); + doubleComplex result =DoubleComplex(0.0 , 0.0); + + printf("\n>>>> Mean Double Complex Array Test\n"); + result = zvariancefa(table1, 9, coef1); + /*printf("\nresult : %e \t+ %e i " ,zreals(result) ,zimags(result)) ;*/ + + assert( fabs(zreals(result) - ( 1.3834586f ) ) / fabs ( zreals(result) ) < 1e-6 ); + assert( fabs(zimags(result) - ( 9.6090226f ) ) / fabs ( zimags(result) ) < 1e-6 ); + + return 0; +} + +/* +static int crowvariancefaTest(void) { + + int i = 0 ; + + double tableR1[9] = {1.0, 4.0, 7.0, 2.0 , 5.0, 8.0, 3.0, 6.0, 9.0}; + double tableI1[9] = {1.0, 2.0, 3.0, 4.0 , 5.0, 6.0, 7.0, 8.0, 9.0}; + double coefR1[9] = {10.0, 1.0, 5.0,11.0 , 2.0, 6.0,12.0, 3.0, 7.0}; + double coefI1[9] = { 0.0, 0.0, 0.0, 0.0 , 0.0, 0.0, 0.0, 0.0, 0.0}; + + double tableR2[10] = {1.0, 4.0, 7.0, 2.0 , 5.0, 8.0, 3.0, 6.0, 9.0, 10.0}; + double tableI2[10] = {1.0, 2.0, 3.0, 4.0 , 5.0, 6.0, 7.0, 8.0, 9.0, 15.0}; + double coefR2[10] = {10.0, 1.0, 5.0,11.0 , 2.0, 6.0,12.0, 3.0, 7.0, 19.0}; + double coefI2[10] = { 0.0, 0.0, 0.0, 0.0 , 0.0, 0.0, 0.0, 0.0, 0.0, 0.0}; + + doubleComplex* table1 = DoubleComplexMatrix (tableR1, tableI1, 9); + doubleComplex* coef1 = DoubleComplexMatrix (coefR1, coefI1, 9); + + doubleComplex* table2 = DoubleComplexMatrix (tableR2, tableI2, 9); + doubleComplex* coef2 = DoubleComplexMatrix (coefR2, coefI2, 9); + + doubleComplex rowMeanmedTable1_3_3[3] = {DoubleComplex(0.0, 0.0)}; + + doubleComplex rowMeanmedTable1_1_9[9] = {DoubleComplex(0.0, 0.0)}; + doubleComplex rowMeanmedTable1_9_1[1] = {DoubleComplex(0.0, 0.0)}; + doubleComplex rowMeanmedTable2_2_5[5] = {DoubleComplex(0.0, 0.0)}; + doubleComplex rowMeanmedTable2_5_2[2] = {DoubleComplex(0.0, 0.0)}; + + printf("\n>>>> Row variancef Double Complex Array Test\n"); + + + + crowvariancefa(table1 , 3 , 3 , coef1 , rowMeanmedTable1_3_3); + + for (i = 0 ; i < 3 ; ++i ) + { + + printf("rowMeanmedTable_3_3[%d] = %e + %ei\n", i, zreals(rowMeanmedTable1_3_3[i]), zimags(rowMeanmedTable1_3_3[i])); + } + assert( ( fabs(zimags(rowMeanmedTable1_3_3[0]) ) - ( 27.0 / 16.0 ) ) / fabs ( zimags(rowMeanmedTable1_3_3[0]) ) < 1e-6 ); + assert( ( fabs(zreals(rowMeanmedTable1_3_3[0]) ) - ( 49.0 / 16.0 ) ) / fabs ( zreals(rowMeanmedTable1_3_3[0]) ) < 1e-6 ); + + assert( ( fabs(zimags(rowMeanmedTable1_3_3[1]) ) - ( 90.0 / 19.0 ) ) / fabs ( zimags(rowMeanmedTable1_3_3[1]) ) < 1e-6 ); + assert( ( fabs(zreals(rowMeanmedTable1_3_3[1]) ) - ( 80.0 / 19.0 ) ) / fabs ( zreals(rowMeanmedTable1_3_3[1]) ) < 1e-6 ); + + assert( ( fabs(zimags(rowMeanmedTable1_3_3[2]) ) - (171.0 / 22.0 ) ) / fabs ( zimags(rowMeanmedTable1_3_3[2]) ) < 1e-6 ); + assert( ( fabs(zreals(rowMeanmedTable1_3_3[2]) ) - (117.0 / 22.0 ) ) / fabs ( zreals(rowMeanmedTable1_3_3[2]) ) < 1e-6 ); + + + + + return 0; +} +*/ + + +/* +static int scolumnvariancefaTest(void) { + + int i = 0 ; + + double tableR1[9] = {1.0, 4.0, 7.0, 2.0 , 5.0, 8.0, 3.0, 6.0, 9.0}; + double tableI1[9] = {1.0, 2.0, 3.0, 4.0 , 5.0, 6.0, 7.0, 8.0, 9.0}; + double coefR1[9] = {10.0, 1.0, 5.0,11.0 , 2.0, 6.0,12.0, 3.0, 7.0}; + double coefI1[9] = { 0.0, 0.0, 0.0, 0.0 , 0.0, 0.0, 0.0, 0.0, 0.0}; + + double tableR2[10] = {1.0, 4.0, 7.0, 2.0 , 5.0, 8.0, 3.0, 6.0, 9.0, 10.0}; + double tableI2[10] = {1.0, 2.0, 3.0, 4.0 , 5.0, 6.0, 7.0, 8.0, 9.0, 15.0}; + double coefR2[10] = {10.0, 1.0, 5.0,11.0 , 2.0, 6.0,12.0, 3.0, 7.0, 19.0}; + double coefI2[10] = { 0.0, 0.0, 0.0, 0.0 , 0.0, 0.0, 0.0, 0.0, 0.0, 0.0}; + + doubleComplex* table1 = DoubleComplexMatrix (tableR1, tableI1, 9); + doubleComplex* coef1 = DoubleComplexMatrix (coefR1, coefI1, 9); + + doubleComplex* table2 = DoubleComplexMatrix (tableR2, tableI2, 9); + doubleComplex* coef2 = DoubleComplexMatrix (coefR2, coefI2, 9); + + doubleComplex columnMeanmedTable1_3_3[3] = {DoubleComplex(0.0, 0.0)}; + + doubleComplex rowMeanmedTable1_1_9[9] = {DoubleComplex(0.0, 0.0)}; + doubleComplex rowMeanmedTable1_9_1[1] = {DoubleComplex(0.0, 0.0)}; + doubleComplex rowMeanmedTable2_2_5[5] = {DoubleComplex(0.0, 0.0)}; + doubleComplex rowMeanmedTable2_5_2[2] = {DoubleComplex(0.0, 0.0)}; + + + printf("\n>>>> Column variancef Double Complex Array Test\n"); + + + + scolumnvariancefa(table1 , 3 , 3 , coef1 , columnMeanmedTable1_3_3); + + for (i = 0 ; i < 3 ; ++i ) + { + printf("columnMeanmedTable_3_3[%d] = %e + %ei\n", i, zreals(columnMeanmedTable1_3_3[i]), zimags(columnMeanmedTable1_3_3[i])); + } + assert( ( fabs(zimags(columnMeanmedTable1_3_3[0]) ) - (138.0 / 33.0 ) ) / fabs ( zimags(columnMeanmedTable1_3_3[0]) ) < 1e-6 ); + assert( ( fabs(zreals(columnMeanmedTable1_3_3[0]) ) - ( 68.0 / 33.0 ) ) / fabs ( zreals(columnMeanmedTable1_3_3[0]) ) < 1e-6 ); + + assert( ( fabs(zimags(columnMeanmedTable1_3_3[1]) ) - ( 36.0 / 6.0 ) ) / fabs ( zimags(columnMeanmedTable1_3_3[1]) ) < 1e-6 ); + assert( ( fabs(zreals(columnMeanmedTable1_3_3[1]) ) - ( 32.0 / 6.0 ) ) / fabs ( zreals(columnMeanmedTable1_3_3[1]) ) < 1e-6 ); + + assert( ( fabs(zimags(columnMeanmedTable1_3_3[2]) ) - (114.0 / 18.0 ) ) / fabs ( zimags(columnMeanmedTable1_3_3[2]) ) < 1e-6 ); + assert( ( fabs(zreals(columnMeanmedTable1_3_3[2]) ) - (146.0 / 18.0 ) ) / fabs ( zreals(columnMeanmedTable1_3_3[2]) ) < 1e-6 ); + + + + + return 0; +} + +*/ + +static int testvariancef(void) { + + dvariancefsTest(); + dvariancefaTest(); + /*dcolumnvariancefaTest(); + srowvariancefaTest();*/ + zvariancefsTest(); + zvariancefaTest(); + /*crowvariancefaTest(); + scolumnvariancefaTest(); +*/ + return 0; +} + +int main(void) { + assert(testvariancef() == 0); + return 0; +} + diff --git a/2.3-1/src/c/statisticsFunctions/variancef/testFloatVariance.c b/2.3-1/src/c/statisticsFunctions/variancef/testFloatVariance.c new file mode 100644 index 00000000..97b56d4d --- /dev/null +++ b/2.3-1/src/c/statisticsFunctions/variancef/testFloatVariance.c @@ -0,0 +1,329 @@ +/* + * 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 <assert.h> +#include <stdio.h> + +#include "variance.h" + +#define SINGLE 1.323312455f +#define LINES 7 +#define COLUMNS 10 +#define MATRIX {0.102326436434f,0.939044147730f,0.638607255649f,0.059883427806f,0.311199211050f,\ + 0.377510951832f,0.909709410276f,0.928138985299f,0.855155082885f,0.308869514614f,\ +0.729239261709f,0.127006734256f,0.242402311414f,0.807912770193f,0.621117659844f,\ + 0.081452373881f,0.088844371960f,0.587072817143f,0.068080495112f,0.995457543526f,\ +0.835322400089f,0.656235548668f,0.767905956600f,0.706818781793f,0.187699332368f,\ + 0.568810169585f,0.401039466728f,0.397196868435f,0.483212330844f,0.161224133335f,\ +0.932864250615f,0.719208867755f,0.262409000657f,0.931377100293f,0.596724558622f,\ + 0.310327019077f,0.350161732174f,0.104841318447f,0.830732351169f,0.804621329065f,\ +0.050784428138f,0.551920620725f,0.125952405389f,0.083156193607f,0.420623748098f,\ + 0.168616071343f,0.707545555662f,0.104633864947f,0.465604968835f,0.489758284763f,\ +0.167727907188f,0.760689914692f,0.454900974408f,0.063926273491f,0.87152507063f,0.978668818716f,\ + 0.135898929089f,0.484713065904f,0.785042577423f,0.049412418623f,\ +0.947593610268f,0.884073690511f,0.212796610314f,0.654832502827f,0.007690255996f,\ + 0.031808692031f,0.706323316786f,0.008731670678f,0.270014822017f,0.153652121313f} + + +#define MATRIXROW {0.168824942350f,0.072908122527f,0.057987977092f,0.149998975703f,0.085086319404f,\ +0.108508638451f,0.096937985957f,0.107281660264f,0.091363871817f,0.128577818421f} + +#define MATRIXCOL { 0.123307827428f,0.123213594199f,0.054037725959f,0.092551230301f,0.055505564488f,\ +0.127629921958f,0.138516743375f } + + +#define IMATRIX {0.05826747464016080f,0.99946373142302036f,0.85600351681932807f,0.62329693790525198f,\ + 0.49792320514097810f,0.44210509583353996f,0.55833499459549785f,0.09633230511099100f,\ + 0.80100952507928014f,0.34466254524886608f,\ +0.48831309471279383f,0.95087061496451497f,0.01332767866551876f,0.76261807000264525f,\ + 0.74346329551190138f,0.65157829830422997f,0.57006288319826126f,0.70580983115360141f,\ + 0.51323400903493166f,0.64977857517078519f,\ +0.80352442665025592f,0.69910932797938585f,0.69258948462083936f,0.91169391758739948f,\ + 0.92454590043053031f,0.27637310232967138f,0.31692579621449113f,0.86305770650506020f,\ + 0.20109100220724940f,0.01225362811237574f,\ +0.38199013099074364f,0.96006405679509044f,0.16440964583307505f,0.59608811559155583f,\ + 0.72101737372577190f,0.58661046391353011f,0.99326277803629637f,0.00761850038543344f,\ + 0.78608208894729614f,0.89965870184823871f,\ +0.43115562805905938f,0.81857266277074814f,0.83410377753898501f,0.55516970623284578f,\ + 0.51345925079658628f,0.04770902730524540f,0.80747798969969153f,0.80489510949701071f,\ + 0.78650354826822877f,0.30791273340582848f,\ +0.75731822755187750f,0.53423820668831468f,0.42618893459439278f,0.85448804078623652f,\ + 0.92601215932518244f,0.94169309409335256f,0.85547966323792934f,0.59637623047456145f,\ + 0.69515300076454878f,0.18359116325154901f,\ +0.01200280850753188f,0.2255702270194888f,0.34853330114856362f,0.55313225090503693f,\ + 0.63695094687864184f,0.96132039744406939f,0.50314606027677655f,0.11768362112343311f,\ + 0.42481321236118674f,0.52963322307914495f} + +#define RMATRIX {0.53868199465796351f,0.65326874051243067f,0.37497402401641011f,0.60422550700604916f,\ + 0.33622304117307067f,0.03531436901539564f,0.33213760564103723f,0.39493087679147720f,\ + 0.04170337272807956f,0.87363853026181459f,\ +0.65950810909271240f,0.31221040291711688f,0.15333442110568285f,0.66478573577478528f,\ + 0.44319023378193378f,0.40884594758972526f,0.94536898937076330f,0.67733758920803666f,\ + 0.18673646822571754f,0.92331133363768458f,\ +0.55921846115961671f,0.75012728199362755f,0.23257926432415843f,0.57102064136415720f,\ + 0.60969385923817754f,0.67336730472743511f,0.07624059682711959f,0.10437540244311094f,\ + 0.95672677317634225f,0.19771346449851990f,\ +0.05278092902153730f,0.75808868417516351f,0.17633479088544846f,0.01146994484588504f,\ + 0.36732212174683809f,0.19948644982650876f,0.52714426256716251f,0.21445603063330054f,\ + 0.94751045759767294f,0.04272260749712586f,\ +0.03257346292957664f,0.53217577841132879f,0.87635089689865708f,0.15471007302403450f,\ + 0.25448470888659358f,0.91815057490020990f,0.72509902389720082f,0.87545845471322536f,\ + 0.05635281419381499f,0.01432112138718367f,\ +0.57406943850219250f,0.80984140699729323f,0.01664119493216276f,0.93888836959376931f,\ + 0.11264799535274506f,0.66036546928808093f,0.76042845565825701f,0.25908330874517560f,\ + 0.88014078326523304f,0.70332178613170981f,\ +0.94614937948063016f,0.78529163636267185f,0.20241560926660895f,0.10981105919927359f,\ + 0.75415370846167207f,0.15320260450243950f,0.59521253732964396f,0.71318271104246378f,\ + 0.51107599260285497f,0.52125945501029491f} + + + + + + +#define IMATRIXROW {-0.0419293790250184f,-0.05416405376783551f,+0.11775191182077104f,+0.08015791690354153f,+0.00011032748454003f,\ +-0.10124210045965254f,0.06720614014223115f,+0.02470873836336094f,-0.07082037296251543f,-0.00621987869853545f} + +#define RMATRIXROW {0.01439621349781126f,-0.04697393442028135f,-0.03018604392150223f,0.09765990436118642f,0.01606884471097247f,\ +-0.00604250542333471f,0.02870576510687836f,-0.04985742926427023f,0.12356001472881707f,0.05909180726174274f} + +#define IMATRIXCOL {-0.01904810719805961f,+0.04121453132770223f,+0.00378553967089328f,\ ++0.10307670507342410f,+0.03497427750676810f,+0.01761849804019567f,-0.10182321471060848f} + +#define RMATRIXCOL {-0.02739893277693160f,0.01792852626358409f,-0.02205084134302381f,\ +-0.01012610864032573f,0.07317682977907164f,0.04762062457313784f,0.00849011627117621f} + + +static void svariancesTest (void ) { + + float toTest = svariances (SINGLE) ; + + assert ( fabs ( toTest - SINGLE ) / fabs( toTest) < 1e-06 ) ; +} + + +static void srowvariancesTest (void ) { + + float toTest = srowvariances (SINGLE) ; + + assert ( fabs ( toTest - SINGLE ) / fabs( toTest) < 1e-06 ) ; +} + +static void scolumnvariancesTest (void) { + + float toTest = scolumnvariances (SINGLE) ; + + assert ( fabs ( toTest - SINGLE ) / fabs( toTest) < 1e-06 ) ; +} + + +static void cvariancesTest (void ) { + + floatComplex toTest = cvariances ( FloatComplex ( SINGLE , SINGLE ) ); + + assert ( fabs ( creals( toTest) - SINGLE ) / fabs( creals( toTest)) < 1e-06 ) ; + assert ( fabs ( cimags( toTest) - SINGLE ) / fabs( cimags( toTest)) < 1e-06 ) ; +} + +static void crowvariancesTest (void ) { + + floatComplex toTest = crowvariances ( FloatComplex ( SINGLE , SINGLE ) ); + + assert ( fabs ( creals( toTest) - SINGLE ) / fabs( creals( toTest)) < 1e-06 ) ; + assert ( fabs ( cimags( toTest) - SINGLE ) / fabs( cimags( toTest)) < 1e-06 ) ; +} + +static void ccolumnvariancesTest (void ) { + + floatComplex toTest = crowvariances ( FloatComplex ( SINGLE , SINGLE ) ); + + assert ( fabs ( creals( toTest) - SINGLE ) / fabs( creals( toTest)) < 1e-06 ) ; + assert ( fabs ( cimags( toTest) - SINGLE ) / fabs( cimags( toTest)) < 1e-06 ) ; +} + + + + + + +static void svarianceaTest ( void){ + + float mtoTest[] = MATRIX ; + float result = 0.100753297434f; + float out = svariancea ( mtoTest , LINES*COLUMNS ); ; + + + + printf ( "out : %e\t result : %e\t\n" , out , result ) ; + + + + assert ( fabs ( out - result ) / fabs( out ) < 1e-06 ) ; + +} + + +static void srowvarianceaTest ( void ) +{ + int i = 0 ; + + float mtoTest[] = MATRIX ; + float result[COLUMNS] = MATRIXROW ; + float out[COLUMNS] ; + + srowvariancea ( mtoTest , LINES , COLUMNS , out ) ; + + for ( i = 0 ; i < COLUMNS ; i++) + { + printf ( "ROWout : %e\t result : %e\t\n" , out[i] , result [i] ) ; + assert ( fabs ( out[i] - result[i] ) / fabs( out[i] ) < 1e-06 ) ; + } + +} + +static void scolumnvarianceaTest ( void ) +{ + int i = 0 ; + + float mtoTest[] = MATRIX ; + float result[LINES] = MATRIXCOL ; + float out[ LINES] ; + + + + scolumnvariancea ( mtoTest , LINES , COLUMNS , out ) ; + + for ( i = 0 ; i < LINES ; i++) + { + printf ( "%dCOLout : %e\t result : %e\t\n" ,i, out[i] , result [i] ) ; + assert ( fabs ( out[i] - result[i] ) / fabs( out[i] ) < 1e-06 ) ; + } + +} + + + + +static void cvarianceaTest ( void){ + + float rmtoTest [] = RMATRIX ; + float imtoTest [] = IMATRIX ; + floatComplex Result = FloatComplex ( 0.01225832057910708f , 0.01071188208687752f ); + + floatComplex* mtoTest = FloatComplexMatrix ( rmtoTest , imtoTest , LINES*COLUMNS ) ; + floatComplex out = cvariancea ( mtoTest , LINES*COLUMNS ); ; + + assert ( fabs( creals(out) - creals (Result) ) / fabs (creals (out)) < 1e-06 ); + assert( fabs( cimags(out) - cimags (Result )) / fabs (cimags (out)) < 1e-06 ); + + +} + +static void crowvarianceaTest (void ) { + + int i = 0 ; + + float rmtoTest [] = RMATRIX ; + float imtoTest [] = IMATRIX ; + float rResult [] = RMATRIXROW; + float iResult [] = IMATRIXROW ; + + floatComplex out[COLUMNS]; + floatComplex* mtoTest = FloatComplexMatrix ( rmtoTest , imtoTest , LINES*COLUMNS ) ; + floatComplex* Result = FloatComplexMatrix ( rResult , iResult , COLUMNS ); + + crowvariancea ( mtoTest , LINES , COLUMNS , out ) ; + + /*FIXME test failed under 1-e04 precision */ + for ( i = 0 ; i < COLUMNS ; i++) + { + printf ( "%d out : %e %e \t result %e %e \n" , i , creals(out[i]) , cimags(out[i]), creals(Result[i]) ,cimags( Result[i])); + assert ( fabs( creals(out[i]) - creals (Result[i]) ) / fabs (creals (out[i])) < 3e-6 ); + assert( fabs( cimags(out[i]) - cimags (Result[i])) / fabs (cimags (out[i])) < 3e-6); + + } +} + + + +static void ccolumnvarianceaTest ( void) { + int i = 0 ; + + float rmtoTest [] = RMATRIX ; + float imtoTest [] = IMATRIX ; + float rResult [] = RMATRIXCOL; + float iResult [] = IMATRIXCOL ; + + floatComplex out[LINES]; + floatComplex* mtoTest = FloatComplexMatrix ( rmtoTest , imtoTest , LINES*COLUMNS ) ; + floatComplex* Result = FloatComplexMatrix ( rResult , iResult , LINES ); + + ccolumnvariancea ( mtoTest , LINES , COLUMNS , out ) ; + + + for ( i = 0 ; i < LINES ; i++) + { + printf ( "%d out : %e %e \t result %e %e \n" , i , creals(out[i]) , cimags(out[i]), creals(Result[i]) ,cimags( Result[i])); + assert ( fabs( creals(out[i]) - creals (Result[i]) ) / fabs (creals (out[i])) < 1e-06 ); + assert( fabs( cimags(out[i]) - cimags (Result[i])) / fabs (cimags (out[i])) < 1e-06); + + } + + + +} + + + + + +static int testFloatVariance (void) { + printf("\n\n\n\n*********************\n"); + printf("***** Float Tests ****\n"); + printf("*********************\n"); + + printf("\n\t>>>>singleton real Tests\n"); + scolumnvariancesTest () ; + svariancesTest () ; + srowvariancesTest () ; + + + printf("\n\t>>>>singleton complex Tests\n"); + + crowvariancesTest () ; + ccolumnvariancesTest () ; + cvariancesTest () ; + + + + printf("\n\t>>>>array real Tests\n"); + + svarianceaTest () ; + + scolumnvarianceaTest () ; + srowvarianceaTest ( ); + + + printf("\n\t>>>>array complex Tests\n"); + + cvarianceaTest () ; + crowvarianceaTest ( ); + ccolumnvarianceaTest () ; + + + return 0; +} + +int main(void) { + assert(testFloatVariance () == 0); + return 0; +} diff --git a/2.3-1/src/c/statisticsFunctions/variancef/testFloatVariancef.c b/2.3-1/src/c/statisticsFunctions/variancef/testFloatVariancef.c new file mode 100644 index 00000000..4363052e --- /dev/null +++ b/2.3-1/src/c/statisticsFunctions/variancef/testFloatVariancef.c @@ -0,0 +1,381 @@ +/* + * Scilab ( http://www.scilab.org/ ) - This file is part of Scilab + * Copyright (C) 2008-2008 - INRIA - Allan SIMON + * + * 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 <assert.h> +#include <stdio.h> +#include <math.h> +#include "variancef.h" + + +/* #define LOCAL_DEBUG */ + +#define ERROR(x) printf("diff = %e\n", x) + + + #define VALUE1 3.0f + #define VALUE2 1.123456789f + #define COEF1 56.0f + #define COEF2 2.0f + + +static int svariancefsTest(void) { + + printf("\n>>>> variancef Float Scalar Test\n"); + printf("result : %e " ,svariancefs(VALUE1,COEF1)) ; + + assert( ( svariancefs(VALUE1,COEF1) ) == 0.0f ); + assert( ( svariancefs(VALUE2,COEF2) ) == 0.0f ); + + + + return 0; +} + +static int svariancefaTest(void) { + float table1[3] = {3.0f, 6.0f, 9.0f}; + float coef1[3] = {10.0f, 2.0f, 6.0f}; + + float table2[5] = {3.186784563f, + 4.186784563f, + 5.186784563f, + 6.186784563f, + 7.186784563f}; + + float coef2[5] = {3.0f, + 4.0f, + 5.0f, + 6.0f, + 7.0f}; + + printf("\n>>>> variancef Float Array Test\n"); + printf("result : %e " ,svariancefa(table1, 3, coef1)) ; + printf("result : %e " ,svariancefa(table2, 5, coef2)) ; + assert(svariancefa(table1, 3, coef1) == 8.0f); + assert((svariancefa(table2, 5, coef2) - 1.916666666 )/ svariancefa(table2, 5 ,coef2) < 1e-6); + return 0; +} + +/* +static int scolumnvariancefaTest(void) { + int i = 0; + float table1[9] = {1.0f, 4.0f, 7.0f, 2.0f , 5.0f, 8.0f, 3.0f, 6.0f, 9.0f}; + float coef1[9] = {10.0f, 1.0f, 5.0f,11.0f , 2.0f, 6.0f,12.0f, 3.0f, 7.0f}; + float table2[10] = {1.0f, 2.0f, 3.0f, 4.0f , 5.0f, 6.0f, 7.0f, 8.0f, 9.0f, 10.0f}; + float coef2[10] = {11.0f, 12.0f, 13.0f, 14.0f , 15.0f, 16.0f, 17.0f, 18.0f, 19.0f, 20.0f}; + float columnMeanmedTable1_3_3[3] = {0}; + float columnMeanmedTable1_1_9[1] = {0}; + float columnMeanmedTable1_9_1[9] = {0}; + float columnMeanmedTable2_2_5[2] = {0}; + float columnMeanmedTable2_5_2[5] = {0}; + + printf("\n>>>> Column Variancef Float Array Test\n"); + + [ 1 2 3 ] [10 11 12 ] + [ 4 5 6 ].*[ 1 2 3 ] => [ 68 32 146 ] + [ 7 8 9 ] [ 5 6 7 ] + + scolumnvariancefa(table1, 3, 3, coef1 ,columnMeanmedTable1_3_3); + assert( ( fabs(columnMeanmedTable1_3_3[0] ) - ( 68.0f / 33.0f ) ) / fabs ( columnMeanmedTable1_3_3[0] ) < 1e-6 ); + assert( ( fabs(columnMeanmedTable1_3_3[1] ) - ( 32.0f / 6.0f ) ) / fabs ( columnMeanmedTable1_3_3[1] ) < 1e-6 ); + assert( ( fabs(columnMeanmedTable1_3_3[2] ) - ( 146.0f / 18.0f ) ) / fabs ( columnMeanmedTable1_3_3[2] ) < 1e-6 ); + + + [ 1 2 3 4 5 6 7 8 9 ] => [ 45 ] + + scolumnvariancefa(table1, 1, 9, coef1 ,columnMeanmedTable1_1_9); + printf("result qui foire : %e\n " ,columnMeanmedTable1_1_9[0]) ; + assert( ( fabs(columnMeanmedTable1_1_9[0] ) - ( 1.146666666f ) ) / fabs ( columnMeanmedTable1_1_9[0] ) < 1e-6 ); + + + [ 1 ] + [ 2 ] + [ 3 ] + [ 4 ] + [ 5 ] => [ 1 2 3 4 5 6 7 8 9 ] + [ 6 ] + [ 7 ] + [ 8 ] + [ 9 ] + + scolumnvariancefa(table1, 9, 1, coef1, columnMeanmedTable1_9_1); + for ( i = 0 ; i < 9 ; ++i) { + printf("columnMeanmedTable1_9_1[%d] = %e\n", i, columnMeanmedTable1_9_1[i]); + assert(columnMeanmedTable1_9_1[i] == table1[i]); + } + + + [ 1 3 5 7 9 ] .* [ 11 13 15 17 19 ] + [ 2 4 6 8 10 ] [ 12 14 16 18 20 ]=> [ 415 520 ] + + scolumnvariancefa(table2, 2, 5, coef2 , columnMeanmedTable2_2_5); + assert( ( fabs(columnMeanmedTable2_2_5[0] ) - ( 415.0f / 75.0f ) ) / fabs ( columnMeanmedTable2_2_5[0] ) < 1e-6 ); + assert( ( fabs(columnMeanmedTable2_2_5[1] ) - ( 520.0f / 80.0f ) ) / fabs ( columnMeanmedTable2_2_5[1] ) < 1e-6 ); + for ( i = 0 ; i < 2 ; ++i) { + printf("columnMeanmedTable2_2_5[%d] = %e\n", i, columnMeanmedTable2_2_5[i]); + } + + + [ 1 6 ] [ 11 16 ] + [ 2 7 ] [ 12 17 ] => [ 107 143 183 227 275 ] + [ 3 8 ].*[ 13 18 ] + [ 4 9 ] [ 14 19 ] + [ 5 10 ] [ 15 20 ] + + + scolumnvariancefa(table2, 5, 2, coef2 ,columnMeanmedTable2_5_2); + assert( ( fabs(columnMeanmedTable2_5_2[0] ) - ( 107.0f / 27.0f ) ) / fabs ( columnMeanmedTable2_5_2[0] ) < 1e-6 ); + assert( ( fabs(columnMeanmedTable2_5_2[1] ) - ( 143.0f / 29.0f ) ) / fabs ( columnMeanmedTable2_5_2[1] ) < 1e-6 ); + assert( ( fabs(columnMeanmedTable2_5_2[2] ) - ( 183.0f / 31.0f ) ) / fabs ( columnMeanmedTable2_5_2[2] ) < 1e-6 ); + assert( ( fabs(columnMeanmedTable2_5_2[3] ) - ( 227.0f / 33.0f ) ) / fabs ( columnMeanmedTable2_5_2[3] ) < 1e-6 ); + assert( ( fabs(columnMeanmedTable2_5_2[4] ) - ( 275.0f / 35.0f ) ) / fabs ( columnMeanmedTable2_5_2[4] ) < 1e-6 ); + for ( i = 0 ; i < 5 ; ++i) { + printf("columnMeanmedTable2_5_2[%d] = %e\n", i, columnMeanmedTable2_5_2[i]); + } + + return 0; +} +*/ +/* +static int srowvariancefaTest(void) { + int i = 0; + float table1[9] = {1.0f, 4.0f, 7.0f, 2.0f , 5.0f, 8.0f, 3.0f, 6.0f, 9.0f}; + float coef1[9] = {10.0f, 1.0f, 5.0f,11.0f , 2.0f, 6.0f,12.0f, 3.0f, 7.0f}; + float table2[10] = {1.0f, 2.0f, 3.0f, 4.0f , 5.0f, 6.0f, 7.0f, 8.0f, 9.0f, 10.0f}; + float coef2[10] = {11.0f, 12.0f, 13.0f, 14.0f , 15.0f, 16.0f, 17.0f, 18.0f, 19.0f, 20.0f}; + float rowMeanmedTable1_3_3[3] = {0}; + float rowMeanmedTable1_1_9[9] = {0}; + float rowMeanmedTable1_9_1[1] = {0}; + float rowMeanmedTable2_2_5[5] = {0}; + float rowMeanmedTable2_5_2[2] = {0}; + + printf("\n>>>> Row Mean Float Array Test\n"); + + [ 1 2 3 ] [10 11 12 ] + [ 4 5 6 ].*[ 1 2 3 ] => [ 49 80 117 ] + [ 7 8 9 ] [ 5 6 7 ] + + srowvariancefa(table1, 3, 3, coef1 , rowMeanmedTable1_3_3); + for ( i = 0 ; i < 3 ; ++i) { + printf("rowMeanmedTable1_3_3[%d] = %e\n", i, rowMeanmedTable1_3_3[i]); + } + assert( ( fabs(rowMeanmedTable1_3_3[0] ) - ( 49.0f / 16.0f ) ) / fabs ( rowMeanmedTable1_3_3[0] ) < 1e-6 ); + assert( ( fabs(rowMeanmedTable1_3_3[1] ) - ( 80.0f / 19.0f ) ) / fabs ( rowMeanmedTable1_3_3[1] ) < 1e-6 ); + assert( ( fabs(rowMeanmedTable1_3_3[2] ) - ( 117.0f / 22.0f ) ) / fabs ( rowMeanmedTable1_3_3[2] ) < 1e-6 ); + + + [ 1 ] + [ 2 ] + [ 3 ] + [ 4 ] + [ 5 ] => [ 1 2 3 4 5 6 7 8 9 ] + [ 6 ] + [ 7 ] + [ 8 ] + [ 9 ] + + srowvariancefa(table1, 1, 9, coef1, rowMeanmedTable1_1_9); + for ( i = 0 ; i < 9 ; ++i) { + printf("rowMeanmedTable1_1_9[%d] = %e\n", i, rowMeanmedTable1_1_9[i]); + assert(rowMeanmedTable1_1_9[i] == table1[i]); + } + + + [ 1 2 3 4 5 6 7 8 9 ] => [ 246 ] + + srowvariancefa(table1, 9, 1, coef1, rowMeanmedTable1_9_1); + assert( ( fabs(rowMeanmedTable1_9_1[0] ) - ( 246.0f / 57.0f ) ) / fabs ( rowMeanmedTable1_9_1[0] ) < 1e-6 ); + + + [ 1 3 5 7 9 ] .* [ 11 13 15 17 19 ] + [ 2 4 6 8 10 ] [ 12 14 16 18 20 ] => [ 3 7 11 15 19 ] + + srowvariancefa(table2, 2, 5, coef2, rowMeanmedTable2_2_5); + for ( i = 0 ; i < 5 ; ++i) { + printf("rowMeanmedTable2_2_5[%d] = %e\n", i, rowMeanmedTable2_2_5[i]); + } + assert( ( fabs(rowMeanmedTable2_2_5[0] ) - ( 35.0f / 23.0f ) ) / fabs ( rowMeanmedTable2_2_5[0] ) < 1e-6 ); + assert( ( fabs(rowMeanmedTable2_2_5[1] ) - ( 95.0f / 27.0f ) ) / fabs ( rowMeanmedTable2_2_5[1] ) < 1e-6 ); + assert( ( fabs(rowMeanmedTable2_2_5[2] ) - ( 171.0f / 31.0f ) ) / fabs ( rowMeanmedTable2_2_5[2] ) < 1e-6 ); + assert( ( fabs(rowMeanmedTable2_2_5[3] ) - ( 263.0f / 35.0f ) ) / fabs ( rowMeanmedTable2_2_5[3] ) < 1e-6 ); + assert( ( fabs(rowMeanmedTable2_2_5[4] ) - ( 371.0f / 39.0f ) ) / fabs ( rowMeanmedTable2_2_5[4] ) < 1e-6 ); + + + return 0; +} +*/ + +static int cvariancefsTest(void) { + + + printf("\n>>>> Mean Float Complex Scalar Test\n"); + assert( creals(cvariancefs(FloatComplex(3.0f, 3.0f),FloatComplex(3.0f, 0.0f);)) == 0.0f ); + assert( cimags(cvariancefs(FloatComplex(3.0f, 3.0f),FloatComplex(3.0f, 0.0f);)) == 0.0f ); + assert( creals(cvariancefs(FloatComplex(1.123456789f, 1.123456789f),FloatComplex(1.123456789f, 1.123456789f))) == 0.0f ); + assert( cimags(cvariancefs(FloatComplex(1.123456789f, 1.123456789f),FloatComplex(1.123456789f, 1.123456789f))) == 0.0f ); + + return 0; +} + + + +static int cvariancefaTest(void) { + + float tableR1[9] = {1.0f, 4.0f, 7.0f, 2.0f , 5.0f, 8.0f, 3.0f, 6.0f, 9.0f}; + float tableI1[9] = {1.0f, 2.0f, 3.0f, 4.0f , 5.0f, 6.0f, 7.0f, 8.0f, 9.0f}; + float coefR1[9] = {10.0f, 1.0f, 5.0f,11.0f , 2.0f, 6.0f,12.0f, 3.0f, 7.0f}; + float coefI1[9] = { 0.0f, 0.0f, 0.0f, 0.0f , 0.0f, 0.0f, 0.0f, 0.0f, 0.0f}; + + floatComplex* table1 = FloatComplexMatrix (tableR1, tableI1, 9); + floatComplex* coef1 = FloatComplexMatrix (coefR1, coefI1, 9); + floatComplex result =FloatComplex(0.0f , 0.0f); + + printf("\n>>>> Mean Float Complex Array Test\n"); + result = cvariancefa(table1, 9, coef1); + /*printf("\nresult : %lf \t+ %lf i " ,creals(result) ,cimags(result)) ;*/ + + assert( fabs(creals(result) - ( 1.3834586f ) ) / fabs ( creals(result) ) < 1e-6 ); + assert( fabs(cimags(result) - ( 9.6090226f ) ) / fabs ( cimags(result) ) < 1e-6 ); + + return 0; +} + +/* +static int crowvariancefaTest(void) { + + int i = 0 ; + + float tableR1[9] = {1.0f, 4.0f, 7.0f, 2.0f , 5.0f, 8.0f, 3.0f, 6.0f, 9.0f}; + float tableI1[9] = {1.0f, 2.0f, 3.0f, 4.0f , 5.0f, 6.0f, 7.0f, 8.0f, 9.0f}; + float coefR1[9] = {10.0f, 1.0f, 5.0f,11.0f , 2.0f, 6.0f,12.0f, 3.0f, 7.0f}; + float coefI1[9] = { 0.0f, 0.0f, 0.0f, 0.0f , 0.0f, 0.0f, 0.0f, 0.0f, 0.0f}; + + float tableR2[10] = {1.0f, 4.0f, 7.0f, 2.0f , 5.0f, 8.0f, 3.0f, 6.0f, 9.0f, 10.0f}; + float tableI2[10] = {1.0f, 2.0f, 3.0f, 4.0f , 5.0f, 6.0f, 7.0f, 8.0f, 9.0f, 15.0f}; + float coefR2[10] = {10.0f, 1.0f, 5.0f,11.0f , 2.0f, 6.0f,12.0f, 3.0f, 7.0f, 19.0f}; + float coefI2[10] = { 0.0f, 0.0f, 0.0f, 0.0f , 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f}; + + floatComplex* table1 = FloatComplexMatrix (tableR1, tableI1, 9); + floatComplex* coef1 = FloatComplexMatrix (coefR1, coefI1, 9); + + floatComplex* table2 = FloatComplexMatrix (tableR2, tableI2, 9); + floatComplex* coef2 = FloatComplexMatrix (coefR2, coefI2, 9); + + floatComplex rowMeanmedTable1_3_3[3] = {FloatComplex(0.0f, 0.0f)}; + + floatComplex rowMeanmedTable1_1_9[9] = {FloatComplex(0.0f, 0.0f)}; + floatComplex rowMeanmedTable1_9_1[1] = {FloatComplex(0.0f, 0.0f)}; + floatComplex rowMeanmedTable2_2_5[5] = {FloatComplex(0.0f, 0.0f)}; + floatComplex rowMeanmedTable2_5_2[2] = {FloatComplex(0.0f, 0.0f)}; + + printf("\n>>>> Row variancef Float Complex Array Test\n"); + + + + crowvariancefa(table1 , 3 , 3 , coef1 , rowMeanmedTable1_3_3); + + for (i = 0 ; i < 3 ; ++i ) + { + + printf("rowMeanmedTable_3_3[%d] = %e + %ei\n", i, creals(rowMeanmedTable1_3_3[i]), cimags(rowMeanmedTable1_3_3[i])); + } + assert( ( fabs(cimags(rowMeanmedTable1_3_3[0]) ) - ( 27.0f / 16.0f ) ) / fabs ( cimags(rowMeanmedTable1_3_3[0]) ) < 1e-6 ); + assert( ( fabs(creals(rowMeanmedTable1_3_3[0]) ) - ( 49.0f / 16.0f ) ) / fabs ( creals(rowMeanmedTable1_3_3[0]) ) < 1e-6 ); + + assert( ( fabs(cimags(rowMeanmedTable1_3_3[1]) ) - ( 90.0f / 19.0f ) ) / fabs ( cimags(rowMeanmedTable1_3_3[1]) ) < 1e-6 ); + assert( ( fabs(creals(rowMeanmedTable1_3_3[1]) ) - ( 80.0f / 19.0f ) ) / fabs ( creals(rowMeanmedTable1_3_3[1]) ) < 1e-6 ); + + assert( ( fabs(cimags(rowMeanmedTable1_3_3[2]) ) - (171.0f / 22.0f ) ) / fabs ( cimags(rowMeanmedTable1_3_3[2]) ) < 1e-6 ); + assert( ( fabs(creals(rowMeanmedTable1_3_3[2]) ) - (117.0f / 22.0f ) ) / fabs ( creals(rowMeanmedTable1_3_3[2]) ) < 1e-6 ); + + + + + return 0; +} +*/ + + +/* +static int ccolumnvariancefaTest(void) { + + int i = 0 ; + + float tableR1[9] = {1.0f, 4.0f, 7.0f, 2.0f , 5.0f, 8.0f, 3.0f, 6.0f, 9.0f}; + float tableI1[9] = {1.0f, 2.0f, 3.0f, 4.0f , 5.0f, 6.0f, 7.0f, 8.0f, 9.0f}; + float coefR1[9] = {10.0f, 1.0f, 5.0f,11.0f , 2.0f, 6.0f,12.0f, 3.0f, 7.0f}; + float coefI1[9] = { 0.0f, 0.0f, 0.0f, 0.0f , 0.0f, 0.0f, 0.0f, 0.0f, 0.0f}; + + float tableR2[10] = {1.0f, 4.0f, 7.0f, 2.0f , 5.0f, 8.0f, 3.0f, 6.0f, 9.0f, 10.0f}; + float tableI2[10] = {1.0f, 2.0f, 3.0f, 4.0f , 5.0f, 6.0f, 7.0f, 8.0f, 9.0f, 15.0f}; + float coefR2[10] = {10.0f, 1.0f, 5.0f,11.0f , 2.0f, 6.0f,12.0f, 3.0f, 7.0f, 19.0f}; + float coefI2[10] = { 0.0f, 0.0f, 0.0f, 0.0f , 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f}; + + floatComplex* table1 = FloatComplexMatrix (tableR1, tableI1, 9); + floatComplex* coef1 = FloatComplexMatrix (coefR1, coefI1, 9); + + floatComplex* table2 = FloatComplexMatrix (tableR2, tableI2, 9); + floatComplex* coef2 = FloatComplexMatrix (coefR2, coefI2, 9); + + floatComplex columnMeanmedTable1_3_3[3] = {FloatComplex(0.0f, 0.0f)}; + + floatComplex rowMeanmedTable1_1_9[9] = {FloatComplex(0.0f, 0.0f)}; + floatComplex rowMeanmedTable1_9_1[1] = {FloatComplex(0.0f, 0.0f)}; + floatComplex rowMeanmedTable2_2_5[5] = {FloatComplex(0.0f, 0.0f)}; + floatComplex rowMeanmedTable2_5_2[2] = {FloatComplex(0.0f, 0.0f)}; + + + printf("\n>>>> Column variancef Float Complex Array Test\n"); + + + + ccolumnvariancefa(table1 , 3 , 3 , coef1 , columnMeanmedTable1_3_3); + + for (i = 0 ; i < 3 ; ++i ) + { + printf("columnMeanmedTable_3_3[%d] = %e + %ei\n", i, creals(columnMeanmedTable1_3_3[i]), cimags(columnMeanmedTable1_3_3[i])); + } + assert( ( fabs(cimags(columnMeanmedTable1_3_3[0]) ) - (138.0f / 33.0f ) ) / fabs ( cimags(columnMeanmedTable1_3_3[0]) ) < 1e-6 ); + assert( ( fabs(creals(columnMeanmedTable1_3_3[0]) ) - ( 68.0f / 33.0f ) ) / fabs ( creals(columnMeanmedTable1_3_3[0]) ) < 1e-6 ); + + assert( ( fabs(cimags(columnMeanmedTable1_3_3[1]) ) - ( 36.0f / 6.0f ) ) / fabs ( cimags(columnMeanmedTable1_3_3[1]) ) < 1e-6 ); + assert( ( fabs(creals(columnMeanmedTable1_3_3[1]) ) - ( 32.0f / 6.0f ) ) / fabs ( creals(columnMeanmedTable1_3_3[1]) ) < 1e-6 ); + + assert( ( fabs(cimags(columnMeanmedTable1_3_3[2]) ) - (114.0f / 18.0f ) ) / fabs ( cimags(columnMeanmedTable1_3_3[2]) ) < 1e-6 ); + assert( ( fabs(creals(columnMeanmedTable1_3_3[2]) ) - (146.0f / 18.0f ) ) / fabs ( creals(columnMeanmedTable1_3_3[2]) ) < 1e-6 ); + + + + + return 0; +} + +*/ + +static int testvariancef(void) { + + svariancefsTest(); + svariancefaTest(); + /*scolumnvariancefaTest(); + srowvariancefaTest();*/ + cvariancefsTest(); + cvariancefaTest(); + /*crowvariancefaTest(); + ccolumnvariancefaTest(); +*/ + return 0; +} + +int main(void) { + assert(testvariancef() == 0); + return 0; +} + diff --git a/2.3-1/src/c/statisticsFunctions/variancef/zcolumnvariancefa.c b/2.3-1/src/c/statisticsFunctions/variancef/zcolumnvariancefa.c new file mode 100644 index 00000000..47fee75b --- /dev/null +++ b/2.3-1/src/c/statisticsFunctions/variancef/zcolumnvariancefa.c @@ -0,0 +1,35 @@ +/* + * Scilab ( http://www.scilab.org/ ) - This file is part of Scilab + * Copyright (C) 2008-2008 - INRIA - Allan SIMON + * + * 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 "variancef.h" +#include "matrixTranspose.h" + +void zcolumnvariancefa(doubleComplex *in1, int lines, int columns,doubleComplex *in2 , doubleComplex* out){ + + int i = 0 ; + + doubleComplex* transp = (doubleComplex*) malloc ( sizeof (doubleComplex) *(unsigned int) (lines*columns)); + + + + ztransposea ( in1 , lines , columns , transp ) ; + + + for ( i = 0; i < lines ; i++) + out[i] = zvariancefa ( transp + i*columns , columns, in2 ) ; + + + free (transp); + +} + diff --git a/2.3-1/src/c/statisticsFunctions/variancef/zrowvariancefa.c b/2.3-1/src/c/statisticsFunctions/variancef/zrowvariancefa.c new file mode 100644 index 00000000..b39b2ee7 --- /dev/null +++ b/2.3-1/src/c/statisticsFunctions/variancef/zrowvariancefa.c @@ -0,0 +1,21 @@ +/* + * Scilab ( http://www.scilab.org/ ) - This file is part of Scilab + * Copyright (C) 2008-2008 - INRIA - Allan SIMON + * + * 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 "variancef.h" + +void zrowvariancefa(doubleComplex *in1, int lines, int columns,doubleComplex *in2, doubleComplex* out){ + + int i = 0 ; + + for ( i = 0; i < columns ; i++) + out[i] = zvariancefa ( in1 + i*lines , lines , in2 ) ; +} diff --git a/2.3-1/src/c/statisticsFunctions/variancef/zvariancefa.c b/2.3-1/src/c/statisticsFunctions/variancef/zvariancefa.c new file mode 100644 index 00000000..6de6f11a --- /dev/null +++ b/2.3-1/src/c/statisticsFunctions/variancef/zvariancefa.c @@ -0,0 +1,35 @@ +/* + * Scilab ( http://www.scilab.org/ ) - This file is part of Scilab + * Copyright (C) 2008-2008 - INRIA - Allan SIMON + * + * 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 "variancef.h" +#include "division.h" + +doubleComplex zvariancefa(doubleComplex *in1, int size, doubleComplex *in2) + +{ + int i = 0 ; + doubleComplex temp = DoubleComplex (0.0, 0.0 ); + doubleComplex accumulate =DoubleComplex (0.0, 0.0 ); + doubleComplex accumulateFre = DoubleComplex (0.0, 0.0 ); + + doubleComplex meanf = zmeanfa (in1 , size , in2); + for(i = 0 ; i < size ; ++i) + { + temp = zpows ( zdiffs (in1[i] , meanf ) ,DoubleComplex (2.0, 0.0 ) ); + temp = zmuls( in2[i] , temp); + + accumulate = zadds( temp , accumulate); + accumulateFre = zadds(in2[i ] ,accumulateFre ); + } + + return zrdivs(accumulate, zdiffs(accumulateFre ,DoubleComplex(1.0,0.0) )); +} |