/[escript]/trunk/escript/test/python/test_util.py
ViewVC logotype

Diff of /trunk/escript/test/python/test_util.py

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

trunk/escript/py_src/test_util.py revision 437 by gross, Fri Jan 20 00:16:58 2006 UTC trunk/escript/test/python/test_util.py revision 1312 by ksteube, Mon Sep 24 06:18:44 2007 UTC
# Line 1  Line 1 
1    #
2  # $Id$  # $Id$
3    #
4    #######################################################
5    #
6    #           Copyright 2003-2007 by ACceSS MNRF
7    #       Copyright 2007 by University of Queensland
8    #
9    #                http://esscc.uq.edu.au
10    #        Primary Business: Queensland, Australia
11    #  Licensed under the Open Software License version 3.0
12    #     http://www.opensource.org/licenses/osl-3.0.php
13    #
14    #######################################################
15    #
16    
17  """  """
18  Test suite for the util.py module.  Test suite for the util.py module.
19    
# Line 16  to run the use: Line 31  to run the use:
31     unittest.TextTestRunner(verbosity=2).run(suite)     unittest.TextTestRunner(verbosity=2).run(suite)
32    
33  For function spaces which support tagging there is the extended test case Test_util_with_tagged_data available.  For function spaces which support tagging there is the extended test case Test_util_with_tagged_data available.
34  This test assumes that the functionspace has samples with tags equal to 1 and different from 1.  This test assumes that samples with x_0 coordinate 0 are tagged with 1 and all samples tagged with 1 have x_0
35    coordinate 0.
36    
37  @note: at this stage thsi test will not pass as it tests for functionlity that has not been implemented yet. It also does not test the full functionalitu of util.py yet.  @note: at this stage this test will not pass as it tests for functionlity that has not been implemented yet. It also does not test the full functionalitu of util.py yet.
38    
39  @var __author__: name of author  @var __author__: name of author
40  @var __licence__: licence agreement  @var __copyright__: copyrights
41    @var __license__: licence agreement
42  @var __url__: url entry point on documentation  @var __url__: url entry point on documentation
43  @var __version__: version  @var __version__: version
44  @var __date__: date of the version  @var __date__: date of the version
45  """  """
46    
47  __author__="Lutz Gross, l.gross@uq.edu.au"  __author__="Lutz Gross, l.gross@uq.edu.au"
48  __licence__="contact: esys@access.uq.edu.au"  __copyright__="""  Copyright (c) 2006 by ACcESS MNRF
49                        http://www.access.edu.au
50                    Primary Business: Queensland, Australia"""
51    __license__="""Licensed under the Open Software License version 3.0
52                 http://www.opensource.org/licenses/osl-3.0.php"""
53  __url__="http://www.iservo.edu.au/esys/escript"  __url__="http://www.iservo.edu.au/esys/escript"
54  __version__="$Revision$"  __version__="$Revision$"
55  __date__="$Date$"  __date__="$Date$"
# Line 36  __date__="$Date$" Line 57  __date__="$Date$"
57  import unittest  import unittest
58  import numarray  import numarray
59  from esys.escript import *  from esys.escript import *
60  from esys.escript.test_util_base import Test_util_base  from test_util_base import Test_util_base
61  from esys.escript.test_util_reduction_no_tagged_data import Test_util_reduction_no_tagged_data  from test_util_reduction_no_tagged_data import Test_util_reduction_no_tagged_data
62  from esys.escript.test_util_reduction_with_tagged_data import Test_util_reduction_with_tagged_data  from test_util_reduction_with_tagged_data import Test_util_reduction_with_tagged_data
63  from esys.escript.test_util_overloaded_binary_no_tagged_data import Test_util_overloaded_binary_no_tagged_data  from test_util_overloaded_binary_no_tagged_data import Test_util_overloaded_binary_no_tagged_data
64  from esys.escript.test_util_overloaded_binary_with_tagged_data import Test_util_overloaded_binary_with_tagged_data  from test_util_overloaded_binary_with_tagged_data import Test_util_overloaded_binary_with_tagged_data
65  from esys.escript.test_util_unary_no_tagged_data import Test_util_unary_no_tagged_data  from test_util_unary_no_tagged_data import Test_util_unary_no_tagged_data
66  from esys.escript.test_util_unary_with_tagged_data import Test_util_unary_with_tagged_data  from test_util_unary_with_tagged_data import Test_util_unary_with_tagged_data
67  from esys.escript.test_util_binary_no_tagged_data import Test_util_binary_no_tagged_data  from test_util_binary_no_tagged_data import Test_util_binary_no_tagged_data
68  from esys.escript.test_util_binary_with_tagged_data import Test_util_binary_with_tagged_data  from test_util_binary_with_tagged_data import Test_util_binary_with_tagged_data
69  from esys.escript.test_util_spatial_functions import Test_Util_SpatialFunctions  from test_util_spatial_functions import Test_Util_SpatialFunctions, Test_Util_SpatialFunctions_noGradOnBoundary, Test_Util_SpatialFunctions_noGradOnBoundary_noContact
70    from test_util_slicing_no_tagged_data import Test_util_slicing_no_tagged_data
71    from test_util_slicing_with_tagged_data import Test_util_slicing_with_tagged_data
72    
73    
74  class Test_util_reduction(Test_util_reduction_no_tagged_data,Test_util_reduction_with_tagged_data):  class Test_util_reduction(Test_util_reduction_no_tagged_data,Test_util_reduction_with_tagged_data):
75     """ test for reduction operation Lsup,sup,inf for all data types"""     """ test for reduction operation Lsup,sup,inf for all data types"""
# Line 61  class Test_util_binary(Test_util_binary_ Line 85  class Test_util_binary(Test_util_binary_
85  class Test_util_overloaded_binary(Test_util_overloaded_binary_no_tagged_data,Test_util_overloaded_binary_with_tagged_data):  class Test_util_overloaded_binary(Test_util_overloaded_binary_no_tagged_data,Test_util_overloaded_binary_with_tagged_data):
86     """test for all overloaded operation"""     """test for all overloaded operation"""
87     pass     pass
88  class Test_util_with_tagged_data(Test_util_unary_with_tagged_data,Test_util_reduction_with_tagged_data,Test_util_binary_with_tagged_data,Test_util_overloaded_binary_with_tagged_data):  class Test_util_with_tagged_data(Test_util_unary_with_tagged_data,Test_util_reduction_with_tagged_data,Test_util_binary_with_tagged_data,Test_util_overloaded_binary_with_tagged_data,Test_util_slicing_with_tagged_data):
89     """test for all operations without tagged data"""     """test for all operations without tagged data"""
90     pass     pass
91  class Test_util_no_tagged_data(Test_util_unary_no_tagged_data,Test_util_reduction_no_tagged_data,Test_util_binary_no_tagged_data,Test_util_overloaded_binary_no_tagged_data):  class Test_util_no_tagged_data(Test_util_unary_no_tagged_data,Test_util_reduction_no_tagged_data,Test_util_binary_no_tagged_data,Test_util_overloaded_binary_no_tagged_data, Test_util_slicing_no_tagged_data):
92     """all tests without tagged data"""     """all tests without tagged data"""
93     pass     pass
94    
# Line 72  class Test_util(Test_util_unary,Test_uti Line 96  class Test_util(Test_util_unary,Test_uti
96     """all tests"""     """all tests"""
97     pass     pass
98    
 class Test_util_binary_still_failing(Test_util_base):  
    """  
    these binary opereations still fail! (see Mantis 0000053)  
    """  
    #+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++  
    def test_power_float_rank0_constData_rank0(self):  
       arg0=4.35251522982  
       arg1=Data(2.94566651719,self.functionspace)  
       res=power(arg0,arg1)  
       ref=Data(76.1230031099,self.functionspace)  
       self.failUnless(isinstance(res,Data),"wrong type of result.")  
       self.failUnlessEqual(res.getShape(),(),"wrong shape of result.")  
       self.failUnless(Lsup(res-ref)<=self.RES_TOL*Lsup(ref),"wrong result")  
    #+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++  
    def test_power_float_rank0_expandedData_rank0(self):  
       arg0=3.41819405792  
       msk_arg1=whereNegative(self.functionspace.getX()[0]-0.5)  
       arg1=msk_arg1*(3.18794922769)+(1.-msk_arg1)*(0.35955973515)  
       res=power(arg0,arg1)  
       msk_ref=whereNegative(self.functionspace.getX()[0]-0.5)  
       ref=msk_ref*(50.3172415941)+(1.-msk_ref)*(1.55572132713)  
       self.failUnless(isinstance(res,Data),"wrong type of result.")  
       self.failUnlessEqual(res.getShape(),(),"wrong shape of result.")  
       self.failUnless(Lsup(res-ref)<=self.RES_TOL*Lsup(ref),"wrong result")  
    #+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++  
    def test_power_float_rank0_taggedData_rank0(self):  
       arg0=3.76704928748  
       arg1=Data(1.30536801555,self.functionspace)  
       arg1.setTaggedValue(1,3.46723750757)  
       res=power(arg0,arg1)  
       ref=Data(5.64798685367,self.functionspace)  
       ref.setTaggedValue(1,99.3420963479)  
       self.failUnless(isinstance(res,Data),"wrong type of result.")  
       self.failUnlessEqual(res.getShape(),(),"wrong shape of result.")  
       self.failUnless(Lsup(res-ref)<=self.RES_TOL*Lsup(ref),"wrong result")  
99    
100  class Test_util_overloaded_binary_still_failing(Test_util_base):  class Test_util_overloaded_binary_still_failing(Test_util_base):
101     """     """
102     these overloaded operations still fail!     these overloaded operations still fail!
103    
         - as float**Data is not implemented  (Manits 0000053)  
104          - wrong return value of Data binaries (Mantis 0000054)          - wrong return value of Data binaries (Mantis 0000054)
105     """     """
106     #+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++     #+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
    def test_add_overloaded_float_rank0_constData_rank0(self):  
       arg0=4.48433439008  
       arg1=Data(-1.25231625216,self.functionspace)  
       res=arg0+arg1  
       ref=Data(3.23201813791,self.functionspace)  
       self.failUnless(isinstance(res,Data),"wrong type of result.")  
       self.failUnlessEqual(res.getShape(),(),"wrong shape of result.")  
       self.failUnless(Lsup(res-ref)<=self.RES_TOL*Lsup(ref),"wrong result")  
    #+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++  
    def test_add_overloaded_float_rank0_constData_rank1(self):  
       arg0=4.85806264721  
       arg1=Data(numarray.array([3.4764753469957483, -4.7297221681385793]),self.functionspace)  
       res=arg0+arg1  
       ref=Data(numarray.array([8.3345379942063662, 0.1283404790720386]),self.functionspace)  
       self.failUnless(isinstance(res,Data),"wrong type of result.")  
       self.failUnlessEqual(res.getShape(),(2,),"wrong shape of result.")  
       self.failUnless(Lsup(res-ref)<=self.RES_TOL*Lsup(ref),"wrong result")  
    #+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++  
    def test_add_overloaded_float_rank0_constData_rank2(self):  
       arg0=-0.960748612766  
       arg1=Data(numarray.array([[0.61422796012866687, 1.5847396672359153, -0.02029629132715538, 1.1599743577238719, -0.30494414561669991], [-1.6332700213242113, -4.1634540348788427, -3.1593884738543752, 3.138999837647523, 4.139765676872841], [-3.0736191251063238, -0.47515643032457078, -3.2556867253522856, 3.6985726867609188, -3.5706723780370697], [4.1364498963669423, -2.544180573547139, -1.0163117145359282, -1.3794398980792755, 0.58834072547391614]]),self.functionspace)  
       res=arg0+arg1  
       ref=Data(numarray.array([[-0.34652065263774023, 0.6239910544695082, -0.98104490409356249, 0.19922574495746481, -1.265692758383107], [-2.5940186340906184, -5.1242026476452498, -4.1201370866207823, 2.1782512248811159, 3.1790170641064339], [-4.0343677378727314, -1.4359050430909779, -4.2164353381186928, 2.7378240739945117, -4.5314209908034773], [3.1757012836005352, -3.5049291863135461, -1.9770603273023353, -2.3401885108456826, -0.37240788729249097]]),self.functionspace)  
       self.failUnless(isinstance(res,Data),"wrong type of result.")  
       self.failUnlessEqual(res.getShape(),(4, 5),"wrong shape of result.")  
       self.failUnless(Lsup(res-ref)<=self.RES_TOL*Lsup(ref),"wrong result")  
    #+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++  
    def test_add_overloaded_float_rank0_constData_rank3(self):  
       arg0=-3.17470622105  
       arg1=Data(numarray.array([[[0.65666944854588216, -4.1171453089427104], [1.9474307214553077, 0.98996240702017069]], [[0.8351759676296, 0.84765720508473841], [-0.73306138067678361, -1.6966350647734476]], [[0.77055741316163573, -1.0104702506086003], [2.6508038143233561, 1.3075966449956189]], [[-2.4184982027935131, -4.0371906810452138], [1.2411499700180153, 1.4592005525281948]], [[1.3478873047166404, 0.21073088816010088], [3.2702195130177483, -3.1362166121457422]], [[-3.2521819658894549, -1.225716368558424], [-2.4157142528193623, -4.2847313298257017]]]),self.functionspace)  
       res=arg0+arg1  
       ref=Data(numarray.array([[[-2.5180367725044688, -7.2918515299930613], [-1.2272754995950432, -2.1847438140301803]], [[-2.3395302534207509, -2.3270490159656125], [-3.9077676017271346, -4.8713412858237986]], [[-2.4041488078887152, -4.1851764716589512], [-0.52390240672699484, -1.867109576054732]], [[-5.5932044238438641, -7.2118969020955648], [-1.9335562510323356, -1.7155056685221561]], [[-1.8268189163337105, -2.9639753328902501], [0.095513291967397329, -6.3109228331960932]], [[-6.4268881869398058, -4.400422589608775], [-5.5904204738697132, -7.4594375508760526]]]),self.functionspace)  
       self.failUnless(isinstance(res,Data),"wrong type of result.")  
       self.failUnlessEqual(res.getShape(),(6, 2, 2),"wrong shape of result.")  
       self.failUnless(Lsup(res-ref)<=self.RES_TOL*Lsup(ref),"wrong result")  
    #+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++  
    def test_add_overloaded_float_rank0_constData_rank4(self):  
       arg0=-1.24556902458  
       arg1=Data(numarray.array([[[[0.95144503839694927, 3.8747049772318984, 1.6637456016483814, 0.45629857743059787], [0.76792326033735137, 1.9249883810246082, -2.4437444255155372, 0.38011748852073701], [0.65207760300037076, -0.091909570334745894, -2.0902439423360364, 3.4217991791591587]], [[-2.8680510086311726, 4.9365226673466527, -0.89916792700143233, -4.5469112333531827], [-2.897100382404354, -4.132929551372893, -2.7160972180694412, -0.78846072447344451], [1.8280431279004761, -4.9506723340122285, 1.7565050257148807, 1.8885877844760133]]], [[[4.1775975687948534, -1.0659928286440188, -0.90921430152893645, -2.6369242728496767], [4.3543064450317637, -4.9884877795643483, 0.36411425710799339, -3.4648550299306047], [-2.6049605881010973, 1.4161117095327729, 1.8837504532810883, -4.407757287520063]], [[-2.3132870552683427, 4.2496663906996091, 4.9705995976045561, -0.05277006541191831], [-2.979704960306079, 1.373065595947792, -0.57292261081363094, 2.7719543224879137], [4.4692942689897883, -3.0137040993676734, 0.31446957898421601, -1.9473328719399072]]], [[[-4.8463597361851507, 4.4412299279977319, -4.3284149545626596, 1.8753470484358568], [2.6146814732931638, 1.3047608154660075, 3.8494725026732848, 4.9493006531083168], [2.5319156998838537, 0.12049544852721805, -1.8063580652030842, -2.2951712912760582]], [[4.1405675018147594, -0.64722844279997549, -2.8990375200828633, -0.36389730738412585], [-4.2130069316255963, -0.84404839000688536, 3.0476235653881254, 1.3810642470080126], [2.3820109788743915, -2.0352074520887209, -2.944895101856464, -4.8326554343975845]]]]),self.functionspace)  
       res=arg0+arg1  
       ref=Data(numarray.array([[[[-0.29412398618140223, 2.6291359526535469, 0.41817657707002986, -0.78927044714775363], [-0.47764576424100014, 0.67941935644625673, -3.6893134500938887, -0.86545153605761449], [-0.59349142157798074, -1.3374785949130974, -3.3358129669143879, 2.1762301545808072]], [[-4.1136200332095241, 3.6909536427683012, -2.1447369515797838, -5.7924802579315342], [-4.142669406982705, -5.3784985759512445, -3.9616662426477927, -2.034029749051796], [0.58247410332212457, -6.19624135859058, 0.51093600113652915, 0.64301875989766177]]], [[[2.9320285442165019, -2.3115618532223703, -2.154783326107288, -3.8824932974280282], [3.1087374204534122, -6.2340568041426998, -0.88145476747035811, -4.7104240545089562], [-3.8505296126794488, 0.17054268495442138, 0.63818142870273675, -5.6533263120984145]], [[-3.5588560798466942, 3.0040973661212576, 3.7250305730262046, -1.2983390899902698], [-4.2252739848844305, 0.12749657136944048, -1.8184916353919824, 1.5263852979095622], [3.2237252444114368, -4.2592731239460253, -0.93109944559413549, -3.1929018965182587]]], [[[-6.0919287607635022, 3.1956609034193804, -5.5739839791410111, 0.62977802385750525], [1.3691124487148123, 0.059191790887656026, 2.6039034780949333, 3.7037316285299653], [1.2863466753055022, -1.1250735760511335, -3.0519270897814357, -3.5407403158544097]], [[2.8949984772364079, -1.892797467378327, -4.1446065446612153, -1.6094663319624773], [-5.4585759562039478, -2.0896174145852369, 1.8020545408097739, 0.13549522242966106], [1.13644195429604, -3.2807764766670724, -4.190464126434815, -6.078224458975936]]]]),self.functionspace)  
       self.failUnless(isinstance(res,Data),"wrong type of result.")  
       self.failUnlessEqual(res.getShape(),(3, 2, 3, 4),"wrong shape of result.")  
       self.failUnless(Lsup(res-ref)<=self.RES_TOL*Lsup(ref),"wrong result")  
    #+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++  
    def test_add_overloaded_float_rank0_expandedData_rank0(self):  
       arg0=2.28756974271  
       msk_arg1=whereNegative(self.functionspace.getX()[0]-0.5)  
       arg1=msk_arg1*(-3.25821080509)+(1.-msk_arg1)*(-1.96555890794)  
       res=arg0+arg1  
       msk_ref=whereNegative(self.functionspace.getX()[0]-0.5)  
       ref=msk_ref*(-0.970641062386)+(1.-msk_ref)*(0.322010834763)  
       self.failUnless(isinstance(res,Data),"wrong type of result.")  
       self.failUnlessEqual(res.getShape(),(),"wrong shape of result.")  
       self.failUnless(Lsup(res-ref)<=self.RES_TOL*Lsup(ref),"wrong result")  
    #+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++  
    def test_add_overloaded_float_rank0_expandedData_rank1(self):  
       arg0=-1.48109757274  
       msk_arg1=whereNegative(self.functionspace.getX()[0]-0.5)  
       arg1=msk_arg1*numarray.array([-0.11930313378942881, -0.62281906788654862])+(1.-msk_arg1)*numarray.array([0.1478840234613461, -3.1708375150120496])  
       res=arg0+arg1  
       msk_ref=whereNegative(self.functionspace.getX()[0]-0.5)  
       ref=msk_ref*numarray.array([-1.6004007065266519, -2.1039166406237717])+(1.-msk_ref)*numarray.array([-1.333213549275877, -4.6519350877492727])  
       self.failUnless(isinstance(res,Data),"wrong type of result.")  
       self.failUnlessEqual(res.getShape(),(2,),"wrong shape of result.")  
       self.failUnless(Lsup(res-ref)<=self.RES_TOL*Lsup(ref),"wrong result")  
    #+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++  
    def test_add_overloaded_float_rank0_expandedData_rank2(self):  
       arg0=-0.169932463749  
       msk_arg1=whereNegative(self.functionspace.getX()[0]-0.5)  
       arg1=msk_arg1*numarray.array([[-4.2612545702701947, -1.4553735194531603, -0.58970170069199934, 2.7142248448804684, 0.49630072117932134], [-4.4881867211938173, 4.7705859316762904, 0.71514670382955803, 0.49136004396150845, -1.8325172939297341], [-0.90143719345550544, -3.3235824514646928, 0.73933527403416832, 1.3622462235470776, -4.2416111224814399], [-0.72400532463398015, -2.2001224685497434, 0.016979746508940963, -2.0434113303003629, 0.15588719034756338]])+(1.-msk_arg1)*numarray.array([[2.7213765937575989, -2.2795969932854887, -0.52139742824568991, 2.8522134294177048, 0.8457424404837921], [1.9417193032851561, -1.2624908054580599, 3.3961247882993515, 3.0526027481796163, -3.2773680756777548], [0.89186961224714789, -1.9930074425254896, -3.0982993453261845, 1.5175592177325035, 4.0767012391093225], [3.0717058826665884, 0.60287437134118527, 0.69734800421018406, -3.3849064077596527, 1.9193476027911105]])  
       res=arg0+arg1  
       msk_ref=whereNegative(self.functionspace.getX()[0]-0.5)  
       ref=msk_ref*numarray.array([[-4.4311870340193167, -1.6253059832022823, -0.75963416444112131, 2.5442923811313465, 0.32636825743019937], [-4.6581191849429393, 4.6006534679271684, 0.54521424008043606, 0.32142758021238649, -2.002449757678856], [-1.0713696572046274, -3.4935149152138147, 0.56940281028504636, 1.1923137597979556, -4.4115435862305619], [-0.89393778838310212, -2.3700549322988653, -0.152952717240181, -2.2133437940494849, -0.014045273401558589]])+(1.-msk_ref)*numarray.array([[2.5514441300084769, -2.4495294570346107, -0.69132989199481187, 2.6822809656685829, 0.67580997673467014], [1.7717868395360341, -1.4324232692071819, 3.2261923245502295, 2.8826702844304943, -3.4473005394268768], [0.72193714849802593, -2.1629399062746115, -3.2682318090753064, 1.3476267539833815, 3.9067687753602005], [2.9017734189174664, 0.4329419075920633, 0.52741554046106209, -3.5548388715087746, 1.7494151390419885]])  
       self.failUnless(isinstance(res,Data),"wrong type of result.")  
       self.failUnlessEqual(res.getShape(),(4, 5),"wrong shape of result.")  
       self.failUnless(Lsup(res-ref)<=self.RES_TOL*Lsup(ref),"wrong result")  
    #+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++  
    def test_add_overloaded_float_rank0_expandedData_rank3(self):  
       arg0=-4.99910304361  
       msk_arg1=whereNegative(self.functionspace.getX()[0]-0.5)  
       arg1=msk_arg1*numarray.array([[[0.29850093254277077, 3.714075099304516], [-2.0062084292548397, -0.35557992699667018]], [[-1.7426953986146456, 4.8061906014757394], [1.5737034064549089, 1.6496607633994582]], [[-1.6800592932716416, -4.0500748737766106], [4.4429696282040823, -1.6492563959507054]], [[-2.5051430702127195, -3.1501945875217996], [1.4127543784903365, 0.79949247012357461]], [[-4.2713142705563358, 1.0772945429521563], [-2.4393864151027076, -1.3896557048674865]], [[0.53207200317978298, 4.0627978954482842], [1.0050799831054178, 1.4452226284926244]]])+(1.-msk_arg1)*numarray.array([[[2.3431949600418616, 0.8414028269541598], [4.6319839217175183, 0.56797063519890667]], [[-3.2338388926276354, 4.5658188965197937], [4.5411637311129489, 1.2477521190802747]], [[3.9620056685525924, 4.3928088981260256], [-4.5202678253177471, -0.70854236298596263]], [[-4.7481282129627207, 2.5902043569660824], [3.4921233211469893, 2.0298092936252115]], [[-2.6485885919561092, -1.4434844680815795], [1.4293998615045513, -3.4092526835229608]], [[-1.6057571388949521, -1.8750269826220798], [-4.0024929190275502, -3.5596610079280868]]])  
       res=arg0+arg1  
       msk_ref=whereNegative(self.functionspace.getX()[0]-0.5)  
       ref=msk_ref*numarray.array([[[-4.7006021110648444, -1.2850279443030992], [-7.0053114728624548, -5.3546829706042853]], [[-6.7417984422222608, -0.19291244213187575], [-3.4253996371527062, -3.3494422802081569]], [[-6.6791623368792568, -9.0491779173842257], [-0.55613341540353289, -6.6483594395583205]], [[-7.5042461138203347, -8.1492976311294143], [-3.5863486651172787, -4.1996105734840405]], [[-9.2704173141639501, -3.9218085006554588], [-7.4384894587103227, -6.3887587484751016]], [[-4.4670310404278322, -0.93630514815933097], [-3.9940230605021974, -3.5538804151149908]]])+(1.-msk_ref)*numarray.array([[[-2.6559080835657536, -4.1577002166534553], [-0.36711912189009688, -4.4311324084087085]], [[-8.2329419362352496, -0.43328414708782148], [-0.45793931249466624, -3.7513509245273404]], [[-1.0370973750550228, -0.60629414548158955], [-9.5193708689253622, -5.7076454065935778]], [[-9.7472312565703358, -2.4088986866415327], [-1.5069797224606258, -2.9692937499824037]], [[-7.6476916355637243, -6.4425875116891946], [-3.5697031821030638, -8.4083557271305764]], [[-6.6048601825025672, -6.8741300262296949], [-9.0015959626351645, -8.558764051535702]]])  
       self.failUnless(isinstance(res,Data),"wrong type of result.")  
       self.failUnlessEqual(res.getShape(),(6, 2, 2),"wrong shape of result.")  
       self.failUnless(Lsup(res-ref)<=self.RES_TOL*Lsup(ref),"wrong result")  
    #+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++  
    def test_add_overloaded_float_rank0_expandedData_rank4(self):  
       arg0=1.21550213728  
       msk_arg1=whereNegative(self.functionspace.getX()[0]-0.5)  
       arg1=msk_arg1*numarray.array([[[[1.0090528070218792, 1.9106307145237276, 1.6811659991192984, 2.8746039011671201], [3.2128900608106026, -1.0029381650779232, 4.2582290110477778, -1.5314746280325542], [4.0200741047501438, 0.85429503200093215, -0.28959048929557341, 1.4685265541069095]], [[1.2666874812904458, 0.90859131882091138, -4.2124353036681423, -1.7969402819454117], [1.0681193393672039, -4.3552123630695094, -4.0032577832731144, 3.2235178675683365], [-2.293608774526823, -0.27617082319340369, -3.0553161480163284, 2.699016796800481]]], [[[-3.1592591010135926, -1.8065617435984271, -0.93322835636729717, -0.89350955190884562], [2.1664533395005003, 3.2021639012191052, 0.15085237132003737, 3.6542023388021132], [-3.189090353824271, -0.78745648331728368, 3.5473512169629995, -0.63428493269093256]], [[-2.386669713513625, -4.7249747367905695, 3.4621305968521305, 0.34721477382276866], [2.3599620375368797, 4.925504023751424, -1.3387970171374377, 1.152119609204016], [0.57074477861866502, 1.8075335514397075, -4.0376335655417996, 0.86708280343111621]]], [[[2.9038868635591397, -0.27534668498916304, -3.9273410552323949, -2.6820553539377601], [2.4365074320647118, 0.34999517479826903, -0.22854769539843645, 4.6781171985127763], [4.3296374276993586, 0.21922883926851178, -4.1350155169284406, -2.3582136069048265]], [[2.7860786548105585, 0.83594561167553039, 3.623188500876843, 4.3388769109633465], [1.5411983648209908, -4.097340022156307, -3.2603388376815912, -3.7625212974408386], [4.3922641365190778, -1.4584604688981551, -1.9458060732729168, 4.7470750011718614]]]])+(1.-msk_arg1)*numarray.array([[[[-2.2971897212575207, -1.9323104367751931, -3.8542469069725396, 4.4485944332819258], [-0.06607231477291009, 3.5762633193874507, 3.0154617420368783, 4.9407171282501405], [2.8328870417941907, 0.23672608745144785, -4.1568219116800043, -4.1857481457198258]], [[-4.8093606380089078, -0.0397779241154117, -2.259901622863195, -2.6136275582736266], [-1.4468880860816835, -2.8849999573458129, -3.4179565382839341, -0.92149747328494236], [-2.9713341854979558, 2.8022998913702484, 2.1636456257249694, 0.86254768081227784]]], [[[2.7331065399732859, -2.2351090040619894, -4.6449973078603453, 0.13463596660747346], [2.6288109676308435, -0.037459392356389287, 1.9238240618360258, -3.6974685040353252], [-3.7273667494078842, 0.99700193553500505, 3.4049543411691605, -2.8277946400159495]], [[-0.22566250469420268, 2.9040508082870895, -2.2086574043072238, -1.4485197834588757], [-2.7506068061432885, 4.319997296598773, 4.9353724835318005, 2.4434995113874622], [-3.2330978793405016, -1.185285494021231, -3.1350829568229797, 4.9424587873350312]]], [[[0.98877632378951397, -4.3541317234880017, -3.7870507206588968, -0.87876410126227356], [2.4458382558057332, -2.9329967445924341, -3.0784459129878936, 4.664501550132039], [-0.58295001827707527, -4.1343617072890195, -0.20833671027188227, 0.33631155313822081]], [[-3.5785184648203838, 0.24035957564971877, -2.460749216305802, -4.8033953332916379], [-3.3222083232340403, 4.0706334960022428, 4.3331160444287882, -0.61020302237093649], [-2.3490864183384028, 0.58130243023294614, 1.5993199992299312, -2.5330132221058621]]]])  
       res=arg0+arg1  
       msk_ref=whereNegative(self.functionspace.getX()[0]-0.5)  
       ref=msk_ref*numarray.array([[[[2.224554944300225, 3.1261328518020735, 2.8966681363976443, 4.0901060384454659], [4.4283921980889485, 0.21256397220042267, 5.4737311483261237, -0.3159724907542083], [5.2355762420284897, 2.069797169279278, 0.92591164798277248, 2.6840286913852553]], [[2.4821896185687917, 2.1240934560992573, -2.9969331663897965, -0.58143814466706578], [2.2836214766455498, -3.1397102257911635, -2.7877556459947685, 4.4390200048466824], [-1.0781066372484771, 0.93933131408494219, -1.8398140107379826, 3.9145189340788269]]], [[[-1.9437569637352468, -0.59105960632008125, 0.28227378091104871, 0.32199258536950026], [3.3819554767788462, 4.4176660384974511, 1.3663545085983833, 4.8697044760804591], [-1.9735882165459251, 0.4280456539610622, 4.7628533542413454, 0.58121720458741333]], [[-1.1711675762352791, -3.5094725995122236, 4.6776327341304764, 1.5627169111011145], [3.5754641748152256, 6.1410061610297699, -0.12329487985909182, 2.3676217464823619], [1.7862469158970109, 3.0230356887180534, -2.8221314282634538, 2.0825849407094621]]], [[[4.1193890008374856, 0.94015545228918285, -2.711838917954049, -1.4665532166594142], [3.6520095693430576, 1.5654973120766149, 0.98695444187990944, 5.8936193357911222], [5.5451395649777044, 1.4347309765468577, -2.9195133796500947, -1.1427114696264806]], [[4.0015807920889044, 2.0514477489538763, 4.8386906381551889, 5.5543790482416924], [2.7567005020993367, -2.8818378848779611, -2.0448367004032453, -2.5470191601624927], [5.6077662737974237, -0.24295833161980918, -0.73030393599457089, 5.9625771384502073]]]])+(1.-msk_ref)*numarray.array([[[[-1.0816875839791749, -0.71680829949684721, -2.6387447696941937, 5.6640965705602717], [1.1494298225054358, 4.7917654566657966, 4.2309638793152242, 6.1562192655284864], [4.0483891790725366, 1.4522282247297937, -2.9413197744016584, -2.9702460084414799]], [[-3.5938585007305619, 1.1757242131629342, -1.0443994855848491, -1.3981254209952807], [-0.23138594880333763, -1.6694978200674671, -2.2024544010055882, 0.29400466399340353], [-1.7558320482196099, 4.0178020286485943, 3.3791477630033153, 2.0780498180906237]]], [[[3.9486086772516318, -1.0196068667836435, -3.4294951705819994, 1.3501381038858193], [3.8443131049091894, 1.1780427449219566, 3.1393261991143717, -2.4819663667569793], [-2.5118646121295383, 2.2125040728133509, 4.6204564784475064, -1.6122925027376036]], [[0.9898396325841432, 4.1195529455654354, -0.99315526702887791, -0.23301764618052978], [-1.5351046688649426, 5.5354994338771188, 6.1508746208101464, 3.6590016486658081], [-2.0175957420621558, 0.030216643257114928, -1.9195808195446338, 6.1579609246133771]]], [[[2.2042784610678599, -3.1386295862096558, -2.5715485833805509, 0.33673803601607233], [3.6613403930840791, -1.7174946073140882, -1.8629437757095477, 5.8800036874103849], [0.63255211900127062, -2.9188595700106736, 1.0071654270064636, 1.5518136904165667]], [[-2.3630163275420379, 1.4558617129280647, -1.2452470790274561, -3.587893196013292], [-2.1067061859556944, 5.2861356332805887, 5.5486181817071341, 0.6052991149074094], [-1.1335842810600569, 1.796804567511292, 2.8148221365082771, -1.3175110848275162]]]])  
       self.failUnless(isinstance(res,Data),"wrong type of result.")  
       self.failUnlessEqual(res.getShape(),(3, 2, 3, 4),"wrong shape of result.")  
       self.failUnless(Lsup(res-ref)<=self.RES_TOL*Lsup(ref),"wrong result")  
    #+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++  
    def test_add_overloaded_float_rank0_Symbol_rank0(self):  
       arg0=-1.02534174881  
       arg1=Symbol(shape=())  
       res=arg0+arg1  
       s1=numarray.array(-4.33625684225)  
       sub=res.substitute({arg1:s1})  
       ref=numarray.array(-5.36159859106)  
       self.failUnless(isinstance(res,Symbol),"wrong type of result.")  
       self.failUnlessEqual(res.getShape(),(),"wrong shape of result.")  
       self.failUnless(Lsup(sub-ref)<=self.RES_TOL*Lsup(ref),"wrong result")  
    #+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++  
    def test_add_overloaded_float_rank0_Symbol_rank1(self):  
       arg0=4.00638967702  
       arg1=Symbol(shape=(2,))  
       res=arg0+arg1  
       s1=numarray.array([-3.2788211191636272, 0.40197241921644977])  
       sub=res.substitute({arg1:s1})  
       ref=numarray.array([0.72756855785368479, 4.4083620962337617])  
       self.failUnless(isinstance(res,Symbol),"wrong type of result.")  
       self.failUnlessEqual(res.getShape(),(2,),"wrong shape of result.")  
       self.failUnless(Lsup(sub-ref)<=self.RES_TOL*Lsup(ref),"wrong result")  
    #+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++  
    def test_add_overloaded_float_rank0_Symbol_rank2(self):  
       arg0=4.37575468534  
       arg1=Symbol(shape=(4, 5))  
       res=arg0+arg1  
       s1=numarray.array([[-4.6630396568758279, -3.1956340017400708, -2.8069532594662983, 1.7209167084099626, -1.423118573430818], [2.9213094545958302, -3.3219853686124692, -4.4040134430919808, 2.7752933668193407, 4.2049998039803587], [-1.1383874736469437, 0.23485791628185027, -3.5007437909710113, 0.5915098132733192, 3.874076015675719], [0.3702045875364357, 3.0308157187054778, 0.89848093801439877, -3.761713470419914, 0.1526054517776112]])  
       sub=res.substitute({arg1:s1})  
       ref=numarray.array([[-0.28728497153464261, 1.1801206836011144, 1.568801425874887, 6.0966713937511479, 2.9526361119103672], [7.2970641399370155, 1.0537693167287161, -0.02825875775079556, 7.151048052160526, 8.5807544893215439], [3.2373672116942416, 4.6106126016230355, 0.87501089437017399, 4.9672644986145045, 8.2498307010169043], [4.745959272877621, 7.4065704040466631, 5.274235623355584, 0.61404121492127128, 4.5283601371187965]])  
       self.failUnless(isinstance(res,Symbol),"wrong type of result.")  
       self.failUnlessEqual(res.getShape(),(4, 5),"wrong shape of result.")  
       self.failUnless(Lsup(sub-ref)<=self.RES_TOL*Lsup(ref),"wrong result")  
    #+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++  
    def test_add_overloaded_float_rank0_Symbol_rank3(self):  
       arg0=1.18463485087  
       arg1=Symbol(shape=(6, 2, 2))  
       res=arg0+arg1  
       s1=numarray.array([[[-4.8037156497413713, -2.0905139798443759], [-4.1734764428560878, -1.5196595332126259]], [[0.5139082550288423, 1.8261032121495049], [-2.8489875583341737, -3.7544885746479384]], [[-3.8307712191969756, 3.8835809221879884], [0.38860156986987526, 4.833612940224576]], [[2.0131711043766574, -1.6211007660194667], [1.834869732218209, 1.452027834491183]], [[-2.0904105484106497, -2.5515706248989876], [1.432725583104915, 0.38179177628590466]], [[-0.1816750387292867, 0.25623546736859737], [-2.5404325223276683, -3.6270715752041993]]])  
       sub=res.substitute({arg1:s1})  
       ref=numarray.array([[[-3.6190807988741645, -0.90587912897716905], [-2.9888415919888809, -0.33502468234541904]], [[1.6985431058960492, 3.0107380630167118], [-1.6643527074669668, -2.5698537237807315]], [[-2.6461363683297687, 5.0682157730551953], [1.5732364207370821, 6.0182477910917829]], [[3.1978059552438642, -0.43646591515225985], [3.0195045830854159, 2.6366626853583899]], [[-0.90577569754344278, -1.3669357740317807], [2.6173604339721219, 1.5664266271531115]], [[1.0029598121379202, 1.4408703182358042], [-1.3557976714604614, -2.4424367243369924]]])  
       self.failUnless(isinstance(res,Symbol),"wrong type of result.")  
       self.failUnlessEqual(res.getShape(),(6, 2, 2),"wrong shape of result.")  
       self.failUnless(Lsup(sub-ref)<=self.RES_TOL*Lsup(ref),"wrong result")  
    #+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++  
    def test_add_overloaded_float_rank0_Symbol_rank4(self):  
       arg0=-4.65129821567  
       arg1=Symbol(shape=(3, 2, 3, 4))  
       res=arg0+arg1  
       s1=numarray.array([[[[0.68993670010109565, -4.0163179251569474, -4.1648310461251414, -4.778814664891148], [1.0707877090708386, 2.5326113162472019, -1.5147221392342658, 0.88657360420535625], [-4.3335120564307195, 4.3865636722950754, 4.4304446339569274, 4.7048447967064071]], [[0.32793921406159754, -1.8294601672862152, 4.0882430559927307, 2.1117933944770932], [-0.79488102071059963, 1.8905549855669266, -4.8371445680209373, -3.6127183225555006], [1.5281970384410375, -4.6239921683710383, -2.6453258525672494, 1.1246634985101176]]], [[[0.21398595796777009, 0.31807416662460319, -2.2221092516238503, 0.12560580463083504], [-4.6168031995078094, 1.9986179024253641, -1.7382356570952617, -1.9522476741058439], [-3.0079988792632961, -0.60003495704375265, 4.9879893207661503, 1.7658211080853325]], [[-0.3202973551798145, 1.136127817429081, -4.9309227460362521, -4.5290306196460426], [-0.21707037673963114, 4.6725867751122117, 1.980083908153512, -3.0159873108253166], [-2.2415810532060956, 2.9465927419293161, -1.4080210694824968, -2.7777957375257509]]], [[[-4.5562764421472721, 1.9285026147658986, -3.7918606762119875, -2.6948114406357337], [-1.3639643163845125, 1.9381789471260182, -0.71828943754706209, -4.1320520853554532], [-1.2947446193334491, 1.1673610140762491, 1.8451268841455253, -1.2878294697467965]], [[-1.5686556530611453, 1.1924537989183301, -1.1110231639994019, 1.4621405634564724], [-0.13152846075432212, 1.7791464711106739, 4.57076914605722, 4.722965521992478], [1.8530166481929111, -4.152439969506899, 1.6654844780892599, 2.3242972690569292]]]])  
       sub=res.substitute({arg1:s1})  
       ref=numarray.array([[[[-3.961361515565466, -8.6676161408235082, -8.8161292617917031, -9.4301128805577097], [-3.580510506595723, -2.1186868994193597, -6.1660203549008274, -3.7647246114612054], [-8.9848102720972811, -0.26473454337148628, -0.22085358170963421, 0.053546581039845442]], [[-4.3233590016049641, -6.4807583829527768, -0.56305515967383091, -2.5395048211894684], [-5.4461792363771613, -2.7607432300996351, -9.4884427836874998, -8.2640165382220623], [-3.1231011772255242, -9.2752903840376, -7.296624068233811, -3.5266347171564441]]], [[[-4.4373122576987916, -4.3332240490419585, -6.873407467290412, -4.5256924110357266], [-9.268101415174371, -2.6526803132411976, -6.3895338727618238, -6.6035458897724055], [-7.6592970949298582, -5.2513331727103143, 0.33669110509958866, -2.8854771075812291]], [[-4.9715955708463762, -3.5151703982374807, -9.5822209617028129, -9.1803288353126042], [-4.8683685924061928, 0.021288559445650002, -2.6712143075130497, -7.6672855264918782], [-6.8928792688726572, -1.7047054737372456, -6.0593192851490585, -7.4290939531923126]]], [[[-9.2075746578138329, -2.7227956009006631, -8.4431588918785501, -7.3461096563022954], [-6.0152625320510742, -2.7131192685405434, -5.3695876532136237, -8.7833503010220149], [-5.9460428350000107, -3.4839372015903125, -2.8061713315210364, -5.9391276854133581]], [[-6.2199538687277069, -3.4588444167482315, -5.7623213796659636, -3.1891576522100893], [-4.7828266764208838, -2.8721517445558877, -0.080529069609341697, 0.071667306325916336], [-2.7982815674736505, -8.8037381851734615, -2.9858137375773017, -2.3270009466096324]]]])  
       self.failUnless(isinstance(res,Symbol),"wrong type of result.")  
       self.failUnlessEqual(res.getShape(),(3, 2, 3, 4),"wrong shape of result.")  
       self.failUnless(Lsup(sub-ref)<=self.RES_TOL*Lsup(ref),"wrong result")  
    #+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++  
    def test_pow_overloaded_float_rank0_constData_rank0(self):  
       arg0=3.7652582944  
       arg1=Data(3.1005820944,self.functionspace)  
       res=arg0**arg1  
       ref=Data(60.9956643611,self.functionspace)  
       self.failUnless(isinstance(res,Data),"wrong type of result.")  
       self.failUnlessEqual(res.getShape(),(),"wrong shape of result.")  
       self.failUnless(Lsup(res-ref)<=self.RES_TOL*Lsup(ref),"wrong result")  
    #+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++  
    def test_pow_overloaded_float_rank0_constData_rank1(self):  
       arg0=1.56847796034  
       arg1=Data(numarray.array([1.668960941491038, 1.5438441811985528]),self.functionspace)  
       res=arg0**arg1  
       ref=Data(numarray.array([2.1195606529779085, 2.003494811618745]),self.functionspace)  
       self.failUnless(isinstance(res,Data),"wrong type of result.")  
       self.failUnlessEqual(res.getShape(),(2,),"wrong shape of result.")  
       self.failUnless(Lsup(res-ref)<=self.RES_TOL*Lsup(ref),"wrong result")  
    #+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++  
    def test_pow_overloaded_float_rank0_constData_rank2(self):  
       arg0=0.853668063781  
       arg1=Data(numarray.array([[3.2486997556413488, 0.86400711652329565, 3.2884578380088287, 1.2334289335947253, 2.5487776044652506], [3.7635594458327879, 2.0892653973449962, 3.1786608578416762, 0.14432777693961937, 2.6022783227644193], [0.10738723325449236, 1.9315854964052719, 3.1596089936211107, 0.45131939265454701, 2.5221015795578148], [3.296601365878248, 0.11581499226281025, 3.8612489083924948, 4.5664152349145377, 1.2728985965946598]]),self.functionspace)  
       res=arg0**arg1  
       ref=Data(numarray.array([[0.59810674931764074, 0.87223445231801477, 0.59435632263408789, 0.82271593116798969, 0.66814547267568969], [0.55131803150166692, 0.71852942411582488, 0.60477125876633264, 0.97742422610323876, 0.66251382293516647], [0.98315347711569301, 0.73668002747870431, 0.60659694046203705, 0.93108516866399793, 0.67097133288368638], [0.59359104068625757, 0.98184343378610262, 0.54286252143570424, 0.48555362457985307, 0.81759440057278132]]),self.functionspace)  
       self.failUnless(isinstance(res,Data),"wrong type of result.")  
       self.failUnlessEqual(res.getShape(),(4, 5),"wrong shape of result.")  
       self.failUnless(Lsup(res-ref)<=self.RES_TOL*Lsup(ref),"wrong result")  
    #+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++  
    def test_pow_overloaded_float_rank0_constData_rank3(self):  
       arg0=0.357074915448  
       arg1=Data(numarray.array([[[0.38518924057053733, 0.24038528636715123], [1.6360866883952314, 0.43029605106106911]], [[3.423417953608805, 4.2988721626759077], [1.2524682631274544, 1.1468077998964645]], [[0.58295721049108573, 3.824568580799006], [3.0208703291598176, 1.3499811271261073]], [[3.0953057377971902, 1.3094835373781], [3.6681512369867795, 4.6149094849966819]], [[2.7674281276596542, 1.1256247920546796], [1.8871491353554231, 1.9524702935330096]], [[1.7534659804811799, 0.081583735919993849], [0.44546937195258135, 0.72867650813344209]]]),self.functionspace)  
       res=arg0**arg1  
       ref=Data(numarray.array([[[0.67255485268654747, 0.78071033102668452], [0.18547078622777072, 0.6420282101483078]], [[0.029438000064868096, 0.01195004623087142], [0.27532476037344766, 0.30697352764374525]], [[0.54862782939462229, 0.019475895313555789], [0.044559875252802042, 0.24901961219972699]], [[0.041271801415451524, 0.25962452868686592], [0.022879873935515389, 0.0086302791912317954]], [[0.057848702603705324, 0.31374356524419156], [0.14321555126374733, 0.13389855839543346]], [[0.16435341072630344, 0.91941680244570745], [0.63207408549094379, 0.4721785335572487]]]),self.functionspace)  
       self.failUnless(isinstance(res,Data),"wrong type of result.")  
       self.failUnlessEqual(res.getShape(),(6, 2, 2),"wrong shape of result.")  
       self.failUnless(Lsup(res-ref)<=self.RES_TOL*Lsup(ref),"wrong result")  
    #+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++  
    def test_pow_overloaded_float_rank0_constData_rank4(self):  
       arg0=2.54914513421  
       arg1=Data(numarray.array([[[[1.270326259520153, 2.703299648777842, 4.8868346033905601, 2.3051326073096781], [3.2104019478564068, 4.817944979076735, 3.3247417263409202, 0.98796021017567104], [2.8880422572281463, 3.785353186109202, 1.1117179336379168, 4.9472947776437248]], [[3.5602918771225234, 3.5282818484304541, 2.8402575218661106, 1.6543365821874987], [0.16084877586377758, 0.89809582383337261, 1.3182980703805016, 3.3178012989111392], [3.2028874945099108, 2.5648139049109338, 4.8955284805714774, 3.5432022149852789]]], [[[1.1618978717086723, 2.7972414378300354, 3.8402714340316493, 1.6001498069270363], [1.087268582711364, 1.737265734430502, 3.6813919135947497, 4.3853914265325047], [1.88609441539519, 0.76524872642235886, 3.6761434732611624, 4.3321470021505437]], [[3.8235160205264509, 1.4456401748290546, 4.9173755965598991, 0.81975566563269575], [3.2061466542685157, 4.1636780468474139, 4.6306556567028174, 2.5296462390778065], [4.845909777306229, 0.57810028049528195, 1.1669649534267978, 4.7820404580882832]]], [[[2.1014714421841116, 2.4894332649036168, 2.3637808594117877, 0.5984928521048446], [3.4559984949550633, 2.686579205418913, 2.2483997830542748, 0.020742963721536667], [4.9435995803226715, 3.1161994022593595, 1.4907525564149176, 2.7151195320092083]], [[4.9609626993990288, 3.2550482319119549, 2.756546888804754, 4.1177301026436313], [3.2969135888482954, 1.1694652654802464, 3.5049458620366489, 2.086655354958836], [1.305388807910512, 4.1439092644148641, 4.1618527860945553, 0.27563591561125417]]]]),self.functionspace)  
       res=arg0**arg1  
       ref=Data(numarray.array([[[[3.2828699942440989, 12.548917902286258, 96.823997850208443, 8.6455645449807932], [20.169256775933832, 90.779260772485557, 22.446930364732179, 2.5205867988213329], [14.917109221466619, 34.541958014986271, 2.8300631290510951, 102.45984550866767]], [[27.982290424490554, 27.156547644185704, 14.264784430300786, 4.7023331158783899], [1.162433367658529, 2.3172946523503977, 3.433595788127132, 22.301619783037562], [20.027929872633244, 11.023675606380118, 97.614909291888679, 27.538362597921434]]], [[[2.9661217756338676, 13.701992022280693, 36.363479213061616, 4.469842090112488], [2.7660500872410752, 5.0817740136946528, 31.339903588247452, 60.561863519575425], [5.8411520949429976, 2.0464112817180369, 31.186362199170709, 57.618372322207513]], [[35.797782115214986, 3.8681232751319539, 99.631049282802593, 2.1534968710662095], [20.089103989632303, 49.214844611560132, 76.185667975322431, 10.666807966518682], [93.186153150784094, 1.7176584513241597, 2.9802192231638229, 87.779931945141115]]], [[[7.1454003570562259, 10.272878285306508, 9.1332992663966657, 1.7507504263789035], [25.380431205406289, 12.354101945587495, 8.1985574857144279, 1.0196000020407845], [102.10617058325805, 18.467431327194475, 4.0349088932001909, 12.688486277704584]], [[103.77870947420652, 21.029739940364855, 13.190026463287207, 47.143641282881781], [21.869948257238978, 2.9872001672429778, 26.569962421375287, 7.0470181501669806], [3.3923676531460898, 48.312798275660654, 49.130857281409916, 1.2942463156201212]]]]),self.functionspace)  
       self.failUnless(isinstance(res,Data),"wrong type of result.")  
       self.failUnlessEqual(res.getShape(),(3, 2, 3, 4),"wrong shape of result.")  
       self.failUnless(Lsup(res-ref)<=self.RES_TOL*Lsup(ref),"wrong result")  
    #+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++  
    def test_pow_overloaded_float_rank0_expandedData_rank0(self):  
       arg0=0.672041586744  
       msk_arg1=whereNegative(self.functionspace.getX()[0]-0.5)  
       arg1=msk_arg1*(2.50085945333)+(1.-msk_arg1)*(0.714228495159)  
       res=arg0**arg1  
       msk_ref=whereNegative(self.functionspace.getX()[0]-0.5)  
       ref=msk_ref*(0.370119550813)+(1.-msk_ref)*(0.752872459895)  
       self.failUnless(isinstance(res,Data),"wrong type of result.")  
       self.failUnlessEqual(res.getShape(),(),"wrong shape of result.")  
       self.failUnless(Lsup(res-ref)<=self.RES_TOL*Lsup(ref),"wrong result")  
    #+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++  
    def test_pow_overloaded_float_rank0_expandedData_rank1(self):  
       arg0=3.83643456658  
       msk_arg1=whereNegative(self.functionspace.getX()[0]-0.5)  
       arg1=msk_arg1*numarray.array([2.4649528119460604, 4.4015773579432063])+(1.-msk_arg1)*numarray.array([2.5050056042267443, 3.1185274699598557])  
       res=arg0**arg1  
       msk_ref=whereNegative(self.functionspace.getX()[0]-0.5)  
       ref=msk_ref*numarray.array([27.501378365433037, 371.70924493690819])+(1.-msk_ref)*numarray.array([29.02300655036413, 66.220868195790914])  
       self.failUnless(isinstance(res,Data),"wrong type of result.")  
       self.failUnlessEqual(res.getShape(),(2,),"wrong shape of result.")  
       self.failUnless(Lsup(res-ref)<=self.RES_TOL*Lsup(ref),"wrong result")  
    #+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++  
    def test_pow_overloaded_float_rank0_expandedData_rank2(self):  
       arg0=1.13471850643  
       msk_arg1=whereNegative(self.functionspace.getX()[0]-0.5)  
       arg1=msk_arg1*numarray.array([[0.58912677090382137, 0.93983668514090013, 2.0122074986633924, 4.4727320622173794, 1.2940493913793865], [0.41905245533976337, 1.7214742795801785, 3.3690628746243316, 4.3264805098978441, 2.2821866717410533], [3.5873589494704259, 4.5154183135527708, 0.67571874016825018, 0.49739384193149055, 2.297552452346038], [2.4711308013943767, 0.035889491188690691, 0.56766133369174721, 2.9251085245873232, 4.0512786424163183]])+(1.-msk_arg1)*numarray.array([[4.3857003148743008, 4.7692907184605806, 2.1049865113290753, 4.7253126157148948, 4.6473956540399657], [4.7007738365129486, 3.4364353832802648, 1.8949658645375465, 4.6712667420053657, 3.7857807635261378], [3.2496714869217667, 1.8954007017372452, 1.414346327611854, 1.8982366357369476, 4.2242475882140065], [2.9895955236808205, 4.0056998573414901, 4.0987731208544638, 2.6341113165055616, 0.83739250662962583]])  
       res=arg0**arg1  
       msk_ref=whereNegative(self.functionspace.getX()[0]-0.5)  
       ref=msk_ref*numarray.array([[1.0772985404874016, 1.1261231478052052, 1.2895741613114386, 1.7599483980551891, 1.1776817946355922], [1.0543893459992322, 1.24304977052763, 1.5308110476569741, 1.7277164132177647, 1.3343353041969708], [1.5736329944297045, 1.7694687751144236, 1.0891531288355194, 1.0648808615781149, 1.3369290986616456], [1.3665822272329975, 1.0045461819546835, 1.0743798971224092, 1.4472839975883616, 1.6686572548284615]])+(1.-msk_ref)*numarray.array([[1.7406959700520956, 1.8271638189402759, 1.3047845032528298, 1.8170363298534116, 1.7992308696652106], [1.8114098407754482, 1.5439013229774907, 1.2706067196110626, 1.8046672342912449, 1.6135946927617708], [1.5078856800121894, 1.2706765499191768, 1.1957236972774039, 1.2711320654123079, 1.7055367599969291], [1.459127798590762, 1.6590726589695033, 1.6787036103748865, 1.3950233126781093, 1.1116368001118335]])  
       self.failUnless(isinstance(res,Data),"wrong type of result.")  
       self.failUnlessEqual(res.getShape(),(4, 5),"wrong shape of result.")  
       self.failUnless(Lsup(res-ref)<=self.RES_TOL*Lsup(ref),"wrong result")  
    #+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++  
    def test_pow_overloaded_float_rank0_expandedData_rank3(self):  
       arg0=4.69671679008  
       msk_arg1=whereNegative(self.functionspace.getX()[0]-0.5)  
       arg1=msk_arg1*numarray.array([[[4.1109492881321765, 1.5337005632312695], [4.3407884519530366, 4.6530992322911136]], [[2.5646089934744452, 2.519089903454621], [1.4887838873084611, 0.34112905345492628]], [[3.5362317357059716, 3.8706128693651469], [1.1870955077990113, 4.4747271870138459]], [[1.188825141228715, 0.62354589843593555], [2.2744424942987802, 2.6498967536945086]], [[1.900681769034668, 2.9685327729104474], [4.9963790460373829, 1.7061294551675452]], [[2.5090791675722377, 2.1621870068681837], [3.4768663195477485, 4.2757225442582376]]])+(1.-msk_arg1)*numarray.array([[[0.55947048241267894, 3.892675918272622], [2.0928980801633474, 3.4373418158231508]], [[3.1001717026044253, 0.2732937451339511], [1.3529965739226828, 2.942372355807342]], [[0.19566839701147096, 3.5887158621765871], [2.74664233625374, 0.52321381674739664]], [[4.8284101588082473, 3.8297905260356648], [0.37716052032457881, 1.5885464889650818]], [[1.1563227169890045, 2.9607643976148381], [3.2225447832954872, 1.3146888053450296]], [[3.6572582485321434, 3.2335045378392566], [0.55266266203484782, 1.6820417984729208]]])  
       res=arg0**arg1  
       msk_ref=whereNegative(self.functionspace.getX()[0]-0.5)  
       ref=msk_ref*numarray.array([[[577.71361183417048, 10.723372898515619], [824.36065818127418, 1336.3674293440472]], [[52.831128957427595, 49.239135886293603], [10.00360738339231, 1.6949956135969837]], [[237.4764687630614, 398.34185963465751], [6.2731270382215989, 1014.1368084784533]], [[6.2899333072924852, 2.6235818996943157], [33.725443528800987, 60.281732951333787]], [[18.917655727234941, 98.683288531378238], [2272.6854395211553, 14.001293771330797]], [[48.482529090228326, 28.349477896809432], [216.64029075415539, 745.42910675836185]]])+(1.-msk_ref)*numarray.array([[[2.3760146936426265, 412.1713290347119], [25.468135625976604, 203.7918870061259]], [[120.97006271287876, 1.5261499268949541], [8.1084059812258715, 94.76963162907046]], [[1.3534709167425627, 257.56041919364674], [70.013028937280922, 2.2464259022347384]], [[1752.664443764852, 373.9656614833155], [1.7921498298672001, 11.672841617856733]], [[5.9815136051294902, 97.504545603100766], [146.17983011754166, 7.6418857758763306]], [[286.36867675378357, 148.67917899777751], [2.351124714064428, 13.489200678865306]]])  
       self.failUnless(isinstance(res,Data),"wrong type of result.")  
       self.failUnlessEqual(res.getShape(),(6, 2, 2),"wrong shape of result.")  
       self.failUnless(Lsup(res-ref)<=self.RES_TOL*Lsup(ref),"wrong result")  
    #+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++  
    def test_pow_overloaded_float_rank0_expandedData_rank4(self):  
       arg0=3.30902145167  
       msk_arg1=whereNegative(self.functionspace.getX()[0]-0.5)  
       arg1=msk_arg1*numarray.array([[[[3.1725349657503203, 3.0845748500431833, 1.3251300629206579, 2.6569079873920867], [4.401133367358729, 0.2813959929768825, 1.7519650763785801, 2.6178805778238692], [1.8864041086569574, 3.7791551835731969, 1.3422457102105219, 0.2081604723265463]], [[2.1902428534420713, 3.0841633696278761, 2.9965222635048661, 2.2869374663249884], [2.7280695311253944, 3.9590303115195788, 3.1301491431538744, 4.182436518053791], [1.2260234819740716, 1.8242153795636069, 3.9401624249260436, 3.4349251048319336]]], [[[0.48861823801104354, 2.3131499879646946, 1.2086122619459398, 2.2409237938676974], [3.3117711127665297, 0.87018754086000127, 1.6709579147934865, 1.2893183225200897], [1.3390161693818554, 1.0108007072272069, 3.9414993282493, 1.4462150778696792]], [[3.7967170311866441, 2.0212015799940115, 3.8412381336762307, 2.4057808908249125], [0.26260712889943277, 1.5647590608685933, 2.3707533968847603, 2.6465667159258581], [4.4731993538103074, 3.7651741459195378, 3.1338509227608538, 3.5035590250769135]]], [[[3.3050973895841906, 4.0367399640154655, 2.4941086434787398, 0.39145638395278809], [1.0614822508511919, 4.5756493953902719, 0.475720968447504, 2.1319535282121014], [1.7670440121784567, 4.7448652509649039, 1.8204034323285305, 4.7703236186277493]], [[2.1011053202368353, 2.3665545270862758, 1.6073533542163603, 1.2600308196018239], [0.29247411729720818, 2.3684742025187231, 1.7771399367205181, 4.9668082864579608], [4.595426606005498, 1.6371273654479281, 1.5037601874471596, 3.78912031777574]]]])+(1.-msk_arg1)*numarray.array([[[[4.8327836291046573, 1.1638816644184602, 2.1517890444121353, 3.3263630206047123], [3.7647650305885212, 1.1608624440787043, 0.61940200250059252, 3.3853649131580092], [2.9385268975715064, 0.52662330688397618, 4.4799956940372914, 2.9996151641521429]], [[0.70044410456478112, 4.3945400808511978, 3.1252348972736086, 1.2688805783984476], [0.15599343791305745, 0.53599762707945264, 1.061576396298286, 2.5648049865803384], [0.19676100009146294, 0.32071368159627772, 4.7168617485783004, 0.11755525142074101]]], [[[3.7377217347115015, 2.9327497612552462, 1.8145282053559222, 0.56740904011144078], [1.4416030660600863, 4.1189600680246015, 2.1110973910715658, 3.5384856009199517], [0.95118141400261069, 2.4572939344524936, 0.54929526659505457, 2.9652939525377708]], [[2.0885234488307876, 0.25836797235157094, 2.6699858158100973, 3.3139553157584252], [2.6559413882762239, 1.2879435669486743, 3.3675769889236591, 4.237965236929135], [0.79625310217359302, 3.3583510561037029, 1.2582374986295783, 2.1398901148681815]]], [[[4.7482284899129752, 2.2293361019743232, 1.1930794286761943, 1.0124469031550984], [0.38197241933053727, 4.1981998835993846, 0.79098246624754098, 4.4325191244897875], [4.135761934042792, 2.5772295341335645, 2.2968196972889792, 0.4273068074746656]], [[1.1976128220324929, 1.7459294668094707, 0.96078177214101046, 4.0854494840822007], [3.2731005299433793, 0.82489742017210455, 4.9787451612568212, 1.3471667907126523], [4.343723010658568, 0.57644019147251058, 0.71342917305041831, 2.0211306038878543]]]])  
       res=arg0**arg1  
       msk_ref=whereNegative(self.functionspace.getX()[0]-0.5)  
       ref=msk_ref*numarray.array([[[[44.541526569463137, 40.091495998956134, 4.8828067986685939, 24.032224484143175], [193.76135996199952, 1.4003654269209849, 8.1375846434933727, 22.935670648779361], [9.5579208088126997, 92.050334604168881, 4.9838450947922492, 1.2828648641369595]], [[13.748910875268686, 40.071759842941873, 36.082063760330911, 15.435490923052084], [26.168365475343812, 114.15801285560873, 42.338669214857362, 149.14562304631761], [4.3367450539559762, 8.8724583914528239, 111.60939851359214, 60.971817813198015]]], [[[1.7944637697607297, 15.927333847311955, 4.2473229866626534, 14.608551648073879], [52.616997841336541, 2.8329316847606481, 7.3857759810555583, 4.6779782048798051], [4.9646215069645256, 3.3520671162853026, 111.78809510460806, 5.644134732164181]], [[94.005281960103943, 11.230979059402637, 99.149346198163528, 17.794399015213255], [1.3692312903098052, 6.5043609053916684, 17.063949250753016, 23.736660466381913], [211.21260699785594, 90.523102907549571, 42.52663468713218, 66.190881211600896]]], [[[52.198465234023658, 125.28297981521477, 19.77822080158063, 1.597495779133167], [3.5616552748767889, 238.76083054241485, 1.7669814438499811, 12.822578271065522], [8.2857540079134431, 292.35093722860603, 8.8320781648818247, 301.39441025042674]], [[12.357868168826375, 16.978424976621678, 6.844486437856224, 4.5168689568684455], [1.4190531977552476, 17.01747238246455, 8.3864639284588733, 381.28365954211506], [244.47884719156841, 7.0927460162084532, 6.0464928235844093, 93.154587613024191]]]])+(1.-msk_ref)*numarray.array([[[[324.78475431172814, 4.0259540631320077, 13.130578736246635, 53.54383496616213], [90.478796459093957, 4.0114347064939215, 2.0984709533536985, 57.460940797659013], [33.662874823011009, 1.8779581626455863, 212.93737318668644, 36.215855509993467]], [[2.3121739758861097, 192.23862246855467, 42.090421189774155, 4.5649571677125911], [1.2052294205209508, 1.8991433322517872, 3.5620565513756124, 21.524252643769405], [1.2654838573469389, 1.4678266430201032, 282.71645200527132, 1.1510479483688476]]], [[[87.597643951351131, 33.430958374780801, 8.7702010825145305, 1.9718879873813866], [5.6130706904588212, 138.23621312261142, 12.50651858980023, 69.015953092721603], [3.1212502046915214, 18.925816809951922, 1.9296054663911439, 34.758580290537438]], [[12.173200204345505, 1.3623030451242739, 24.411277858111475, 52.754704457848213], [24.004442882739546, 4.6702887676119742, 56.25075494797089, 159.3928238308925], [2.5930590384710972, 55.633148887433734, 4.5071862303782986, 12.944938739392638]]], [[[293.5299119704776, 14.407381017935226, 4.1691054609354943, 3.3586769436892241], [1.5794682740857684, 151.98569970294611, 2.5767557720475129, 201.17700525164358], [141.04371902898262, 21.846663187868508, 15.619108363619203, 1.6675204530848913]], [[4.1917838851875393, 8.0790224539183537, 3.157314804255805, 132.80254310369224], [50.237611053976565, 2.6834829790067647, 386.76911099066751, 5.0132806634938518], [180.89686297334865, 1.9933140453396749, 2.3483825436453394, 11.230025210903007]]]])  
       self.failUnless(isinstance(res,Data),"wrong type of result.")  
       self.failUnlessEqual(res.getShape(),(3, 2, 3, 4),"wrong shape of result.")  
       self.failUnless(Lsup(res-ref)<=self.RES_TOL*Lsup(ref),"wrong result")  
    #+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++  
    def test_add_overloaded_constData_rank0_Symbol_rank0(self):  
       arg0=Data(0.499161085524,self.functionspace)  
       arg1=Symbol(shape=())  
       res=arg0+arg1  
       s1=numarray.array(0.377874196418)  
       sub=res.substitute({arg1:s1})  
       ref=Data(0.877035281942,self.functionspace)  
       self.failUnless(isinstance(res,Symbol),"wrong type of result.")  
       self.failUnlessEqual(res.getShape(),(),"wrong shape of result.")  
       self.failUnless(Lsup(sub-ref)<=self.RES_TOL*Lsup(ref),"wrong result")  
    #+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++  
107     def test_add_overloaded_constData_rank0_Symbol_rank1(self):     def test_add_overloaded_constData_rank0_Symbol_rank1(self):
108        arg0=Data(-4.93686078973,self.functionspace)        arg0=Data(-4.93686078973,self.functionspace)
109        arg1=Symbol(shape=(2,))        arg1=Symbol(shape=(2,))
# Line 690  class Test_util_overloaded_binary_still_ Line 412  class Test_util_overloaded_binary_still_
412        res=arg0+arg1        res=arg0+arg1
413        s1=numarray.array(-2.65110429185)        s1=numarray.array(-2.65110429185)
414        sub=res.substitute({arg1:s1})        sub=res.substitute({arg1:s1})
415        msk_ref=whereNegative(self.functionspace.getX()[0]-0.5)        msk_ref=1.-whereZero(self.functionspace.getX()[0],1.e-8)
416        ref=msk_ref*(-3.13235414188)+(1.-msk_ref)*(-4.13575846049)        ref=msk_ref*(-3.13235414188)+(1.-msk_ref)*(-4.13575846049)
417        self.failUnless(isinstance(res,Symbol),"wrong type of result.")        self.failUnless(isinstance(res,Symbol),"wrong type of result.")
418        self.failUnlessEqual(res.getShape(),(),"wrong shape of result.")        self.failUnlessEqual(res.getShape(),(),"wrong shape of result.")
# Line 703  class Test_util_overloaded_binary_still_ Line 425  class Test_util_overloaded_binary_still_
425        res=arg0+arg1        res=arg0+arg1
426        s1=numarray.array([-0.62992419613163175, 4.55886114005793])        s1=numarray.array([-0.62992419613163175, 4.55886114005793])
427        sub=res.substitute({arg1:s1})        sub=res.substitute({arg1:s1})
428        msk_ref=whereNegative(self.functionspace.getX()[0]-0.5)        msk_ref=1.-whereZero(self.functionspace.getX()[0],1.e-8)
429        ref=msk_ref*numarray.array([0.50419020369403444, 5.6929755398835962])+(1.-msk_ref)*numarray.array([-1.259561745462479, 3.9292235907270827])        ref=msk_ref*numarray.array([0.50419020369403444, 5.6929755398835962])+(1.-msk_ref)*numarray.array([-1.259561745462479, 3.9292235907270827])
430        self.failUnless(isinstance(res,Symbol),"wrong type of result.")        self.failUnless(isinstance(res,Symbol),"wrong type of result.")
431        self.failUnlessEqual(res.getShape(),(2,),"wrong shape of result.")        self.failUnlessEqual(res.getShape(),(2,),"wrong shape of result.")
# Line 716  class Test_util_overloaded_binary_still_ Line 438  class Test_util_overloaded_binary_still_
438        res=arg0+arg1        res=arg0+arg1
439        s1=numarray.array([[-2.793178683106079, -2.6222774715493582, 1.0142792223620747, -3.0640922264732984, -2.3554298671206055], [0.088775964219395043, 3.4441381957619619, 3.3892189758872853, 2.7423767697866088, 3.977644321141641], [1.4526982641352157, 2.2184052986969505, -3.952710218879385, -4.7169576073736375, -0.7937042808225101], [2.2686916098744314, -1.553248315886353, -2.7367045745859819, 3.7958840729585344, 1.4548199443717298]])        s1=numarray.array([[-2.793178683106079, -2.6222774715493582, 1.0142792223620747, -3.0640922264732984, -2.3554298671206055], [0.088775964219395043, 3.4441381957619619, 3.3892189758872853, 2.7423767697866088, 3.977644321141641], [1.4526982641352157, 2.2184052986969505, -3.952710218879385, -4.7169576073736375, -0.7937042808225101], [2.2686916098744314, -1.553248315886353, -2.7367045745859819, 3.7958840729585344, 1.4548199443717298]])
440        sub=res.substitute({arg1:s1})        sub=res.substitute({arg1:s1})
441        msk_ref=whereNegative(self.functionspace.getX()[0]-0.5)        msk_ref=1.-whereZero(self.functionspace.getX()[0],1.e-8)
442        ref=msk_ref*numarray.array([[0.22491426047411567, 0.39581547203083645, 4.0323721659422693, -0.045999282893103732, 0.66266307645958911], [3.1068689077995897, 6.4622311393421565, 6.4073119194674799, 5.7604697133668035, 6.9957372647218357], [4.4707912077154104, 5.2364982422771451, -0.93461727529919036, -1.6988646637934428, 2.2243886627576845], [5.2867845534546261, 1.4648446276938416, 0.28138836899421271, 6.813977016538729, 4.4729128879519244]])+(1.-msk_ref)*numarray.array([[-1.9034350252987218, -1.732533813742001, 1.9040228801694319, -2.1743485686659412, -1.4656862093132483], [0.97851962202675224, 4.3338818535693191, 4.2789626336946425, 3.632120427593966, 4.8673879789489982], [2.3424419219425729, 3.1081489565043077, -3.0629665610720278, -3.8272139495662802, 0.096039376984847102], [3.1584352676817886, -0.66350465807899583, -1.8469609167786247, 4.6856277307658916, 2.344563602179087]])        ref=msk_ref*numarray.array([[0.22491426047411567, 0.39581547203083645, 4.0323721659422693, -0.045999282893103732, 0.66266307645958911], [3.1068689077995897, 6.4622311393421565, 6.4073119194674799, 5.7604697133668035, 6.9957372647218357], [4.4707912077154104, 5.2364982422771451, -0.93461727529919036, -1.6988646637934428, 2.2243886627576845], [5.2867845534546261, 1.4648446276938416, 0.28138836899421271, 6.813977016538729, 4.4729128879519244]])+(1.-msk_ref)*numarray.array([[-1.9034350252987218, -1.732533813742001, 1.9040228801694319, -2.1743485686659412, -1.4656862093132483], [0.97851962202675224, 4.3338818535693191, 4.2789626336946425, 3.632120427593966, 4.8673879789489982], [2.3424419219425729, 3.1081489565043077, -3.0629665610720278, -3.8272139495662802, 0.096039376984847102], [3.1584352676817886, -0.66350465807899583, -1.8469609167786247, 4.6856277307658916, 2.344563602179087]])
443        self.failUnless(isinstance(res,Symbol),"wrong type of result.")        self.failUnless(isinstance(res,Symbol),"wrong type of result.")
444        self.failUnlessEqual(res.getShape(),(4, 5),"wrong shape of result.")        self.failUnlessEqual(res.getShape(),(4, 5),"wrong shape of result.")
# Line 729  class Test_util_overloaded_binary_still_ Line 451  class Test_util_overloaded_binary_still_
451        res=arg0+arg1        res=arg0+arg1
452        s1=numarray.array([[[1.9993822405268356, -3.1230808428690615], [4.9036400439562815, -4.8838867997176525]], [[0.42763250705520939, 1.7579324334230453], [-3.7242679708963458, 1.8833596506298056]], [[-3.5481907533254931, 0.2040318933875751], [-2.5124574767604746, -4.1576503017979416]], [[2.4187154671810562, -0.51775884222858526], [-1.722028671225063, 4.8177194310600537]], [[3.5460779618762999, 3.7426721831596925], [-3.14876579453641, -1.8491069265603413]], [[-2.0602497125201733, 1.8445672729830882], [2.6289048953955998, -2.1171625740448654]]])        s1=numarray.array([[[1.9993822405268356, -3.1230808428690615], [4.9036400439562815, -4.8838867997176525]], [[0.42763250705520939, 1.7579324334230453], [-3.7242679708963458, 1.8833596506298056]], [[-3.5481907533254931, 0.2040318933875751], [-2.5124574767604746, -4.1576503017979416]], [[2.4187154671810562, -0.51775884222858526], [-1.722028671225063, 4.8177194310600537]], [[3.5460779618762999, 3.7426721831596925], [-3.14876579453641, -1.8491069265603413]], [[-2.0602497125201733, 1.8445672729830882], [2.6289048953955998, -2.1171625740448654]]])
453        sub=res.substitute({arg1:s1})        sub=res.substitute({arg1:s1})
454        msk_ref=whereNegative(self.functionspace.getX()[0]-0.5)        msk_ref=1.-whereZero(self.functionspace.getX()[0],1.e-8)
455        ref=msk_ref*numarray.array([[[-2.9850633807947604, -8.1075264641906575], [-0.080805577365314463, -9.8683324210392485]], [[-4.5568131142663866, -3.2265131878985507], [-8.7087135922179417, -3.1010859706917904]], [[-8.5326363746470886, -4.7804137279340209], [-7.4969030980820701, -9.1420959231195376]], [[-2.5657301541405397, -5.5022044635501812], [-6.7064742925466589, -0.16672619026154223]], [[-1.4383676594452961, -1.2417734381619034], [-8.1332114158580069, -6.8335525478819372]], [[-7.0446953338417693, -3.1398783483385078], [-2.3555407259259962, -7.1016081953664614]]])+(1.-msk_ref)*numarray.array([[[6.3069499004015404, 1.1844868170056433], [9.2112077038309863, -0.57631913984294769]], [[4.7352001669299142, 6.0655000932977501], [0.58329968897835904, 6.1909273105045104]], [[0.75937690654921175, 4.5115995532622799], [1.7951101831142302, 0.14991735807676321]], [[6.726283127055761, 3.7898088176461195], [2.5855389886496418, 9.1252870909347585]], [[7.8536456217510047, 8.0502398430343973], [1.1588018653382948, 2.4584607333143635]], [[2.2473179473545315, 6.152134932857793], [6.9364725552703046, 2.1904050858298394]]])        ref=msk_ref*numarray.array([[[-2.9850633807947604, -8.1075264641906575], [-0.080805577365314463, -9.8683324210392485]], [[-4.5568131142663866, -3.2265131878985507], [-8.7087135922179417, -3.1010859706917904]], [[-8.5326363746470886, -4.7804137279340209], [-7.4969030980820701, -9.1420959231195376]], [[-2.5657301541405397, -5.5022044635501812], [-6.7064742925466589, -0.16672619026154223]], [[-1.4383676594452961, -1.2417734381619034], [-8.1332114158580069, -6.8335525478819372]], [[-7.0446953338417693, -3.1398783483385078], [-2.3555407259259962, -7.1016081953664614]]])+(1.-msk_ref)*numarray.array([[[6.3069499004015404, 1.1844868170056433], [9.2112077038309863, -0.57631913984294769]], [[4.7352001669299142, 6.0655000932977501], [0.58329968897835904, 6.1909273105045104]], [[0.75937690654921175, 4.5115995532622799], [1.7951101831142302, 0.14991735807676321]], [[6.726283127055761, 3.7898088176461195], [2.5855389886496418, 9.1252870909347585]], [[7.8536456217510047, 8.0502398430343973], [1.1588018653382948, 2.4584607333143635]], [[2.2473179473545315, 6.152134932857793], [6.9364725552703046, 2.1904050858298394]]])
456        self.failUnless(isinstance(res,Symbol),"wrong type of result.")        self.failUnless(isinstance(res,Symbol),"wrong type of result.")
457        self.failUnlessEqual(res.getShape(),(6, 2, 2),"wrong shape of result.")        self.failUnlessEqual(res.getShape(),(6, 2, 2),"wrong shape of result.")
# Line 742  class Test_util_overloaded_binary_still_ Line 464  class Test_util_overloaded_binary_still_
464        res=arg0+arg1        res=arg0+arg1
465        s1=numarray.array([[[[3.9689996783063126, 2.6024749301521517, -2.8657897182202263, 3.4523361907793202], [1.0646468808240472, 2.2809214673673006, 1.9110441510817342, 3.6637536830808415], [-4.8161620946685977, 1.1260192950202335, -1.5444099528131283, 4.5856953227320361]], [[3.4807853259935388, 1.0632821522370133, -1.7813251042294, 0.96803702807832348], [-2.2395880868316476, 4.8919502166960243, 3.0915081953974273, -0.85921425228962178], [-0.24500754865585961, -3.000069805276242, -2.3285433357124861, -3.7526812827715004]]], [[[-2.6148866735769314, -2.9426881222754986, -2.1105189060422127, -1.718323686970705], [0.38236683235255065, 4.8146833101999391, -0.69724678041282662, -3.674837501299455], [-1.1217878757973345, 1.9457797122429064, 4.3330454272287042, 1.2870165165330079]], [[0.90390350707926448, 4.0932246664578322, 4.0170833493811937, 2.3057200276883218], [-4.1149618340720506, 4.3206785552080422, 4.5478406361616468, 3.4270491303459689], [-3.2122582790653578, -0.051138136931458078, 2.847106348954056, -2.0922906343243097]]], [[[-3.8470709835005801, 0.79389346854249432, 1.9702586564654192, -1.230993932131331], [0.52027641197917784, 4.1606002966489264, -4.1240899145057277, 3.0855602864655047], [1.2434749670286918, 1.9421106344042691, -4.7997149299258455, -3.1016051858236517]], [[-4.0158867307020536, -1.2810983979769732, 4.1806447574751786, 2.4159993753375488], [3.8210591526688589, 2.9170696329659753, 0.212629682453775, -3.6791629346607402], [-0.52709663403725493, -2.0893727810689953, -1.7473644406170976, -4.1869442335699976]]]])        s1=numarray.array([[[[3.9689996783063126, 2.6024749301521517, -2.8657897182202263, 3.4523361907793202], [1.0646468808240472, 2.2809214673673006, 1.9110441510817342, 3.6637536830808415], [-4.8161620946685977, 1.1260192950202335, -1.5444099528131283, 4.5856953227320361]], [[3.4807853259935388, 1.0632821522370133, -1.7813251042294, 0.96803702807832348], [-2.2395880868316476, 4.8919502166960243, 3.0915081953974273, -0.85921425228962178], [-0.24500754865585961, -3.000069805276242, -2.3285433357124861, -3.7526812827715004]]], [[[-2.6148866735769314, -2.9426881222754986, -2.1105189060422127, -1.718323686970705], [0.38236683235255065, 4.8146833101999391, -0.69724678041282662, -3.674837501299455], [-1.1217878757973345, 1.9457797122429064, 4.3330454272287042, 1.2870165165330079]], [[0.90390350707926448, 4.0932246664578322, 4.0170833493811937, 2.3057200276883218], [-4.1149618340720506, 4.3206785552080422, 4.5478406361616468, 3.4270491303459689], [-3.2122582790653578, -0.051138136931458078, 2.847106348954056, -2.0922906343243097]]], [[[-3.8470709835005801, 0.79389346854249432, 1.9702586564654192, -1.230993932131331], [0.52027641197917784, 4.1606002966489264, -4.1240899145057277, 3.0855602864655047], [1.2434749670286918, 1.9421106344042691, -4.7997149299258455, -3.1016051858236517]], [[-4.0158867307020536, -1.2810983979769732, 4.1806447574751786, 2.4159993753375488], [3.8210591526688589, 2.9170696329659753, 0.212629682453775, -3.6791629346607402], [-0.52709663403725493, -2.0893727810689953, -1.7473644406170976, -4.1869442335699976]]]])
466        sub=res.substitute({arg1:s1})        sub=res.substitute({arg1:s1})
467        msk_ref=whereNegative(self.functionspace.getX()[0]-0.5)        msk_ref=1.-whereZero(self.functionspace.getX()[0],1.e-8)
468        ref=msk_ref*numarray.array([[[[0.99920714490574225, -0.36731760324841867, -5.8355822516207967, 0.48254365737874982], [-1.9051456525765231, -0.68887106603326975, -1.0587483823188362, 0.69396114968027112], [-7.7859546280691685, -1.8437732383803369, -4.5142024862136987, 1.6159027893314657]], [[0.51099279259296848, -1.9065103811635571, -4.7511176376299709, -2.0017555053222469], [-5.2093806202322179, 1.9221576832954539, 0.12171566199685691, -3.8290067856901921], [-3.21480008205643, -5.9698623386768119, -5.2983358691130569, -6.7224738161720712]]], [[[-5.5846792069775013, -5.9124806556760685, -5.0803114394427826, -4.6881162203712758], [-2.5874257010480197, 1.8448907767993687, -3.667039313813397, -6.6446300347000253], [-4.0915804091979044, -1.024012821157664, 1.3632528938281339, -1.6827760168675625]], [[-2.0658890263213059, 1.1234321330572619, 1.0472908159806233, -0.66407250571224852], [-7.0847543674726214, 1.3508860218074719, 1.5780481027610764, 0.45725659694539855], [-6.1820508124659277, -3.0209306703320284, -0.12268618444651436, -5.0620831677248805]]], [[[-6.8168635169011509, -2.175899064858076, -0.99953387693515117, -4.2007864655319018], [-2.4495161214213925, 1.190807763248356, -7.0938824479062976, 0.11576775306493436], [-1.7263175663718786, -1.0276818989963012, -7.7695074633264163, -6.0713977192242226]], [[-6.9856792641026235, -4.250890931377544, 1.2108522240746082, -0.55379315806302154], [0.8512666192682885, -0.052722900434595044, -2.7571628509467954, -6.6489554680613105], [-3.4968891674378253, -5.0591653144695652, -4.7171569740176675, -7.1567367669705675]]]])+(1.-msk_ref)*numarray.array([[[[-0.29235367894345909, -1.65887842709762, -7.1271430754699985, -0.80901716647045152], [-3.1967064764257245, -1.9804318898824711, -2.3503092061680375, -0.59759967416893023], [-9.0775154519183694, -3.1353340622295383, -5.8057633100629005, 0.32434196548226435]], [[-0.78056803125623286, -3.1980712050127584, -6.0426784614791718, -3.2933163291714482], [-6.5009414440814197, 0.63059685944625254, -1.1698451618523444, -5.1205676095393935], [-4.5063609059056313, -7.2614231625260137, -6.5898966929622578, -8.0140346400212721]]], [[[-6.8762400308267031, -7.2040414795252703, -6.3718722632919844, -5.9796770442204767], [-3.8789865248972211, 0.5533299529501674, -4.9586001376625983, -7.9361908585492262], [-5.3831412330471062, -2.3155736450068654, 0.071692069978932516, -2.9743368407167639]], [[-3.3574498501705072, -0.16812869079193948, -0.244270007868578, -1.9556333295614499], [-8.3763151913218223, 0.059325197958270515, 0.28648727891187509, -0.83430422690380279], [-7.4736116363151295, -4.3124914941812298, -1.4142470082957157, -6.3536439915740814]]], [[[-8.1084243407503518, -3.4674598887072774, -2.2910947007843525, -5.4923472893811027], [-3.7410769452705939, -0.10075306060084532, -8.3854432717554985, -1.175793070784267], [-3.01787839022108, -2.3192427228455026, -9.0610682871756172, -7.3629585430734235]], [[-8.2772400879518244, -5.5424517552267449, -0.080708599774593104, -1.8453539819122229], [-0.44029420458091284, -1.3442837242837964, -4.0487236747959967, -7.9405162919105123], [-4.7884499912870266, -6.350726138318767, -6.0087177978668693, -8.4482975908197702]]]])        ref=msk_ref*numarray.array([[[[0.99920714490574225, -0.36731760324841867, -5.8355822516207967, 0.48254365737874982], [-1.9051456525765231, -0.68887106603326975, -1.0587483823188362, 0.69396114968027112], [-7.7859546280691685, -1.8437732383803369, -4.5142024862136987, 1.6159027893314657]], [[0.51099279259296848, -1.9065103811635571, -4.7511176376299709, -2.0017555053222469], [-5.2093806202322179, 1.9221576832954539, 0.12171566199685691, -3.8290067856901921], [-3.21480008205643, -5.9698623386768119, -5.2983358691130569, -6.7224738161720712]]], [[[-5.5846792069775013, -5.9124806556760685, -5.0803114394427826, -4.6881162203712758], [-2.5874257010480197, 1.8448907767993687, -3.667039313813397, -6.6446300347000253], [-4.0915804091979044, -1.024012821157664, 1.3632528938281339, -1.6827760168675625]], [[-2.0658890263213059, 1.1234321330572619, 1.0472908159806233, -0.66407250571224852], [-7.0847543674726214, 1.3508860218074719, 1.5780481027610764, 0.45725659694539855], [-6.1820508124659277, -3.0209306703320284, -0.12268618444651436, -5.0620831677248805]]], [[[-6.8168635169011509, -2.175899064858076, -0.99953387693515117, -4.2007864655319018], [-2.4495161214213925, 1.190807763248356, -7.0938824479062976, 0.11576775306493436], [-1.7263175663718786, -1.0276818989963012, -7.7695074633264163, -6.0713977192242226]], [[-6.9856792641026235, -4.250890931377544, 1.2108522240746082, -0.55379315806302154], [0.8512666192682885, -0.052722900434595044, -2.7571628509467954, -6.6489554680613105], [-3.4968891674378253, -5.0591653144695652, -4.7171569740176675, -7.1567367669705675]]]])+(1.-msk_ref)*numarray.array([[[[-0.29235367894345909, -1.65887842709762, -7.1271430754699985, -0.80901716647045152], [-3.1967064764257245, -1.9804318898824711, -2.3503092061680375, -0.59759967416893023], [-9.0775154519183694, -3.1353340622295383, -5.8057633100629005, 0.32434196548226435]], [[-0.78056803125623286, -3.1980712050127584, -6.0426784614791718, -3.2933163291714482], [-6.5009414440814197, 0.63059685944625254, -1.1698451618523444, -5.1205676095393935], [-4.5063609059056313, -7.2614231625260137, -6.5898966929622578, -8.0140346400212721]]], [[[-6.8762400308267031, -7.2040414795252703, -6.3718722632919844, -5.9796770442204767], [-3.8789865248972211, 0.5533299529501674, -4.9586001376625983, -7.9361908585492262], [-5.3831412330471062, -2.3155736450068654, 0.071692069978932516, -2.9743368407167639]], [[-3.3574498501705072, -0.16812869079193948, -0.244270007868578, -1.9556333295614499], [-8.3763151913218223, 0.059325197958270515, 0.28648727891187509, -0.83430422690380279], [-7.4736116363151295, -4.3124914941812298, -1.4142470082957157, -6.3536439915740814]]], [[[-8.1084243407503518, -3.4674598887072774, -2.2910947007843525, -5.4923472893811027], [-3.7410769452705939, -0.10075306060084532, -8.3854432717554985, -1.175793070784267], [-3.01787839022108, -2.3192427228455026, -9.0610682871756172, -7.3629585430734235]], [[-8.2772400879518244, -5.5424517552267449, -0.080708599774593104, -1.8453539819122229], [-0.44029420458091284, -1.3442837242837964, -4.0487236747959967, -7.9405162919105123], [-4.7884499912870266, -6.350726138318767, -6.0087177978668693, -8.4482975908197702]]]])
469        self.failUnless(isinstance(res,Symbol),"wrong type of result.")        self.failUnless(isinstance(res,Symbol),"wrong type of result.")
470        self.failUnlessEqual(res.getShape(),(3, 2, 3, 4),"wrong shape of result.")        self.failUnlessEqual(res.getShape(),(3, 2, 3, 4),"wrong shape of result.")
# Line 755  class Test_util_overloaded_binary_still_ Line 477  class Test_util_overloaded_binary_still_
477        res=arg0+arg1        res=arg0+arg1
478        s1=numarray.array(2.92811762582)        s1=numarray.array(2.92811762582)
479        sub=res.substitute({arg1:s1})        sub=res.substitute({arg1:s1})
480        msk_ref=whereNegative(self.functionspace.getX()[0]-0.5)        msk_ref=1.-whereZero(self.functionspace.getX()[0],1.e-8)
481        ref=msk_ref*numarray.array([5.1226896213358133, -0.5570634291388572])+(1.-msk_ref)*numarray.array([-0.23134311474438096, 3.9788272724958178])        ref=msk_ref*numarray.array([5.1226896213358133, -0.5570634291388572])+(1.-msk_ref)*numarray.array([-0.23134311474438096, 3.9788272724958178])
482        self.failUnless(isinstance(res,Symbol),"wrong type of result.")        self.failUnless(isinstance(res,Symbol),"wrong type of result.")
483        self.failUnlessEqual(res.getShape(),(2,),"wrong shape of result.")        self.failUnlessEqual(res.getShape(),(2,),"wrong shape of result.")
# Line 768  class Test_util_overloaded_binary_still_ Line 490  class Test_util_overloaded_binary_still_
490        res=arg0+arg1        res=arg0+arg1
491        s1=numarray.array([0.68148355985483988, 0.33396702170122339])        s1=numarray.array([0.68148355985483988, 0.33396702170122339])
492        sub=res.substitute({arg1:s1})        sub=res.substitute({arg1:s1})
493        msk_ref=whereNegative(self.functionspace.getX()[0]-0.5)        msk_ref=1.-whereZero(self.functionspace.getX()[0],1.e-8)
494        ref=msk_ref*numarray.array([2.6202027989189594, -1.9608214734970586])+(1.-msk_ref)*numarray.array([-3.3135461365498418, -4.6244908785891283])        ref=msk_ref*numarray.array([2.6202027989189594, -1.9608214734970586])+(1.-msk_ref)*numarray.array([-3.3135461365498418, -4.6244908785891283])
495        self.failUnless(isinstance(res,Symbol),"wrong type of result.")        self.failUnless(isinstance(res,Symbol),"wrong type of result.")
496        self.failUnlessEqual(res.getShape(),(2,),"wrong shape of result.")        self.failUnlessEqual(res.getShape(),(2,),"wrong shape of result.")
# Line 781  class Test_util_overloaded_binary_still_ Line 503  class Test_util_overloaded_binary_still_
503        res=arg0+arg1        res=arg0+arg1
504        s1=numarray.array(3.22997214356)        s1=numarray.array(3.22997214356)
505        sub=res.substitute({arg1:s1})        sub=res.substitute({arg1:s1})
506        msk_ref=whereNegative(self.functionspace.getX()[0]-0.5)        msk_ref=1.-whereZero(self.functionspace.getX()[0],1.e-8)
507        ref=msk_ref*numarray.array([[5.1635247225953336, 8.117660546839355, -0.44943269985894219, 0.29620485502327121, 3.8179954023107499], [4.5031163302506245, 8.0321436676533509, 6.2171006495911953, 7.5973748227340447, 5.5623822513887671], [6.4873399114363206, 6.8444532812559906, -0.81653758085589168, -0.14128220888986398, 4.0642178705461589], [-1.5434290409833791, 2.038140492063099, 0.58839537224572069, -0.51420023879439203, 5.8092119603804129]])+(1.-msk_ref)*numarray.array([[3.7403536194302305, -0.31804651356245639, 6.979383990099592, 6.9028891483626662, 0.27767472767517809], [6.4409087201596815, 1.4952401042218435, 2.2303291487266304, 2.4749632963695696, 4.8228512403378794], [-0.88751228141377325, 7.4329853104169761, -1.6184787565666703, 5.9332065734331447, 7.5309656537231859], [1.7772701565236098, 7.1646782813566308, 4.4441244527932326, -0.43686616468143136, -0.61008695375603317]])        ref=msk_ref*numarray.array([[5.1635247225953336, 8.117660546839355, -0.44943269985894219, 0.29620485502327121, 3.8179954023107499], [4.5031163302506245, 8.0321436676533509, 6.2171006495911953, 7.5973748227340447, 5.5623822513887671], [6.4873399114363206, 6.8444532812559906, -0.81653758085589168, -0.14128220888986398, 4.0642178705461589], [-1.5434290409833791, 2.038140492063099, 0.58839537224572069, -0.51420023879439203, 5.8092119603804129]])+(1.-msk_ref)*numarray.array([[3.7403536194302305, -0.31804651356245639, 6.979383990099592, 6.9028891483626662, 0.27767472767517809], [6.4409087201596815, 1.4952401042218435, 2.2303291487266304, 2.4749632963695696, 4.8228512403378794], [-0.88751228141377325, 7.4329853104169761, -1.6184787565666703, 5.9332065734331447, 7.5309656537231859], [1.7772701565236098, 7.1646782813566308, 4.4441244527932326, -0.43686616468143136, -0.61008695375603317]])
508        self.failUnless(isinstance(res,Symbol),"wrong type of result.")        self.failUnless(isinstance(res,Symbol),"wrong type of result.")
509        self.failUnlessEqual(res.getShape(),(4, 5),"wrong shape of result.")        self.failUnlessEqual(res.getShape(),(4, 5),"wrong shape of result.")
# Line 794  class Test_util_overloaded_binary_still_ Line 516  class Test_util_overloaded_binary_still_
516        res=arg0+arg1        res=arg0+arg1
517        s1=numarray.array([[-1.4953863183942318, -3.5127993001524969, 2.9138150805794103, -1.6144165168200519, -0.65062618022498242], [-4.9181569250500168, -2.6971927119277908, 4.2365880197149934, -4.2036145824282496, 2.2260090531531453], [4.0868409931398002, -3.3893548967194032, 2.9012650531553019, -2.2355683566643378, 2.9627609193479501], [4.9921359000605019, 0.6569024014440803, 3.3639734573108839, 0.89356331435440595, -4.0709626638242327]])        s1=numarray.array([[-1.4953863183942318, -3.5127993001524969, 2.9138150805794103, -1.6144165168200519, -0.65062618022498242], [-4.9181569250500168, -2.6971927119277908, 4.2365880197149934, -4.2036145824282496, 2.2260090531531453], [4.0868409931398002, -3.3893548967194032, 2.9012650531553019, -2.2355683566643378, 2.9627609193479501], [4.9921359000605019, 0.6569024014440803, 3.3639734573108839, 0.89356331435440595, -4.0709626638242327]])
518        sub=res.substitute({arg1:s1})        sub=res.substitute({arg1:s1})
519        msk_ref=whereNegative(self.functionspace.getX()[0]-0.5)        msk_ref=1.-whereZero(self.functionspace.getX()[0],1.e-8)
520        ref=msk_ref*numarray.array([[-1.5701293083088785, -5.3610486882102553, 4.0064413254105702, 2.9014318034443196, -3.7311931135255385], [-4.9095962284341068, -5.6668789206252903, 7.5390341051317531, -2.6947980364163069, -1.4191974960325813], [4.2737813472604653, -8.0632471147279183, 6.8563696406624457, 1.7728490548995346, 2.3294391465881326], [7.5015217801447127, 0.29518329125185083, 3.5553574110671482, -2.2859988717983675, -6.6977575782777334]])+(1.-msk_ref)*numarray.array([[-5.0896050870573841, -7.2188814432658379, 3.8671347594651726, -6.4984209168829263, -0.25674716770353712], [-0.85285897572911828, 1.8353914302218737, 3.8083975147833273, -5.9461231628794335, 4.9380831425555352], [4.6557276095476459, -5.8462847989150095, 6.4698331732243259, -4.3149036312303144, 1.1937980533549375], [0.12884045798990051, -2.2259643266212561, 6.7729978466911085, 3.9587365744804757, 0.57541381173979289]])        ref=msk_ref*numarray.array([[-1.5701293083088785, -5.3610486882102553, 4.0064413254105702, 2.9014318034443196, -3.7311931135255385], [-4.9095962284341068, -5.6668789206252903, 7.5390341051317531, -2.6947980364163069, -1.4191974960325813], [4.2737813472604653, -8.0632471147279183, 6.8563696406624457, 1.7728490548995346, 2.3294391465881326], [7.5015217801447127, 0.29518329125185083, 3.5553574110671482, -2.2859988717983675, -6.6977575782777334]])+(1.-msk_ref)*numarray.array([[-5.0896050870573841, -7.2188814432658379, 3.8671347594651726, -6.4984209168829263, -0.25674716770353712], [-0.85285897572911828, 1.8353914302218737, 3.8083975147833273, -5.9461231628794335, 4.9380831425555352], [4.6557276095476459, -5.8462847989150095, 6.4698331732243259, -4.3149036312303144, 1.1937980533549375], [0.12884045798990051, -2.2259643266212561, 6.7729978466911085, 3.9587365744804757, 0.57541381173979289]])
521        self.failUnless(isinstance(res,Symbol),"wrong type of result.")        self.failUnless(isinstance(res,Symbol),"wrong type of result.")
522        self.failUnlessEqual(res.getShape(),(4, 5),"wrong shape of result.")        self.failUnlessEqual(res.getShape(),(4, 5),"wrong shape of result.")
# Line 807  class Test_util_overloaded_binary_still_ Line 529  class Test_util_overloaded_binary_still_
529        res=arg0+arg1        res=arg0+arg1
530        s1=numarray.array(2.24723235412)        s1=numarray.array(2.24723235412)
531        sub=res.substitute({arg1:s1})        sub=res.substitute({arg1:s1})
532        msk_ref=whereNegative(self.functionspace.getX()[0]-0.5)        msk_ref=1.-whereZero(self.functionspace.getX()[0],1.e-8)
533        ref=msk_ref*numarray.array([[[0.05147554507665264, 2.8147051298670691], [0.82461519626188773, -0.87020128380973727]], [[4.162249224651223, 2.7149471880082547], [1.5146161086913388, 3.700543270658593]], [[-2.1227703135939935, -2.1649565969349194], [-1.9960146591431203, -2.3893494370667456]], [[6.6185084149912807, 2.7353891422443546], [-2.044726233040274, 5.1225942777562228]], [[6.9883150766937963, -1.0469164749421873], [5.83069369781734, 2.7820108496959088]], [[-0.022491836182242153, 3.7311359734610559], [6.598689776950259, 4.2807158310208244]]])+(1.-msk_ref)*numarray.array([[[4.15382795571686, 6.0483859942655247], [6.4953434972230752, 3.012966152760999]], [[3.9961013751868313, 6.7536918674872357], [0.98569783307687509, 0.73765739724913093]], [[3.4482526805427538, 2.3027266866259595], [6.574205438044423, 1.7031082816825673]], [[-0.37848166647976944, -1.1989921579657521], [3.5924095339980582, 4.7096305575557551]], [[-0.32408006631310116, 4.1828647503599985], [4.1351981630657715, 5.3685123542806572]], [[4.1892758624206561, 3.0526224692574928], [1.8707122928729838, 2.980630372563005]]])        ref=msk_ref*numarray.array([[[0.05147554507665264, 2.8147051298670691], [0.82461519626188773, -0.87020128380973727]], [[4.162249224651223, 2.7149471880082547], [1.5146161086913388, 3.700543270658593]], [[-2.1227703135939935, -2.1649565969349194], [-1.9960146591431203, -2.3893494370667456]], [[6.6185084149912807, 2.7353891422443546], [-2.044726233040274, 5.1225942777562228]], [[6.9883150766937963, -1.0469164749421873], [5.83069369781734, 2.7820108496959088]], [[-0.022491836182242153, 3.7311359734610559], [6.598689776950259, 4.2807158310208244]]])+(1.-msk_ref)*numarray.array([[[4.15382795571686, 6.0483859942655247], [6.4953434972230752, 3.012966152760999]], [[3.9961013751868313, 6.7536918674872357], [0.98569783307687509, 0.73765739724913093]], [[3.4482526805427538, 2.3027266866259595], [6.574205438044423, 1.7031082816825673]], [[-0.37848166647976944, -1.1989921579657521], [3.5924095339980582, 4.7096305575557551]], [[-0.32408006631310116, 4.1828647503599985], [4.1351981630657715, 5.3685123542806572]], [[4.1892758624206561, 3.0526224692574928], [1.8707122928729838, 2.980630372563005]]])
534        self.failUnless(isinstance(res,Symbol),"wrong type of result.")        self.failUnless(isinstance(res,Symbol),"wrong type of result.")
535        self.failUnlessEqual(res.getShape(),(6, 2, 2),"wrong shape of result.")        self.failUnlessEqual(res.getShape(),(6, 2, 2),"wrong shape of result.")
# Line 820  class Test_util_overloaded_binary_still_ Line 542  class Test_util_overloaded_binary_still_
542        res=arg0+arg1        res=arg0+arg1
543        s1=numarray.array([[[-3.655791939954395, 1.9082625611635287], [2.0305234873740705, -3.9575879711347337]], [[0.58883813376680294, -0.44253502109642717], [-0.50659655202841058, 4.7262250303753071]], [[2.3551049262619417, -2.7472704728416062], [-4.2131185370897501, 1.1560716927603512]], [[-1.8521430501234626, -2.8126771236453196], [-1.6116964851382032, 4.3144406033510982]], [[-4.4005771771028979, -3.8795508309654512], [0.95903540985898683, -0.84559016177598512]], [[-2.6007509769442674, -0.13151235868250399], [-1.5038936232862978, -3.9733280592961249]]])        s1=numarray.array([[[-3.655791939954395, 1.9082625611635287], [2.0305234873740705, -3.9575879711347337]], [[0.58883813376680294, -0.44253502109642717], [-0.50659655202841058, 4.7262250303753071]], [[2.3551049262619417, -2.7472704728416062], [-4.2131185370897501, 1.1560716927603512]], [[-1.8521430501234626, -2.8126771236453196], [-1.6116964851382032, 4.3144406033510982]], [[-4.4005771771028979, -3.8795508309654512], [0.95903540985898683, -0.84559016177598512]], [[-2.6007509769442674, -0.13151235868250399], [-1.5038936232862978, -3.9733280592961249]]])
544        sub=res.substitute({arg1:s1})        sub=res.substitute({arg1:s1})
545        msk_ref=whereNegative(self.functionspace.getX()[0]-0.5)        msk_ref=1.-whereZero(self.functionspace.getX()[0],1.e-8)
546        ref=msk_ref*numarray.array([[[-7.2887961231440688, 3.8093902207282344], [6.0833072777471031, -0.21226631705251187]], [[1.7311438404991062, -5.0616705712627974], [-0.70139056289777457, 8.3780562862524945]], [[1.5734636519387317, -2.7498293517250794], [-6.7286245247876035, -1.6292947310521066]], [[-4.3078990975897122, -4.5128032654936234], [0.63206024695022167, -0.23840841479535957]], [[-1.0040530779684378, -1.1263869417310231], [-0.059229576068998924, -0.46679835805516134]], [[-4.8641550357030034, -3.8223885120512522], [-4.1691335387764488, -5.9893094897554988]]])+(1.-msk_ref)*numarray.array([[[1.3423988525253838, 6.1859833123847636], [-2.4480211460205981, -7.7716150231049319]], [[2.0405530678616994, 1.4697497499981562], [-1.6050790517361664, 9.6522776591464066]], [[5.3782919449857731, -7.1740740276438082], [-4.3140400874405413, -1.2665894706273826]], [[1.29185167349765, -5.5282867298255924], [-1.891195895205303, 4.4700697288265729]], [[-6.0710651727675691, -4.757772858967197], [-3.137784999036084, -5.7268376492158923]], [[-5.688414772562286, 0.29657368710709076], [-2.2700678609374894, -2.4921861623155905]]])        ref=msk_ref*numarray.array([[[-7.2887961231440688, 3.8093902207282344], [6.0833072777471031, -0.21226631705251187]], [[1.7311438404991062, -5.0616705712627974], [-0.70139056289777457, 8.3780562862524945]], [[1.5734636519387317, -2.7498293517250794], [-6.7286245247876035, -1.6292947310521066]], [[-4.3078990975897122, -4.5128032654936234], [0.63206024695022167, -0.23840841479535957]], [[-1.0040530779684378, -1.1263869417310231], [-0.059229576068998924, -0.46679835805516134]], [[-4.8641550357030034, -3.8223885120512522], [-4.1691335387764488, -5.9893094897554988]]])+(1.-msk_ref)*numarray.array([[[1.3423988525253838, 6.1859833123847636], [-2.4480211460205981, -7.7716150231049319]], [[2.0405530678616994, 1.4697497499981562], [-1.6050790517361664, 9.6522776591464066]], [[5.3782919449857731, -7.1740740276438082], [-4.3140400874405413, -1.2665894706273826]], [[1.29185167349765, -5.5282867298255924], [-1.891195895205303, 4.4700697288265729]], [[-6.0710651727675691, -4.757772858967197], [-3.137784999036084, -5.7268376492158923]], [[-5.688414772562286, 0.29657368710709076], [-2.2700678609374894, -2.4921861623155905]]])
547        self.failUnless(isinstance(res,Symbol),"wrong type of result.")        self.failUnless(isinstance(res,Symbol),"wrong type of result.")
548        self.failUnlessEqual(res.getShape(),(6, 2, 2),"wrong shape of result.")        self.failUnlessEqual(res.getShape(),(6, 2, 2),"wrong shape of result.")
# Line 833  class Test_util_overloaded_binary_still_ Line 555  class Test_util_overloaded_binary_still_
555        res=arg0+arg1        res=arg0+arg1
556        s1=numarray.array(3.43950171094)        s1=numarray.array(3.43950171094)
557        sub=res.substitute({arg1:s1})        sub=res.substitute({arg1:s1})
558        msk_ref=whereNegative(self.functionspace.getX()[0]-0.5)        msk_ref=1.-whereZero(self.functionspace.getX()[0],1.e-8)
559        ref=msk_ref*numarray.array([[[[8.4045088393544027, 6.8979158128444471, 2.4003397213113455, 7.9937980435917257], [3.4378224936738357, 0.5341575544082926, 3.4652878195255834, 2.543953239326247], [7.9299101636769116, 2.5439652483570576, 7.3324466732916402, 0.56794097631134921]], [[-0.28787300806781335, 5.6950840494026815, 3.9733019011173134, 3.1446923061403496], [-0.19496507194445378, -1.410454278331466, 6.9737188514749224, 5.4270933045441234], [6.5038503159009711, 0.49120697278531011, 4.6967981517671227, -1.0204800490628809]]], [[[-0.35949758918370645, 7.6401785426791786, 1.5054174653044021, 3.6924595166231891], [3.5925555235695814, 5.6239493255647357, 1.3799210624895868, 5.0591736261127398], [1.8890420084640027, 5.67231141694133, 0.1746030047470275, 1.6696492558943903]], [[0.33274027161532338, 7.0885358006194181, 7.7343620879881314, 0.0012077009723823195], [1.6744286300615157, 6.0323948850111799, 5.6925607750057976, 6.204836692452635], [2.5518327510315268, 7.2839055234555872, 7.2678347103281471, 5.1356562306145443]]], [[[1.7453197817635084, -0.91125864227424369, 4.0257556952110924, -1.513935309050523], [7.7653415719601178, 8.1793189608048262, 3.1652516466454799, 2.6299211870438706], [3.7175031668842422, 2.7330354016725336, 2.0775817712385374, 3.2123763441032711]], [[-0.29121608494058737, 3.2681426078221207, 2.1940756709047098, 5.289417244855918], [4.204775067338419, -0.79238747904296858, 7.5785792129411611, 5.5481129764752986], [-1.0085484025864755, 7.7685530425028073, -0.67030845144125362, 0.55554181390182933]]]])+(1.-msk_ref)*numarray.array([[[[7.3718730427060652, 7.8922443496774353, 5.2884244565877339, 5.7353401245031757], [1.8462785282940213, 3.3960184965830926, 6.1261578361435696, 2.1330336197273074], [-1.1244533321294004, -1.0899257783190217, 4.5534350117845772, 0.083406537061532671]], [[3.041661126650907, 4.7967547235667558, 4.1787178076158416, 0.63589195113784047], [1.7928709300808214, -0.23355052745490923, -0.84204716226577059, 0.34517661525282417], [4.2842191408104631, 6.7699258807193399, 0.71876596069863652, 1.6137890391470848]]], [[[3.6498097238721234, 8.0774668459505605, 7.6529584734701377, 7.4945201177782792], [0.86398415696606801, 6.1108182313846893, 6.7203089549601636, 6.2870382106300013], [8.2898849989819468, 2.5455359420968957, 8.3121969809368235, 5.2965174101680326]], [[-1.2383857127275038, 5.5504786403298372, 4.2304776060431024, 1.3282943125296014], [5.9984597786302167, 6.2702113919798634, 3.4519448552740322, -0.32062049506471579], [2.0639578055855083, 6.4195237723449585, 5.0974599142611332, 7.8822133516852269]]], [[[2.5729002477636138, 4.7427327439115432, 6.4422087347721284, 0.52801793799265884], [-0.017273177868172951, 6.8033103797689609, 7.5881179575420425, 5.5144139156175314], [4.2838948962297572, -0.21972721991757904, 4.2138017341534741, 5.2322984356117743]], [[2.2413601890809791, 5.7840329689809495, 1.8958718411520463, 5.0506482290169048], [5.0625755834737944, 2.1359927309126241, -1.239248909812078, 6.3550477907135585], [6.7710173198017145, -0.080578795945922099, 2.3214012936309363, 1.190910092821305]]]])        ref=msk_ref*numarray.array([[[[8.4045088393544027, 6.8979158128444471, 2.4003397213113455, 7.9937980435917257], [3.4378224936738357, 0.5341575544082926, 3.4652878195255834, 2.543953239326247], [7.9299101636769116, 2.5439652483570576, 7.3324466732916402, 0.56794097631134921]], [[-0.28787300806781335, 5.6950840494026815, 3.9733019011173134, 3.1446923061403496], [-0.19496507194445378, -1.410454278331466, 6.9737188514749224, 5.4270933045441234], [6.5038503159009711, 0.49120697278531011, 4.6967981517671227, -1.0204800490628809]]], [[[-0.35949758918370645, 7.6401785426791786, 1.5054174653044021, 3.6924595166231891], [3.5925555235695814, 5.6239493255647357, 1.3799210624895868, 5.0591736261127398], [1.8890420084640027, 5.67231141694133, 0.1746030047470275, 1.6696492558943903]], [[0.33274027161532338, 7.0885358006194181, 7.7343620879881314, 0.0012077009723823195], [1.6744286300615157, 6.0323948850111799, 5.6925607750057976, 6.204836692452635], [2.5518327510315268, 7.2839055234555872, 7.2678347103281471, 5.1356562306145443]]], [[[1.7453197817635084, -0.91125864227424369, 4.0257556952110924, -1.513935309050523], [7.7653415719601178, 8.1793189608048262, 3.1652516466454799, 2.6299211870438706], [3.7175031668842422, 2.7330354016725336, 2.0775817712385374, 3.2123763441032711]], [[-0.29121608494058737, 3.2681426078221207, 2.1940756709047098, 5.289417244855918], [4.204775067338419, -0.79238747904296858, 7.5785792129411611, 5.5481129764752986], [-1.0085484025864755, 7.7685530425028073, -0.67030845144125362, 0.55554181390182933]]]])+(1.-msk_ref)*numarray.array([[[[7.3718730427060652, 7.8922443496774353, 5.2884244565877339, 5.7353401245031757], [1.8462785282940213, 3.3960184965830926, 6.1261578361435696, 2.1330336197273074], [-1.1244533321294004, -1.0899257783190217, 4.5534350117845772, 0.083406537061532671]], [[3.041661126650907, 4.7967547235667558, 4.1787178076158416, 0.63589195113784047], [1.7928709300808214, -0.23355052745490923, -0.84204716226577059, 0.34517661525282417], [4.2842191408104631, 6.7699258807193399, 0.71876596069863652, 1.6137890391470848]]], [[[3.6498097238721234, 8.0774668459505605, 7.6529584734701377, 7.4945201177782792], [0.86398415696606801, 6.1108182313846893, 6.7203089549601636, 6.2870382106300013], [8.2898849989819468, 2.5455359420968957, 8.3121969809368235, 5.2965174101680326]], [[-1.2383857127275038, 5.5504786403298372, 4.2304776060431024, 1.3282943125296014], [5.9984597786302167, 6.2702113919798634, 3.4519448552740322, -0.32062049506471579], [2.0639578055855083, 6.4195237723449585, 5.0974599142611332, 7.8822133516852269]]], [[[2.5729002477636138, 4.7427327439115432, 6.4422087347721284, 0.52801793799265884], [-0.017273177868172951, 6.8033103797689609, 7.5881179575420425, 5.5144139156175314], [4.2838948962297572, -0.21972721991757904, 4.2138017341534741, 5.2322984356117743]], [[2.2413601890809791, 5.7840329689809495, 1.8958718411520463, 5.0506482290169048], [5.0625755834737944, 2.1359927309126241, -1.239248909812078, 6.3550477907135585], [6.7710173198017145, -0.080578795945922099, 2.3214012936309363, 1.190910092821305]]]])
560        self.failUnless(isinstance(res,Symbol),"wrong type of result.")        self.failUnless(isinstance(res,Symbol),"wrong type of result.")
561        self.failUnlessEqual(res.getShape(),(3, 2, 3, 4),"wrong shape of result.")        self.failUnlessEqual(res.getShape(),(3, 2, 3, 4),"wrong shape of result.")
# Line 846  class Test_util_overloaded_binary_still_ Line 568  class Test_util_overloaded_binary_still_
568        res=arg0+arg1        res=arg0+arg1
569        s1=numarray.array([[[[-0.55399336747432937, -3.6468486902030306, 2.4533567494215669, 4.8267547347789659], [1.1480960590338416, 3.5599245920968787, -2.8247534868419724, -2.2031349101131505], [1.7520095897646017, 4.4293583295521266, -3.2046920932014888, -3.8760923163847472]], [[3.9288042477427645, 1.103593535294765, 0.62546922225950485, 2.5431633219905123], [2.5483588394973191, -0.82358610517599207, -0.47010674146441023, 2.7635563586840011], [3.5616440522317419, 2.2995934729430481, -3.501591556463012, 1.3778428754586027]]], [[[-4.3918539920661051, 0.24976043236636869, -2.4847081470778463, 4.8636790550226792], [-4.2172400078729559, -2.0316184192507647, -0.53464794178739794, -0.035422588600630966], [1.7049703562375615, 4.2019750499164399, -3.7430217705554858, -3.4952387702082346]], [[-0.39925876875124189, 1.4505137462439404, -4.1941814051173072, -1.844757872605356], [-3.4448187389632414, -3.5340944666273377, -3.178247383159305, -1.7824872241435519], [-3.6843631882800798, -4.1186208792142187, 2.0636953370355959, -0.18717114434561122]]], [[[-2.4316812831173742, 0.39582208925882689, 1.4893695917228467, -3.1232026180567773], [2.1122901499636226, 4.9884613457151978, -4.7793541216702149, -3.9541373136233391], [-4.8256481088328194, -0.10764491664526066, 2.9970513787255895, -1.0443943611478437]], [[3.6491162738908258, 3.4225261399204765, -2.9600723325757849, 3.3422667802452324], [-3.763493116056098, 4.6894908619506595, 2.532040050484988, 0.99028387045053101], [2.5962274887920085, -0.2721955960411897, -4.7946284910477441, -0.96141278632713245]]]])        s1=numarray.array([[[[-0.55399336747432937, -3.6468486902030306, 2.4533567494215669, 4.8267547347789659], [1.1480960590338416, 3.5599245920968787, -2.8247534868419724, -2.2031349101131505], [1.7520095897646017, 4.4293583295521266, -3.2046920932014888, -3.8760923163847472]], [[3.9288042477427645, 1.103593535294765, 0.62546922225950485, 2.5431633219905123], [2.5483588394973191, -0.82358610517599207, -0.47010674146441023, 2.7635563586840011], [3.5616440522317419, 2.2995934729430481, -3.501591556463012, 1.3778428754586027]]], [[[-4.3918539920661051, 0.24976043236636869, -2.4847081470778463, 4.8636790550226792], [-4.2172400078729559, -2.0316184192507647, -0.53464794178739794, -0.035422588600630966], [1.7049703562375615, 4.2019750499164399, -3.7430217705554858, -3.4952387702082346]], [[-0.39925876875124189, 1.4505137462439404, -4.1941814051173072, -1.844757872605356], [-3.4448187389632414, -3.5340944666273377, -3.178247383159305, -1.7824872241435519], [-3.6843631882800798, -4.1186208792142187, 2.0636953370355959, -0.18717114434561122]]], [[[-2.4316812831173742, 0.39582208925882689, 1.4893695917228467, -3.1232026180567773], [2.1122901499636226, 4.9884613457151978, -4.7793541216702149, -3.9541373136233391], [-4.8256481088328194, -0.10764491664526066, 2.9970513787255895, -1.0443943611478437]], [[3.6491162738908258, 3.4225261399204765, -2.9600723325757849, 3.3422667802452324], [-3.763493116056098, 4.6894908619506595, 2.532040050484988, 0.99028387045053101], [2.5962274887920085, -0.2721955960411897, -4.7946284910477441, -0.96141278632713245]]]])
570        sub=res.substitute({arg1:s1})        sub=res.substitute({arg1:s1})
571        msk_ref=whereNegative(self.functionspace.getX()[0]-0.5)        msk_ref=1.-whereZero(self.functionspace.getX()[0],1.e-8)
572        ref=msk_ref*numarray.array([[[[2.6970740729665748, -1.52967900397269, 5.4143826253879936, 0.98935697683392032], [1.9019285017951733, 5.9677189802571515, 1.0485309200283126, 1.5906234908688068], [-2.8549803003753347, 1.8840613045625512, 0.44613869325621813, -4.4423940828967652]], [[7.6027031991242779, -0.051760102760903592, 4.9288214180626868, 4.5633323167826818], [5.059386898921522, 0.29423174043758227, 3.1021028465928149, -0.28603375808082099], [1.7454470756403131, -1.550775814516876, -1.6710143957134287, 5.1907784763862779]]], [[[0.42409522568862457, -2.4762155842302951, -2.5408280385813118, 8.0957228049877816], [-0.075985958818899135, 0.28294512322906851, 3.6952145822947813, -4.9680400515450032], [2.9554938361058012, 8.3748732152932757, -5.1956728806839303, -4.2338952283369302]], [[-2.9019790957551375, 0.6922966889838289, -6.2016015483743567, -2.046425861522311], [-1.6485742451391205, 1.3845691250511787, -6.5394729506324536, -4.922697593957885], [1.1256495185412279, -7.8190141521781564, -0.3172510491206495, 2.4465584988086508]]], [[[-1.5854928014760299, 2.6808316193281385, 4.5933047694055702, -0.38738041932951983], [0.78118982230464962, 2.516574445386754, -0.94014251566243345, -0.16553698840561726], [-7.5663404715320404, -1.2181260510255796, 4.0624946480426525, -2.6493208823542926]], [[6.7850482946843549, 5.8384677276276866, -5.9382564973935503, 3.7880363384214615], [-2.3612397132491423, 7.9076786084666235, 6.6881434394589077, -3.5411797797636613], [5.0858307842690458, -1.9471711068363931, -9.0924037570822733, 3.4248168828822312]]]])+(1.-msk_ref)*numarray.array([[[[3.2558298420390832, -5.6649010904527994, 6.8741409206040709, 2.3942796381246985], [3.6162843157954541, 6.5878895025755728, -0.58638693563644573, -2.2945550678745148], [6.5366952289276066, 4.8793732877008011, -0.36187833619029774, -0.22179267551309101]], [[0.54551165363519338, -3.5648115071384296, 3.3400504533460582, 3.1180597261424818], [5.7846886934035586, -1.1043481612719912, -2.63116311251677, -1.196474444964037], [7.7061531735330018, 2.5342395084524254, -8.4230448405757858, 5.1379716827226893]]], [[[0.19603839648528876, -2.5104840194304319, -4.9670575046338108, 3.6638171005414875], [-5.2337722702839988, 2.8426930112094917, 2.4723225271505775, 1.9732146853615733], [-0.043317945389794943, 8.7253532155655407, -2.6948548397224279, -0.11722790219478885]], [[-4.9344101757148495, -3.3099703624852657, -5.9276382359889279, -6.1527710225971397], [0.58737887014114687, -6.1916944978948436, -1.8410050343293127, -5.6774488952603139], [-0.10502471709837469, -1.5116902030014687, 3.8693210135481246, -4.1787165614155981]]], [[[-2.0331659601574215, 2.6423508183647542, 2.1310751995191133, -7.8563340886456512], [5.6451941208665124, 2.4573343884044316, -1.9425566471843956, -8.2999342356910084], [-6.3523260642578183, -2.7059660635395963, 1.6676716207038802, -4.2331322279556716]], [[6.7907497844717764, 3.7739862663859078, -0.53168232816014793, 6.1236568007953185], [-0.24067136989108695, 4.6771865296498483, -0.60746418082574882, 5.8550190266057012], [4.8532408672840184, -2.0257196178858674, -4.4067077810612139, -1.1798120178640703]]]])        ref=msk_ref*numarray.array([[[[2.6970740729665748, -1.52967900397269, 5.4143826253879936, 0.98935697683392032], [1.9019285017951733, 5.9677189802571515, 1.0485309200283126, 1.5906234908688068], [-2.8549803003753347, 1.8840613045625512, 0.44613869325621813, -4.4423940828967652]], [[7.6027031991242779, -0.051760102760903592, 4.9288214180626868, 4.5633323167826818], [5.059386898921522, 0.29423174043758227, 3.1021028465928149, -0.28603375808082099], [1.7454470756403131, -1.550775814516876, -1.6710143957134287, 5.1907784763862779]]], [[[0.42409522568862457, -2.4762155842302951, -2.5408280385813118, 8.0957228049877816], [-0.075985958818899135, 0.28294512322906851, 3.6952145822947813, -4.9680400515450032], [2.9554938361058012, 8.3748732152932757, -5.1956728806839303, -4.2338952283369302]], [[-2.9019790957551375, 0.6922966889838289, -6.2016015483743567, -2.046425861522311], [-1.6485742451391205, 1.3845691250511787, -6.5394729506324536, -4.922697593957885], [1.1256495185412279, -7.8190141521781564, -0.3172510491206495, 2.4465584988086508]]], [[[-1.5854928014760299, 2.6808316193281385, 4.5933047694055702, -0.38738041932951983], [0.78118982230464962, 2.516574445386754, -0.94014251566243345, -0.16553698840561726], [-7.5663404715320404, -1.2181260510255796, 4.0624946480426525, -2.6493208823542926]], [[6.7850482946843549, 5.8384677276276866, -5.9382564973935503, 3.7880363384214615], [-2.3612397132491423, 7.9076786084666235, 6.6881434394589077, -3.5411797797636613], [5.0858307842690458, -1.9471711068363931, -9.0924037570822733, 3.4248168828822312]]]])+(1.-msk_ref)*numarray.array([[[[3.2558298420390832, -5.6649010904527994, 6.8741409206040709, 2.3942796381246985], [3.6162843157954541, 6.5878895025755728, -0.58638693563644573, -2.2945550678745148], [6.5366952289276066, 4.8793732877008011, -0.36187833619029774, -0.22179267551309101]], [[0.54551165363519338, -3.5648115071384296, 3.3400504533460582, 3.1180597261424818], [5.7846886934035586, -1.1043481612719912, -2.63116311251677, -1.196474444964037], [7.7061531735330018, 2.5342395084524254, -8.4230448405757858, 5.1379716827226893]]], [[[0.19603839648528876, -2.5104840194304319, -4.9670575046338108, 3.6638171005414875], [-5.2337722702839988, 2.8426930112094917, 2.4723225271505775, 1.9732146853615733], [-0.043317945389794943, 8.7253532155655407, -2.6948548397224279, -0.11722790219478885]], [[-4.9344101757148495, -3.3099703624852657, -5.9276382359889279, -6.1527710225971397], [0.58737887014114687, -6.1916944978948436, -1.8410050343293127, -5.6774488952603139], [-0.10502471709837469, -1.5116902030014687, 3.8693210135481246, -4.1787165614155981]]], [[[-2.0331659601574215, 2.6423508183647542, 2.1310751995191133, -7.8563340886456512], [5.6451941208665124, 2.4573343884044316, -1.9425566471843956, -8.2999342356910084], [-6.3523260642578183, -2.7059660635395963, 1.6676716207038802, -4.2331322279556716]], [[6.7907497844717764, 3.7739862663859078, -0.53168232816014793, 6.1236568007953185], [-0.24067136989108695, 4.6771865296498483, -0.60746418082574882, 5.8550190266057012], [4.8532408672840184, -2.0257196178858674, -4.4067077810612139, -1.1798120178640703]]]])
573        self.failUnless(isinstance(res,Symbol),"wrong type of result.")        self.failUnless(isinstance(res,Symbol),"wrong type of result.")
574        self.failUnlessEqual(res.getShape(),(3, 2, 3, 4),"wrong shape of result.")        self.failUnlessEqual(res.getShape(),(3, 2, 3, 4),"wrong shape of result.")
# Line 1171  class Test_util_overloaded_binary_still_ Line 893  class Test_util_overloaded_binary_still_
893        res=arg0-arg1        res=arg0-arg1
894        s1=numarray.array(0.0730314190245)        s1=numarray.array(0.0730314190245)
895        sub=res.substitute({arg1:s1})        sub=res.substitute({arg1:s1})
896        msk_ref=whereNegative(self.functionspace.getX()[0]-0.5)        msk_ref=1.-whereZero(self.functionspace.getX()[0],1.e-8)
897        ref=msk_ref*(2.35110424173)+(1.-msk_ref)*(2.66288904994)        ref=msk_ref*(2.35110424173)+(1.-msk_ref)*(2.66288904994)
898        self.failUnless(isinstance(res,Symbol),"wrong type of result.")        self.failUnless(isinstance(res,Symbol),"wrong type of result.")
899        self.failUnlessEqual(res.getShape(),(),"wrong shape of result.")        self.failUnlessEqual(res.getShape(),(),"wrong shape of result.")
# Line 1184  class Test_util_overloaded_binary_still_ Line 906  class Test_util_overloaded_binary_still_
906        res=arg0-arg1        res=arg0-arg1
907        s1=numarray.array([1.0449404678521192, -2.9654578889240057])        s1=numarray.array([1.0449404678521192, -2.9654578889240057])
908        sub=res.substitute({arg1:s1})        sub=res.substitute({arg1:s1})
909        msk_ref=whereNegative(self.functionspace.getX()[0]-0.5)        msk_ref=1.-whereZero(self.functionspace.getX()[0],1.e-8)
910        ref=msk_ref*numarray.array([-3.4307907470591283, 0.57960760971699665])+(1.-msk_ref)*numarray.array([-3.1904098199744872, 0.81998853680163775])        ref=msk_ref*numarray.array([-3.4307907470591283, 0.57960760971699665])+(1.-msk_ref)*numarray.array([-3.1904098199744872, 0.81998853680163775])
911        self.failUnless(isinstance(res,Symbol),"wrong type of result.")        self.failUnless(isinstance(res,Symbol),"wrong type of result.")
912        self.failUnlessEqual(res.getShape(),(2,),"wrong shape of result.")        self.failUnlessEqual(res.getShape(),(2,),"wrong shape of result.")
# Line 1197  class Test_util_overloaded_binary_still_ Line 919  class Test_util_overloaded_binary_still_
919        res=arg0-arg1        res=arg0-arg1
920        s1=numarray.array([[-2.5429314638433684, 2.0318827224945402, -2.3636856893688076, 3.4855417570765717, 0.44952339669472341], [2.5403509140391156, 2.3524971436536095, 3.9461465487262188, 2.6955339698780154, -0.45702899742654868], [-1.0602022717036155, 0.74771157767510843, 1.6452939357358289, -3.0322095528230921, 1.6787335078454735], [-4.263078102519902, 3.2046384335109863, 4.0147512257312048, 3.3998288702285713, -0.56118778404289138]])        s1=numarray.array([[-2.5429314638433684, 2.0318827224945402, -2.3636856893688076, 3.4855417570765717, 0.44952339669472341], [2.5403509140391156, 2.3524971436536095, 3.9461465487262188, 2.6955339698780154, -0.45702899742654868], [-1.0602022717036155, 0.74771157767510843, 1.6452939357358289, -3.0322095528230921, 1.6787335078454735], [-4.263078102519902, 3.2046384335109863, 4.0147512257312048, 3.3998288702285713, -0.56118778404289138]])
921        sub=res.substitute({arg1:s1})        sub=res.substitute({arg1:s1})
922        msk_ref=whereNegative(self.functionspace.getX()[0]-0.5)        msk_ref=1.-whereZero(self.functionspace.getX()[0],1.e-8)
923        ref=msk_ref*numarray.array([[4.6956978646047602, 0.12088367826685165, 4.5164520901301994, -1.3327753563151798, 1.7032430040666684], [-0.38758451327772381, -0.19973074289221771, -1.793380147964827, -0.5427675691166236, 2.6097953981879405], [3.2129686724650073, 1.4050548230862834, 0.50747246502556287, 5.1849759535844839, 0.47403289291591832], [6.4158445032812939, -1.0518720327495945, -1.861984824969813, -1.2470624694671795, 2.7139541848042832]])+(1.-msk_ref)*numarray.array([[0.50008379570506278, -4.0747303906328458, 0.32083802123050198, -5.5283894252148773, -2.4923710648330291], [-4.5831985821774213, -4.3953448117919152, -5.9889942168645245, -4.7383816380163211, -1.585818670711757], [-0.98264539643469018, -2.7905592458134141, -3.6881416038741346, 0.98936188468478647, -3.7215811759837791], [2.2202304343815964, -5.247486101649292, -6.0575988938695104, -5.4426765383668769, -1.4816598840954143]])        ref=msk_ref*numarray.array([[4.6956978646047602, 0.12088367826685165, 4.5164520901301994, -1.3327753563151798, 1.7032430040666684], [-0.38758451327772381, -0.19973074289221771, -1.793380147964827, -0.5427675691166236, 2.6097953981879405], [3.2129686724650073, 1.4050548230862834, 0.50747246502556287, 5.1849759535844839, 0.47403289291591832], [6.4158445032812939, -1.0518720327495945, -1.861984824969813, -1.2470624694671795, 2.7139541848042832]])+(1.-msk_ref)*numarray.array([[0.50008379570506278, -4.0747303906328458, 0.32083802123050198, -5.5283894252148773, -2.4923710648330291], [-4.5831985821774213, -4.3953448117919152, -5.9889942168645245, -4.7383816380163211, -1.585818670711757], [-0.98264539643469018, -2.7905592458134141, -3.6881416038741346, 0.98936188468478647, -3.7215811759837791], [2.2202304343815964, -5.247486101649292, -6.0575988938695104, -5.4426765383668769, -1.4816598840954143]])
924        self.failUnless(isinstance(res,Symbol),"wrong type of result.")        self.failUnless(isinstance(res,Symbol),"wrong type of result.")
925        self.failUnlessEqual(res.getShape(),(4, 5),"wrong shape of result.")        self.failUnlessEqual(res.getShape(),(4, 5),"wrong shape of result.")
# Line 1210  class Test_util_overloaded_binary_still_ Line 932  class Test_util_overloaded_binary_still_
932        res=arg0-arg1        res=arg0-arg1
933        s1=numarray.array([[[-0.52002332126128437, 4.3478222442071139], [3.3434922005534364, 2.8013302606159396]], [[-2.3200079969586795, -3.0556917667690642], [-2.7103276420969582, 4.1511200748037105]], [[-0.92404095393396624, 2.6484690327098859], [-2.1529217611726503, 4.4602897709717144]], [[0.58271708006920253, 1.9322598870751975], [-3.5184596230462182, -4.4222029485403436]], [[-4.3953168785776278, -4.450145776704125], [4.2137072146995536, 3.8966485797913304]], [[3.1838339108927798, -3.6438064267677328], [1.3789445362861974, -2.9975552731311272]]])        s1=numarray.array([[[-0.52002332126128437, 4.3478222442071139], [3.3434922005534364, 2.8013302606159396]], [[-2.3200079969586795, -3.0556917667690642], [-2.7103276420969582, 4.1511200748037105]], [[-0.92404095393396624, 2.6484690327098859], [-2.1529217611726503, 4.4602897709717144]], [[0.58271708006920253, 1.9322598870751975], [-3.5184596230462182, -4.4222029485403436]], [[-4.3953168785776278, -4.450145776704125], [4.2137072146995536, 3.8966485797913304]], [[3.1838339108927798, -3.6438064267677328], [1.3789445362861974, -2.9975552731311272]]])
934        sub=res.substitute({arg1:s1})        sub=res.substitute({arg1:s1})
935        msk_ref=whereNegative(self.functionspace.getX()[0]-0.5)        msk_ref=1.-whereZero(self.functionspace.getX()[0],1.e-8)
936        ref=msk_ref*numarray.array([[[3.8282762978010325, -1.0395692676673658], [-0.035239224013688286, 0.50692271592380855]], [[5.6282609734984277, 6.3639447433088119], [6.0185806186367063, -0.84286709826396233]], [[4.2322939304737144, 0.65978394382986227], [5.4611747377123985, -1.1520367944319663]], [[2.7255358964705456, 1.3759930894645507], [6.8267125995859663, 7.7304559250800917]], [[7.7035698551173759, 7.7583987532438732], [-0.90545423815980541, -0.58839560325158224]], [[0.12441906564696836, 6.952059403307481], [1.9293084402535507, 6.3058082496708749]]])+(1.-msk_ref)*numarray.array([[[-3.4007399029178136, -8.2685854683862114], [-7.2642554247325339, -6.7220934847950371]], [[-1.6007552272204184, -0.86507145741003377], [-1.2104355820821397, -8.071883298982808]], [[-2.9967222702451317, -6.5692322568889843], [-1.7678414630064476, -8.3810529951508119]], [[-4.5034803042483009, -5.853023111254295], [-0.40230360113287977, 0.50143972436124562]], [[0.47455365439852981, 0.52938255252502708], [-8.1344704388786511, -7.8174118039704279]], [[-7.1045971350718773, -0.27695679741136514], [-5.2997077604652958, -0.92320795104797071]]])        ref=msk_ref*numarray.array([[[3.8282762978010325, -1.0395692676673658], [-0.035239224013688286, 0.50692271592380855]], [[5.6282609734984277, 6.3639447433088119], [6.0185806186367063, -0.84286709826396233]], [[4.2322939304737144, 0.65978394382986227], [5.4611747377123985, -1.1520367944319663]], [[2.7255358964705456, 1.3759930894645507], [6.8267125995859663, 7.7304559250800917]], [[7.7035698551173759, 7.7583987532438732], [-0.90545423815980541, -0.58839560325158224]], [[0.12441906564696836, 6.952059403307481], [1.9293084402535507, 6.3058082496708749]]])+(1.-msk_ref)*numarray.array([[[-3.4007399029178136, -8.2685854683862114], [-7.2642554247325339, -6.7220934847950371]], [[-1.6007552272204184, -0.86507145741003377], [-1.2104355820821397, -8.071883298982808]], [[-2.9967222702451317, -6.5692322568889843], [-1.7678414630064476, -8.3810529951508119]], [[-4.5034803042483009, -5.853023111254295], [-0.40230360113287977, 0.50143972436124562]], [[0.47455365439852981, 0.52938255252502708], [-8.1344704388786511, -7.8174118039704279]], [[-7.1045971350718773, -0.27695679741136514], [-5.2997077604652958, -0.92320795104797071]]])
937        self.failUnless(isinstance(res,Symbol),"wrong type of result.")        self.failUnless(isinstance(res,Symbol),"wrong type of result.")
938        self.failUnlessEqual(res.getShape(),(6, 2, 2),"wrong shape of result.")        self.failUnlessEqual(res.getShape(),(6, 2, 2),"wrong shape of result.")
# Line 1223  class Test_util_overloaded_binary_still_ Line 945  class Test_util_overloaded_binary_still_
945        res=arg0-arg1        res=arg0-arg1
946        s1=numarray.array([[[[-3.7034845683259832, -3.2006988280486115, 4.6850337347787345, -1.5431340070704103], [-3.9508001556883876, 4.7231128873762902, -3.0051096732527691, -0.071944916970104522], [3.2109725637398565, 4.0910170733379978, -3.7166755556626772, -4.402146700420734]], [[-1.5273991623031669, -1.4865381526416344, 3.902360473786171, -1.3538484671917517], [0.38707743115008331, 4.3855048056490773, 1.9022231675241139, 1.397387379628614], [1.0431068102446126, 3.0934379513218886, 2.0138255231319624, 4.2870052231295865]]], [[[-4.2737086360299941, 4.2752748398653857, -3.7092106416006629, 1.417380944080846], [-2.4275128587779737, -2.879911926405645, -4.23153844815229, -0.30555854124221682], [-2.6571106905165331, 2.6754859746804112, -4.5544081791240201, -0.020082609244357563]], [[1.0570642052363857, -1.7647078574502792, 2.6330635742775668, 3.717540829723692], [4.9220552078075279, -3.9060168420798869, 1.4799017868437296, 2.7842835488914588], [-2.0839669385912343, -4.8850626605172867, 1.7595980725429907, 3.0026383083452117]]], [[[-0.83195539201513036, -1.2109400306251725, 2.0638657571201078, -0.86905066581365009], [-0.54092453152611775, 3.4954317917180884, 3.7826658876966359, -2.5779636206330894], [1.6720368874738147, 0.42564364358069096, -4.9027760864384096, 0.66861897918883617]], [[-4.1302737255553801, -3.2949127465748109, 1.5706320204575341, -2.2912291830881903], [-2.19574275564025, 3.983182476523945, 2.032922034582441, -2.7459308093848711], [4.6025690264891459, 3.7012963844874829, 0.1748188819614116, 4.2002322255258893]]]])        s1=numarray.array([[[[-3.7034845683259832, -3.2006988280486115, 4.6850337347787345, -1.5431340070704103], [-3.9508001556883876, 4.7231128873762902, -3.0051096732527691, -0.071944916970104522], [3.2109725637398565, 4.0910170733379978, -3.7166755556626772, -4.402146700420734]], [[-1.5273991623031669, -1.4865381526416344, 3.902360473786171, -1.3538484671917517], [0.38707743115008331, 4.3855048056490773, 1.9022231675241139, 1.397387379628614], [1.0431068102446126, 3.0934379513218886, 2.0138255231319624, 4.2870052231295865]]], [[[-4.2737086360299941, 4.2752748398653857, -3.7092106416006629, 1.417380944080846], [-2.4275128587779737, -2.879911926405645, -4.23153844815229, -0.30555854124221682], [-2.6571106905165331, 2.6754859746804112, -4.5544081791240201, -0.020082609244357563]], [[1.0570642052363857, -1.7647078574502792, 2.6330635742775668, 3.717540829723692], [4.9220552078075279, -3.9060168420798869, 1.4799017868437296, 2.7842835488914588], [-2.0839669385912343, -4.8850626605172867, 1.7595980725429907, 3.0026383083452117]]], [[[-0.83195539201513036, -1.2109400306251725, 2.0638657571201078, -0.86905066581365009], [-0.54092453152611775, 3.4954317917180884, 3.7826658876966359, -2.5779636206330894], [1.6720368874738147, 0.42564364358069096, -4.9027760864384096, 0.66861897918883617]], [[-4.1302737255553801, -3.2949127465748109, 1.5706320204575341, -2.2912291830881903], [-2.19574275564025, 3.983182476523945, 2.032922034582441, -2.7459308093848711], [4.6025690264891459, 3.7012963844874829, 0.1748188819614116, 4.2002322255258893]]]])
947        sub=res.substitute({arg1:s1})        sub=res.substitute({arg1:s1})
948        msk_ref=whereNegative(self.functionspace.getX()[0]-0.5)        msk_ref=1.-whereZero(self.functionspace.getX()[0],1.e-8)
949        ref=msk_ref*numarray.array([[[[7.984636175171131, 7.4818504348937598, -0.40388212793358669, 5.8242856139155581], [8.2319517625335354, -0.44196128053114236, 7.286261280097917, 4.3530965238152524], [1.0701790431052913, 0.19013453350715004, 7.997827162507825, 8.6832983072658827]], [[5.8085507691483151, 5.7676897594867818, 0.37879113305897683, 5.6350000740368991], [3.8940741756950645, -0.10435319880392946, 2.3789284393210339, 2.8837642272165338], [3.2380447966005352, 1.1877136555232592, 2.2673260837131854, -0.0058536162844387007]]], [[[8.5548602428751419, 0.005876766979762138, 7.9903622484458108, 2.8637706627643018], [6.7086644656231211, 7.1610635332507933, 8.5126900549974387, 4.5867101480873647], [6.938262297361681, 1.6056656321647367, 8.835559785969167, 4.3012342160895054]], [[3.2240874016087622, 6.0458594642954271, 1.6480880325675811, 0.5636107771214558], [-0.64090360096238008, 8.1871684489250356, 2.8012498200014182, 1.496868057953689], [6.3651185454363821, 9.1662142673624345, 2.5215535343021571, 1.2785132984999361]]], [[[5.1131069988602782, 5.4920916374703204, 2.2172858497250401, 5.1502022726587979], [4.8220761383712656, 0.78571981512705946, 0.49848571914851192, 6.8591152274782372], [2.6091147193713331, 3.8555079632644569, 9.1839276932835574, 3.6125326276563117]], [[8.4114253324005279, 7.5760643534199588, 2.7105195863876137, 6.5723807899333382], [6.4768943624853978, 0.29796913032120287, 2.2482295722627068, 7.0270824162300194], [-0.32141741964399806, 0.57985522235766496, 4.1063327248837362, 0.080919381319258576]]]])+(1.-msk_ref)*numarray.array([[[[0.70723868548106505, 0.20445294520369339, -7.6812796176236526, -1.4531118757745078], [0.9545542728434695, -7.7193587702212083, 0.0088637904078510132, -2.9243009658748136], [-6.2072184465847746, -7.0872629561829159, 0.72042967281775905, 1.4059008175758159]], [[-1.4688467205417512, -1.5097077302032837, -6.8986063566310891, -1.6423974156531664], [-3.3833233139950014, -7.3817506884939954, -4.898469050369032, -4.3936332624735321], [-4.0393526930895307, -6.0896838341668067, -5.0100714059768805, -7.2832511059745046]]], [[[1.277462753185076, -7.2715207227103038, 0.71296475875574483, -4.4136268269257641], [-0.56873302406694437, -0.11633395643927313, 1.2352925653073719, -2.6906873416027013], [-0.33913519232838496, -5.6717318575253293, 1.558162296279102, -2.9761632736005605]], [[-4.0533100880813038, -1.2315380253946389, -5.6293094571224849, -6.7137867125686101], [-7.918301090652446, 0.90977095923496876, -4.4761476696886477, -5.7805294317363769], [-0.91227894425368383, 1.8888167776723686, -4.7558439553879088, -5.9988841911901298]]], [[[-2.1642904908297877, -1.7853058522197456, -5.0601116399650259, -2.127195217031268], [-2.4553213513188004, -6.4916776745630065, -6.778911770541554, -0.41828226221182874], [-4.6682827703187328, -3.4218895264256091, 1.9065302035934915, -3.6648648620337543]], [[1.134027842710462, 0.29866686372989282, -4.5668779033024522, -0.70501669975672776], [-0.8005031272046681, -6.9794283593688631, -5.0291679174273591, -0.250315073460047], [-7.598814909334064, -6.697542267332401, -3.1710647648063297, -7.1964781083708074]]]])        ref=msk_ref*numarray.array([[[[7.984636175171131, 7.4818504348937598, -0.40388212793358669, 5.8242856139155581], [8.2319517625335354, -0.44196128053114236, 7.286261280097917, 4.3530965238152524], [1.0701790431052913, 0.19013453350715004, 7.997827162507825, 8.6832983072658827]], [[5.8085507691483151, 5.7676897594867818, 0.37879113305897683, 5.6350000740368991], [3.8940741756950645, -0.10435319880392946, 2.3789284393210339, 2.8837642272165338], [3.2380447966005352, 1.1877136555232592, 2.2673260837131854, -0.0058536162844387007]]], [[[8.5548602428751419, 0.005876766979762138, 7.9903622484458108, 2.8637706627643018], [6.7086644656231211, 7.1610635332507933, 8.5126900549974387, 4.5867101480873647], [6.938262297361681, 1.6056656321647367, 8.835559785969167, 4.3012342160895054]], [[3.2240874016087622, 6.0458594642954271, 1.6480880325675811, 0.5636107771214558], [-0.64090360096238008, 8.1871684489250356, 2.8012498200014182, 1.496868057953689], [6.3651185454363821, 9.1662142673624345, 2.5215535343021571, 1.2785132984999361]]], [[[5.1131069988602782, 5.4920916374703204, 2.2172858497250401, 5.1502022726587979], [4.8220761383712656, 0.78571981512705946, 0.49848571914851192, 6.8591152274782372], [2.6091147193713331, 3.8555079632644569, 9.1839276932835574, 3.6125326276563117]], [[8.4114253324005279, 7.5760643534199588, 2.7105195863876137, 6.5723807899333382], [6.4768943624853978, 0.29796913032120287, 2.2482295722627068, 7.0270824162300194], [-0.32141741964399806, 0.57985522235766496, 4.1063327248837362, 0.080919381319258576]]]])+(1.-msk_ref)*numarray.array([[[[0.70723868548106505, 0.20445294520369339, -7.6812796176236526, -1.4531118757745078], [0.9545542728434695, -7.7193587702212083, 0.0088637904078510132, -2.9243009658748136], [-6.2072184465847746, -7.0872629561829159, 0.72042967281775905, 1.4059008175758159]], [[-1.4688467205417512, -1.5097077302032837, -6.8986063566310891, -1.6423974156531664], [-3.3833233139950014, -7.3817506884939954, -4.898469050369032, -4.3936332624735321], [-4.0393526930895307, -6.0896838341668067, -5.0100714059768805, -7.2832511059745046]]], [[[1.277462753185076, -7.2715207227103038, 0.71296475875574483, -4.4136268269257641], [-0.56873302406694437, -0.11633395643927313, 1.2352925653073719, -2.6906873416027013], [-0.33913519232838496, -5.6717318575253293, 1.558162296279102, -2.9761632736005605]], [[-4.0533100880813038, -1.2315380253946389, -5.6293094571224849, -6.7137867125686101], [-7.918301090652446, 0.90977095923496876, -4.4761476696886477, -5.7805294317363769], [-0.91227894425368383, 1.8888167776723686, -4.7558439553879088, -5.9988841911901298]]], [[[-2.1642904908297877, -1.7853058522197456, -5.0601116399650259, -2.127195217031268], [-2.4553213513188004, -6.4916776745630065, -6.778911770541554, -0.41828226221182874], [-4.6682827703187328, -3.4218895264256091, 1.9065302035934915, -3.6648648620337543]], [[1.134027842710462, 0.29866686372989282, -4.5668779033024522, -0.70501669975672776], [-0.8005031272046681, -6.9794283593688631, -5.0291679174273591, -0.250315073460047], [-7.598814909334064, -6.697542267332401, -3.1710647648063297, -7.1964781083708074]]]])
950        self.failUnless(isinstance(res,Symbol),"wrong type of result.")        self.failUnless(isinstance(res,Symbol),"wrong type of result.")
951        self.failUnlessEqual(res.getShape(),(3, 2, 3, 4),"wrong shape of result.")        self.failUnlessEqual(res.getShape(),(3, 2, 3, 4),"wrong shape of result.")
# Line 1236  class Test_util_overloaded_binary_still_ Line 958  class Test_util_overloaded_binary_still_
958        res=arg0-arg1        res=arg0-arg1
959        s1=numarray.array(4.01685432532)        s1=numarray.array(4.01685432532)
960        sub=res.substitute({arg1:s1})        sub=res.substitute({arg1:s1})
961        msk_ref=whereNegative(self.functionspace.getX()[0]-0.5)        msk_ref=1.-whereZero(self.functionspace.getX()[0],1.e-8)
962        ref=msk_ref*numarray.array([-3.4449989576654145, -8.5184983853296714])+(1.-msk_ref)*numarray.array([-4.4586644173155481, -2.2330252413511991])        ref=msk_ref*numarray.array([-3.4449989576654145, -8.5184983853296714])+(1.-msk_ref)*numarray.array([-4.4586644173155481, -2.2330252413511991])
963        self.failUnless(isinstance(res,Symbol),"wrong type of result.")        self.failUnless(isinstance(res,Symbol),"wrong type of result.")
964        self.failUnlessEqual(res.getShape(),(2,),"wrong shape of result.")        self.failUnlessEqual(res.getShape(),(2,),"wrong shape of result.")
# Line 1249  class Test_util_overloaded_binary_still_ Line 971  class Test_util_overloaded_binary_still_
971        res=arg0-arg1        res=arg0-arg1
972        s1=numarray.array([-1.5016152385157842, 0.80809700227400683])        s1=numarray.array([-1.5016152385157842, 0.80809700227400683])
973        sub=res.substitute({arg1:s1})        sub=res.substitute({arg1:s1})
974        msk_ref=whereNegative(self.functionspace.getX()[0]-0.5)        msk_ref=1.-whereZero(self.functionspace.getX()[0],1.e-8)
975        ref=msk_ref*numarray.array([-2.6718056955445597, 3.7446611980556117])+(1.-msk_ref)*numarray.array([-0.19845304377299477, -0.041257118510259261])        ref=msk_ref*numarray.array([-2.6718056955445597, 3.7446611980556117])+(1.-msk_ref)*numarray.array([-0.19845304377299477, -0.041257118510259261])
976        self.failUnless(isinstance(res,Symbol),"wrong type of result.")        self.failUnless(isinstance(res,Symbol),"wrong type of result.")
977        self.failUnlessEqual(res.getShape(),(2,),"wrong shape of result.")        self.failUnlessEqual(res.getShape(),(2,),"wrong shape of result.")
# Line 1262  class Test_util_overloaded_binary_still_ Line 984  class Test_util_overloaded_binary_still_
984        res=arg0-arg1        res=arg0-arg1
985        s1=numarray.array(-3.53998589595)        s1=numarray.array(-3.53998589595)
986        sub=res.substitute({arg1:s1})        sub=res.substitute({arg1:s1})
987        msk_ref=whereNegative(self.functionspace.getX()[0]-0.5)        msk_ref=1.-whereZero(self.functionspace.getX()[0],1.e-8)
988        ref=msk_ref*numarray.array([[6.8899985356048354, 7.0343762163049011, 1.8393997428112305, 5.0352206165652902, -1.0579719212770256], [1.2344527865926112, -0.10743039062817417, 0.47668977732565487, 8.2658243642932199, 2.9561025209271889], [8.3041161186778911, 3.4281636912925197, 6.402831743196824, 5.2367572555253137, 6.3874618747960046], [6.1263181433500398, 5.1749199121315019, 0.54651586451727718, 6.9468550431737093, 2.5608543292843917]])+(1.-msk_ref)*numarray.array([[3.1959121108656845, 6.2189313420115155, 0.16042713806118192, -0.6259402728875525, 5.8547401785466793], [1.4784710101757881, 1.42180904308377, 8.325581676303905, 5.9648489805742217, 7.9997311324856302], [8.1384950264388056, 6.539219312053195, 4.2797329844212939, 3.2955857208562298, 3.0483223901158096], [5.1278599746604021, 6.5610241156093263, 7.1743301892914353, 5.0894510202984335, 0.17645462843161352]])        ref=msk_ref*numarray.array([[6.8899985356048354, 7.0343762163049011, 1.8393997428112305, 5.0352206165652902, -1.0579719212770256], [1.2344527865926112, -0.10743039062817417, 0.47668977732565487, 8.2658243642932199, 2.9561025209271889], [8.3041161186778911, 3.4281636912925197, 6.402831743196824, 5.2367572555253137, 6.3874618747960046], [6.1263181433500398, 5.1749199121315019, 0.54651586451727718, 6.9468550431737093, 2.5608543292843917]])+(1.-msk_ref)*numarray.array([[3.1959121108656845, 6.2189313420115155, 0.16042713806118192, -0.6259402728875525, 5.8547401785466793], [1.4784710101757881, 1.42180904308377, 8.325581676303905, 5.9648489805742217, 7.9997311324856302], [8.1384950264388056, 6.539219312053195, 4.2797329844212939, 3.2955857208562298, 3.0483223901158096], [5.1278599746604021, 6.5610241156093263, 7.1743301892914353, 5.0894510202984335, 0.17645462843161352]])
989        self.failUnless(isinstance(res,Symbol),"wrong type of result.")        self.failUnless(isinstance(res,Symbol),"wrong type of result.")
990        self.failUnlessEqual(res.getShape(),(4, 5),"wrong shape of result.")        self.failUnlessEqual(res.getShape(),(4, 5),"wrong shape of result.")
# Line 1275  class Test_util_overloaded_binary_still_ Line 997  class Test_util_overloaded_binary_still_
997        res=arg0-arg1        res=arg0-arg1
998        s1=numarray.array([[3.235357796595256, -1.480870361715898, 4.6623764990451662, -0.75539625063053251, 1.764045470290668], [0.076611613190003425, -4.3375283365611939, -0.16726979393963415, 3.2199460507232871, -3.1622960810628884], [0.33570324662007156, 1.8340432936621101, 3.3105489280357343, -4.5476113052695135, 1.6510039686145541], [1.9731991965232831, -1.2055959073743616, 3.1802938969891557, 1.6969195493915894, 4.7202410276309497]])        s1=numarray.array([[3.235357796595256, -1.480870361715898, 4.6623764990451662, -0.75539625063053251, 1.764045470290668], [0.076611613190003425, -4.3375283365611939, -0.16726979393963415, 3.2199460507232871, -3.1622960810628884], [0.33570324662007156, 1.8340432936621101, 3.3105489280357343, -4.5476113052695135, 1.6510039686145541], [1.9731991965232831, -1.2055959073743616, 3.1802938969891557, 1.6969195493915894, 4.7202410276309497]])
999        sub=res.substitute({arg1:s1})        sub=res.substitute({arg1:s1})
1000        msk_ref=whereNegative(self.functionspace.getX()[0]-0.5)        msk_ref=1.-whereZero(self.functionspace.getX()[0],1.e-8)
1001        ref=msk_ref*numarray.array([[-1.1485579139097046, 3.792596290932527, -8.1343361721673055, 2.5371795317882464, -0.24984717246047516], [3.0244749577849639, 2.1670359841220401, 3.8877103446862504, 1.4098650159375339, 4.8258305761534777], [-2.9102309586036146, -3.4543771108965293, 0.40139438460585275, 0.29808753920724484, -3.7664288492977129], [-1.8261131324074347, -3.1683203016307417, -2.8981730548323243, -4.9423553424402735, -0.67122395896466536]])+(1.-msk_ref)*numarray.array([[-0.66892886918947347, -2.4067563390756432, -1.6017647758834297, 1.2121288356594766, -4.1738495951274102], [2.4065647348000612, -0.062820153145580981, -3.5157181642486712, -7.7139007133004212, 3.2581786269521453], [4.5480666122686761, 2.854639683626659, -5.0326785094414408, 1.7009197599912822, -3.3830693439830264], [-1.0614028273342235, 0.43252351407477319, -7.3595118224393037, -4.5518512782717035, -2.3362339718311915]])        ref=msk_ref*numarray.array([[-1.1485579139097046, 3.792596290932527, -8.1343361721673055, 2.5371795317882464, -0.24984717246047516], [3.0244749577849639, 2.1670359841220401, 3.8877103446862504, 1.4098650159375339, 4.8258305761534777], [-2.9102309586036146, -3.4543771108965293, 0.40139438460585275, 0.29808753920724484, -3.7664288492977129], [-1.8261131324074347, -3.1683203016307417, -2.8981730548323243, -4.9423553424402735, -0.67122395896466536]])+(1.-msk_ref)*numarray.array([[-0.66892886918947347, -2.4067563390756432, -1.6017647758834297, 1.2121288356594766, -4.1738495951274102], [2.4065647348000612, -0.062820153145580981, -3.5157181642486712, -7.7139007133004212, 3.2581786269521453], [4.5480666122686761, 2.854639683626659, -5.0326785094414408, 1.7009197599912822, -3.3830693439830264], [-1.0614028273342235, 0.43252351407477319, -7.3595118224393037, -4.5518512782717035, -2.3362339718311915]])
1002        self.failUnless(isinstance(res,Symbol),"wrong type of result.")        self.failUnless(isinstance(res,Symbol),"wrong type of result.")
1003        self.failUnlessEqual(res.getShape(),(4, 5),"wrong shape of result.")        self.failUnlessEqual(res.getShape(),(4, 5),"wrong shape of result.")
# Line 1288  class Test_util_overloaded_binary_still_ Line 1010  class Test_util_overloaded_binary_still_
1010        res=arg0-arg1        res=arg0-arg1
1011        s1=numarray.array(-4.30522721091)        s1=numarray.array(-4.30522721091)
1012        sub=res.substitute({arg1:s1})        sub=res.substitute({arg1:s1})
1013        msk_ref=whereNegative(self.functionspace.getX()[0]-0.5)        msk_ref=1.-whereZero(self.functionspace.getX()[0],1.e-8)
1014        ref=msk_ref*numarray.array([[[-0.17897720120150851, 8.7980737601856447], [3.4563845367661816, -0.38475638428350933]], [[0.45313705960565454, 0.092174453107833898], [2.3915401090053097, 2.667914085849846]], [[0.11144253207288735, 3.6452321869146029], [3.7332055534665125, 1.7705667711935718]], [[0.55336109683168644, 0.071914507359040591], [3.1199013000263394, 4.5753608048197041]], [[9.0227365887160964, 1.7929022679327429], [8.1252993749775158, 8.8982302237938669]], [[-0.40131954231939027, 2.5996334377816126], [2.9737531269368853, -0.042238501373582871]]])+(1.-msk_ref)*numarray.array([[[8.0805372626461072, 8.0961452258875735], [5.3001074886383135, 1.2766100738609829]], [[7.942701479062741, 5.4509082804697213], [4.3031140147884299, 3.9167821268663072]], [[1.7457164980548709, 0.8596652297155245], [-0.2719580199022138, 5.6695241376889314]], [[4.1207703056430169, 4.8019778167761427], [0.43813488089029118, 0.15044889462232369]], [[0.36632188865777859, 5.6324852919293571], [7.9042745901316458, 6.5081311430103614]], [[-0.23514382022516944, 3.4278444750493247], [7.6887582034995763, 7.6590723414438493]]])        ref=msk_ref*numarray.array([[[-0.17897720120150851, 8.7980737601856447], [3.4563845367661816, -0.38475638428350933]], [[0.45313705960565454, 0.092174453107833898], [2.3915401090053097, 2.667914085849846]], [[0.11144253207288735, 3.6452321869146029], [3.7332055534665125, 1.7705667711935718]], [[0.55336109683168644, 0.071914507359040591], [3.1199013000263394, 4.5753608048197041]], [[9.0227365887160964, 1.7929022679327429], [8.1252993749775158, 8.8982302237938669]], [[-0.40131954231939027, 2.5996334377816126], [2.9737531269368853, -0.042238501373582871]]])+(1.-msk_ref)*numarray.array([[[8.0805372626461072, 8.0961452258875735], [5.3001074886383135, 1.2766100738609829]], [[7.942701479062741, 5.4509082804697213], [4.3031140147884299, 3.9167821268663072]], [[1.7457164980548709, 0.8596652297155245], [-0.2719580199022138, 5.6695241376889314]], [[4.1207703056430169, 4.8019778167761427], [0.43813488089029118, 0.15044889462232369]], [[0.36632188865777859, 5.6324852919293571], [7.9042745901316458, 6.5081311430103614]], [[-0.23514382022516944, 3.4278444750493247], [7.6887582034995763, 7.6590723414438493]]])
1015        self.failUnless(isinstance(res,Symbol),"wrong type of result.")        self.failUnless(isinstance(res,Symbol),"wrong type of result.")
1016        self.failUnlessEqual(res.getShape(),(6, 2, 2),"wrong shape of result.")        self.failUnlessEqual(res.getShape(),(6, 2, 2),"wrong shape of result.")
# Line 1301  class Test_util_overloaded_binary_still_ Line 1023  class Test_util_overloaded_binary_still_
1023        res=arg0-arg1        res=arg0-arg1
1024        s1=numarray.array([[[-0.065448649070245501, -1.0082288113108073], [2.940556380714975, 2.6943538184190166]], [[4.4012174975531551, 2.1536331083101858], [0.42620647125632161, -3.3632985397458972]], [[0.7816306898353016, -4.1519556164933835], [4.587159382474109, 3.7392943755961223]], [[1.0899221203445091, -3.3294088440228276], [4.0864323956812836, -1.4550107947057112]], [[3.7465493005246273, 3.1852429656365171], [-3.8082443104157484, -2.7860725384289688]], [[-4.7267420836233232, 0.9545260667209563], [-4.6866116848499395, 0.18931611034152862]]])        s1=numarray.array([[[-0.065448649070245501, -1.0082288113108073], [2.940556380714975, 2.6943538184190166]], [[4.4012174975531551, 2.1536331083101858], [0.42620647125632161, -3.3632985397458972]], [[0.7816306898353016, -4.1519556164933835], [4.587159382474109, 3.7392943755961223]], [[1.0899221203445091, -3.3294088440228276], [4.0864323956812836, -1.4550107947057112]], [[3.7465493005246273, 3.1852429656365171], [-3.8082443104157484, -2.7860725384289688]], [[-4.7267420836233232, 0.9545260667209563], [-4.6866116848499395, 0.18931611034152862]]])
1025        sub=res.substitute({arg1:s1})        sub=res.substitute({arg1:s1})
1026        msk_ref=whereNegative(self.functionspace.getX()[0]-0.5)        msk_ref=1.-whereZero(self.functionspace.getX()[0],1.e-8)
1027        ref=msk_ref*numarray.array([[[2.1402350004775057, 4.5244675117122242], [-2.3386809532167838, -4.1407910328615154]], [[-5.1984416376608387, -5.4204365672253854], [3.2735557089055689, 0.99568262254575934]], [[-5.0804771052582254, 7.1489197572390859], [-1.9507066696900193, -2.62840992760409]], [[-2.2543514906622479, 8.095110707794559], [-0.13143320831464855, -1.6855463985633268]], [[-1.8295744921879296, 0.41284505402078508], [8.4587607600264789, -0.70458366019008878]], [[-0.07319119893096282, 2.4729142286192003], [1.4175309031254644, 3.1259102375697525]]])+(1.-msk_ref)*numarray.array([[[-0.12782912571090765, 2.1386215969620648], [-2.8698358178990127, -2.4252189516602654]], [[-6.6305643452242924, 2.2725145337674411], [-2.593954293861239, 7.359601763751221]], [[-3.7979313142821374, 4.1915674601042863], [-6.2933608294393535, -4.5932310035155002]], [[1.2371067852550492, 4.698823283352084], [-2.346415781400963, 2.4826340106180944]], [[-3.4008135906244963, -6.2427900393731264], [3.6392180505109799, 0.73195444061103254]], [[6.1590369486824308, 0.42210982429678356], [3.4618057404229328, 3.6712854524430822]]])        ref=msk_ref*numarray.array([[[2.1402350004775057, 4.5244675117122242], [-2.3386809532167838, -4.1407910328615154]], [[-5.1984416376608387, -5.4204365672253854], [3.2735557089055689, 0.99568262254575934]], [[-5.0804771052582254, 7.1489197572390859], [-1.9507066696900193, -2.62840992760409]], [[-2.2543514906622479, 8.095110707794559], [-0.13143320831464855, -1.6855463985633268]], [[-1.8295744921879296, 0.41284505402078508], [8.4587607600264789, -0.70458366019008878]], [[-0.07319119893096282, 2.4729142286192003], [1.4175309031254644, 3.1259102375697525]]])+(1.-msk_ref)*numarray.array([[[-0.12782912571090765, 2.1386215969620648], [-2.8698358178990127, -2.4252189516602654]], [[-6.6305643452242924, 2.2725145337674411], [-2.593954293861239, 7.359601763751221]], [[-3.7979313142821374, 4.1915674601042863], [-6.2933608294393535, -4.5932310035155002]], [[1.2371067852550492, 4.698823283352084], [-2.346415781400963, 2.4826340106180944]], [[-3.4008135906244963, -6.2427900393731264], [3.6392180505109799, 0.73195444061103254]], [[6.1590369486824308, 0.42210982429678356], [3.4618057404229328, 3.6712854524430822]]])
1028        self.failUnless(isinstance(res,Symbol),"wrong type of result.")        self.failUnless(isinstance(res,Symbol),"wrong type of result.")
1029        self.failUnlessEqual(res.getShape(),(6, 2, 2),"wrong shape of result.")        self.failUnlessEqual(res.getShape(),(6, 2, 2),"wrong shape of result.")
# Line 1314  class Test_util_overloaded_binary_still_ Line 1036  class Test_util_overloaded_binary_still_
1036        res=arg0-arg1        res=arg0-arg1
1037        s1=numarray.array(3.09580908291)        s1=numarray.array(3.09580908291)
1038        sub=res.substitute({arg1:s1})        sub=res.substitute({arg1:s1})
1039        msk_ref=whereNegative(self.functionspace.getX()[0]-0.5)        msk_ref=1.-whereZero(self.functionspace.getX()[0],1.e-8)
1040        ref=msk_ref*numarray.array([[[[-5.4873871330441668, -4.6671938580084422, -5.1923121823556659, -5.2509776927960692], [0.24780050414610599, -0.026408751211041803, -3.9108554490143375, -5.5652014702857127], [-5.4150356170683933, -6.5830703643509239, -3.624101829717957, -2.7943601100865445]], [[-7.9361933722865308, -0.5523332126478131, -3.749503190986557, -0.70860584200654131], [-7.5318923349352103, -5.0687405834511212, -0.95284563623780549, -7.5751598615274824], [-7.7747629753987821, -4.3217049290728173, 1.5746456148722672, -7.2725033373005736]]], [[[-4.0928659042352473, -2.4644151635231788, 0.55228121045586676, -2.1780190575579628], [-5.7358269190023199, -8.0651190327795028, -5.1789480572426676, -7.9785477840897059], [-2.1685231212316403, -3.7982100238332572, -7.3927085579064045, -4.9620934701213866]], [[1.3722438704155788, -3.7202313417268646, 0.21912177146159983, -8.0682855287285449], [-5.651695948321187, -2.5518804176755072, -7.1914965652693912, -6.2932566611345662], [-4.2153516207420179, -1.6668246459710865, -4.3586466851996049, -5.1289940465388426]]], [[[-2.9401975247504337, -2.0391559371975436, -4.7387365743610816, -6.256807970415462], [-7.012787741827867, -3.1821063577281912, -5.3807591611551242, -6.6894833632847472], [1.4416678078979732, -1.1043620533300107, -5.7669788706509761, -7.7434564397289396]], [[1.6509688509322622, -1.6699575641792928, -1.7378370936584808, 0.7882730752540219], [-3.8399177358783332, -7.2327123636137314, -2.9907563995731685, -2.8939721745920206], [0.13004153101546123, -3.2872680911378014, -5.0835090694048404, -4.2144519358149228]]]])+(1.-msk_ref)*numarray.array([[[[-7.1964296194354835, -2.1114487427447042, -5.1618002881481901, -7.9249397587519272], [-6.3862748838110202, -1.1999213808425786, -7.5626130903476048, 1.6371754527984432], [-4.8739762778611802, -3.8742220682708304, -5.8867370034336837, -7.0253834906645576]], [[-4.459685958154779, 1.3680693837358575, -0.58384574270757916, 0.37003656953775099], [-5.4130048886080129, -5.7526344358263231, -0.85384307923433056, -5.063326055769986], [-4.2102026653606694, -1.9089377913524093, -1.2498865179791832, 0.32814064848686897]]], [[[0.1099817406881165, -2.0903564811416206, -0.24276473293559775, -0.18405518971746204], [0.67321132112562587, -3.369881144288744, -4.7713121150473228, -7.1933277268156015], [-1.5382107747810529, -4.5096280467651777, -7.6757401450405967, -5.2789806328854905]], [[1.1349661022591864, -7.6699682778665332, 0.5184438567819214, -0.12628780298442344], [-1.9884877996067241, 0.46074445578928191, 1.0205079743213563, -5.7009667416313023], [-5.5843422831258795, -0.3764446779275552, 0.59329281525601907, -0.86787282462095305]]], [[[0.74133500959818832, -2.9969019640625518, -7.9443076295506261, -6.3604704945447708], [-4.4124427921783882, 0.80318545537056707, -0.6435494632291352, 1.762101173644453], [-0.28925129070568367, -5.7099055129255234, -2.830953554024898, -6.3413997639010713]], [[0.32209144747146645, -8.0465629466167385, -7.0244106403643816, -2.418940865048123], [-1.8661748193174486, -4.1107341304564704, -1.1228779078331019, -7.7432629613077397], [-4.323452358934305, -0.57877214500123841, -2.1212708299492666, 0.76388488807906541]]]])        ref=msk_ref*numarray.array([[[[-5.4873871330441668, -4.6671938580084422, -5.1923121823556659, -5.2509776927960692], [0.24780050414610599, -0.026408751211041803, -3.9108554490143375, -5.5652014702857127], [-5.4150356170683933, -6.5830703643509239, -3.624101829717957, -2.7943601100865445]], [[-7.9361933722865308, -0.5523332126478131, -3.749503190986557, -0.70860584200654131], [-7.5318923349352103, -5.0687405834511212, -0.95284563623780549, -7.5751598615274824], [-7.7747629753987821, -4.3217049290728173, 1.5746456148722672, -7.2725033373005736]]], [[[-4.0928659042352473, -2.4644151635231788, 0.55228121045586676, -2.1780190575579628], [-5.7358269190023199, -8.0651190327795028, -5.1789480572426676, -7.9785477840897059], [-2.1685231212316403, -3.7982100238332572, -7.3927085579064045, -4.9620934701213866]], [[1.3722438704155788, -3.7202313417268646, 0.21912177146159983, -8.0682855287285449], [-5.651695948321187, -2.5518804176755072, -7.1914965652693912, -6.2932566611345662], [-4.2153516207420179, -1.6668246459710865, -4.3586466851996049, -5.1289940465388426]]], [[[-2.9401975247504337, -2.0391559371975436, -4.7387365743610816, -6.256807970415462], [-7.012787741827867, -3.1821063577281912, -5.3807591611551242, -6.6894833632847472], [1.4416678078979732, -1.1043620533300107, -5.7669788706509761, -7.7434564397289396]], [[1.6509688509322622, -1.6699575641792928, -1.7378370936584808, 0.7882730752540219], [-3.8399177358783332, -7.2327123636137314, -2.9907563995731685, -2.8939721745920206], [0.13004153101546123, -3.2872680911378014, -5.0835090694048404, -4.2144519358149228]]]])+(1.-msk_ref)*numarray.array([[[[-7.1964296194354835, -2.1114487427447042, -5.1618002881481901, -7.9249397587519272], [-6.3862748838110202, -1.1999213808425786, -7.5626130903476048, 1.6371754527984432], [-4.8739762778611802, -3.8742220682708304, -5.8867370034336837, -7.0253834906645576]], [[-4.459685958154779, 1.3680693837358575, -0.58384574270757916, 0.37003656953775099], [-5.4130048886080129, -5.7526344358263231, -0.85384307923433056, -5.063326055769986], [-4.2102026653606694, -1.9089377913524093, -1.2498865179791832, 0.32814064848686897]]], [[[0.1099817406881165, -2.0903564811416206, -0.24276473293559775, -0.18405518971746204], [0.67321132112562587, -3.369881144288744, -4.7713121150473228, -7.1933277268156015], [-1.5382107747810529, -4.5096280467651777, -7.6757401450405967, -5.2789806328854905]], [[1.1349661022591864, -7.6699682778665332, 0.5184438567819214, -0.12628780298442344], [-1.9884877996067241, 0.46074445578928191, 1.0205079743213563, -5.7009667416313023], [-5.5843422831258795, -0.3764446779275552, 0.59329281525601907, -0.86787282462095305]]], [[[0.74133500959818832, -2.9969019640625518, -7.9443076295506261, -6.3604704945447708], [-4.4124427921783882, 0.80318545537056707, -0.6435494632291352, 1.762101173644453], [-0.28925129070568367, -5.7099055129255234, -2.830953554024898, -6.3413997639010713]], [[0.32209144747146645, -8.0465629466167385, -7.0244106403643816, -2.418940865048123], [-1.8661748193174486, -4.1107341304564704, -1.1228779078331019, -7.7432629613077397], [-4.323452358934305, -0.57877214500123841, -2.1212708299492666, 0.76388488807906541]]]])
1041        self.failUnless(isinstance(res,Symbol),"wrong type of result.")        self.failUnless(isinstance(res,Symbol),"wrong type of result.")
1042        self.failUnlessEqual(res.getShape(),(3, 2, 3, 4),"wrong shape of result.")        self.failUnlessEqual(res.getShape(),(3, 2, 3, 4),"wrong shape of result.")
# Line 1327  class Test_util_overloaded_binary_still_ Line 1049  class Test_util_overloaded_binary_still_
1049        res=arg0-arg1        res=arg0-arg1
1050        s1=numarray.array([[[[-1.3801587913318047, -1.0654264899468902, 0.63456255053258914, 0.019001978473544234], [2.9683175293448718, 3.6853848061948291, -3.378954186340446, 0.041808892524110242], [-0.43021730340079323, 3.8311628728062068, -2.1793361115232388, 3.1444277139479642]], [[4.3924534836876852, 4.6258828194696662, -1.337885612990688, 4.1259618924749724], [-4.4897704263159222, 0.15369009386017485, 2.6962829695946411, 2.0341337355139855], [-2.3651800760864128, 2.5627722574362446, 4.595047097795911, -4.3290029697233141]]], [[[4.178160967558556, -4.7760981608958755, -1.9186656311572339, 1.2206352911034513], [-0.085772738154105355, -1.3074976307569877, -1.956712770838227, 3.2327542991796854], [1.1038448851539249, 3.3037436446982742, -0.27900134960503031, -0.91401651221828928]], [[-2.3182986051061674, -1.849076104179066, 1.7255801749968178, -4.800626013966669], [-1.065938515473257, -1.7027357609246607, -4.5450782032387052, 4.2110109611691939], [0.42483398312984555, -2.0300778021420198, -1.8600131931716146, -0.65565335271777681]]], [[[1.5409796879232402, 3.8526060616448135, 4.5046749363240419, -2.3425879056067043], [-2.0020629040094438, 4.0201378578644089, -0.91649358299543415, -4.6048272916989044], [2.9771669103984353, -0.18712141889004474, 4.7604346415721732, 3.1208517541066438]], [[-2.0397258049700016, 4.8476984980922424, -0.83670507076672873, -0.65429392708528322], [1.8648243434781451, -3.0663012456143979, -0.46932892583376429, 1.7337690374943984], [-2.830192293285001, 2.4237706377557764, -4.5545542759999593, -1.4623880986500994]]]])        s1=numarray.array([[[[-1.3801587913318047, -1.0654264899468902, 0.63456255053258914, 0.019001978473544234], [2.9683175293448718, 3.6853848061948291, -3.378954186340446, 0.041808892524110242], [-0.43021730340079323, 3.8311628728062068, -2.1793361115232388, 3.1444277139479642]], [[4.3924534836876852, 4.6258828194696662, -1.337885612990688, 4.1259618924749724], [-4.4897704263159222, 0.15369009386017485, 2.6962829695946411, 2.0341337355139855], [-2.3651800760864128, 2.5627722574362446, 4.595047097795911, -4.3290029697233141]]], [[[4.178160967558556, -4.7760981608958755, -1.9186656311572339, 1.2206352911034513], [-0.085772738154105355, -1.3074976307569877, -1.956712770838227, 3.2327542991796854], [1.1038448851539249, 3.3037436446982742, -0.27900134960503031, -0.91401651221828928]], [[-2.3182986051061674, -1.849076104179066, 1.7255801749968178, -4.800626013966669], [-1.065938515473257, -1.7027357609246607, -4.5450782032387052, 4.2110109611691939], [0.42483398312984555, -2.0300778021420198, -1.8600131931716146, -0.65565335271777681]]], [[[1.5409796879232402, 3.8526060616448135, 4.5046749363240419, -2.3425879056067043], [-2.0020629040094438, 4.0201378578644089, -0.91649358299543415, -4.6048272916989044], [2.9771669103984353, -0.18712141889004474, 4.7604346415721732, 3.1208517541066438]], [[-2.0397258049700016, 4.8476984980922424, -0.83670507076672873, -0.65429392708528322], [1.8648243434781451, -3.0663012456143979, -0.46932892583376429, 1.7337690374943984], [-2.830192293285001, 2.4237706377557764, -4.5545542759999593, -1.4623880986500994]]]])
1051        sub=res.substitute({arg1:s1})        sub=res.substitute({arg1:s1})
1052        msk_ref=whereNegative(self.functionspace.getX()[0]-0.5)        msk_ref=1.-whereZero(self.functionspace.getX()[0],1.e-8)
1053        ref=msk_ref*numarray.array([[[[6.1028596715959349, 3.9517544283384098, -2.8242594703650701, 4.4112292992128603], [-4.9880341173218969, -8.6556689083226601, 8.169183437876999, 4.5538752380813436], [3.3695587709432733, -2.1851038594777679, 3.1701720826368636, 0.24659350601855401]], [[-3.1137221013705618, -3.2470915359364199, 1.2664646864516693, -7.3647948725128138], [7.8397462516238141, -1.9353381741629425, -0.3997339530266375, -3.9359431985591629], [1.2451519767269015, -3.2241442462947294, -4.3766110813204717, 2.9202902813663507]]], [[[-6.1236534320284308, 5.5394985240682351, 6.051010419919761, 0.22266291146358075], [-3.6797462187742256, 2.3017138109463913, 6.5613374525339943, -2.4885379151712321], [-4.6661223622330734, -2.0639722292265628, -0.77924486179391206, 2.2111167831686789]], [[3.6561999916767975, 1.4537548339665372, 2.9855781334672749, 3.9179405338193884], [-3.7474886749282366, -1.4312069485024659, 6.7210330274504964, -5.7192323720057381], [-3.6933115875339873, 0.8800440076533933, -2.8787592296052957, -0.21595665037058343]]], [[[-2.3196077649707423, 0.20745857418558877, -5.1132191771157096, 0.15460231900727406], [-1.1735701411019983, -1.6204181499754258, 4.4062124515863541, 5.9384474066017985], [-6.1261059102294091, -2.9392144789423282, -0.26527213904102354, 1.6861955370768928]], [[1.553969199917602, -2.2457916265134426, 2.9213293795673154, -3.5153848258880949], [2.6835574179200359, 5.9334248638496305, -1.9930199721978488, -4.4758004824979949], [0.16938986666938405, -0.51369304575566854, -0.18700259554860121, 5.7979944513643824]]]])+(1.-msk_ref)*numarray.array([[[[1.3133449075703019, 3.4007107807050549, 1.3477195541878517, 2.2298064155662987], [-6.5144272316581038, 0.25407483872703018, 0.2396548371209648, -1.2377124091939873], [-1.9733312163236709, -5.0876456778073731, 6.4706628689093657, 0.22731582353249102]], [[-2.3327903387838855, -2.8592346203955632, 5.0430709344256321, -1.8068853998428409], [6.5663619186710811, -3.2420501282977368, 0.68662865504002113, -2.8095680568225019], [1.293144204272433, -0.80503000467645958, -4.2200035235425819, 6.9207361593801036]]], [[[-8.4172074245673247, 5.0012361058125956, 4.4034780580612232, -0.81255944197977303], [3.5541413789090441, 1.4723005816681116, 4.8945629965489506, -7.7877205847549513], [-5.025376706965492, -3.3329887805008376, -2.2747372588783277, 3.3650454488778543]], [[-1.2888109108487207, -2.144817278628516, -1.6518548401496966, 2.6296456047376671], [1.3993796629197739, 1.1221832803358627, 2.1580385370637538, 0.0098389794650213247], [2.1272700145871513, 3.0273675686228678, -0.36626243748827081, -0.44763908047789691]]], [[[3.4250257832125648, -6.0749183893866103, -0.58356181820805375, 3.5445938548965135], [0.069821223771051599, -2.0988131979329276, -4.008004519026275, 8.5246904212210346], [-2.5355403704341173, -4.6532621198031867, -4.6926727015120679, -6.4406870453501135]], [[5.7686620305710798, -0.35109182220032409, 5.597390024284663, -3.5930764082196873], [-6.0043819600272927, 4.4606429565100534, 1.6309328964092842, 2.1421533714131806], [6.1147366142985318, 2.2876350456499726, 5.9321158513885637, -2.5289204029304111]]]])        ref=msk_ref*numarray.array([[[[6.1028596715959349, 3.9517544283384098, -2.8242594703650701, 4.4112292992128603], [-4.9880341173218969, -8.6556689083226601, 8.169183437876999, 4.5538752380813436], [3.3695587709432733, -2.1851038594777679, 3.1701720826368636, 0.24659350601855401]], [[-3.1137221013705618, -3.2470915359364199, 1.2664646864516693, -7.3647948725128138], [7.8397462516238141, -1.9353381741629425, -0.3997339530266375, -3.9359431985591629], [1.2451519767269015, -3.2241442462947294, -4.3766110813204717, 2.9202902813663507]]], [[[-6.1236534320284308, 5.5394985240682351, 6.051010419919761, 0.22266291146358075], [-3.6797462187742256, 2.3017138109463913, 6.5613374525339943, -2.4885379151712321], [-4.6661223622330734, -2.0639722292265628, -0.77924486179391206, 2.2111167831686789]], [[3.6561999916767975, 1.4537548339665372, 2.9855781334672749, 3.9179405338193884], [-3.7474886749282366, -1.4312069485024659, 6.7210330274504964, -5.7192323720057381], [-3.6933115875339873, 0.8800440076533933, -2.8787592296052957, -0.21595665037058343]]], [[[-2.3196077649707423, 0.20745857418558877, -5.1132191771157096, 0.15460231900727406], [-1.1735701411019983, -1.6204181499754258, 4.4062124515863541, 5.9384474066017985], [-6.1261059102294091, -2.9392144789423282, -0.26527213904102354, 1.6861955370768928]], [[1.553969199917602, -2.2457916265134426, 2.9213293795673154, -3.5153848258880949], [2.6835574179200359, 5.9334248638496305, -1.9930199721978488, -4.4758004824979949], [0.16938986666938405, -0.51369304575566854, -0.18700259554860121, 5.7979944513643824]]]])+(1.-msk_ref)*numarray.array([[[[1.3133449075703019, 3.4007107807050549, 1.3477195541878517, 2.2298064155662987], [-6.5144272316581038, 0.25407483872703018, 0.2396548371209648, -1.2377124091939873], [-1.9733312163236709, -5.0876456778073731, 6.4706628689093657, 0.22731582353249102]], [[-2.3327903387838855, -2.8592346203955632, 5.0430709344256321, -1.8068853998428409], [6.5663619186710811, -3.2420501282977368, 0.68662865504002113, -2.8095680568225019], [1.293144204272433, -0.80503000467645958, -4.2200035235425819, 6.9207361593801036]]], [[[-8.4172074245673247, 5.0012361058125956, 4.4034780580612232, -0.81255944197977303], [3.5541413789090441, 1.4723005816681116, 4.8945629965489506, -7.7877205847549513], [-5.025376706965492, -3.3329887805008376, -2.2747372588783277, 3.3650454488778543]], [[-1.2888109108487207, -2.144817278628516, -1.6518548401496966, 2.6296456047376671], [1.3993796629197739, 1.1221832803358627, 2.1580385370637538, 0.0098389794650213247], [2.1272700145871513, 3.0273675686228678, -0.36626243748827081, -0.44763908047789691]]], [[[3.4250257832125648, -6.0749183893866103, -0.58356181820805375, 3.5445938548965135], [0.069821223771051599, -2.0988131979329276, -4.008004519026275, 8.5246904212210346], [-2.5355403704341173, -4.6532621198031867, -4.6926727015120679, -6.4406870453501135]], [[5.7686620305710798, -0.35109182220032409, 5.597390024284663, -3.5930764082196873], [-6.0043819600272927, 4.4606429565100534, 1.6309328964092842, 2.1421533714131806], [6.1147366142985318, 2.2876350456499726, 5.9321158513885637, -2.5289204029304111]]]])
1054        self.failUnless(isinstance(res,Symbol),"wrong type of result.")        self.failUnless(isinstance(res,Symbol),"wrong type of result.")
1055        self.failUnlessEqual(res.getShape(),(3, 2, 3, 4),"wrong shape of result.")        self.failUnlessEqual(res.getShape(),(3, 2, 3, 4),"wrong shape of result.")
# Line 1652  class Test_util_overloaded_binary_still_ Line 1374  class Test_util_overloaded_binary_still_
1374        res=arg0*arg1        res=arg0*arg1
1375        s1=numarray.array(2.5646949317)        s1=numarray.array(2.5646949317)
1376        sub=res.substitute({arg1:s1})        sub=res.substitute({arg1:s1})
1377        msk_ref=whereNegative(self.functionspace.getX()[0]-0.5)        msk_ref=1.-whereZero(self.functionspace.getX()[0],1.e-8)
1378        ref=msk_ref*(-0.1103343692)+(1.-msk_ref)*(4.57606250448)        ref=msk_ref*(-0.1103343692)+(1.-msk_ref)*(4.57606250448)
1379        self.failUnless(isinstance(res,Symbol),"wrong type of result.")        self.failUnless(isinstance(res,Symbol),"wrong type of result.")
1380        self.failUnlessEqual(res.getShape(),(),"wrong shape of result.")        self.failUnlessEqual(res.getShape(),(),"wrong shape of result.")
# Line 1665  class Test_util_overloaded_binary_still_ Line 1387  class Test_util_overloaded_binary_still_
1387        res=arg0*arg1        res=arg0*arg1
1388        s1=numarray.array([4.0270481495052639, 2.7564226252917825])        s1=numarray.array([4.0270481495052639, 2.7564226252917825])
1389        sub=res.substitute({arg1:s1})        sub=res.substitute({arg1:s1})
1390        msk_ref=whereNegative(self.functionspace.getX()[0]-0.5)        msk_ref=1.-whereZero(self.functionspace.getX()[0],1.e-8)
1391        ref=msk_ref*numarray.array([10.362668508083143, 7.0930102828763504])+(1.-msk_ref)*numarray.array([13.270569146744505, 9.0834019581016197])        ref=msk_ref*numarray.array([10.362668508083143, 7.0930102828763504])+(1.-msk_ref)*numarray.array([13.270569146744505, 9.0834019581016197])
1392        self.failUnless(isinstance(res,Symbol),"wrong type of result.")        self.failUnless(isinstance(res,Symbol),"wrong type of result.")
1393        self.failUnlessEqual(res.getShape(),(2,),"wrong shape of result.")        self.failUnlessEqual(res.getShape(),(2,),"wrong shape of result.")
# Line 1678  class Test_util_overloaded_binary_still_ Line 1400  class Test_util_overloaded_binary_still_
1400        res=arg0*arg1        res=arg0*arg1
1401        s1=numarray.array([[-0.87644218701217369, -3.616282438617354, 0.79667729938717624, 3.9811287325297613, 0.065796525107652215], [-1.4217337078130887, 4.8515183472866479, -0.78214368357519071, 3.1809506063985502, 0.95738137909039533], [0.39346667195906182, 4.3285617066713939, -4.5910865330304649, -4.7275376371854012, -0.90249772270981055], [1.0196798908676152, -4.5635511009909653, -4.4978908227402012, 1.164740898313557, -1.7685582007909115]])        s1=numarray.array([[-0.87644218701217369, -3.616282438617354, 0.79667729938717624, 3.9811287325297613, 0.065796525107652215], [-1.4217337078130887, 4.8515183472866479, -0.78214368357519071, 3.1809506063985502, 0.95738137909039533], [0.39346667195906182, 4.3285617066713939, -4.5910865330304649, -4.7275376371854012, -0.90249772270981055], [1.0196798908676152, -4.5635511009909653, -4.4978908227402012, 1.164740898313557, -1.7685582007909115]])
1402        sub=res.substitute({arg1:s1})        sub=res.substitute({arg1:s1})
1403        msk_ref=whereNegative(self.functionspace.getX()[0]-0.5)        msk_ref=1.-whereZero(self.functionspace.getX()[0],1.e-8)
1404        ref=msk_ref*numarray.array([[2.6516907362186282, 10.941123994409631, -2.4103607127155628, -12.044972658985373, -0.19906850524632991], [4.3014795022930183, -14.678351234952618, 2.3663890110066546, -9.6240201354420911, -2.8965736378079594], [-1.1904401048989282, -13.096137028570261, 13.890410353610562, 14.30324548888392, 2.730522202412847], [-3.0850588442572544, 13.807101435875975, 13.608445147811342, -3.5239433883048839, 5.3508029017726937]])+(1.-msk_ref)*numarray.array([[-0.54919476824925706, -2.2660289808399305, 0.49921262496268565, 2.4946483681778449, 0.041229310835994216], [-0.89088444822170665, 3.0400504835102153, -0.49010559441809565, 1.9932420608926262, 0.59991275226964935], [0.24655344177009811, 2.7123562495913784, -2.8768591264593351, -2.9623618939370084, -0.56552164536805005], [0.63895014371973546, -2.8596049191178006, -2.8184609830641962, 0.72984803470084503, -1.108211044164624]])        ref=msk_ref*numarray.array([[2.6516907362186282, 10.941123994409631, -2.4103607127155628, -12.044972658985373, -0.19906850524632991], [4.3014795022930183, -14.678351234952618, 2.3663890110066546, -9.6240201354420911, -2.8965736378079594], [-1.1904401048989282, -13.096137028570261, 13.890410353610562, 14.30324548888392, 2.730522202412847], [-3.0850588442572544, 13.807101435875975, 13.608445147811342, -3.5239433883048839, 5.3508029017726937]])+(1.-msk_ref)*numarray.array([[-0.54919476824925706, -2.2660289808399305, 0.49921262496268565, 2.4946483681778449, 0.041229310835994216], [-0.89088444822170665, 3.0400504835102153, -0.49010559441809565, 1.9932420608926262, 0.59991275226964935], [0.24655344177009811, 2.7123562495913784, -2.8768591264593351, -2.9623618939370084, -0.56552164536805005], [0.63895014371973546, -2.8596049191178006, -2.8184609830641962, 0.72984803470084503, -1.108211044164624]])
1405        self.failUnless(isinstance(res,Symbol),"wrong type of result.")        self.failUnless(isinstance(res,Symbol),"wrong type of result.")
1406        self.failUnlessEqual(res.getShape(),(4, 5),"wrong shape of result.")        self.failUnlessEqual(res.getShape(),(4, 5),"wrong shape of result.")
# Line 1691  class Test_util_overloaded_binary_still_ Line 1413  class Test_util_overloaded_binary_still_
1413        res=arg0*arg1        res=arg0*arg1
1414        s1=numarray.array([[[4.2317874979104992, -1.1989677806745727], [1.3134595205642725, 4.4478340118436144]], [[-0.017162439223159964, -0.41900720330017371], [-4.4667032138911269, 2.0617117365888351]], [[2.9794518983997751, 0.52772381685170533], [-2.6894168529203224, 0.41500536076126604]], [[-4.6733566211583097, 2.4911601334345299], [-4.7318467145182375, -0.81771569841489722]], [[1.3136083167944523, 0.82585873482530836], [0.296465998582784, -1.7304343680929755]], [[-1.3066203047314175, 2.65896658854032], [3.9719908108129438, -2.8680613980844938]]])        s1=numarray.array([[[4.2317874979104992, -1.1989677806745727], [1.3134595205642725, 4.4478340118436144]], [[-0.017162439223159964, -0.41900720330017371], [-4.4667032138911269, 2.0617117365888351]], [[2.9794518983997751, 0.52772381685170533], [-2.6894168529203224, 0.41500536076126604]], [[-4.6733566211583097, 2.4911601334345299], [-4.7318467145182375, -0.81771569841489722]], [[1.3136083167944523, 0.82585873482530836], [0.296465998582784, -1.7304343680929755]], [[-1.3066203047314175, 2.65896658854032], [3.9719908108129438, -2.8680613980844938]]])
1415        sub=res.substitute({arg1:s1})        sub=res.substitute({arg1:s1})
1416        msk_ref=whereNegative(self.functionspace.getX()[0]-0.5)        msk_ref=1.-whereZero(self.functionspace.getX()[0],1.e-8)
1417        ref=msk_ref*numarray.array([[[-15.080443222871585, 4.2726544164712799], [-4.6806584062148398, -15.850348892396909]], [[0.061160252115363196, 1.4931785545617493], [15.917591382781623, -7.3471380122247991]], [[-10.617606675968551, -1.8806022422720292], [9.5840346834818018, -1.4789175456560166]], [[16.654023676852269, -8.8775249158636207], [16.862459599603678, 2.9140204153647811]], [[-4.6811886580533626, -2.9430390270766442], [-1.0564894058000638, 6.166594435995874]], [[4.6562861034687169, -9.475521795410085], [-14.154628967973551, 10.220654296766785]]])+(1.-msk_ref)*numarray.array([[[19.91133899106331, -5.6413640647508636], [6.1800687718624765, 20.927877600075174]], [[-0.080752435100909861, -1.971506005140051], [-21.016660668375366, 9.7007331557512781]], [[14.018869516935215, 2.4830376799828495], [-12.654201250232003, 1.9526765994999067]], [[-21.989002981827273, 11.72136689810848], [-22.264209635536492, -3.8475028525162167]], [[6.1807688855097629, 3.8858173374624307], [1.3949270845997368, -8.1420121690652945]], [[-6.1478890026873314, 12.510927152291805], [18.68894776558027, -13.494756712769872]]])        ref=msk_ref*numarray.array([[[-15.080443222871585, 4.2726544164712799], [-4.6806584062148398, -15.850348892396909]], [[0.061160252115363196, 1.4931785545617493], [15.917591382781623, -7.3471380122247991]], [[-10.617606675968551, -1.8806022422720292], [9.5840346834818018, -1.4789175456560166]], [[16.654023676852269, -8.8775249158636207], [16.862459599603678, 2.9140204153647811]], [[-4.6811886580533626, -2.9430390270766442], [-1.0564894058000638, 6.166594435995874]], [[4.6562861034687169, -9.475521795410085], [-14.154628967973551, 10.220654296766785]]])+(1.-msk_ref)*numarray.array([[[19.91133899106331, -5.6413640647508636], [6.1800687718624765, 20.927877600075174]], [[-0.080752435100909861, -1.971506005140051], [-21.016660668375366, 9.7007331557512781]], [[14.018869516935215, 2.4830376799828495], [-12.654201250232003, 1.9526765994999067]], [[-21.989002981827273, 11.72136689810848], [-22.264209635536492, -3.8475028525162167]], [[6.1807688855097629, 3.8858173374624307], [1.3949270845997368, -8.1420121690652945]], [[-6.1478890026873314, 12.510927152291805], [18.68894776558027, -13.494756712769872]]])
1418        self.failUnless(isinstance(res,Symbol),"wrong type of result.")        self.failUnless(isinstance(res,Symbol),"wrong type of result.")
1419        self.failUnlessEqual(res.getShape(),(6, 2, 2),"wrong shape of result.")        self.failUnlessEqual(res.getShape(),(6, 2, 2),"wrong shape of result.")
# Line 1704  class Test_util_overloaded_binary_still_ Line 1426  class Test_util_overloaded_binary_still_
1426        res=arg0*arg1        res=arg0*arg1
1427        s1=numarray.array([[[[0.67581666027729526, 2.8108253236352603, -3.2853142689252701, 4.9303752145005504], [-1.3657702337917108, 4.3904435823590919, 3.3571499478699067, 0.015664424638796248], [-3.1193276566121941, 2.4614116251071474, 4.8836311348501411, 4.5339873643248207]], [[0.92904130460985179, -4.0289182883108268, 1.1622216990935978, -3.453322460119399], [-4.9809628080889743, -3.091966318347751, -0.82579662341565552, 0.19293706069789529], [-4.1200195632312617, -4.252279729557471, -4.2626018577200098, 2.8104051978786853]]], [[[4.553470024096578, -4.1556230388171853, -4.8792826237543903, -0.084660297479757673], [-1.3940013078624869, -4.391326436454821, 1.8581067287379591, -4.9713750706033011], [1.1291380851369173, 0.083960164404878412, 1.6804470605141759, -4.9497828740616505]], [[1.5580688980525261, -0.37196449698866818, 2.6938341003534481, -2.2283064145681664], [0.4008724735809448, 2.2505971863148471, -1.6587271003862281, -2.7339584931448382], [-4.8561801785490113, 2.7658580526343668, 2.6247408695536976, 1.2921000397940583]]], [[[-3.378532765195783, -4.7136195887628478, -2.2928079312088725, -3.2689147861576906], [2.1255291713840734, -2.9248168929356853, -4.2298230449258032, 0.73722628474508767], [-4.0600914026090829, 4.8210888962888614, -1.5990379796232492, -1.3511964372595688]], [[-2.5350622751408225, 3.9568471756339907, -2.5691428388833124, 3.4094397075929948], [0.80244721075126435, -1.8355785194219432, -4.4146407757484631, 4.8328210906719811], [-4.920522191727871, -2.4717933373462273, -4.5300856839069414, -2.5250375128130722]]]])        s1=numarray.array([[[[0.67581666027729526, 2.8108253236352603, -3.2853142689252701, 4.9303752145005504], [-1.3657702337917108, 4.3904435823590919, 3.3571499478699067, 0.015664424638796248], [-3.1193276566121941, 2.4614116251071474, 4.8836311348501411, 4.5339873643248207]], [[0.92904130460985179, -4.0289182883108268, 1.1622216990935978, -3.453322460119399], [-4.9809628080889743, -3.091966318347751, -0.82579662341565552, 0.19293706069789529], [-4.1200195632312617, -4.252279729557471, -4.2626018577200098, 2.8104051978786853]]], [[[4.553470024096578, -4.1556230388171853, -4.8792826237543903, -0.084660297479757673], [-1.3940013078624869, -4.391326436454821, 1.8581067287379591, -4.9713750706033011], [1.1291380851369173, 0.083960164404878412, 1.6804470605141759, -4.9497828740616505]], [[1.5580688980525261, -0.37196449698866818, 2.6938341003534481, -2.2283064145681664], [0.4008724735809448, 2.2505971863148471, -1.6587271003862281, -2.7339584931448382], [-4.8561801785490113, 2.7658580526343668, 2.6247408695536976, 1.2921000397940583]]], [[[-3.378532765195783, -4.7136195887628478, -2.2928079312088725, -3.2689147861576906], [2.1255291713840734, -2.9248168929356853, -4.2298230449258032, 0.73722628474508767], [-4.0600914026090829, 4.8210888962888614, -1.5990379796232492, -1.3511964372595688]], [[-2.5350622751408225, 3.9568471756339907, -2.5691428388833124, 3.4094397075929948], [0.80244721075126435, -1.8355785194219432, -4.4146407757484631, 4.8328210906719811], [-4.920522191727871, -2.4717933373462273, -4.5300856839069414, -2.5250375128130722]]]])
1428        sub=res.substitute({arg1:s1})        sub=res.substitute({arg1:s1})
1429        msk_ref=whereNegative(self.functionspace.getX()[0]-0.5)        msk_ref=1.-whereZero(self.functionspace.getX()[0],1.e-8)
1430        ref=msk_ref*numarray.array([[[[1.7021095483176161, 7.0793351262596333, -8.2743813744801198, 12.417626292235164], [-3.4398242783642043, 11.057756314881239, 8.455306471815506, 0.039452366764170722], [-7.8563280557071602, 6.1993029702993985, 12.299896811775723, 11.419285197263687]], [[2.3398802786380641, -10.147219935524449, 2.9271676292760325, -8.6975262349660429], [-12.545036033862335, -7.7874158819594053, -2.0798485747710065, 0.48593062666356401], [-10.376667297538809, -10.709777303843696, -10.735774580822937, 7.0782769989541201]]], [[[11.468354158082919, -10.466338090388497, -12.288944666479384, -0.21322513807898585], [-3.510926965763792, -11.059979868212249, 4.6798213046129975, -12.520888390750915], [2.8438433513788075, 0.21146178529132892, 4.2323682668163789, -12.466506357778224]], [[3.9241470419266724, -0.93682852047446297, 6.7846814281166719, -5.6122049776897045], [1.009636052268762, 5.6683464398043348, -4.1776644489085921, -6.8857385877058555], [-12.230758926344738, 6.9660807100382254, 6.6106634513770723, 3.2542787776386608]]], [[[-8.5091611630055262, -11.87170630845092, -5.7746582787226588, -8.2330776928059901], [5.353350561609421, -7.3664339060593971, -10.653217974099684, 1.8567756202110501], [-10.22573243546206, 12.142378141868068, -4.0273316318104415, -3.4031187638502254]], [[-6.3847992476635591, 9.9657018755896978, -6.470634439909837, 8.587003283295978], [2.0210408232317629, -4.6230818330415877, -11.118699284078886, 12.171926806847758], [-12.392810502499694, -6.2254503155317185, -11.409458438197062, -6.3595509152671994]]]])+(1.-msk_ref)*numarray.array([[[[2.495540296879188, 10.379335513483992, -12.131447222167042, 18.206047216225837], [-5.0432829716077814, 16.212279934703215, 12.39670974393805, 0.057842910971599444], [-11.518520219746321, 9.0890803063976193, 18.033438665320531, 16.742333887671666]], [[3.43060499894721, -14.877301096998385, 4.2916537198201299, -12.751839165684238], [-18.392848438720499, -11.417484944606104, -3.0493606800326032, 0.7124450136157725], [-15.213704319978612, -15.70209206496787, -15.740207856266352, 10.377784144870411]]], [[[16.814276124980314, -15.345174751614865, -18.017381226508029, -0.31261908195608412], [-5.1475298585355107, -16.215539987468492, 6.8612990623305103, -18.357444479839728], [4.1694882026791129, 0.31003375015792717, 6.2052677934347074, -18.27771250557068]], [[5.753370623933491, -1.3735269427402785, 9.947330312604274, -8.2283092119504264], [1.4802733796476881, 8.3106207653820228, -6.1250640356231392, -10.095494814878659], [-17.932072464006065, 10.213288057984194, 9.6921946347836005, 4.7712462660838089]]], [[[-12.475668558412432, -17.405649075135688, -8.4664893922387598, -12.070890014125325], [7.8487909682557282, -10.80026410464507, -15.619167856781525, 2.7223032660145061], [-14.992411847417884, 17.802493372372791, -5.9046542486134737, -4.9894673457699161]], [[-9.3610448433105873, 14.611169205765981, -9.4868917262874675, 12.589796434712371], [2.9631399582934548, -6.7781107400101064, -16.301631196256576, 17.845816015294734], [-18.169663657162346, -9.1274161195937573, -16.727926428843457, -9.3240271137605752]]]])        ref=msk_ref*numarray.array([[[[1.7021095483176161, 7.0793351262596333, -8.2743813744801198, 12.417626292235164], [-3.4398242783642043, 11.057756314881239, 8.455306471815506, 0.039452366764170722], [-7.8563280557071602, 6.1993029702993985, 12.299896811775723, 11.419285197263687]], [[2.3398802786380641, -10.147219935524449, 2.9271676292760325, -8.6975262349660429], [-12.545036033862335, -7.7874158819594053, -2.0798485747710065, 0.48593062666356401], [-10.376667297538809, -10.709777303843696, -10.735774580822937, 7.0782769989541201]]], [[[11.468354158082919, -10.466338090388497, -12.288944666479384, -0.21322513807898585], [-3.510926965763792, -11.059979868212249, 4.6798213046129975, -12.520888390750915], [2.8438433513788075, 0.21146178529132892, 4.2323682668163789, -12.466506357778224]], [[3.9241470419266724, -0.93682852047446297, 6.7846814281166719, -5.6122049776897045], [1.009636052268762, 5.6683464398043348, -4.1776644489085921, -6.8857385877058555], [-12.230758926344738, 6.9660807100382254, 6.6106634513770723, 3.2542787776386608]]], [[[-8.5091611630055262, -11.87170630845092, -5.7746582787226588, -8.2330776928059901], [5.353350561609421, -7.3664339060593971, -10.653217974099684, 1.8567756202110501], [-10.22573243546206, 12.142378141868068, -4.0273316318104415, -3.4031187638502254]], [[-6.3847992476635591, 9.9657018755896978, -6.470634439909837, 8.587003283295978], [2.0210408232317629, -4.6230818330415877, -11.118699284078886, 12.171926806847758], [-12.392810502499694, -6.2254503155317185, -11.409458438197062, -6.3595509152671994]]]])+(1.-msk_ref)*numarray.array([[[[2.495540296879188, 10.379335513483992, -12.131447222167042, 18.206047216225837], [-5.0432829716077814, 16.212279934703215, 12.39670974393805, 0.057842910971599444], [-11.518520219746321, 9.0890803063976193, 18.033438665320531, 16.742333887671666]], [[3.43060499894721, -14.877301096998385, 4.2916537198201299, -12.751839165684238], [-18.392848438720499, -11.417484944606104, -3.0493606800326032, 0.7124450136157725], [-15.213704319978612, -15.70209206496787, -15.740207856266352, 10.377784144870411]]], [[[16.814276124980314, -15.345174751614865, -18.017381226508029, -0.31261908195608412], [-5.1475298585355107, -16.215539987468492, 6.8612990623305103, -18.357444479839728], [4.1694882026791129, 0.31003375015792717, 6.2052677934347074, -18.27771250557068]], [[5.753370623933491, -1.3735269427402785, 9.947330312604274, -8.2283092119504264], [1.4802733796476881, 8.3106207653820228, -6.1250640356231392, -10.095494814878659], [-17.932072464006065, 10.213288057984194, 9.6921946347836005, 4.7712462660838089]]], [[[-12.475668558412432, -17.405649075135688, -8.4664893922387598, -12.070890014125325], [7.8487909682557282, -10.80026410464507, -15.619167856781525, 2.7223032660145061], [-14.992411847417884, 17.802493372372791, -5.9046542486134737, -4.9894673457699161]], [[-9.3610448433105873, 14.611169205765981, -9.4868917262874675, 12.589796434712371], [2.9631399582934548, -6.7781107400101064, -16.301631196256576, 17.845816015294734], [-18.169663657162346, -9.1274161195937573, -16.727926428843457, -9.3240271137605752]]]])
1431        self.failUnless(isinstance(res,Symbol),"wrong type of result.")        self.failUnless(isinstance(res,Symbol),"wrong type of result.")
1432        self.failUnlessEqual(res.getShape(),(3, 2, 3, 4),"wrong shape of result.")        self.failUnlessEqual(res.getShape(),(3, 2, 3, 4),"wrong shape of result.")
# Line 1717  class Test_util_overloaded_binary_still_ Line 1439  class Test_util_overloaded_binary_still_
1439        res=arg0*arg1        res=arg0*arg1
1440        s1=numarray.array(-1.23860498141)        s1=numarray.array(-1.23860498141)
1441        sub=res.substitute({arg1:s1})        sub=res.substitute({arg1:s1})
1442        msk_ref=whereNegative(self.functionspace.getX()[0]-0.5)        msk_ref=1.-whereZero(self.functionspace.getX()[0],1.e-8)
1443        ref=msk_ref*numarray.array([-2.2299183579697544, -3.8532611324133779])+(1.-msk_ref)*numarray.array([0.071716238902929969, -0.67400697222367489])        ref=msk_ref*numarray.array([-2.2299183579697544, -3.8532611324133779])+(1.-msk_ref)*numarray.array([0.071716238902929969, -0.67400697222367489])
1444        self.failUnless(isinstance(res,Symbol),"wrong type of result.")        self.failUnless(isinstance(res,Symbol),"wrong type of result.")
1445        self.failUnlessEqual(res.getShape(),(2,),"wrong shape of result.")        self.failUnlessEqual(res.getShape(),(2,),"wrong shape of result.")
# Line 1730  class Test_util_overloaded_binary_still_ Line 1452  class Test_util_overloaded_binary_still_
1452        res=arg0*arg1        res=arg0*arg1
1453        s1=numarray.array([-0.92949574400567592, -1.2179599998896897])        s1=numarray.array([-0.92949574400567592, -1.2179599998896897])
1454        sub=res.substitute({arg1:s1})        sub=res.substitute({arg1:s1})
1455        msk_ref=whereNegative(self.functionspace.getX()[0]-0.5)        msk_ref=1.-whereZero(self.functionspace.getX()[0],1.e-8)
1456        ref=msk_ref*numarray.array([0.73460042153017635, -1.4603139890197456])+(1.-msk_ref)*numarray.array([-3.1499381802216635, -2.4921145086501579])        ref=msk_ref*numarray.array([0.73460042153017635, -1.4603139890197456])+(1.-msk_ref)*numarray.array([-3.1499381802216635, -2.4921145086501579])
1457        self.failUnless(isinstance(res,Symbol),"wrong type of result.")        self.failUnless(isinstance(res,Symbol),"wrong type of result.")
1458        self.failUnlessEqual(res.getShape(),(2,),"wrong shape of result.")        self.failUnlessEqual(res.getShape(),(2,),"wrong shape of result.")
# Line 1743  class Test_util_overloaded_binary_still_ Line 1465  class Test_util_overloaded_binary_still_
1465        res=arg0*arg1        res=arg0*arg1
1466        s1=numarray.array(2.10607695069)        s1=numarray.array(2.10607695069)
1467        sub=res.substitute({arg1:s1})        sub=res.substitute({arg1:s1})
1468        msk_ref=whereNegative(self.functionspace.getX()[0]-0.5)        msk_ref=1.-whereZero(self.functionspace.getX()[0],1.e-8)
1469        ref=msk_ref*numarray.array([[6.3115417917256531, -0.4790254641017731, -7.0935423204623218, 5.4208957733386178, -7.4809939428412591], [8.9569428246464202, 5.3844820505972715, -1.2504780558755719, 0.57217689193258392, 7.5458598343126875], [-7.385228027718342, 6.0385388796403019, -9.4822832603848397, -7.2557623921047183, -1.123972265367853], [6.9644555567263726, 1.9615085942275186, 5.6456813303761022, 1.0462699946498486, -9.8684219048371684]])+(1.-msk_ref)*numarray.array([[-1.8027328915440832, -0.27502415534822766, -0.83987881052595881, -8.6201899329560003, -9.3438794960261902], [5.5358126774666605, -0.60977954141415425, 9.8091987688843929, -1.5973828911781676, 6.0503406573173217], [8.3642746773627188, 10.094329167867425, 3.835654078462837, 5.6910041218650154, 7.3538839566996979], [-8.3250427607485502, -0.82298216409611202, 10.146800651772885, -9.2092604487599345, -9.8623107699953731]])        ref=msk_ref*numarray.array([[6.3115417917256531, -0.4790254641017731, -7.0935423204623218, 5.4208957733386178, -7.4809939428412591], [8.9569428246464202, 5.3844820505972715, -1.2504780558755719, 0.57217689193258392, 7.5458598343126875], [-7.385228027718342, 6.0385388796403019, -9.4822832603848397, -7.2557623921047183, -1.123972265367853], [6.9644555567263726, 1.9615085942275186, 5.6456813303761022, 1.0462699946498486, -9.8684219048371684]])+(1.-msk_ref)*numarray.array([[-1.8027328915440832, -0.27502415534822766, -0.83987881052595881, -8.6201899329560003, -9.3438794960261902], [5.5358126774666605, -0.60977954141415425, 9.8091987688843929, -1.5973828911781676, 6.0503406573173217], [8.3642746773627188, 10.094329167867425, 3.835654078462837, 5.6910041218650154, 7.3538839566996979], [-8.3250427607485502, -0.82298216409611202, 10.146800651772885, -9.2092604487599345, -9.8623107699953731]])
1470        self.failUnless(isinstance(res,Symbol),"wrong type of result.")        self.failUnless(isinstance(res,Symbol),"wrong type of result.")
1471        self.failUnlessEqual(res.getShape(),(4, 5),"wrong shape of result.")        self.failUnlessEqual(res.getShape(),(4, 5),"wrong shape of result.")
# Line 1756  class Test_util_overloaded_binary_still_ Line 1478  class Test_util_overloaded_binary_still_
1478        res=arg0*arg1        res=arg0*arg1
1479        s1=numarray.array([[2.6575119197184351, 0.798780755830788, -4.7246974545048115, -3.594253030805985, 1.5756436650435841], [0.65656829496808733, 0.22663298200663462, 4.5542984252490282, 2.3375554718292921, 2.7227466581468063], [-1.0177447572471587, 1.532657082535188, 2.6217986442668364, 4.1467735088972546, 1.5155361075503855], [-2.6181643161762471, 0.56415045659076313, 3.6099145181301697, -1.4000081350932101, 0.95267578177457679]])        s1=numarray.array([[2.6575119197184351, 0.798780755830788, -4.7246974545048115, -3.594253030805985, 1.5756436650435841], [0.65656829496808733, 0.22663298200663462, 4.5542984252490282, 2.3375554718292921, 2.7227466581468063], [-1.0177447572471587, 1.532657082535188, 2.6217986442668364, 4.1467735088972546, 1.5155361075503855], [-2.6181643161762471, 0.56415045659076313, 3.6099145181301697, -1.4000081350932101, 0.95267578177457679]])
1480        sub=res.substitute({arg1:s1})        sub=res.substitute({arg1:s1})
1481        msk_ref=whereNegative(self.functionspace.getX()[0]-0.5)        msk_ref=1.-whereZero(self.functionspace.getX()[0],1.e-8)
1482        ref=msk_ref*numarray.array([[3.5306845689153685, -2.1312627883288111, -15.541812352931064, -10.33737471163186, 4.5069088220969], [2.6302599498672778, 0.66180496835457081, 9.892603271348559, 7.8967654802351435, -1.5392664701290637], [-2.8628484641474969, -0.84539554973300923, -11.35243333453016, 18.312660324289759, 2.3739049305782052], [-5.6483250889774848, 0.22836226539548773, -10.047043721045087, 2.1261498794140565, -3.417957261864017]])+(1.-msk_ref)*numarray.array([[5.260367358833121, -3.7185439923480388, -17.086027753956419, -17.711449359812622, 7.4234680444816901], [1.6855974846268469, -0.785589537166827, 3.2181932936796902, 1.1938731008992738, 2.1188511721101988], [5.0430071650677997, -2.2360837253220716, -1.5493633519903052, 6.8434560203802217, -0.90988411104533029], [-5.4701294236395936, 2.4389724268900039, -2.027158280413504, -3.0899443142752547, 1.7845727593117799]])        ref=msk_ref*numarray.array([[3.5306845689153685, -2.1312627883288111, -15.541812352931064, -10.33737471163186, 4.5069088220969], [2.6302599498672778, 0.66180496835457081, 9.892603271348559, 7.8967654802351435, -1.5392664701290637], [-2.8628484641474969, -0.84539554973300923, -11.35243333453016, 18.312660324289759, 2.3739049305782052], [-5.6483250889774848, 0.22836226539548773, -10.047043721045087, 2.1261498794140565, -3.417957261864017]])+(1.-msk_ref)*numarray.array([[5.260367358833121, -3.7185439923480388, -17.086027753956419, -17.711449359812622, 7.4234680444816901], [1.6855974846268469, -0.785589537166827, 3.2181932936796902, 1.1938731008992738, 2.1188511721101988], [5.0430071650677997, -2.2360837253220716, -1.5493633519903052, 6.8434560203802217, -0.90988411104533029], [-5.4701294236395936, 2.4389724268900039, -2.027158280413504, -3.0899443142752547, 1.7845727593117799]])
1483        self.failUnless(isinstance(res,Symbol),"wrong type of result.")        self.failUnless(isinstance(res,Symbol),"wrong type of result.")
1484        self.failUnlessEqual(res.getShape(),(4, 5),"wrong shape of result.")        self.failUnlessEqual(res.getShape(),(4, 5),"wrong shape of result.")
# Line 1769  class Test_util_overloaded_binary_still_ Line 1491  class Test_util_overloaded_binary_still_
1491        res=arg0*arg1        res=arg0*arg1
1492        s1=numarray.array(-0.422116691453)        s1=numarray.array(-0.422116691453)
1493        sub=res.substitute({arg1:s1})        sub=res.substitute({arg1:s1})
1494        msk_ref=whereNegative(self.functionspace.getX()[0]-0.5)        msk_ref=1.-whereZero(self.functionspace.getX()[0],1.e-8)
1495        ref=msk_ref*numarray.array([[[0.11164681436744017, -1.1437227150112377], [-0.2074982897720079, -0.48785266669154376]], [[-1.2421401437361563, 0.96476827624502515], [0.020765937229078289, -0.27644765514099601]], [[1.0832710883803918, 0.27359805181627767], [1.9855988172389765, 1.5278117060356851]], [[0.51004459354416765, -1.4350877599033474], [-0.89909017568376171, 0.039710359075749616]], [[1.9579533267701619, 1.9164071790311268], [-0.10806518895313126, 1.0578027661377205]], [[-0.32992406274935349, 1.6403194656131641], [1.2622843327469702, -0.13166367044669411]]])+(1.-msk_ref)*numarray.array([[[-0.59724228055590678, -1.1315470503419538], [1.7068327379441424, -1.7841807511750174]], [[-1.3194062497457233, 2.0774924210974488], [0.16824917784877888, 2.0142831369809828]], [[0.63382548359210156, 1.8316536982639513], [1.8531716676608954, 1.1984792323144307]], [[-0.67139321496560267, -1.9444641678876049], [1.3214444196665345, -0.88862664035176742]], [[0.55313233986365051, 0.95656834615927522], [1.6730133005925627, -1.123282253884367]], [[1.4277473713864239, -0.83409694079570218], [-1.5265466476819478, -2.0239308296843248]]])        ref=msk_ref*numarray.array([[[0.11164681436744017, -1.1437227150112377], [-0.2074982897720079, -0.48785266669154376]], [[-1.2421401437361563, 0.96476827624502515], [0.020765937229078289, -0.27644765514099601]], [[1.0832710883803918, 0.27359805181627767], [1.9855988172389765, 1.5278117060356851]], [[0.51004459354416765, -1.4350877599033474], [-0.89909017568376171, 0.039710359075749616]], [[1.9579533267701619, 1.9164071790311268], [-0.10806518895313126, 1.0578027661377205]], [[-0.32992406274935349, 1.6403194656131641], [1.2622843327469702, -0.13166367044669411]]])+(1.-msk_ref)*numarray.array([[[-0.59724228055590678, -1.1315470503419538], [1.7068327379441424, -1.7841807511750174]], [[-1.3194062497457233, 2.0774924210974488], [0.16824917784877888, 2.0142831369809828]], [[0.63382548359210156, 1.8316536982639513], [1.8531716676608954, 1.1984792323144307]], [[-0.67139321496560267, -1.9444641678876049], [1.3214444196665345, -0.88862664035176742]], [[0.55313233986365051, 0.95656834615927522], [1.6730133005925627, -1.123282253884367]], [[1.4277473713864239, -0.83409694079570218], [-1.5265466476819478, -2.0239308296843248]]])
1496        self.failUnless(isinstance(res,Symbol),"wrong type of result.")        self.failUnless(isinstance(res,Symbol),"wrong type of result.")
1497        self.failUnlessEqual(res.getShape(),(6, 2, 2),"wrong shape of result.")        self.failUnlessEqual(res.getShape(),(6, 2, 2),"wrong shape of result.")
# Line 1782  class Test_util_overloaded_binary_still_ Line 1504  class Test_util_overloaded_binary_still_
1504        res=arg0*arg1        res=arg0*arg1
1505        s1=numarray.array([[[3.7703715218725122, 1.8825293253796147], [-3.5569112589449747, 3.7865091325165103]], [[1.3234025154170119, -1.0706127854081848], [-0.91030140341539401, -4.0779906813336346]], [[2.4564691769773113, -4.2202902733308969], [-1.8831049422439405, 0.41091633330696098]], [[2.5279194148611168, 0.406501938106687], [-0.33008527781400687, -3.1142412235060757]], [[-2.6625713201810175, 2.3132871914260473], [-4.863897694906, 4.1604892545389323]], [[-0.92121754594451399, -3.0027046624253173], [2.5790377788725909, -2.626459339743711]]])        s1=numarray.array([[[3.7703715218725122, 1.8825293253796147], [-3.5569112589449747, 3.7865091325165103]], [[1.3234025154170119, -1.0706127854081848], [-0.91030140341539401, -4.0779906813336346]], [[2.4564691769773113, -4.2202902733308969], [-1.8831049422439405, 0.41091633330696098]], [[2.5279194148611168, 0.406501938106687], [-0.33008527781400687, -3.1142412235060757]], [[-2.6625713201810175, 2.3132871914260473], [-4.863897694906, 4.1604892545389323]], [[-0.92121754594451399, -3.0027046624253173], [2.5790377788725909, -2.626459339743711]]])
1506        sub=res.substitute({arg1:s1})        sub=res.substitute({arg1:s1})
1507        msk_ref=whereNegative(self.functionspace.getX()[0]-0.5)        msk_ref=1.-whereZero(self.functionspace.getX()[0],1.e-8)
1508        ref=msk_ref*numarray.array([[[14.502894961122463, 1.2278477619381107], [-3.9885652346242333, 8.705746690670745]], [[-4.1644900195937034, 3.1147095754765983], [0.68341522360130269, 17.817383296222328]], [[6.4015677754703555, 14.686079593308524], [4.232034427486715, 0.20839157015447368]], [[-4.8089781952947206, -0.43544025775836859], [-1.3251180568739098, 3.6362445602957494]], [[-6.5656829114810957, -7.6858078453893226], [-0.96776122464864589, -2.8617937350698126]], [[-1.9929212996456993, -4.6607610729091382], [10.959093593951833, 12.546701586580348]]])+(1.-msk_ref)*numarray.array([[[13.525125487647125, -2.8124238253222011], [-9.3201733708150698, -12.971834980991126]], [[0.95268142866460237, -3.9570135631362282], [-1.7165209244518427, 3.2711052715447542]], [[4.9924983550597704, 12.891422283435785], [-1.2213857773520564, -1.7291351898596623]], [[3.2513810098112819, 0.009418106351692759], [0.83049572532118243, -8.350755020948105]], [[3.3493975799772628, -10.019961526787521], [13.908434576224618, -9.5659277382281029]], [[0.17721955668497666, 4.5098937271552346], [12.179218148209955, 0.87953893733186228]]])        ref=msk_ref*numarray.array([[[14.502894961122463, 1.2278477619381107], [-3.9885652346242333, 8.705746690670745]], [[-4.1644900195937034, 3.1147095754765983], [0.68341522360130269, 17.817383296222328]], [[6.4015677754703555, 14.686079593308524], [4.232034427486715, 0.20839157015447368]], [[-4.8089781952947206, -0.43544025775836859], [-1.3251180568739098, 3.6362445602957494]], [[-6.5656829114810957, -7.6858078453893226], [-0.96776122464864589, -2.8617937350698126]], [[-1.9929212996456993, -4.6607610729091382], [10.959093593951833, 12.546701586580348]]])+(1.-msk_ref)*numarray.array([[[13.525125487647125, -2.8124238253222011], [-9.3201733708150698, -12.971834980991126]], [[0.95268142866460237, -3.9570135631362282], [-1.7165209244518427, 3.2711052715447542]], [[4.9924983550597704, 12.891422283435785], [-1.2213857773520564, -1.7291351898596623]], [[3.2513810098112819, 0.009418106351692759], [0.83049572532118243, -8.350755020948105]], [[3.3493975799772628, -10.019961526787521], [13.908434576224618, -9.5659277382281029]], [[0.17721955668497666, 4.5098937271552346], [12.179218148209955, 0.87953893733186228]]])
1509        self.failUnless(isinstance(res,Symbol),"wrong type of result.")        self.failUnless(isinstance(res,Symbol),"wrong type of result.")
1510        self.failUnlessEqual(res.getShape(),(6, 2, 2),"wrong shape of result.")        self.failUnlessEqual(res.getShape(),(6, 2, 2),"wrong shape of result.")
# Line 1795  class Test_util_overloaded_binary_still_ Line 1517  class Test_util_overloaded_binary_still_
1517        res=arg0*arg1        res=arg0*arg1
1518        s1=numarray.array(0.717965207903)        s1=numarray.array(0.717965207903)
1519        sub=res.substitute({arg1:s1})        sub=res.substitute({arg1:s1})
1520        msk_ref=whereNegative(self.functionspace.getX()[0]-0.5)        msk_ref=1.-whereZero(self.functionspace.getX()[0],1.e-8)
1521        ref=msk_ref*numarray.array([[[[-0.51382339801631816, 2.7100021501484619, -1.350726738523665, -3.0323025403715427], [-3.2439885912315676, 0.64620265396188303, -3.0915331855279722, 1.5669253265579597], [-2.3268616507127589, 1.0232901572442055, -0.7440960504300036, -3.3412966169236569]], [[-0.015192184007276179, -0.48361063343539723, -0.16799296376949385, -2.3214387043033553], [-3.1117212647398351, 1.3406495324431462, 2.438233786416474, 0.86397232106270994], [-2.9128283314443832, -0.67529008376584743, -1.2898290041654794, 1.4134439250790429]]], [[[1.080347620167597, 0.36305548193114656, 1.7300509199223877, -1.5077578521533153], [-2.9184479681312658, -1.5275239736231971, -0.44947061868890531, 1.7813282511207205], [2.3368934663398959, 2.8662393990196935, 1.2329823705524707, -1.6304800089652003]], [[-0.74189940448410086, 3.3689118307816321, -3.0289098291289465, -0.18667978447841244], [2.9095042944301057, 2.2637078175116527, 2.7922890059647112, 3.5276685049395078], [-1.6241318790748014, -1.0210851747097522, 2.0554193241418712, 1.7848893612164991]]], [[[1.0841363808970814, -1.6504893683335269, -2.1062609118572939, -1.8761629480337436], [-2.0802894030884849, -0.61326619216028622, 3.1284049211184035, 3.037562314540097], [-0.089195363932689647, -3.3575783599208848, -1.1328583368377678, 0.08085115172692571]], [[-2.9749892795677022, -0.55031284166088568, 1.5191552747991404, -2.3359871321986905], [-1.6409988403673095, 2.6601139126172866, 1.5953403162639133, 0.70607262660183523], [1.7848707876394252, -2.2445201726558786, -2.7502278720763003, 2.2874605217258854]]]])+(1.-msk_ref)*numarray.array([[[[1.7295227328719085, -1.9319061898166923, -0.18677750447340177, -2.8155589190091503], [2.8784365234748241, 1.9706407975713816, 3.383897487652936, -3.1798688666551458], [-1.2264565134062644, -0.356538293687512, 2.8340030243311856, -1.1604243647929684]], [[-2.7459603621904449, -1.924175899646795, 2.8821282088880955, 1.5895329566247054], [-1.7981276507231641, -1.2168866578518498, 0.29897621218834564, 2.3018113563323048], [-2.5189173861531855, -1.532547645549204, 1.0360414584772961, 0.88267110424690254]]], [[[2.5219695601663243, 2.7533160203819742, -1.1145659290786001, -0.89101889190998895], [-1.5561597050922877, 2.4201592782474872, 0.40282072952090631, 1.6331873092471489], [-1.4875865800916528, 1.2449446736119429, -0.036250678022026972, -2.6793187566430881]], [[1.0587408447256197, 2.8738120345122611, 2.0163019367076376, 2.1104143768017321], [-3.3076061564825183, -3.473407267087782, 1.1751082297410078, -1.1039597002996688], [-1.9255328696923644, 0.82684994997116834, -2.6128727412832053, 2.5931825775035184]]], [[[1.3911194669720908, 2.1135733996881303, 0.41398398819427723, 0.36689849446726314], [-2.1805132972775692, 3.2465894558060273, -1.4841016329570593, 2.0204020001890131], [-0.97964485587718853, -1.9463049031696793, -1.5641927422961792, 2.0158993695091798]], [[2.8883031427173891, 3.386272476673903, -0.12507878329731756, -2.7513160138682586], [-3.4739158208065777, -3.0598260472046448, -3.2865086943851498, -1.6918756805445263], [-3.0830574538274456, -2.7283126882399662, 0.7992262430365179, 1.3018450797125141]]]])        ref=msk_ref*numarray.array([[[[-0.51382339801631816, 2.7100021501484619, -1.350726738523665, -3.0323025403715427], [-3.2439885912315676, 0.64620265396188303, -3.0915331855279722, 1.5669253265579597], [-2.3268616507127589, 1.0232901572442055, -0.7440960504300036, -3.3412966169236569]], [[-0.015192184007276179, -0.48361063343539723, -0.16799296376949385, -2.3214387043033553], [-3.1117212647398351, 1.3406495324431462, 2.438233786416474, 0.86397232106270994], [-2.9128283314443832, -0.67529008376584743, -1.2898290041654794, 1.4134439250790429]]], [[[1.080347620167597, 0.36305548193114656, 1.7300509199223877, -1.5077578521533153], [-2.9184479681312658, -1.5275239736231971, -0.44947061868890531, 1.7813282511207205], [2.3368934663398959, 2.8662393990196935, 1.2329823705524707, -1.6304800089652003]], [[-0.74189940448410086, 3.3689118307816321, -3.0289098291289465, -0.18667978447841244], [2.9095042944301057, 2.2637078175116527, 2.7922890059647112, 3.5276685049395078], [-1.6241318790748014, -1.0210851747097522, 2.0554193241418712, 1.7848893612164991]]], [[[1.0841363808970814, -1.6504893683335269, -2.1062609118572939, -1.8761629480337436], [-2.0802894030884849, -0.61326619216028622, 3.1284049211184035, 3.037562314540097], [-0.089195363932689647, -3.3575783599208848, -1.1328583368377678, 0.08085115172692571]], [[-2.9749892795677022, -0.55031284166088568, 1.5191552747991404, -2.3359871321986905], [-1.6409988403673095, 2.6601139126172866, 1.5953403162639133, 0.70607262660183523], [1.7848707876394252, -2.2445201726558786, -2.7502278720763003, 2.2874605217258854]]]])+(1.-msk_ref)*numarray.array([[[[1.7295227328719085, -1.9319061898166923, -0.18677750447340177, -2.8155589190091503], [2.8784365234748241, 1.9706407975713816, 3.383897487652936, -3.1798688666551458], [-1.2264565134062644, -0.356538293687512, 2.8340030243311856, -1.1604243647929684]], [[-2.7459603621904449, -1.924175899646795, 2.8821282088880955, 1.5895329566247054], [-1.7981276507231641, -1.2168866578518498, 0.29897621218834564, 2.3018113563323048], [-2.5189173861531855, -1.532547645549204, 1.0360414584772961, 0.88267110424690254]]], [[[2.5219695601663243, 2.7533160203819742, -1.1145659290786001, -0.89101889190998895], [-1.5561597050922877, 2.4201592782474872, 0.40282072952090631, 1.6331873092471489], [-1.4875865800916528, 1.2449446736119429, -0.036250678022026972, -2.6793187566430881]], [[1.0587408447256197, 2.8738120345122611, 2.0163019367076376, 2.1104143768017321], [-3.3076061564825183, -3.473407267087782, 1.1751082297410078, -1.1039597002996688], [-1.9255328696923644, 0.82684994997116834, -2.6128727412832053, 2.5931825775035184]]], [[[1.3911194669720908, 2.1135733996881303, 0.41398398819427723, 0.36689849446726314], [-2.1805132972775692, 3.2465894558060273, -1.4841016329570593, 2.0204020001890131], [-0.97964485587718853, -1.9463049031696793, -1.5641927422961792, 2.0158993695091798]], [[2.8883031427173891, 3.386272476673903, -0.12507878329731756, -2.7513160138682586], [-3.4739158208065777, -3.0598260472046448, -3.2865086943851498, -1.6918756805445263], [-3.0830574538274456, -2.7283126882399662, 0.7992262430365179, 1.3018450797125141]]]])
1522        self.failUnless(isinstance(res,Symbol),"wrong type of result.")        self.failUnless(isinstance(res,Symbol),"wrong type of result.")
1523        self.failUnlessEqual(res.getShape(),(3, 2, 3, 4),"wrong shape of result.")        self.failUnlessEqual(res.getShape(),(3, 2, 3, 4),"wrong shape of result.")
# Line 1808  class Test_util_overloaded_binary_still_ Line 1530  class Test_util_overloaded_binary_still_
1530        res=arg0*arg1        res=arg0*arg1
1531        s1=numarray.array([[[[0.6868381582863794, 0.54627711634776066, -3.2186962400562225, -1.0774604195563131], [-1.8950462499252776, -3.9532997580259446, 0.94174368416758636, -1.45380459144517], [2.0866672501914945, 4.3633150084832497, -4.2883759710766967, 1.1324613195015356]], [[-1.6473475256931112, -2.4240842974365195, 3.0575003656751942, -0.88291292348152517], [-0.26167034327218541, -0.11708643329371515, 2.69348684719085, -4.9379016274841749], [0.9686171163405044, 4.8295378077612252, 3.7003121978510229, 4.056897346655898]]], [[[-1.6908031207422525, 4.8230189206260157, 0.82952788955472112, 3.4446585748455014], [3.3176619789094879, 3.0037317679930418, 1.4804656022305664, 1.0055708904902172], [0.88162105416707792, -0.50313800229601746, 3.9994903610131427, 4.5365056130602301]], [[-4.8084467422206547, -0.19193357971699321, -3.9848748508964316, -3.0854097037447001], [-1.4115589742338477, 1.453415069972718, 3.991034445603626, -4.9809560423233554], [0.17116217177604565, 3.3177075206574909, 1.7537041099136621, -1.9103533234598826]]], [[[2.5308867325681046, -1.042247247233361, -1.1846149285407979, 3.7060742981010737], [-1.297359352173022, 4.2498337462445868, 1.493118867126439, 3.1157447558047586], [0.15917981571003992, -4.2811882943532051, -2.892893263308518, -0.15525299846753171]], [[0.70528939883089059, -3.5415574610175469, 0.91408910363181572, -4.9096466754450141], [3.8808985862028376, -2.4998339203436348, -0.7493422147604818, -2.7415281675633221], [-2.6740604084639994, 1.5889649415442406, -3.0729275401598812, -3.7916787182652412]]]])        s1=numarray.array([[[[0.6868381582863794, 0.54627711634776066, -3.2186962400562225, -1.0774604195563131], [-1.8950462499252776, -3.9532997580259446, 0.94174368416758636, -1.45380459144517], [2.0866672501914945, 4.3633150084832497, -4.2883759710766967, 1.1324613195015356]], [[-1.6473475256931112, -2.4240842974365195, 3.0575003656751942, -0.88291292348152517], [-0.26167034327218541, -0.11708643329371515, 2.69348684719085, -4.9379016274841749], [0.9686171163405044, 4.8295378077612252, 3.7003121978510229, 4.056897346655898]]], [[[-1.6908031207422525, 4.8230189206260157, 0.82952788955472112, 3.4446585748455014], [3.3176619789094879, 3.0037317679930418, 1.4804656022305664, 1.0055708904902172], [0.88162105416707792, -0.50313800229601746, 3.9994903610131427, 4.5365056130602301]], [[-4.8084467422206547, -0.19193357971699321, -3.9848748508964316, -3.0854097037447001], [-1.4115589742338477, 1.453415069972718, 3.991034445603626, -4.9809560423233554], [0.17116217177604565, 3.3177075206574909, 1.7537041099136621, -1.9103533234598826]]], [[[2.5308867325681046, -1.042247247233361, -1.1846149285407979, 3.7060742981010737], [-1.297359352173022, 4.2498337462445868, 1.493118867126439, 3.1157447558047586], [0.15917981571003992, -4.2811882943532051, -2.892893263308518, -0.15525299846753171]], [[0.70528939883089059, -3.5415574610175469, 0.91408910363181572, -4.9096466754450141], [3.8808985862028376, -2.4998339203436348, -0.7493422147604818, -2.7415281675633221], [-2.6740604084639994, 1.5889649415442406, -3.0729275401598812, -3.7916787182652412]]]])
1532        sub=res.substitute({arg1:s1})        sub=res.substitute({arg1:s1})
1533        msk_ref=whereNegative(self.functionspace.getX()[0]-0.5)        msk_ref=1.-whereZero(self.functionspace.getX()[0],1.e-8)
1534        ref=msk_ref*numarray.array([[[[2.0090822894427993, -2.7124858421931139, -0.96836475835178126, 0.3238978397067413], [4.7641057027263036, 15.356469115209322, -2.061662642117656, -6.562625456773401], [-4.6668582162192029, 8.0903141424262, -1.1189299299060254, -1.2665823552745537]], [[-3.0070734760004947, -9.4342525180294281, -9.2584252273842349, -2.7114134793590052], [0.84855946551469918, -0.23571754026667907, 5.3813997896526438, -20.606830883627179], [-0.64931485257841604, -9.6991197608586983, -17.715009990674201, 16.634756638713682]]], [[[1.9876848644362788, -8.8461294682679377, 2.0599533040300941, 3.0738352724669484], [-5.7627329081984522, 5.4922551255024175, -0.40496650907269482, 4.8500525280070113], [0.087742741052748138, -0.61050231454407089, -18.674538525238951, -20.332033570982652]], [[-18.736980336078339, 0.090224051608984959, -7.8265826975130048, -14.918547731118739], [-3.0484834062368544, 4.9989235409822532, 11.35952640798204, 8.9719649100247967], [0.071710601287329825, -14.224428057977713, -0.66194795753096181, 5.108460871613123]]], [[[1.2334105747390316, -5.1860217243322069, 2.4328397786485927, -4.629653480222637], [1.050980717527584, -0.13744197138935588, -4.0947223559985781, -13.014291841725987], [-0.66356095792037362, -12.889128679761718, 10.190317019204748, -0.60864297055611438]], [[-2.6690287016020968, -16.834758078342482, 4.3790342868285039, -24.202574957127123], [0.86810285165369627, -2.7788927376642603, 3.4554490178896384, -12.177018993055025], [2.1023906134884078, 2.4439723034008711, -13.877480957101886, 14.182930630179902]]]])+(1.-msk_ref)*numarray.array([[[[3.0113280542199465, -0.90025075885739858, -3.5176021783907041, 0.30025823205054236], [3.5123576464773363, 2.3959754790373493, 3.5689085831507947, -2.4387143505360127], [-4.5307613983952022, -4.2459520117298588, 9.5902339496154969, 3.4176636848536646]], [[-5.922049778516727, 10.86621388347861, 13.608113750703422, 0.13170480308403179], [-0.74991472483682653, -0.076824482901260024, -9.4579997542208236, 11.187823767842159], [-3.282192872812852, -20.262395804553826, 0.73540426902211176, 3.1334614243985466]]], [[[-6.1684504326080232, 19.867315661446234, 3.9135391265494457, 11.25669626921629], [-13.210129880150486, 11.856336061073677, -3.3294557689967741, 0.35832155842535174], [0.27001061779106766, -0.58035091979845577, 10.695947356351342, 13.332596454925692]], [[-9.2813238562468232, 0.6859935779052545, -3.4482639243184217, -11.457176901097965], [1.0643149425401714, -3.9013400316202884, -12.065093446111812, -9.5404386832200192], [0.20160140002551957, 0.39123422170360572, 7.9160655295443281, -5.3755659751229006]]], [[[-11.180494182182111, 5.0612114481650323, -5.426389984575974, -2.9740490540264393], [4.5323058977990254, 4.5774506556220018, 5.0449546985677118, 6.8641480138584354], [0.62462175972042311, 2.4872322049381017, 3.7512305527917205, -0.27636112765281257]], [[-0.13986843034333699, 12.46630312012565, 0.70275415467140356, 17.410562133681889], [10.092520700006713, -11.98457377122277, -3.7311636912234754, 6.5362289327304204], [-2.095876782493292, 1.1581730360816256, 1.2242572954381448, -8.7721139535984367]]]])        ref=msk_ref*numarray.array([[[[2.0090822894427993, -2.7124858421931139, -0.96836475835178126, 0.3238978397067413], [4.7641057027263036, 15.356469115209322, -2.061662642117656, -6.562625456773401], [-4.6668582162192029, 8.0903141424262, -1.1189299299060254, -1.2665823552745537]], [[-3.0070734760004947, -9.4342525180294281, -9.2584252273842349, -2.7114134793590052], [0.84855946551469918, -0.23571754026667907, 5.3813997896526438, -20.606830883627179], [-0.64931485257841604, -9.6991197608586983, -17.715009990674201, 16.634756638713682]]], [[[1.9876848644362788, -8.8461294682679377, 2.0599533040300941, 3.0738352724669484], [-5.7627329081984522, 5.4922551255024175, -0.40496650907269482, 4.8500525280070113], [0.087742741052748138, -0.61050231454407089, -18.674538525238951, -20.332033570982652]], [[-18.736980336078339, 0.090224051608984959, -7.8265826975130048, -14.918547731118739], [-3.0484834062368544, 4.9989235409822532, 11.35952640798204, 8.9719649100247967], [0.071710601287329825, -14.224428057977713, -0.66194795753096181, 5.108460871613123]]], [[[1.2334105747390316, -5.1860217243322069, 2.4328397786485927, -4.629653480222637], [1.050980717527584, -0.13744197138935588, -4.0947223559985781, -13.014291841725987], [-0.66356095792037362, -12.889128679761718, 10.190317019204748, -0.60864297055611438]], [[-2.6690287016020968, -16.834758078342482, 4.3790342868285039, -24.202574957127123], [0.86810285165369627, -2.7788927376642603, 3.4554490178896384, -12.177018993055025], [2.1023906134884078, 2.4439723034008711, -13.877480957101886, 14.182930630179902]]]])+(1.-msk_ref)*numarray.array([[[[3.0113280542199465, -0.90025075885739858, -3.5176021783907041, 0.30025823205054236], [3.5123576464773363, 2.3959754790373493, 3.5689085831507947, -2.4387143505360127], [-4.5307613983952022, -4.2459520117298588, 9.5902339496154969, 3.4176636848536646]], [[-5.922049778516727, 10.86621388347861, 13.608113750703422, 0.13170480308403179], [-0.74991472483682653, -0.076824482901260024, -9.4579997542208236, 11.187823767842159], [-3.282192872812852, -20.262395804553826, 0.73540426902211176, 3.1334614243985466]]], [[[-6.1684504326080232, 19.867315661446234, 3.9135391265494457, 11.25669626921629], [-13.210129880150486, 11.856336061073677, -3.3294557689967741, 0.35832155842535174], [0.27001061779106766, -0.58035091979845577, 10.695947356351342, 13.332596454925692]], [[-9.2813238562468232, 0.6859935779052545, -3.4482639243184217, -11.457176901097965], [1.0643149425401714, -3.9013400316202884, -12.065093446111812, -9.5404386832200192], [0.20160140002551957, 0.39123422170360572, 7.9160655295443281, -5.3755659751229006]]], [[[-11.180494182182111, 5.0612114481650323, -5.426389984575974, -2.9740490540264393], [4.5323058977990254, 4.5774506556220018, 5.0449546985677118, 6.8641480138584354], [0.62462175972042311, 2.4872322049381017, 3.7512305527917205, -0.27636112765281257]], [[-0.13986843034333699, 12.46630312012565, 0.70275415467140356, 17.410562133681889], [10.092520700006713, -11.98457377122277, -3.7311636912234754, 6.5362289327304204], [-2.095876782493292, 1.1581730360816256, 1.2242572954381448, -8.7721139535984367]]]])
1535        self.failUnless(isinstance(res,Symbol),"wrong type of result.")        self.failUnless(isinstance(res,Symbol),"wrong type of result.")
1536        self.failUnlessEqual(res.getShape(),(3, 2, 3, 4),"wrong shape of result.")        self.failUnlessEqual(res.getShape(),(3, 2, 3, 4),"wrong shape of result.")
# Line 2133  class Test_util_overloaded_binary_still_ Line 1855  class Test_util_overloaded_binary_still_
1855        res=arg0/arg1        res=arg0/arg1
1856        s1=numarray.array(-3.74029681078)        s1=numarray.array(-3.74029681078)
1857        sub=res.substitute({arg1:s1})        sub=res.substitute({arg1:s1})
1858        msk_ref=whereNegative(self.functionspace.getX()[0]-0.5)        msk_ref=1.-whereZero(self.functionspace.getX()[0],1.e-8)
1859        ref=msk_ref*(1.11467581688)+(1.-msk_ref)*(-1.10440155158)        ref=msk_ref*(1.11467581688)+(1.-msk_ref)*(-1.10440155158)
1860        self.failUnless(isinstance(res,Symbol),"wrong type of result.")        self.failUnless(isinstance(res,Symbol),"wrong type of result.")
1861        self.failUnlessEqual(res.getShape(),(),"wrong shape of result.")        self.failUnlessEqual(res.getShape(),(),"wrong shape of result.")
# Line 2146  class Test_util_overloaded_binary_still_ Line 1868  class Test_util_overloaded_binary_still_
1868        res=arg0/arg1        res=arg0/arg1
1869        s1=numarray.array([-0.38687332266391294, 1.9399003858649468])        s1=numarray.array([-0.38687332266391294, 1.9399003858649468])
1870        sub=res.substitute({arg1:s1})        sub=res.substitute({arg1:s1})
1871        msk_ref=whereNegative(self.functionspace.getX()[0]-0.5)        msk_ref=1.-whereZero(self.functionspace.getX()[0],1.e-8)
1872        ref=msk_ref*numarray.array([-2.3105599113962496, 0.4607937586121677])+(1.-msk_ref)*numarray.array([-1.4667128485410923, 0.29250577877272954])        ref=msk_ref*numarray.array([-2.3105599113962496, 0.4607937586121677])+(1.-msk_ref)*numarray.array([-1.4667128485410923, 0.29250577877272954])
1873        self.failUnless(isinstance(res,Symbol),"wrong type of result.")        self.failUnless(isinstance(res,Symbol),"wrong type of result.")
1874        self.failUnlessEqual(res.getShape(),(2,),"wrong shape of result.")        self.failUnlessEqual(res.getShape(),(2,),"wrong shape of result.")
# Line 2159  class Test_util_overloaded_binary_still_ Line 1881  class Test_util_overloaded_binary_still_
1881        res=arg0/arg1        res=arg0/arg1
1882        s1=numarray.array([[4.4998386312884939, 0.78446231481643913, -1.6813079285045305, -3.1798436625479907, -2.0944868186665833], [4.4953342126454849, 1.6650442515799515, -0.91898434961724451, -1.1670746485185877, 4.5503544844109296], [1.9273082092830283, 1.6079265632411186, 2.6574428427115047, -3.0448375461618085, 3.5797303717654643], [-0.075958261118915793, -1.5548980284162739, 3.7360078828652803, -1.3318521748477563, 2.4342937381441239]])        s1=numarray.array([[4.4998386312884939, 0.78446231481643913, -1.6813079285045305, -3.1798436625479907, -2.0944868186665833], [4.4953342126454849, 1.6650442515799515, -0.91898434961724451, -1.1670746485185877, 4.5503544844109296], [1.9273082092830283, 1.6079265632411186, 2.6574428427115047, -3.0448375461618085, 3.5797303717654643], [-0.075958261118915793, -1.5548980284162739, 3.7360078828652803, -1.3318521748477563, 2.4342937381441239]])
1883        sub=res.substitute({arg1:s1})        sub=res.substitute({arg1:s1})
1884        msk_ref=whereNegative(self.functionspace.getX()[0]-0.5)        msk_ref=1.-whereZero(self.functionspace.getX()[0],1.e-8)
1885        ref=msk_ref*numarray.array([[1.0531607556532867, 6.0411486488736692, -2.8186707341949422, -1.4903416507741973, -2.2626322643857333], [1.0542160446968702, 2.8462027052727157, -5.15683804106071, -4.0606258213740682, 1.0414690700430431], [2.4588975600371681, 2.9473071479664283, 1.783313408317817, -1.5564224302276781, 1.3238576543708847], [-62.39023094310253, -3.0478226653052989, 1.2684805819015268, -3.5582428311065093, 1.9467878419876474]])+(1.-msk_ref)*numarray.array([[-0.9237148925791, -5.2986203153641043, 2.472222897099563, 1.3071611057108705, 1.9845281053476089], [-0.92464047416795137, -2.4963708646060252, 4.5230018984057123, 3.5615270738680049, -0.91346025285808652], [-2.1566700841637609, -2.5850483802851589, -1.5641231830532274, 1.3651197789397753, -1.1611399536423701], [54.721736605010705, 2.6732093564730848, -1.1125693757198694, 3.1208928711619754, -1.7075046831007554]])        ref=msk_ref*numarray.array([[1.0531607556532867, 6.0411486488736692, -2.8186707341949422, -1.4903416507741973, -2.2626322643857333], [1.0542160446968702, 2.8462027052727157, -5.15683804106071, -4.0606258213740682, 1.0414690700430431], [2.4588975600371681, 2.9473071479664283, 1.783313408317817, -1.5564224302276781, 1.3238576543708847], [-62.39023094310253, -3.0478226653052989, 1.2684805819015268, -3.5582428311065093, 1.9467878419876474]])+(1.-msk_ref)*numarray.array([[-0.9237148925791, -5.2986203153641043, 2.472222897099563, 1.3071611057108705, 1.9845281053476089], [-0.92464047416795137, -2.4963708646060252, 4.5230018984057123, 3.5615270738680049, -0.91346025285808652], [-2.1566700841637609, -2.5850483802851589, -1.5641231830532274, 1.3651197789397753, -1.1611399536423701], [54.721736605010705, 2.6732093564730848, -1.1125693757198694, 3.1208928711619754, -1.7075046831007554]])
1886        self.failUnless(isinstance(res,Symbol),"wrong type of result.")        self.failUnless(isinstance(res,Symbol),"wrong type of result.")
1887        self.failUnlessEqual(res.getShape(),(4, 5),"wrong shape of result.")        self.failUnlessEqual(res.getShape(),(4, 5),"wrong shape of result.")
# Line 2172  class Test_util_overloaded_binary_still_ Line 1894  class Test_util_overloaded_binary_still_
1894        res=arg0/arg1        res=arg0/arg1
1895        s1=numarray.array([[[1.740883116607046, -2.2503321522792152], [-1.5061945225102802, 2.4982952052110088]], [[-2.7983305802801484, 2.1687543854796365], [1.643320759290833, -1.4653409727441757]], [[3.2175020834207952, 3.7650334271118187], [1.8014810554950147, 0.12236435291525538]], [[-3.1233989028943911, 0.7696710585002986], [-4.2753667310345724, 0.88632267436679513]], [[-4.5134534247108533, 2.7836276968220837], [-1.1959116036265316, -0.39370816860750679]], [[1.5027698132905005, -2.504876271197424], [-4.7995705146222427, 0.81056999509517258]]])        s1=numarray.array([[[1.740883116607046, -2.2503321522792152], [-1.5061945225102802, 2.4982952052110088]], [[-2.7983305802801484, 2.1687543854796365], [1.643320759290833, -1.4653409727441757]], [[3.2175020834207952, 3.7650334271118187], [1.8014810554950147, 0.12236435291525538]], [[-3.1233989028943911, 0.7696710585002986], [-4.2753667310345724, 0.88632267436679513]], [[-4.5134534247108533, 2.7836276968220837], [-1.1959116036265316, -0.39370816860750679]], [[1.5027698132905005, -2.504876271197424], [-4.7995705146222427, 0.81056999509517258]]])
1896        sub=res.substitute({arg1:s1})        sub=res.substitute({arg1:s1})
1897        msk_ref=whereNegative(self.functionspace.getX()[0]-0.5)        msk_ref=1.-whereZero(self.functionspace.getX()[0],1.e-8)
1898        ref=msk_ref*numarray.array([[[2.7502579175572066, -2.1276315010390197], [-3.1787909884378931, 1.9164578969705082]], [[-1.7109763974029355, 2.2076624292018749], [2.9135380587879744, -3.2674153415800777]], [[1.4880728748121901, 1.2716693404400943], [2.6577451705005974, 39.128042284553942]], [[-1.532906210139654, 6.2206802790783859], [-1.1198752940269061, 5.4019576768818869]], [[-1.0608013696955167, 1.7200136284231737], [-4.003538021097242, -12.160981043203339]], [[3.1860352348351633, -1.9114227836496733], [-0.9975637529240533, 5.9068033654860717]]])+(1.-msk_ref)*numarray.array([[[-1.889712439158538, 1.4619035137730338], [2.1841591052200662, -1.3168053453857391]], [[1.1756182431612747, -1.5168930620264134], [-2.0019028311874436, 2.2450532277225537]], [[-1.0224604041517171, -0.87376873121071352], [-1.8261465867424562, -26.885023311092727]], [[1.0532655555218566, -4.2742525449554005], [0.76947047763019516, -3.7117052014083791]], [[0.72888056461647699, -1.1818277581909278], [2.7508458573337604, 8.3558552828834873]], [[-2.1891366538499089, 1.3133457003051041], [0.68542976304877656, -4.0585865507976919]]])        ref=msk_ref*numarray.array([[[2.7502579175572066, -2.1276315010390197], [-3.1787909884378931, 1.9164578969705082]], [[-1.7109763974029355, 2.2076624292018749], [2.9135380587879744, -3.2674153415800777]], [[1.4880728748121901, 1.2716693404400943], [2.6577451705005974, 39.128042284553942]], [[-1.532906210139654, 6.2206802790783859], [-1.1198752940269061, 5.4019576768818869]], [[-1.0608013696955167, 1.7200136284231737], [-4.003538021097242, -12.160981043203339]], [[3.1860352348351633, -1.9114227836496733], [-0.9975637529240533, 5.9068033654860717]]])+(1.-msk_ref)*numarray.array([[[-1.889712439158538, 1.4619035137730338], [2.1841591052200662, -1.3168053453857391]], [[1.1756182431612747, -1.5168930620264134], [-2.0019028311874436, 2.2450532277225537]], [[-1.0224604041517171, -0.87376873121071352], [-1.8261465867424562, -26.885023311092727]], [[1.0532655555218566, -4.2742525449554005], [0.76947047763019516, -3.7117052014083791]], [[0.72888056461647699, -1.1818277581909278], [2.7508458573337604, 8.3558552828834873]], [[-2.1891366538499089, 1.3133457003051041], [0.68542976304877656, -4.0585865507976919]]])
1899        self.failUnless(isinstance(res,Symbol),"wrong type of result.")        self.failUnless(isinstance(res,Symbol),"wrong type of result.")
1900        self.failUnlessEqual(res.getShape(),(6, 2, 2),"wrong shape of result.")        self.failUnlessEqual(res.getShape(),(6, 2, 2),"wrong shape of result.")
# Line 2185  class Test_util_overloaded_binary_still_ Line 1907  class Test_util_overloaded_binary_still_
1907        res=arg0/arg1        res=arg0/arg1
1908        s1=numarray.array([[[[0.53229011632207346, -3.0692416214850793, 4.1551847515535112, 1.9956228948074202], [2.6857183881485671, 2.8513187715775192, 2.8150572483190999, 1.8695234954963702], [-0.89878809174293561, 2.0113600086339014, 1.3054601278816813, 1.3445035108068506]], [[2.3491180092357453, -0.60141647759364947, -2.7471836719998368, 2.7627957847036289], [4.5424699426220343, -3.5606662061522512, 4.2638313458612025, -2.7733238430403837], [0.74945623900841163, -1.8138683468323045, -4.0112916371182106, -1.0801639118432984]]], [[[-3.2970678697848332, -1.0955509383278814, -4.1774865059518689, -0.0073839501556669518], [3.4766781803964601, 2.9172484094685416, 1.016230261992658, 3.9024189052964413], [-4.0414297442027198, 2.9788951120154019, 3.2762553730841475, 2.115591154300632]], [[2.9124374952334513, -1.4781274260861421, 4.8479887494343945, -4.3582251786045347], [2.0756121461581953, -2.2517472797592286, 2.3516485621871688, 1.7775284781206064], [3.4727084749786208, 3.8831969404469557, -4.1994122244787384, -4.1535329385031163]]], [[[3.8977522324001956, -4.4938918457123735, 0.012474134731923492, -0.027833866034599808], [0.81441408850560748, 0.26774810790526793, -1.1937582797303259, -2.6618906938268347], [4.1680717142998951, -2.6383819679851594, 2.73950628932384, 1.8380370529340837]], [[0.47796984802075215, -1.5175649986704984, -4.2513663435369313, 3.4215268334350561], [-1.6384162411134087, -3.5293107080529076, -4.9362183918195077, 2.0866175314723741], [0.68432046227346, 2.8697679941819176, 1.3674204155349967, -2.6241647447917482]]]])        s1=numarray.array([[[[0.53229011632207346, -3.0692416214850793, 4.1551847515535112, 1.9956228948074202], [2.6857183881485671, 2.8513187715775192, 2.8150572483190999, 1.8695234954963702], [-0.89878809174293561, 2.0113600086339014, 1.3054601278816813, 1.3445035108068506]], [[2.3491180092357453, -0.60141647759364947, -2.7471836719998368, 2.7627957847036289], [4.5424699426220343, -3.5606662061522512, 4.2638313458612025, -2.7733238430403837], [0.74945623900841163, -1.8138683468323045, -4.0112916371182106, -1.0801639118432984]]], [[[-3.2970678697848332, -1.0955509383278814, -4.1774865059518689, -0.0073839501556669518], [3.4766781803964601, 2.9172484094685416, 1.016230261992658, 3.9024189052964413], [-4.0414297442027198, 2.9788951120154019, 3.2762553730841475, 2.115591154300632]], [[2.9124374952334513, -1.4781274260861421, 4.8479887494343945, -4.3582251786045347], [2.0756121461581953, -2.2517472797592286, 2.3516485621871688, 1.7775284781206064], [3.4727084749786208, 3.8831969404469557, -4.1994122244787384, -4.1535329385031163]]], [[[3.8977522324001956, -4.4938918457123735, 0.012474134731923492, -0.027833866034599808], [0.81441408850560748, 0.26774810790526793, -1.1937582797303259, -2.6618906938268347], [4.1680717142998951, -2.6383819679851594, 2.73950628932384, 1.8380370529340837]], [[0.47796984802075215, -1.5175649986704984, -4.2513663435369313, 3.4215268334350561], [-1.6384162411134087, -3.5293107080529076, -4.9362183918195077, 2.0866175314723741], [0.68432046227346, 2.8697679941819176, 1.3674204155349967, -2.6241647447917482]]]])
1909        sub=res.substitute({arg1:s1})        sub=res.substitute({arg1:s1})
1910        msk_ref=whereNegative(self.functionspace.getX()[0]-0.5)        msk_ref=1.-whereZero(self.functionspace.getX()[0],1.e-8)
1911        ref=msk_ref*numarray.array([[[[3.300696811560822, -0.57243075210204586, 0.42282795948188318, 0.88039092673325559], [0.65417442778904566, 0.61618094310709759, 0.62411813856314535, 0.93977331336139813], [-1.9547747749556408, 0.87350264608417738, 1.3458306785826581, 1.3067487556914268]], [[0.74790976139219179, -2.9213171823946693, -0.63953797763024534, 0.63592405182349598], [0.38677818718938206, -0.49342684431748218, 0.41205388939105542, -0.63350996465075404], [2.3442706836281171, -0.96860849511920954, -0.43799565045632483, -1.6265385933616416]]], [[[-0.53287598531730074, -1.603693838691949, -0.42057066785647906, -237.93880683514894], [0.50534682780712736, 0.60225529100200292, 1.7288683042409734, 0.45021519534590931], [-0.43472939058011706, 0.58979192744417874, 0.53626109374853115, 0.83046683485988038]], [[0.60325012730574579, -1.188617610879251, 0.36240354105082945, -0.40312930557024584], [0.84646271367295245, -0.78025109902984713, 0.74710495352909456, 0.9884107688824314], [0.50592449738540834, 0.45244377679371173, -0.41837480958128359, -0.42299611337686482]]], [[[0.45075422577276247, -0.39095918417482473, 140.84570413315484, -63.121963998303322], [2.1572911306009535, 6.5618700483636143, -1.4717621813408515, -0.66003021605811329], [0.42152064796339894, -0.66591127103226522, 0.64133026327282083, 0.95587207394159879]], [[3.6758140645167345, -1.1577285264939614, -0.41326203102693038, 0.51349247727679848], [-1.0723332970476791, -0.49781060243882297, -0.35592596402972293, 0.84199824034348569], [2.5674057501257708, 0.61221962658011064, 1.2848486608869423, -0.66951905106439324]]]])+(1.-msk_ref)*numarray.array([[[[-4.037258613650617, 0.70017063565121707, -0.51718346730044429, -1.076853178360514], [-0.80015569263157726, -0.75368383167253838, -0.76339223948840329, -1.1494869480160286], [2.3909894632838751, -1.068427754284504, -1.6461574054884893, -1.5983542176046435]], [[-0.91480838707695511, 3.5732191204351396, 0.78225306847357656, -0.77783268274130046], [-0.47308906480995322, 0.6035367351675005, -0.50400512655556962, 0.77487988374500394], [-2.8674027184371207, 1.1847567993759462, 0.53573588048219245, 1.9895062531899683]]], [[[0.65178908713899886, 1.9615636132468171, 0.51442245331507475, 291.03566678779583], [-0.61811670381217776, -0.73665062258920866, -2.1146711896460979, -0.55068225867953946], [0.53174074352400413, -0.72140601675245186, -0.65592959411445284, -1.0157883543395652]], [[-0.7378674600225622, 1.4538617030959151, -0.44327513287507087, 0.49308899127843331], [-1.0353537683136067, 0.95436680501382209, -0.91382398358183792, -1.2089780183744372], [-0.61882328233601869, -0.55340815571281099, 0.51173658174249104, 0.5173891453132069]]], [[[-0.55134157559292896, 0.47820306559730319, -172.27590556503543, 77.207846528074953], [-2.6386980375371829, -8.0261738314233622, 1.800190954543867, 0.80731822011553245], [-0.51558442473760147, 0.81451165265637826, -0.78444530879788221, -1.1691782021760189]], [[-4.4960845668011187, 1.4160796137002765, 0.50548286913673068, -0.62808008286899497], [1.311628146228581, 0.60889874393290866, 0.43535206234873525, -1.029893032464839], [-3.1403311395116882, -0.74883853379060061, -1.5715670416121414, 0.81892452116337022]]]])        ref=msk_ref*numarray.array([[[[3.300696811560822, -0.57243075210204586, 0.42282795948188318, 0.88039092673325559], [0.65417442778904566, 0.61618094310709759, 0.62411813856314535, 0.93977331336139813], [-1.9547747749556408, 0.87350264608417738, 1.3458306785826581, 1.3067487556914268]], [[0.74790976139219179, -2.9213171823946693, -0.63953797763024534, 0.63592405182349598], [0.38677818718938206, -0.49342684431748218, 0.41205388939105542, -0.63350996465075404], [2.3442706836281171, -0.96860849511920954, -0.43799565045632483, -1.6265385933616416]]], [[[-0.53287598531730074, -1.603693838691949, -0.42057066785647906, -237.93880683514894], [0.50534682780712736, 0.60225529100200292, 1.7288683042409734, 0.45021519534590931], [-0.43472939058011706, 0.58979192744417874, 0.53626109374853115, 0.83046683485988038]], [[0.60325012730574579, -1.188617610879251, 0.36240354105082945, -0.40312930557024584], [0.84646271367295245, -0.78025109902984713, 0.74710495352909456, 0.9884107688824314], [0.50592449738540834, 0.45244377679371173, -0.41837480958128359, -0.42299611337686482]]], [[[0.45075422577276247, -0.39095918417482473, 140.84570413315484, -63.121963998303322], [2.1572911306009535, 6.5618700483636143, -1.4717621813408515, -0.66003021605811329], [0.42152064796339894, -0.66591127103226522, 0.64133026327282083, 0.95587207394159879]], [[3.6758140645167345, -1.1577285264939614, -0.41326203102693038, 0.51349247727679848], [-1.0723332970476791, -0.49781060243882297, -0.35592596402972293, 0.84199824034348569], [2.5674057501257708, 0.61221962658011064, 1.2848486608869423, -0.66951905106439324]]]])+(1.-msk_ref)*numarray.array([[[[-4.037258613650617, 0.70017063565121707, -0.51718346730044429, -1.076853178360514], [-0.80015569263157726, -0.75368383167253838, -0.76339223948840329, -1.1494869480160286], [2.3909894632838751, -1.068427754284504, -1.6461574054884893, -1.5983542176046435]], [[-0.91480838707695511, 3.5732191204351396, 0.78225306847357656, -0.77783268274130046], [-0.47308906480995322, 0.6035367351675005, -0.50400512655556962, 0.77487988374500394], [-2.8674027184371207, 1.1847567993759462, 0.53573588048219245, 1.9895062531899683]]], [[[0.65178908713899886, 1.9615636132468171, 0.51442245331507475, 291.03566678779583], [-0.61811670381217776, -0.73665062258920866, -2.1146711896460979, -0.55068225867953946], [0.53174074352400413, -0.72140601675245186, -0.65592959411445284, -1.0157883543395652]], [[-0.7378674600225622, 1.4538617030959151, -0.44327513287507087, 0.49308899127843331], [-1.0353537683136067, 0.95436680501382209, -0.91382398358183792, -1.2089780183744372], [-0.61882328233601869, -0.55340815571281099, 0.51173658174249104, 0.5173891453132069]]], [[[-0.55134157559292896, 0.47820306559730319, -172.27590556503543, 77.207846528074953], [-2.6386980375371829, -8.0261738314233622, 1.800190954543867, 0.80731822011553245], [-0.51558442473760147, 0.81451165265637826, -0.78444530879788221, -1.1691782021760189]], [[-4.4960845668011187, 1.4160796137002765, 0.50548286913673068, -0.62808008286899497], [1.311628146228581, 0.60889874393290866, 0.43535206234873525, -1.029893032464839], [-3.1403311395116882, -0.74883853379060061, -1.5715670416121414, 0.81892452116337022]]]])
1912        self.failUnless(isinstance(res,Symbol),"wrong type of result.")        self.failUnless(isinstance(res,Symbol),"wrong type of result.")
1913        self.failUnlessEqual(res.getShape(),(3, 2, 3, 4),"wrong shape of result.")        self.failUnlessEqual(res.getShape(),(3, 2, 3, 4),"wrong shape of result.")
# Line 2198  class Test_util_overloaded_binary_still_ Line 1920  class Test_util_overloaded_binary_still_
1920        res=arg0/arg1        res=arg0/arg1
1921        s1=numarray.array(2.67653295039)        s1=numarray.array(2.67653295039)
1922        sub=res.substitute({arg1:s1})        sub=res.substitute({arg1:s1})
1923        msk_ref=whereNegative(self.functionspace.getX()[0]-0.5)        msk_ref=1.-whereZero(self.functionspace.getX()[0],1.e-8)
1924        ref=msk_ref*numarray.array([0.75234846823535373, -0.088020349048417421])+(1.-msk_ref)*numarray.array([-1.3089401354733579, 0.592626877074932])        ref=msk_ref*numarray.array([0.75234846823535373, -0.088020349048417421])+(1.-msk_ref)*numarray.array([-1.3089401354733579, 0.592626877074932])
1925        self.failUnless(isinstance(res,Symbol),"wrong type of result.")        self.failUnless(isinstance(res,Symbol),"wrong type of result.")
1926        self.failUnlessEqual(res.getShape(),(2,),"wrong shape of result.")        self.failUnlessEqual(res.getShape(),(2,),"wrong shape of result.")
# Line 2211  class Test_util_overloaded_binary_still_ Line 1933  class Test_util_overloaded_binary_still_
1933        res=arg0/arg1        res=arg0/arg1
1934        s1=numarray.array([-0.86125236712465636, -3.638203712883775])        s1=numarray.array([-0.86125236712465636, -3.638203712883775])
1935        sub=res.substitute({arg1:s1})        sub=res.substitute({arg1:s1})
1936        msk_ref=whereNegative(self.functionspace.getX()[0]-0.5)        msk_ref=1.-whereZero(self.functionspace.getX()[0],1.e-8)
1937        ref=msk_ref*numarray.array([0.27957372989379237, -0.67401962890853218])+(1.-msk_ref)*numarray.array([3.0354739212666386, 0.47301766192474731])        ref=msk_ref*numarray.array([0.27957372989379237, -0.67401962890853218])+(1.-msk_ref)*numarray.array([3.0354739212666386, 0.47301766192474731])
1938        self.failUnless(isinstance(res,Symbol),"wrong type of result.")        self.failUnless(isinstance(res,Symbol),"wrong type of result.")
1939        self.failUnlessEqual(res.getShape(),(2,),"wrong shape of result.")        self.failUnlessEqual(res.getShape(),(2,),"wrong shape of result.")
# Line 2224  class Test_util_overloaded_binary_still_ Line 1946  class Test_util_overloaded_binary_still_
1946        res=arg0/arg1        res=arg0/arg1
1947        s1=numarray.array(-4.12759091887)        s1=numarray.array(-4.12759091887)
1948        sub=res.substitute({arg1:s1})        sub=res.substitute({arg1:s1})
1949        msk_ref=whereNegative(self.functionspace.getX()[0]-0.5)        msk_ref=1.-whereZero(self.functionspace.getX()[0],1.e-8)
1950        ref=msk_ref*numarray.array([[0.86065557751820976, -1.1409762307454672, 0.045458720671131048, -0.2230806997439248, -0.378747911492956], [0.77916499623529623, 0.35746053385346038, -0.10978684806424793, -0.3844632946500936, -0.54516035398121099], [0.72797568813457048, -0.93682200161917983, -1.1541906044431842, 1.0942949947926262, 0.96682854874783597], [1.0006962119929996, 0.21445555573666569, -0.24521016786851502, 0.89996743278379421, 1.1220502428343315]])+(1.-msk_ref)*numarray.array([[-0.42618710102484819, -0.3362668100161586, -0.37132642648596642, -1.0274579198869207, -0.64330675199020826], [0.57695972189861822, -0.90448925138421032, -0.7661119729091026, -1.0228819784326422, -0.36690824966706698], [-0.30150464215020217, 0.63468039419829836, 1.056751903018037, 0.30011371521305036, 0.47051428497038333], [-0.71555569595749791, -0.020786921448245156, 0.81041695556566817, 0.98112646436194051, -0.058707817240641058]])        ref=msk_ref*numarray.array([[0.86065557751820976, -1.1409762307454672, 0.045458720671131048, -0.2230806997439248, -0.378747911492956], [0.77916499623529623, 0.35746053385346038, -0.10978684806424793, -0.3844632946500936, -0.54516035398121099], [0.72797568813457048, -0.93682200161917983, -1.1541906044431842, 1.0942949947926262, 0.96682854874783597], [1.0006962119929996, 0.21445555573666569, -0.24521016786851502, 0.89996743278379421, 1.1220502428343315]])+(1.-msk_ref)*numarray.array([[-0.42618710102484819, -0.3362668100161586, -0.37132642648596642, -1.0274579198869207, -0.64330675199020826], [0.57695972189861822, -0.90448925138421032, -0.7661119729091026, -1.0228819784326422, -0.36690824966706698], [-0.30150464215020217, 0.63468039419829836, 1.056751903018037, 0.30011371521305036, 0.47051428497038333], [-0.71555569595749791, -0.020786921448245156, 0.81041695556566817, 0.98112646436194051, -0.058707817240641058]])
1951        self.failUnless(isinstance(res,Symbol),"wrong type of result.")        self.failUnless(isinstance(res,Symbol),"wrong type of result.")
1952        self.failUnlessEqual(res.getShape(),(4, 5),"wrong shape of result.")        self.failUnlessEqual(res.getShape(),(4, 5),"wrong shape of result.")
# Line 2237  class Test_util_overloaded_binary_still_ Line 1959  class Test_util_overloaded_binary_still_
1959        res=arg0/arg1        res=arg0/arg1
1960        s1=numarray.array([[-4.2460288300055975, 1.9723502468412493, 4.5012610797315986, 4.2549986105536082, -3.0291017439146586], [-3.3815482186462242, 0.49185174223600381, 3.1342744464723928, 2.5140825751839522, 4.9827618110943668], [-2.6160153055213375, 0.22203465130806865, -0.21905170509580429, 0.15252026869692958, -3.4865345481390886], [-3.7892575047962449, 4.3978652002093614, 1.623750827816151, -1.9970794554891591, -0.020308141898515153]])        s1=numarray.array([[-4.2460288300055975, 1.9723502468412493, 4.5012610797315986, 4.2549986105536082, -3.0291017439146586], [-3.3815482186462242, 0.49185174223600381, 3.1342744464723928, 2.5140825751839522, 4.9827618110943668], [-2.6160153055213375, 0.22203465130806865, -0.21905170509580429, 0.15252026869692958, -3.4865345481390886], [-3.7892575047962449, 4.3978652002093614, 1.623750827816151, -1.9970794554891591, -0.020308141898515153]])
1961        sub=res.substitute({arg1:s1})        sub=res.substitute({arg1:s1})
1962        msk_ref=whereNegative(self.functionspace.getX()[0]-0.5)        msk_ref=1.-whereZero(self.functionspace.getX()[0],1.e-8)
1963        ref=msk_ref*numarray.array([[-1.0176688023992817, -1.4165265917120697, -0.58829320101238813, 0.9626993601740369, 0.55912450922023427], [1.3467314413763516, -7.0622306141083753, 1.3072670361251153, 1.4238507540333454, -0.25667602687325908], [-0.60809679106591863, -16.227555478587014, 7.0112124984233581, 27.844705836384009, 1.0181496473755489], [0.17307044874056365, -0.69956023103684717, -1.8246329055542057, -0.014488305776312136, 167.45065364131872]])+(1.-msk_ref)*numarray.array([[-0.10471314295466831, 0.021665257238055607, 0.5134626527952022, 0.98615648046604887, 1.1728761035316908], [0.032202736233210821, 8.4570213950817141, -1.2838892707131575, 1.423506673928242, -0.16917686408053739], [1.3946059915521991, 15.780931772766907, 6.713554247425833, -14.137537150046303, 1.2354368461707332], [-0.060866357346785971, 0.93851722034111629, 0.084034267759527922, 2.2742276993995696, 85.581961272925469]])        ref=msk_ref*numarray.array([[-1.0176688023992817, -1.4165265917120697, -0.58829320101238813, 0.9626993601740369, 0.55912450922023427], [1.3467314413763516, -7.0622306141083753, 1.3072670361251153, 1.4238507540333454, -0.25667602687325908], [-0.60809679106591863, -16.227555478587014, 7.0112124984233581, 27.844705836384009, 1.0181496473755489], [0.17307044874056365, -0.69956023103684717, -1.8246329055542057, -0.014488305776312136, 167.45065364131872]])+(1.-msk_ref)*numarray.array([[-0.10471314295466831, 0.021665257238055607, 0.5134626527952022, 0.98615648046604887, 1.1728761035316908], [0.032202736233210821, 8.4570213950817141, -1.2838892707131575, 1.423506673928242, -0.16917686408053739], [1.3946059915521991, 15.780931772766907, 6.713554247425833, -14.137537150046303, 1.2354368461707332], [-0.060866357346785971, 0.93851722034111629, 0.084034267759527922, 2.2742276993995696, 85.581961272925469]])
1964        self.failUnless(isinstance(res,Symbol),"wrong type of result.")        self.failUnless(isinstance(res,Symbol),"wrong type of result.")
1965        self.failUnlessEqual(res.getShape(),(4, 5),"wrong shape of result.")        self.failUnlessEqual(res.getShape(),(4, 5),"wrong shape of result.")
# Line 2250  class Test_util_overloaded_binary_still_ Line 1972  class Test_util_overloaded_binary_still_
1972        res=arg0/arg1        res=arg0/arg1
1973        s1=numarray.array(-0.28615667046)        s1=numarray.array(-0.28615667046)
1974        sub=res.substitute({arg1:s1})        sub=res.substitute({arg1:s1})
1975        msk_ref=whereNegative(self.functionspace.getX()[0]-0.5)        msk_ref=1.-whereZero(self.functionspace.getX()[0],1.e-8)
1976        ref=msk_ref*numarray.array([[[-12.16757867527485, -12.221276844844011], [8.8200138533333607, -10.115284899367113]], [[1.4647155654258333, 14.613502332743044], [3.2476043999188389, -11.520168804812155]], [[12.609699145006596, 7.6396185620070858], [-12.413977106970515, -15.976974565469046]], [[-8.8185995316688608, 15.56155472317962], [-0.10953665419564539, 13.008642793981416]], [[-11.756674481041422, 9.7716861768928052], [-9.0665410301538856, 7.8034619058510533]], [[4.8433197651583795, 5.0918493746639122], [-6.3814996385676048, 5.2616527620282927]]])+(1.-msk_ref)*numarray.array([[[3.6771410169222527, -14.339745533681443], [-0.27789855164224664, 0.080756350693547557]], [[0.092624957504787692, -6.7520332382589583], [-13.993089085985231, -7.9544904158717298]], [[-4.4181678854695097, 6.9704025759996995], [-14.923264329180817, 3.9492002614218951]], [[-14.957464785617184, 0.33706733095137653], [-15.678704254727821, -13.738901952950792]], [[-10.903200850382252, 9.5919402707211265], [2.9956958899211616, 9.8547066150873093]], [[-15.853584157763764, 12.475166731199417], [-5.4506312451800714, 4.6905259754858344]]])        ref=msk_ref*numarray.array([[[-12.16757867527485, -12.221276844844011], [8.8200138533333607, -10.115284899367113]], [[1.4647155654258333, 14.613502332743044], [3.2476043999188389, -11.520168804812155]], [[12.609699145006596, 7.6396185620070858], [-12.413977106970515, -15.976974565469046]], [[-8.8185995316688608, 15.56155472317962], [-0.10953665419564539, 13.008642793981416]], [[-11.756674481041422, 9.7716861768928052], [-9.0665410301538856, 7.8034619058510533]], [[4.8433197651583795, 5.0918493746639122], [-6.3814996385676048, 5.2616527620282927]]])+(1.-msk_ref)*numarray.array([[[3.6771410169222527, -14.339745533681443], [-0.27789855164224664, 0.080756350693547557]], [[0.092624957504787692, -6.7520332382589583], [-13.993089085985231, -7.9544904158717298]], [[-4.4181678854695097, 6.9704025759996995], [-14.923264329180817, 3.9492002614218951]], [[-14.957464785617184, 0.33706733095137653], [-15.678704254727821, -13.738901952950792]], [[-10.903200850382252, 9.5919402707211265], [2.9956958899211616, 9.8547066150873093]], [[-15.853584157763764, 12.475166731199417], [-5.4506312451800714, 4.6905259754858344]]])
1977        self.failUnless(isinstance(res,Symbol),"wrong type of result.")        self.failUnless(isinstance(res,Symbol),"wrong type of result.")
1978        self.failUnlessEqual(res.getShape(),(6, 2, 2),"wrong shape of result.")        self.failUnlessEqual(res.getShape(),(6, 2, 2),"wrong shape of result.")
# Line 2263  class Test_util_overloaded_binary_still_ Line 1985  class Test_util_overloaded_binary_still_
1985        res=arg0/arg1        res=arg0/arg1
1986        s1=numarray.array([[[2.0746966987933471, -0.038598186515555355], [4.5881839069107979, -4.5221184818631528]], [[-2.8952171009517813, 3.2089615497034014], [-2.3810029676646538, -0.20007357454609931]], [[1.5952957217622385, 3.5074629033411888], [-4.8216610018108206, 1.1790345104067725]], [[1.5767066224494872, -1.604585837573552], [3.2217724192087989, 4.7028880210110895]], [[4.9340137982802084, -0.75080095286040205], [-2.5470169322631153, -2.2621993393540785]], [[1.0027941556835875, -2.9581897902533969], [-2.2860741942260967, 1.3808737645507074]]])        s1=numarray.array([[[2.0746966987933471, -0.038598186515555355], [4.5881839069107979, -4.5221184818631528]], [[-2.8952171009517813, 3.2089615497034014], [-2.3810029676646538, -0.20007357454609931]], [[1.5952957217622385, 3.5074629033411888], [-4.8216610018108206, 1.1790345104067725]], [[1.5767066224494872, -1.604585837573552], [3.2217724192087989, 4.7028880210110895]], [[4.9340137982802084, -0.75080095286040205], [-2.5470169322631153, -2.2621993393540785]], [[1.0027941556835875, -2.9581897902533969], [-2.2860741942260967, 1.3808737645507074]]])
1987        sub=res.substitute({arg1:s1})        sub=res.substitute({arg1:s1})
1988        msk_ref=whereNegative(self.functionspace.getX()[0]-0.5)        msk_ref=1.-whereZero(self.functionspace.getX()[0],1.e-8)
1989        ref=msk_ref*numarray.array([[[2.1085679133477782, -24.312677699849253], [0.40770778959266579, 0.87982138837347346]], [[1.6915984329586637, -1.1586546958154076], [-1.0632560091570595, 1.2951220254320459]], [[2.654371765368603, 0.7671959110970713], [0.96131917326667549, -1.4184321594279894]], [[-1.5153035856663291, -1.9534360936031212], [-1.420559374043824, 0.51288394571066676]], [[-0.85594752828117715, 5.1846967822550107], [-0.94817209550680237, 2.0129038556436383]], [[1.3064194234616144, 1.5834970851385091], [0.51772712606217608, -1.1794799729080312]]])+(1.-msk_ref)*numarray.array([[[-0.25630251482834782, 59.726538547286722], [-1.0296772906632581, -1.0183173839017754]], [[1.4049222529283787, 0.96246040474414196], [0.9970704586354957, 23.337669986521096]], [[1.9577453696873013, -1.1250703048756534], [0.66978261469400868, 0.65095030571629375]], [[-2.6646061676164279, -2.9776017129266807], [0.33453965626431137, -0.64310680677646215]], [[0.0028769940861437288, 2.3790790716155366], [-0.62253624658671147, -1.0144345783501139]], [[0.8430318781302184, 0.056288098022877722], [-2.1609648703178355, 1.9464917437369802]]])        ref=msk_ref*numarray.array([[[2.1085679133477782, -24.312677699849253], [0.40770778959266579, 0.87982138837347346]], [[1.6915984329586637, -1.1586546958154076], [-1.0632560091570595, 1.2951220254320459]], [[2.654371765368603, 0.7671959110970713], [0.96131917326667549, -1.4184321594279894]], [[-1.5153035856663291, -1.9534360936031212], [-1.420559374043824, 0.51288394571066676]], [[-0.85594752828117715, 5.1846967822550107], [-0.94817209550680237, 2.0129038556436383]], [[1.3064194234616144, 1.5834970851385091], [0.51772712606217608, -1.1794799729080312]]])+(1.-msk_ref)*numarray.array([[[-0.25630251482834782, 59.726538547286722], [-1.0296772906632581, -1.0183173839017754]], [[1.4049222529283787, 0.96246040474414196], [0.9970704586354957, 23.337669986521096]], [[1.9577453696873013, -1.1250703048756534], [0.66978261469400868, 0.65095030571629375]], [[-2.6646061676164279, -2.9776017129266807], [0.33453965626431137, -0.64310680677646215]], [[0.0028769940861437288, 2.3790790716155366], [-0.62253624658671147, -1.0144345783501139]], [[0.8430318781302184, 0.056288098022877722], [-2.1609648703178355, 1.9464917437369802]]])
1990        self.failUnless(isinstance(res,Symbol),"wrong type of result.")        self.failUnless(isinstance(res,Symbol),"wrong type of result.")
1991        self.failUnlessEqual(res.getShape(),(6, 2, 2),"wrong shape of result.")        self.failUnlessEqual(res.getShape(),(6, 2, 2),"wrong shape of result.")
# Line 2276  class Test_util_overloaded_binary_still_ Line 1998  class Test_util_overloaded_binary_still_
1998        res=arg0/arg1        res=arg0/arg1
1999        s1=numarray.array(2.66573806719)        s1=numarray.array(2.66573806719)
2000        sub=res.substitute({arg1:s1})        sub=res.substitute({arg1:s1})
2001        msk_ref=whereNegative(self.functionspace.getX()[0]-0.5)        msk_ref=1.-whereZero(self.functionspace.getX()[0],1.e-8)
2002        ref=msk_ref*numarray.array([[[[-0.16675538843211471, 1.1502874266315799, -0.80286661357682243, 0.09861405254483871], [-0.083625220053744204, -0.66768465557178724, -0.31338247111570511, -1.8151165822394388], [-1.0094567157580112, 0.41397549643762593, 0.35039342744007457, -1.6930965340977453]], [[1.3476747385954884, 0.1963866546110643, -0.06495265314148993, 0.53961284553270628], [0.84969443393929622, -1.6650702367684398, 0.14618005297240813, 0.059411525245472156], [1.0532249096146338, 0.45089734269967507, 1.4063229247809164, 1.0541419853204237]]], [[[1.5629509308409302, -1.7837795609661897, -0.77695207174998171, -1.0956932550060703], [1.5716116085784111, -1.7228913001128441, -0.27858588368149767, 0.045850708115761904], [-1.3109596645285277, -0.5896649852344733, 1.0083895499175104, -0.16967113325105213]], [[0.22529857996487432, -1.6088682721916423, -0.84248531760932877, 0.34233784829880937], [1.2471415996099637, 1.0073895092277732, 0.48932282045276504, 1.3404175496588318], [1.0480127566711488, 0.32153882716974125, 0.26896270521588078, -0.016215716857401703]]], [[[1.6054818464464042, -0.21550960380171494, 1.3269413990545242, -1.8344691377708944], [1.299192007982737, 0.84019886380726794, 0.34749286979442995, 0.60454604350793251], [-1.4047451601330245, 0.022155610007608559, -0.74024170173101733, 0.5179453470187918]], [[-0.84428407263630001, 1.0529983617442118, -1.3755638213979053, 1.2513502677786434], [-0.86925838741351014, -0.69478585880924792, 0.34400062505739643, -0.21255013134095985], [-0.97500855373963136, -0.26676323976338612, 1.3184594791778352, 1.115647322501641]]]])+(1.-msk_ref)*numarray.array([[[[0.41397238148416005, -1.8471604435804707, 0.2142386316834391, 0.95633646557068408], [0.48163299130222342, 0.77444994300265702, 0.93273547081138874, -0.85520086131672679], [1.2877614620220696, -1.4039358766544225, -1.6721146592788225, -1.044490223017593]], [[0.086589143873261026, -1.6069078880519039, -1.5765426276573689, -1.7800053013936494], [1.6320054951625498, -0.7241986281252718, 1.2863142366988327, 0.61953887258350682], [0.24741612596359824, 0.7529291633123758, 1.4607513271074251, 0.63868292985895248]]], [[[-1.6786172539481112, 0.26100281721871821, -0.10745205396451149, -0.95227907266657619], [-0.016450653323677209, 1.1017183620993041, 0.65693298776039311, -0.94827308712706726], [-1.1139422815460562, 0.58457925065244776, -0.59482660845934698, -0.59471358559422671]], [[-1.0794303191321972, 0.068626143601199674, -0.54203018832267935, -0.82340935272625038], [0.50619060992421039, -1.6113575653696872, 0.37013540341897494, -1.6526499268222394], [-1.7564122551849053, 1.4484161566875804, -1.3219182680327803, -1.3302857613479471]]], [[[0.91458459794258318, 1.2950012069615637, -1.4139619160741743, 1.8686309117048736], [0.31707258315789316, 1.4201387193205603, -1.5644776208624107, -0.20609365919729955], [-1.3292064621650026, -0.52721727525641704, 0.26255192901259999, 1.7411737315658249]], [[-0.10766495723412189, -0.074580184594690943, -0.62220788258068571, -1.2913566940695587], [-1.7186164631668384, 0.65218492356209323, -1.4575239428531019, 0.36525387700306983], [0.20523014405310749, -0.95095359701515858, -1.8733909374079507, 1.5311737244869104]]]])        ref=msk_ref*numarray.array([[[[-0.16675538843211471, 1.1502874266315799, -0.80286661357682243, 0.09861405254483871], [-0.083625220053744204, -0.66768465557178724, -0.31338247111570511, -1.8151165822394388], [-1.0094567157580112, 0.41397549643762593, 0.35039342744007457, -1.6930965340977453]], [[1.3476747385954884, 0.1963866546110643, -0.06495265314148993, 0.53961284553270628], [0.84969443393929622, -1.6650702367684398, 0.14618005297240813, 0.059411525245472156], [1.0532249096146338, 0.45089734269967507, 1.4063229247809164, 1.0541419853204237]]], [[[1.5629509308409302, -1.7837795609661897, -0.77695207174998171, -1.0956932550060703], [1.5716116085784111, -1.7228913001128441, -0.27858588368149767, 0.045850708115761904], [-1.3109596645285277, -0.5896649852344733, 1.0083895499175104, -0.16967113325105213]], [[0.22529857996487432, -1.6088682721916423, -0.84248531760932877, 0.34233784829880937], [1.2471415996099637, 1.0073895092277732, 0.48932282045276504, 1.3404175496588318], [1.0480127566711488, 0.32153882716974125, 0.26896270521588078, -0.016215716857401703]]], [[[1.6054818464464042, -0.21550960380171494, 1.3269413990545242, -1.8344691377708944], [1.299192007982737, 0.84019886380726794, 0.34749286979442995, 0.60454604350793251], [-1.4047451601330245, 0.022155610007608559, -0.74024170173101733, 0.5179453470187918]], [[-0.84428407263630001, 1.0529983617442118, -1.3755638213979053, 1.2513502677786434], [-0.86925838741351014, -0.69478585880924792, 0.34400062505739643, -0.21255013134095985], [-0.97500855373963136, -0.26676323976338612, 1.3184594791778352, 1.115647322501641]]]])+(1.-msk_ref)*numarray.array([[[[0.41397238148416005, -1.8471604435804707, 0.2142386316834391, 0.95633646557068408], [0.48163299130222342, 0.77444994300265702, 0.93273547081138874, -0.85520086131672679], [1.2877614620220696, -1.4039358766544225, -1.6721146592788225, -1.044490223017593]], [[0.086589143873261026, -1.6069078880519039, -1.5765426276573689, -1.7800053013936494], [1.6320054951625498, -0.7241986281252718, 1.2863142366988327, 0.61953887258350682], [0.24741612596359824, 0.7529291633123758, 1.4607513271074251, 0.63868292985895248]]], [[[-1.6786172539481112, 0.26100281721871821, -0.10745205396451149, -0.95227907266657619], [-0.016450653323677209, 1.1017183620993041, 0.65693298776039311, -0.94827308712706726], [-1.1139422815460562, 0.58457925065244776, -0.59482660845934698, -0.59471358559422671]], [[-1.0794303191321972, 0.068626143601199674, -0.54203018832267935, -0.82340935272625038], [0.50619060992421039, -1.6113575653696872, 0.37013540341897494, -1.6526499268222394], [-1.7564122551849053, 1.4484161566875804, -1.3219182680327803, -1.3302857613479471]]], [[[0.91458459794258318, 1.2950012069615637, -1.4139619160741743, 1.8686309117048736], [0.31707258315789316, 1.4201387193205603, -1.5644776208624107, -0.20609365919729955], [-1.3292064621650026, -0.52721727525641704, 0.26255192901259999, 1.7411737315658249]], [[-0.10766495723412189, -0.074580184594690943, -0.62220788258068571, -1.2913566940695587], [-1.7186164631668384, 0.65218492356209323, -1.4575239428531019, 0.36525387700306983], [0.20523014405310749, -0.95095359701515858, -1.8733909374079507, 1.5311737244869104]]]])
2003        self.failUnless(isinstance(res,Symbol),"wrong type of result.")        self.failUnless(isinstance(res,Symbol),"wrong type of result.")
2004        self.failUnlessEqual(res.getShape(),(3, 2, 3, 4),"wrong shape of result.")        self.failUnlessEqual(res.getShape(),(3, 2, 3, 4),"wrong shape of result.")
# Line 2289  class Test_util_overloaded_binary_still_ Line 2011  class Test_util_overloaded_binary_still_
2011        res=arg0/arg1        res=arg0/arg1
2012        s1=numarray.array([[[[-0.49104290278642271, -2.3674315644822963, 4.0989949383597608, -1.7292635092608224], [-4.622988996878866, -4.1541086550089714, -0.037463128987194061, -2.6489483804003844], [-1.3280913255545124, 3.198305008176586, 4.0433681250873974, -4.8641097044412218]], [[-3.8791417988042811, -1.1645861545593315, -2.3888987565565021, -3.5719587761449887], [-2.4965270383303331, 3.9852223086984733, 0.5007169845482391, -3.108649685462217], [0.20848826126615183, 4.6794023694682423, 4.6869612020471063, 2.7794546763479264]]], [[[3.9549024552919079, -0.48631450907908125, 4.4520002177282301, 4.2795685433565982], [-0.044877637378450963, 2.5321944239340848, -1.7730261622972501, 1.866409581291264], [-1.5466816416052809, 2.912554476943007, -3.3751196293325059, -2.725818247229256]], [[-4.851701238543999, -4.998185592299647, -0.44584459532102105, -1.2909219819916928], [0.84509859941086773, -1.8873930915550119, 3.6306196902313079, -0.58336909128228509], [-2.247976724721672, -2.3230490248981575, 4.8350209920697722, -0.32527190181639298]]], [[[2.5335174897949022, -0.20854461379276934, 3.2780648503024352, -1.6620646994478872], [-2.1379815500652954, -3.2990143123595739, 2.9742698157590199, -3.0724429738487213], [-1.941430518641484, -3.8959116863238554, -3.0686598489329029, 4.0511881765933175]], [[0.02000325485725174, 3.2082680619577548, -4.598681116192207, 4.4506904679653321], [-1.3308670983956148, -1.4563013194069239, 1.9676557830927131, -1.443387189237999], [3.9560651184617885, 3.6345685490807202, -3.1473146440504864, 2.5626571964669047]]]])        s1=numarray.array([[[[-0.49104290278642271, -2.3674315644822963, 4.0989949383597608, -1.7292635092608224], [-4.622988996878866, -4.1541086550089714, -0.037463128987194061, -2.6489483804003844], [-1.3280913255545124, 3.198305008176586, 4.0433681250873974, -4.8641097044412218]], [[-3.8791417988042811, -1.1645861545593315, -2.3888987565565021, -3.5719587761449887], [-2.4965270383303331, 3.9852223086984733, 0.5007169845482391, -3.108649685462217], [0.20848826126615183, 4.6794023694682423, 4.6869612020471063, 2.7794546763479264]]], [[[3.9549024552919079, -0.48631450907908125, 4.4520002177282301, 4.2795685433565982], [-0.044877637378450963, 2.5321944239340848, -1.7730261622972501, 1.866409581291264], [-1.5466816416052809, 2.912554476943007, -3.3751196293325059, -2.725818247229256]], [[-4.851701238543999, -4.998185592299647, -0.44584459532102105, -1.2909219819916928], [0.84509859941086773, -1.8873930915550119, 3.6306196902313079, -0.58336909128228509], [-2.247976724721672, -2.3230490248981575, 4.8350209920697722, -0.32527190181639298]]], [[[2.5335174897949022, -0.20854461379276934, 3.2780648503024352, -1.6620646994478872], [-2.1379815500652954, -3.2990143123595739, 2.9742698157590199, -3.0724429738487213], [-1.941430518641484, -3.8959116863238554, -3.0686598489329029, 4.0511881765933175]], [[0.02000325485725174, 3.2082680619577548, -4.598681116192207, 4.4506904679653321], [-1.3308670983956148, -1.4563013194069239, 1.9676557830927131, -1.443387189237999], [3.9560651184617885, 3.6345685490807202, -3.1473146440504864, 2.5626571964669047]]]])
2013        sub=res.substitute({arg1:s1})        sub=res.substitute({arg1:s1})
2014        msk_ref=whereNegative(self.functionspace.getX()[0]-0.5)        msk_ref=1.-whereZero(self.functionspace.getX()[0],1.e-8)
2015        ref=msk_ref*numarray.array([[[[-0.26692229001064205, 0.19885873770611004, -1.0465465029518624, 1.1181056258382696], [-0.13830360552907706, 0.80330964898773283, -19.429643178861738, 0.099203093268639547], [2.986875938683629, -1.1480465371192021, 0.51934518479270775, 0.49648401132503633]], [[1.2279008511818705, 0.28180912845077649, -1.6730565421652779, -0.34733288039983173], [-0.70062421444068845, -0.11353892593910048, 9.2276510545379935, 0.66963678015000538], [-3.2816488989412327, -0.018558832023123775, 0.9807787578967162, -0.32796280554448065]]], [[[0.41563304164901532, 4.8953633274033006, -1.0060304328401219, -1.1616260269333594], [-101.43397097149828, 1.490297970370789, -0.62428760628404523, -1.1850178719997067], [-0.053555636159778923, 1.0371300604863249, -1.291058595851039, -0.18245067811287974]], [[-0.16407151694367492, 0.25326309579912565, -10.822193808552843, 3.3145404571095454], [-5.1863817870065798, -1.348733628879734, 1.3321515146271816, 3.3642001467839115], [1.1845081664272488, -1.9102494451953862, -0.74401954478721888, -2.0039395631523571]]], [[[1.2190939122756466, -14.998071124806016, 0.51155603954235385, -0.5906616210734561], [-1.9609158519571066, 0.14405209220302512, 0.71003058349945258, -0.71349209293425142], [-0.19634221905167631, 0.026507155728614104, 0.21445137531607825, 0.66314735446318107]], [[-157.61442618672615, -1.0100192970849919, 0.22541064348860901, 0.86434760274348943], [1.3673457816808718, 1.0231862389635615, 0.09224972362744735, 1.9442455668211094], [-1.2144237177893482, 0.99364914197916654, -1.4532221807783379, -1.8215580986331779]]]])+(1.-msk_ref)*numarray.array([[[[9.0847562175307548, 1.778995292561067, -1.0232209271680595, -2.6987201009137105], [0.14972528615081884, 0.12133798041887074, -131.42919529410358, -1.0919436530339175], [-1.3941761929913368, 1.164058005397852, -0.74681041285503469, -0.80051890017845562]], [[-0.38249803887159334, 4.1689131086319398, 0.73141690092266454, -0.90446672481449997], [0.76060602339657379, 0.2173604465747247, -9.879728652007838, -0.47244978099981061], [-20.909614121584703, -0.52322153328871157, -1.0481592170429599, 1.1181278413803195]]], [[[0.29732648638247061, -1.1389455735288434, 0.20023948914673259, 0.14814687684718106], [-12.430756373157672, -1.5125118563266158, 0.064114862641108966, 2.0187332441924042], [2.3110877318397747, -0.85481475622463277, -0.79738959712203872, 1.107634200210057]], [[0.5537448644793036, -0.92709881139841899, -10.271674824635689, -1.2580773672773902], [4.0101027383583956, -0.15510131000245292, -0.29802903157125132, -5.402719975423115], [-0.0025642366860165779, -0.59028737896051597, 0.68976761182818369, -13.511219209980442]]], [[[-0.72307985519587537, 1.1578563845894034, 0.38289603651893378, 2.6914473541170971], [-0.8288972310274092, 0.5803287826743494, -0.37735470305926527, -0.67287427157387836], [-0.97204427369426094, -0.32735223991262846, -1.3978494129477628, 0.82072493298010418]], [[59.459275890228867, -0.95758774625624643, 0.87822569277673845, 0.61462320089170264], [-2.65978045034828, -2.3738902894641662, -0.76043784039873807, -0.92389751694797129], [0.31008655924816314, 0.89999700786337411, 1.5387790324814787, 0.61943307038110118]]]])        ref=msk_ref*numarray.array([[[[-0.26692229001064205, 0.19885873770611004, -1.0465465029518624, 1.1181056258382696], [-0.13830360552907706, 0.80330964898773283, -19.429643178861738, 0.099203093268639547], [2.986875938683629, -1.1480465371192021, 0.51934518479270775, 0.49648401132503633]], [[1.2279008511818705, 0.28180912845077649, -1.6730565421652779, -0.34733288039983173], [-0.70062421444068845, -0.11353892593910048, 9.2276510545379935, 0.66963678015000538], [-3.2816488989412327, -0.018558832023123775, 0.9807787578967162, -0.32796280554448065]]], [[[0.41563304164901532, 4.8953633274033006, -1.0060304328401219, -1.1616260269333594], [-101.43397097149828, 1.490297970370789, -0.62428760628404523, -1.1850178719997067], [-0.053555636159778923, 1.0371300604863249, -1.291058595851039, -0.18245067811287974]], [[-0.16407151694367492, 0.25326309579912565, -10.822193808552843, 3.3145404571095454], [-5.1863817870065798, -1.348733628879734, 1.3321515146271816, 3.3642001467839115], [1.1845081664272488, -1.9102494451953862, -0.74401954478721888, -2.0039395631523571]]], [[[1.2190939122756466, -14.998071124806016, 0.51155603954235385, -0.5906616210734561], [-1.9609158519571066, 0.14405209220302512, 0.71003058349945258, -0.71349209293425142], [-0.19634221905167631, 0.026507155728614104, 0.21445137531607825, 0.66314735446318107]], [[-157.61442618672615, -1.0100192970849919, 0.22541064348860901, 0.86434760274348943], [1.3673457816808718, 1.0231862389635615, 0.09224972362744735, 1.9442455668211094], [-1.2144237177893482, 0.99364914197916654, -1.4532221807783379, -1.8215580986331779]]]])+(1.-msk_ref)*numarray.array([[[[9.0847562175307548, 1.778995292561067, -1.0232209271680595, -2.6987201009137105], [0.14972528615081884, 0.12133798041887074, -131.42919529410358, -1.0919436530339175], [-1.3941761929913368, 1.164058005397852, -0.74681041285503469, -0.80051890017845562]], [[-0.38249803887159334, 4.1689131086319398, 0.73141690092266454, -0.90446672481449997], [0.76060602339657379, 0.2173604465747247, -9.879728652007838, -0.47244978099981061], [-20.909614121584703, -0.52322153328871157, -1.0481592170429599, 1.1181278413803195]]], [[[0.29732648638247061, -1.1389455735288434, 0.20023948914673259, 0.14814687684718106], [-12.430756373157672, -1.5125118563266158, 0.064114862641108966, 2.0187332441924042], [2.3110877318397747, -0.85481475622463277, -0.79738959712203872, 1.107634200210057]], [[0.5537448644793036, -0.92709881139841899, -10.271674824635689, -1.2580773672773902], [4.0101027383583956, -0.15510131000245292, -0.29802903157125132, -5.402719975423115], [-0.0025642366860165779, -0.59028737896051597, 0.68976761182818369, -13.511219209980442]]], [[[-0.72307985519587537, 1.1578563845894034, 0.38289603651893378, 2.6914473541170971], [-0.8288972310274092, 0.5803287826743494, -0.37735470305926527, -0.67287427157387836], [-0.97204427369426094, -0.32735223991262846, -1.3978494129477628, 0.82072493298010418]], [[59.459275890228867, -0.95758774625624643, 0.87822569277673845, 0.61462320089170264], [-2.65978045034828, -2.3738902894641662, -0.76043784039873807, -0.92389751694797129], [0.31008655924816314, 0.89999700786337411, 1.5387790324814787, 0.61943307038110118]]]])
2016        self.failUnless(isinstance(res,Symbol),"wrong type of result.")        self.failUnless(isinstance(res,Symbol),"wrong type of result.")
2017        self.failUnlessEqual(res.getShape(),(3, 2, 3, 4),"wrong shape of result.")        self.failUnlessEqual(res.getShape(),(3, 2, 3, 4),"wrong shape of result.")
# Line 2614  class Test_util_overloaded_binary_still_ Line 2336  class Test_util_overloaded_binary_still_
2336        res=arg0**arg1        res=arg0**arg1
2337        s1=numarray.array(1.19010675911)        s1=numarray.array(1.19010675911)
2338        sub=res.substitute({arg1:s1})        sub=res.substitute({arg1:s1})
2339        msk_ref=whereNegative(self.functionspace.getX()[0]-0.5)        msk_ref=1.-whereZero(self.functionspace.getX()[0],1.e-8)
2340        ref=msk_ref*(5.03931257301)+(1.-msk_ref)*(3.04374385558)        ref=msk_ref*(5.03931257301)+(1.-msk_ref)*(3.04374385558)
2341        self.failUnless(isinstance(res,Symbol),"wrong type of result.")        self.failUnless(isinstance(res,Symbol),"wrong type of result.")
2342        self.failUnlessEqual(res.getShape(),(),"wrong shape of result.")        self.failUnlessEqual(res.getShape(),(),"wrong shape of result.")
# Line 2627  class Test_util_overloaded_binary_still_ Line 2349  class Test_util_overloaded_binary_still_
2349        res=arg0**arg1        res=arg0**arg1
2350        s1=numarray.array([2.6436168652771852, 2.5263281686556338])        s1=numarray.array([2.6436168652771852, 2.5263281686556338])
2351        sub=res.substitute({arg1:s1})        sub=res.substitute({arg1:s1})
2352        msk_ref=whereNegative(self.functionspace.getX()[0]-0.5)        msk_ref=1.-whereZero(self.functionspace.getX()[0],1.e-8)
2353        ref=msk_ref*numarray.array([66.316927996841926, 55.056023448709631])+(1.-msk_ref)*numarray.array([0.11835780466515407, 0.13011163831115394])        ref=msk_ref*numarray.array([66.316927996841926, 55.056023448709631])+(1.-msk_ref)*numarray.array([0.11835780466515407, 0.13011163831115394])
2354        self.failUnless(isinstance(res,Symbol),"wrong type of result.")        self.failUnless(isinstance(res,Symbol),"wrong type of result.")
2355        self.failUnlessEqual(res.getShape(),(2,),"wrong shape of result.")        self.failUnlessEqual(res.getShape(),(2,),"wrong shape of result.")
# Line 2640  class Test_util_overloaded_binary_still_ Line 2362  class Test_util_overloaded_binary_still_
2362        res=arg0**arg1        res=arg0**arg1
2363        s1=numarray.array([[4.6753994855762322, 0.74230895194578139, 2.1240057964580989, 2.0718366932114969, 2.7712387841020072], [4.8863576750157955, 3.3414363161035081, 4.4581631371080581, 3.9608316372247754, 1.8708117955421679], [0.79134090721377925, 2.3698715200137062, 0.74563755408533605, 4.505431587220242, 0.4266953364877229], [3.3582640582818506, 0.67592276895656023, 2.452334295239794, 2.7354796748175381, 3.2941264764122526]])        s1=numarray.array([[4.6753994855762322, 0.74230895194578139, 2.1240057964580989, 2.0718366932114969, 2.7712387841020072], [4.8863576750157955, 3.3414363161035081, 4.4581631371080581, 3.9608316372247754, 1.8708117955421679], [0.79134090721377925, 2.3698715200137062, 0.74563755408533605, 4.505431587220242, 0.4266953364877229], [3.3582640582818506, 0.67592276895656023, 2.452334295239794, 2.7354796748175381, 3.2941264764122526]])
2364        sub=res.substitute({arg1:s1})        sub=res.substitute({arg1:s1})
2365        msk_ref=whereNegative(self.functionspace.getX()[0]-0.5)        msk_ref=1.-whereZero(self.functionspace.getX()[0],1.e-8)
2366        ref=msk_ref*numarray.array([[0.00086866920141233242, 0.32657631384691554, 0.040676166994520334, 0.044004484321484766, 0.015331132004679567], [0.0006320228919676138, 0.006490022445223345, 0.0012052761606645113, 0.0025509778179644465, 0.059581973194475848], [0.30330653494922644, 0.028077810453111935, 0.32494161295940505, 0.0011223757616437124, 0.52556667655735056], [0.0063274466863977204, 0.36095246360643463, 0.024795450879728644, 0.016180314072261656, 0.0069698203697718527]])+(1.-msk_ref)*numarray.array([[596.49404196608316, 2.758547548814811, 18.236484447034929, 16.981275833658771, 44.175210333542509], [795.87329080398752, 96.312603680055275, 443.24228674444652, 224.59209670569982, 12.901182307496537], [2.9497748837706252, 25.521265789520019, 2.7711276915218876, 472.82742687229063, 1.7918956896122926], [98.553740344816347, 2.519239939249529, 28.566511661869622, 42.067800778483488, 90.281149199634811]])        ref=msk_ref*numarray.array([[0.00086866920141233242, 0.32657631384691554, 0.040676166994520334, 0.044004484321484766, 0.015331132004679567], [0.0006320228919676138, 0.006490022445223345, 0.0012052761606645113, 0.0025509778179644465, 0.059581973194475848], [0.30330653494922644, 0.028077810453111935, 0.32494161295940505, 0.0011223757616437124, 0.52556667655735056], [0.0063274466863977204, 0.36095246360643463, 0.024795450879728644, 0.016180314072261656, 0.0069698203697718527]])+(1.-msk_ref)*numarray.array([[596.49404196608316, 2.758547548814811, 18.236484447034929, 16.981275833658771, 44.175210333542509], [795.87329080398752, 96.312603680055275, 443.24228674444652, 224.59209670569982, 12.901182307496537], [2.9497748837706252, 25.521265789520019, 2.7711276915218876, 472.82742687229063, 1.7918956896122926], [98.553740344816347, 2.519239939249529, 28.566511661869622, 42.067800778483488, 90.281149199634811]])
2367        self.failUnless(isinstance(res,Symbol),"wrong type of result.")        self.failUnless(isinstance(res,Symbol),"wrong type of result.")
2368        self.failUnlessEqual(res.getShape(),(4, 5),"wrong shape of result.")        self.failUnlessEqual(res.getShape(),(4, 5),"wrong shape of result.")
# Line 2653  class Test_util_overloaded_binary_still_ Line 2375  class Test_util_overloaded_binary_still_
2375        res=arg0**arg1        res=arg0**arg1
2376        s1=numarray.array([[[2.2563487326899501, 3.8457355666351378], [1.9663888270560579, 1.8151676332476596]], [[1.9217762174895128, 2.4048860435314841], [4.813058542284506, 4.3600788139918567]], [[3.6808048059364755, 3.3840843094394528], [3.0170356512966436, 2.5508193338300997]], [[3.8450720577204835, 0.67106380009782396], [1.9102190488265116, 1.1868982505742023]], [[0.59290803321196273, 3.8932917892980128], [4.4531448032102059, 4.4445121819332796]], [[0.41428618209261464, 0.051071515023622144], [2.4927355451451532, 4.7132104714638183]]])        s1=numarray.array([[[2.2563487326899501, 3.8457355666351378], [1.9663888270560579, 1.8151676332476596]], [[1.9217762174895128, 2.4048860435314841], [4.813058542284506, 4.3600788139918567]], [[3.6808048059364755, 3.3840843094394528], [3.0170356512966436, 2.5508193338300997]], [[3.8450720577204835, 0.67106380009782396], [1.9102190488265116, 1.1868982505742023]], [[0.59290803321196273, 3.8932917892980128], [4.4531448032102059, 4.4445121819332796]], [[0.41428618209261464, 0.051071515023622144], [2.4927355451451532, 4.7132104714638183]]])
2377        sub=res.substitute({arg1:s1})        sub=res.substitute({arg1:s1})
2378        msk_ref=whereNegative(self.functionspace.getX()[0]-0.5)        msk_ref=1.-whereZero(self.functionspace.getX()[0],1.e-8)
2379        ref=msk_ref*numarray.array([[[0.3974484050535696, 0.20749684554046716], [0.44748303191812167, 0.47602844004520567]], [[0.45572159368027115, 0.3740253845053354], [0.13970710514501208, 0.1681380586023484]], [[0.22197424916106345, 0.25061038586978807], [0.29119610241028077, 0.35235777758344106]], [[0.20755315311788622, 0.76001390077105713], [0.4578804680988246, 0.61547615679232826]], [[0.78469649471659941, 0.20350059736582529], [0.1618593719639588, 0.16243176848774246]], [[0.84415908115348237, 0.9793318673956567], [0.36082725088606604, 0.14552953583002134]]])+(1.-msk_ref)*numarray.array([[[4.4056635605850065, 12.521522255051883], [3.6412493793131264, 3.2967695028025417]], [[3.5360386886022686, 4.8574364755138051], [23.645706011695786, 17.557470752187442]], [[11.235238076367091, 9.2446772457911379], [7.2632004540196622, 5.3463783054067413]], [[12.516063266569189, 1.5543052033699192], [3.5092825682082269, 2.1815579144301767]], [[1.4764846419069859, 12.919054099710024], [18.664872368805973, 18.559278355021636]], [[1.3129444351849795, 1.0341342656584545], [5.1461364913354837, 22.143866788073627]]])        ref=msk_ref*numarray.array([[[0.3974484050535696, 0.20749684554046716], [0.44748303191812167, 0.47602844004520567]], [[0.45572159368027115, 0.3740253845053354], [0.13970710514501208, 0.1681380586023484]], [[0.22197424916106345, 0.25061038586978807], [0.29119610241028077, 0.35235777758344106]], [[0.20755315311788622, 0.76001390077105713], [0.4578804680988246, 0.61547615679232826]], [[0.78469649471659941, 0.20350059736582529], [0.1618593719639588, 0.16243176848774246]], [[0.84415908115348237, 0.9793318673956567], [0.36082725088606604, 0.14552953583002134]]])+(1.-msk_ref)*numarray.array([[[4.4056635605850065, 12.521522255051883], [3.6412493793131264, 3.2967695028025417]], [[3.5360386886022686, 4.8574364755138051], [23.645706011695786, 17.557470752187442]], [[11.235238076367091, 9.2446772457911379], [7.2632004540196622, 5.3463783054067413]], [[12.516063266569189, 1.5543052033699192], [3.5092825682082269, 2.1815579144301767]], [[1.4764846419069859, 12.919054099710024], [18.664872368805973, 18.559278355021636]], [[1.3129444351849795, 1.0341342656584545], [5.1461364913354837, 22.143866788073627]]])
2380        self.failUnless(isinstance(res,Symbol),"wrong type of result.")        self.failUnless(isinstance(res,Symbol),"wrong type of result.")
2381        self.failUnlessEqual(res.getShape(),(6, 2, 2),"wrong shape of result.")        self.failUnlessEqual(res.getShape(),(6, 2, 2),"wrong shape of result.")
# Line 2666  class Test_util_overloaded_binary_still_ Line 2388  class Test_util_overloaded_binary_still_
2388        res=arg0**arg1        res=arg0**arg1
2389        s1=numarray.array([[[[2.6380701938784497, 2.9629720449422932, 2.0446868934255567, 4.8175127309430978], [1.3635679921902024, 4.0348929972817613, 0.48578845331301845, 0.6568058052005824], [3.6259594179773944, 4.8833845034250496, 0.17118845347763492, 2.8807344472514744]], [[3.7872819664046382, 2.0283029183322161, 4.195326597362893, 0.8191596059342755], [4.662510379944262, 4.789692391303805, 3.4481515021939262, 4.9761891209019513], [2.2719212875559021, 0.82975847999621222, 4.439414472830145, 1.8852687223641864]]], [[[2.7020104975723047, 4.5020705352915407, 1.5409389663367554, 0.97655922243535154], [4.4327920846767279, 1.2070229778784267, 1.180070165465704, 4.1464377615296018], [2.3485800159004779, 0.92564409151457272, 1.3159639335830047, 2.1511673414313619]], [[0.67131880064612526, 4.8955556418535782, 2.2506779725819133, 0.87252916617244536], [4.4692090605181223, 0.5599807925656004, 0.45977109117815407, 4.241776420974686], [0.10366241812321508, 3.474014078895685, 3.7814907650865814, 0.42360844286683369]]], [[[4.6735648406283454, 4.8096752492979133, 2.4020835023858504, 0.028018252523416498], [3.0625590290547757, 0.58899929292552688, 2.9657775813630796, 2.8232788482355757], [3.5721497242605142, 0.1026911589702196, 0.96937822981287203, 1.4745359217544272]], [[4.4358232648059834, 4.8858574700575055, 0.12958247843545609, 2.3143102578684847], [4.4995406401536417, 2.7438403794734514, 0.79036172567538532, 2.8291086208021698], [2.1403277048976621, 1.7854892302428567, 3.2175511398028198, 2.2141578239271626]]]])        s1=numarray.array([[[[2.6380701938784497, 2.9629720449422932, 2.0446868934255567, 4.8175127309430978], [1.3635679921902024, 4.0348929972817613, 0.48578845331301845, 0.6568058052005824], [3.6259594179773944, 4.8833845034250496, 0.17118845347763492, 2.8807344472514744]], [[3.7872819664046382, 2.0283029183322161, 4.195326597362893, 0.8191596059342755], [4.662510379944262, 4.789692391303805, 3.4481515021939262, 4.9761891209019513], [2.2719212875559021, 0.82975847999621222, 4.439414472830145, 1.8852687223641864]]], [[[2.7020104975723047, 4.5020705352915407, 1.5409389663367554, 0.97655922243535154], [4.4327920846767279, 1.2070229778784267, 1.180070165465704, 4.1464377615296018], [2.3485800159004779, 0.92564409151457272, 1.3159639335830047, 2.1511673414313619]], [[0.67131880064612526, 4.8955556418535782, 2.2506779725819133, 0.87252916617244536], [4.4692090605181223, 0.5599807925656004, 0.45977109117815407, 4.241776420974686], [0.10366241812321508, 3.474014078895685, 3.7814907650865814, 0.42360844286683369]]], [[[4.6735648406283454, 4.8096752492979133, 2.4020835023858504, 0.028018252523416498], [3.0625590290547757, 0.58899929292552688, 2.9657775813630796, 2.8232788482355757], [3.5721497242605142, 0.1026911589702196, 0.96937822981287203, 1.4745359217544272]], [[4.4358232648059834, 4.8858574700575055, 0.12958247843545609, 2.3143102578684847], [4.4995406401536417, 2.7438403794734514, 0.79036172567538532, 2.8291086208021698], [2.1403277048976621, 1.7854892302428567, 3.2175511398028198, 2.2141578239271626]]]])
2390        sub=res.substitute({arg1:s1})        sub=res.substitute({arg1:s1})
2391        msk_ref=whereNegative(self.functionspace.getX()[0]-0.5)        msk_ref=1.-whereZero(self.functionspace.getX()[0],1.e-8)
2392        ref=msk_ref*numarray.array([[[[0.46697236820910309, 0.4251688569858818, 0.55421437937030293, 0.24892928289707733], [0.67462579387593102, 0.31202205865545657, 0.86916353458001161, 0.82729945889608358], [0.35111490324641437, 0.24424084521249903, 0.95178705456471835, 0.4353822920175896]], [[0.33513967826607993, 0.55684161809685462, 0.29790193303502599, 0.78942349360018449], [0.26031974043813144, 0.25093633422170408, 0.36960623321731489, 0.23778491271896876], [0.5190290391620882, 0.7870120299198623, 0.27763514033863773, 0.58031323020447134]]], [[[0.4584327319058415, 0.2726590153429701, 0.64095522784194636, 0.75435958166730099], [0.27816636635874648, 0.70580941159230892, 0.71132202006551259, 0.30213569162871079], [0.50767024397026028, 0.76552810261749937, 0.68395982577298942, 0.53743925812492843]], [[0.82384097660306221, 0.24338427701318588, 0.5222214683526496, 0.77735542213054876], [0.27525763916079377, 0.85074760711847108, 0.8757155010308979, 0.29393436593140532], [0.97052084128694038, 0.36685728768934739, 0.33570038099456212, 0.88490447516411319]]], [[[0.25949041102751735, 0.24949307499742268, 0.49989006439112732, 0.99194508136056547], [0.41312093974828379, 0.84365128690300062, 0.4248246841166638, 0.44266318304703822], [0.35661109732082952, 0.97079297101378215, 0.75592484780330382, 0.65335916612578604]], [[0.2779230891091658, 0.24406656155341364, 0.96328661097812074, 0.5127170622032361], [0.27285820009128608, 0.45293076326734039, 0.79601298639062723, 0.44191890575185372], [0.53912347815665429, 0.59727019317581997, 0.39504573523467901, 0.52775565076090036]]]])+(1.-msk_ref)*numarray.array([[[[14.691046718037269, 20.454350037996647, 8.0268769664070003, 135.27381407927967], [4.0107650751284751, 60.952499669669109, 1.6402399176594569, 1.952376358334921], [40.186842086843704, 144.66206840658916, 1.1905067348617921, 18.810688455066671]], [[47.364305203048531, 7.8940253918321845, 71.773735613725677, 2.3034937866731684], [115.51607639444967, 131.49411855954435, 33.529235226876615, 159.00485859216263], [10.117484786482814, 2.3284979957690046, 92.033787676254107, 6.8237293167676798]]], [[[15.679752919549529, 98.099238680439939, 4.8050084874390588, 2.7040758813612364], [91.415034073834107, 3.419585458341726, 3.3269773094822024, 68.286943858713769], [10.939199023944678, 2.5674062272419249, 3.8209180362455766, 8.9464834982803971]], [[1.981453691419933, 146.46675031929558, 9.900901847104036, 2.4321880005782641], [94.869822531040455, 1.7690057222223956, 1.597340808107695, 75.251373799975866], [1.1113710866765436, 34.42428766459463, 47.085719191365783, 1.5395706950189538]]], [[[116.82419551043782, 134.19814758177736, 11.551938486777251, 1.0289516346644614], [22.638197863126429, 1.822076880682197, 20.512888611573942, 17.741362775456043], [38.043378121935739, 1.1102720828025088, 2.6843681900085201, 4.4907429327926405]], [[91.697730193603263, 145.02693984793967, 1.1411056053730484, 10.563916657693198], [97.846757795918251, 16.362297569123484, 2.2369031706777256, 17.847032010620911], [8.8482427982193652, 6.1642530670809563, 26.509932823363236, 9.5393470687936492]]]])        ref=msk_ref*numarray.array([[[[0.46697236820910309, 0.4251688569858818, 0.55421437937030293, 0.24892928289707733], [0.67462579387593102, 0.31202205865545657, 0.86916353458001161, 0.82729945889608358], [0.35111490324641437, 0.24424084521249903, 0.95178705456471835, 0.4353822920175896]], [[0.33513967826607993, 0.55684161809685462, 0.29790193303502599, 0.78942349360018449], [0.26031974043813144, 0.25093633422170408, 0.36960623321731489, 0.23778491271896876], [0.5190290391620882, 0.7870120299198623, 0.27763514033863773, 0.58031323020447134]]], [[[0.4584327319058415, 0.2726590153429701, 0.64095522784194636, 0.75435958166730099], [0.27816636635874648, 0.70580941159230892, 0.71132202006551259, 0.30213569162871079], [0.50767024397026028, 0.76552810261749937, 0.68395982577298942, 0.53743925812492843]], [[0.82384097660306221, 0.24338427701318588, 0.5222214683526496, 0.77735542213054876], [0.27525763916079377, 0.85074760711847108, 0.8757155010308979, 0.29393436593140532], [0.97052084128694038, 0.36685728768934739, 0.33570038099456212, 0.88490447516411319]]], [[[0.25949041102751735, 0.24949307499742268, 0.49989006439112732, 0.99194508136056547], [0.41312093974828379, 0.84365128690300062, 0.4248246841166638, 0.44266318304703822], [0.35661109732082952, 0.97079297101378215, 0.75592484780330382, 0.65335916612578604]], [[0.2779230891091658, 0.24406656155341364, 0.96328661097812074, 0.5127170622032361], [0.27285820009128608, 0.45293076326734039, 0.79601298639062723, 0.44191890575185372], [0.53912347815665429, 0.59727019317581997, 0.39504573523467901, 0.52775565076090036]]]])+(1.-msk_ref)*numarray.array([[[[14.691046718037269, 20.454350037996647, 8.0268769664070003, 135.27381407927967], [4.0107650751284751, 60.952499669669109, 1.6402399176594569, 1.952376358334921], [40.186842086843704, 144.66206840658916, 1.1905067348617921, 18.810688455066671]], [[47.364305203048531, 7.8940253918321845, 71.773735613725677, 2.3034937866731684], [115.51607639444967, 131.49411855954435, 33.529235226876615, 159.00485859216263], [10.117484786482814, 2.3284979957690046, 92.033787676254107, 6.8237293167676798]]], [[[15.679752919549529, 98.099238680439939, 4.8050084874390588, 2.7040758813612364], [91.415034073834107, 3.419585458341726, 3.3269773094822024, 68.286943858713769], [10.939199023944678, 2.5674062272419249, 3.8209180362455766, 8.9464834982803971]], [[1.981453691419933, 146.46675031929558, 9.900901847104036, 2.4321880005782641], [94.869822531040455, 1.7690057222223956, 1.597340808107695, 75.251373799975866], [1.1113710866765436, 34.42428766459463, 47.085719191365783, 1.5395706950189538]]], [[[116.82419551043782, 134.19814758177736, 11.551938486777251, 1.0289516346644614], [22.638197863126429, 1.822076880682197, 20.512888611573942, 17.741362775456043], [38.043378121935739, 1.1102720828025088, 2.6843681900085201, 4.4907429327926405]], [[91.697730193603263, 145.02693984793967, 1.1411056053730484, 10.563916657693198], [97.846757795918251, 16.362297569123484, 2.2369031706777256, 17.847032010620911], [8.8482427982193652, 6.1642530670809563, 26.509932823363236, 9.5393470687936492]]]])
2393        self.failUnless(isinstance(res,Symbol),"wrong type of result.")        self.failUnless(isinstance(res,Symbol),"wrong type of result.")
2394        self.failUnlessEqual(res.getShape(),(3, 2, 3, 4),"wrong shape of result.")        self.failUnlessEqual(res.getShape(),(3, 2, 3, 4),"wrong shape of result.")
# Line 2679  class Test_util_overloaded_binary_still_ Line 2401  class Test_util_overloaded_binary_still_
2401        res=arg0**arg1        res=arg0**arg1
2402        s1=numarray.array(0.699591439915)        s1=numarray.array(0.699591439915)
2403        sub=res.substitute({arg1:s1})        sub=res.substitute({arg1:s1})
2404        msk_ref=whereNegative(self.functionspace.getX()[0]-0.5)        msk_ref=1.-whereZero(self.functionspace.getX()[0],1.e-8)
2405        ref=msk_ref*numarray.array([2.3399771894150048, 1.1701585901306912])+(1.-msk_ref)*numarray.array([1.961444030062393, 2.6191950693986477])        ref=msk_ref*numarray.array([2.3399771894150048, 1.1701585901306912])+(1.-msk_ref)*numarray.array([1.961444030062393, 2.6191950693986477])
2406        self.failUnless(isinstance(res,Symbol),"wrong type of result.")        self.failUnless(isinstance(res,Symbol),"wrong type of result.")
2407        self.failUnlessEqual(res.getShape(),(2,),"wrong shape of result.")        self.failUnlessEqual(res.getShape(),(2,),"wrong shape of result.")
# Line 2692  class Test_util_overloaded_binary_still_ Line 2414  class Test_util_overloaded_binary_still_
2414        res=arg0**arg1        res=arg0**arg1
2415        s1=numarray.array([0.19493460590675868, 0.37275617681790979])        s1=numarray.array([0.19493460590675868, 0.37275617681790979])
2416        sub=res.substitute({arg1:s1})        sub=res.substitute({arg1:s1})
2417        msk_ref=whereNegative(self.functionspace.getX()[0]-0.5)        msk_ref=1.-whereZero(self.functionspace.getX()[0],1.e-8)
2418        ref=msk_ref*numarray.array([1.1002656649360483, 1.7464991087435378])+(1.-msk_ref)*numarray.array([1.2970675798548577, 0.92753082328744252])        ref=msk_ref*numarray.array([1.1002656649360483, 1.7464991087435378])+(1.-msk_ref)*numarray.array([1.2970675798548577, 0.92753082328744252])
2419        self.failUnless(isinstance(res,Symbol),"wrong type of result.")        self.failUnless(isinstance(res,Symbol),"wrong type of result.")
2420        self.failUnlessEqual(res.getShape(),(2,),"wrong shape of result.")        self.failUnlessEqual(res.getShape(),(2,),"wrong shape of result.")
# Line 2705  class Test_util_overloaded_binary_still_ Line 2427  class Test_util_overloaded_binary_still_
2427        res=arg0**arg1        res=arg0**arg1
2428        s1=numarray.array(3.78316573875)        s1=numarray.array(3.78316573875)
2429        sub=res.substitute({arg1:s1})        sub=res.substitute({arg1:s1})
2430        msk_ref=whereNegative(self.functionspace.getX()[0]-0.5)        msk_ref=1.-whereZero(self.functionspace.getX()[0],1.e-8)
2431        ref=msk_ref*numarray.array([[18.779775455751572, 4.1420177962146392, 35.957264419285686, 58.476737694947722, 0.082853171282090368], [358.29836883297418, 111.90699977530605, 0.65137899230049978, 141.60168268705098, 253.09677617643018], [73.439289997168572, 0.28685689187808994, 105.66597309931271, 7.375725087754101, 21.270319186387162], [87.434158812368196, 57.278835913940632, 336.04006980086507, 70.251208719601834, 343.026691645879]])+(1.-msk_ref)*numarray.array([[1.3938881764903226, 14.700284663667441, 11.73805133343139, 211.49498553743527, 385.50749280191758], [346.90396824584991, 418.45522695975438, 0.001659846678596532, 27.087693111746457, 32.548382942851433], [28.034349489398465, 4.760824245330129, 29.366567710791657, 184.31350289398216, 275.18010771503333], [14.387946682774784, 317.89053486869193, 3.808357224353176, 299.14481902814708, 68.033345855427385]])        ref=msk_ref*numarray.array([[18.779775455751572, 4.1420177962146392, 35.957264419285686, 58.476737694947722, 0.082853171282090368], [358.29836883297418, 111.90699977530605, 0.65137899230049978, 141.60168268705098, 253.09677617643018], [73.439289997168572, 0.28685689187808994, 105.66597309931271, 7.375725087754101, 21.270319186387162], [87.434158812368196, 57.278835913940632, 336.04006980086507, 70.251208719601834, 343.026691645879]])+(1.-msk_ref)*numarray.array([[1.3938881764903226, 14.700284663667441, 11.73805133343139, 211.49498553743527, 385.50749280191758], [346.90396824584991, 418.45522695975438, 0.001659846678596532, 27.087693111746457, 32.548382942851433], [28.034349489398465, 4.760824245330129, 29.366567710791657, 184.31350289398216, 275.18010771503333], [14.387946682774784, 317.89053486869193, 3.808357224353176, 299.14481902814708, 68.033345855427385]])
2432        self.failUnless(isinstance(res,Symbol),"wrong type of result.")        self.failUnless(isinstance(res,Symbol),"wrong type of result.")
2433        self.failUnlessEqual(res.getShape(),(4, 5),"wrong shape of result.")        self.failUnlessEqual(res.getShape(),(4, 5),"wrong shape of result.")
# Line 2718  class Test_util_overloaded_binary_still_ Line 2440  class Test_util_overloaded_binary_still_
2440        res=arg0**arg1        res=arg0**arg1
2441        s1=numarray.array([[1.6740108349001657, 1.0983217973929327, 2.6623064498244773, 2.2798561052986765, 3.6845747147837828], [4.3798182023690195, 4.2698739944277841, 4.2383864724604932, 4.9591926764314964, 1.9824609539459526], [3.2387478783732324, 3.3259184012655032, 2.1941523398057003, 4.0625995557427093, 4.8743264039948446], [4.8481310965503583, 1.7779251415271708, 1.5207108244957652, 2.8795914146785719, 3.1141173303804011]])        s1=numarray.array([[1.6740108349001657, 1.0983217973929327, 2.6623064498244773, 2.2798561052986765, 3.6845747147837828], [4.3798182023690195, 4.2698739944277841, 4.2383864724604932, 4.9591926764314964, 1.9824609539459526], [3.2387478783732324, 3.3259184012655032, 2.1941523398057003, 4.0625995557427093, 4.8743264039948446], [4.8481310965503583, 1.7779251415271708, 1.5207108244957652, 2.8795914146785719, 3.1141173303804011]])
2442        sub=res.substitute({arg1:s1})        sub=res.substitute({arg1:s1})
2443        msk_ref=whereNegative(self.functionspace.getX()[0]-0.5)        msk_ref=1.-whereZero(self.functionspace.getX()[0],1.e-8)
2444        ref=msk_ref*numarray.array([[8.417972599993977, 3.5785602759130959, 54.89401322776628, 0.04446823603392755, 0.045523959981275147], [85.521388499072543, 857.00193926760005, 0.0075430058128210555, 0.24368075613780074, 7.8886461687139846], [101.375399563874, 60.612767354257009, 19.176435549891746, 596.73527193917596, 0.013125179067304385], [0.018840957902037998, 14.873123822489182, 2.412442697829198, 17.538356540586207, 67.011850455779282]])+(1.-msk_ref)*numarray.array([[5.6326999533695528, 3.8104873485274715, 0.042578313772200164, 1.1254140167308759, 223.62815838004201], [9.9811609597114664e-07, 4.4156660315269248e-05, 172.33841809891487, 422.54920258499891, 4.3887361076615221], [80.343152159641292, 3.2364636570138612, 15.002564341252342, 0.00037313137629075503, 45.727033232007521], [42.176056669762183, 7.7638809912833535, 2.410032511928951, 46.12867892129659, 0.61251300718761692]])        ref=msk_ref*numarray.array([[8.417972599993977, 3.5785602759130959, 54.89401322776628, 0.04446823603392755, 0.045523959981275147], [85.521388499072543, 857.00193926760005, 0.0075430058128210555, 0.24368075613780074, 7.8886461687139846], [101.375399563874, 60.612767354257009, 19.176435549891746, 596.73527193917596, 0.013125179067304385], [0.018840957902037998, 14.873123822489182, 2.412442697829198, 17.538356540586207, 67.011850455779282]])+(1.-msk_ref)*numarray.array([[5.6326999533695528, 3.8104873485274715, 0.042578313772200164, 1.1254140167308759, 223.62815838004201], [9.9811609597114664e-07, 4.4156660315269248e-05, 172.33841809891487, 422.54920258499891, 4.3887361076615221], [80.343152159641292, 3.2364636570138612, 15.002564341252342, 0.00037313137629075503, 45.727033232007521], [42.176056669762183, 7.7638809912833535, 2.410032511928951, 46.12867892129659, 0.61251300718761692]])
2445        self.failUnless(isinstance(res,Symbol),"wrong type of result.")        self.failUnless(isinstance(res,Symbol),"wrong type of result.")
2446        self.failUnlessEqual(res.getShape(),(4, 5),"wrong shape of result.")        self.failUnlessEqual(res.getShape(),(4, 5),"wrong shape of result.")
# Line 2731  class Test_util_overloaded_binary_still_ Line 2453  class Test_util_overloaded_binary_still_
2453        res=arg0**arg1        res=arg0**arg1
2454        s1=numarray.array(1.64119571575)        s1=numarray.array(1.64119571575)
2455        sub=res.substitute({arg1:s1})        sub=res.substitute({arg1:s1})
2456        msk_ref=whereNegative(self.functionspace.getX()[0]-0.5)        msk_ref=1.-whereZero(self.functionspace.getX()[0],1.e-8)
2457        ref=msk_ref*numarray.array([[[1.9930901042958082, 3.002574660335485], [2.5427898612694202, 0.0069420127858769061]], [[2.5558956598031486, 3.0614967927086982], [4.7513950253624326, 8.5950885220880409]], [[5.6113975378576457, 2.314892597573075], [0.26259333944973678, 0.046372745994703042]], [[13.469537098377412, 6.2273831362190117], [12.30764818435267, 10.983802793710373]], [[0.70352398635403779, 0.39026469662582264], [4.4681583148783117, 1.3164733429091755]], [[0.019559420904627398, 1.7716023809068993], [7.2046823707751297, 1.4033469855089122]]])+(1.-msk_ref)*numarray.array([[[13.456416622942902, 0.20290200992370636], [4.2444374915697596, 4.555600020117053]], [[0.54042975712737396, 3.3267961785662878], [8.6910804035262679, 12.199682654465931]], [[5.2058678192157588, 3.8971894283303108], [7.3243458168738007, 12.418428073578472]], [[11.69003291392138, 6.1516337953720388], [10.467877865690189, 1.2024550430674248]], [[0.32646300963953717, 5.8812480980889106], [12.939594832592748, 4.9884248325848493]], [[7.721745317334916, 5.8959018271931791], [12.38897315671394, 2.017120291385428]]])        ref=msk_ref*numarray.array([[[1.9930901042958082, 3.002574660335485], [2.5427898612694202, 0.0069420127858769061]], [[2.5558956598031486, 3.0614967927086982], [4.7513950253624326, 8.5950885220880409]], [[5.6113975378576457, 2.314892597573075], [0.26259333944973678, 0.046372745994703042]], [[13.469537098377412, 6.2273831362190117], [12.30764818435267, 10.983802793710373]], [[0.70352398635403779, 0.39026469662582264], [4.4681583148783117, 1.3164733429091755]], [[0.019559420904627398, 1.7716023809068993], [7.2046823707751297, 1.4033469855089122]]])+(1.-msk_ref)*numarray.array([[[13.456416622942902, 0.20290200992370636], [4.2444374915697596, 4.555600020117053]], [[0.54042975712737396, 3.3267961785662878], [8.6910804035262679, 12.199682654465931]], [[5.2058678192157588, 3.8971894283303108], [7.3243458168738007, 12.418428073578472]], [[11.69003291392138, 6.1516337953720388], [10.467877865690189, 1.2024550430674248]], [[0.32646300963953717, 5.8812480980889106], [12.939594832592748, 4.9884248325848493]], [[7.721745317334916, 5.8959018271931791], [12.38897315671394, 2.017120291385428]]])
2458        self.failUnless(isinstance(res,Symbol),"wrong type of result.")        self.failUnless(isinstance(res,Symbol),"wrong type of result.")
2459        self.failUnlessEqual(res.getShape(),(6, 2, 2),"wrong shape of result.")        self.failUnlessEqual(res.getShape(),(6, 2, 2),"wrong shape of result.")
# Line 2744  class Test_util_overloaded_binary_still_ Line 2466  class Test_util_overloaded_binary_still_
2466        res=arg0**arg1        res=arg0**arg1
2467        s1=numarray.array([[[3.3768399353556626, 3.4694128090700103], [2.6611077778706638, 4.7864233330931185]], [[4.9555409678460247, 0.010698537162774534], [2.8076143657320407, 3.7887318420629978]], [[2.1423378448144343, 3.7966127742235574], [1.5741855830682956, 2.1033597558551511]], [[3.9825245309777801, 3.6349263894947268], [3.5799239365129902, 2.0164283244391386]], [[3.6226439393408643, 4.9183593732809756], [1.7503012770341879, 1.0972210847818915]], [[3.6053129680740859, 0.62203119125832551], [2.0971628851516746, 3.4194100307384194]]])        s1=numarray.array([[[3.3768399353556626, 3.4694128090700103], [2.6611077778706638, 4.7864233330931185]], [[4.9555409678460247, 0.010698537162774534], [2.8076143657320407, 3.7887318420629978]], [[2.1423378448144343, 3.7966127742235574], [1.5741855830682956, 2.1033597558551511]], [[3.9825245309777801, 3.6349263894947268], [3.5799239365129902, 2.0164283244391386]], [[3.6226439393408643, 4.9183593732809756], [1.7503012770341879, 1.0972210847818915]], [[3.6053129680740859, 0.62203119125832551], [2.0971628851516746, 3.4194100307384194]]])
2468        sub=res.substitute({arg1:s1})        sub=res.substitute({arg1:s1})
2469        msk_ref=whereNegative(self.functionspace.getX()[0]-0.5)        msk_ref=1.-whereZero(self.functionspace.getX()[0],1.e-8)
2470        ref=msk_ref*numarray.array([[[54.611349170405944, 33.551816341891154], [0.016825760933191474, 208.00979874129121]], [[10.455137735826503, 1.0100372010979246], [20.958463298115625, 90.860711273194042]], [[0.031583528579419061, 281.94806992465448], [12.515953279940252, 16.361342175787566]], [[0.25711048110146106, 0.0015972351316030258], [229.9296414285823, 14.777410118323925]], [[278.96748872614285, 51.911088761839025], [0.39363525259421744, 2.8627384505791156]], [[145.85298054850662, 1.4164354746260404], [7.9869868217120832, 105.76186523993667]]])+(1.-msk_ref)*numarray.array([[[132.34735806170755, 0.032074955115904545], [3.643215388155344, 0.21731329247521483]], [[53.405342835947991, 1.0144990942028391], [8.3099079183543108, 399.82240904268821]], [[26.504634051058805, 157.77722575526394], [11.020782121972983, 26.290062276398668]], [[79.381573877626664, 171.86061546946161], [225.84646216243317, 0.70423922334287992]], [[5.2335663139405515, 238.3353173607245], [9.9924053355866782, 2.7623614919775887]], [[133.82698542544125, 2.0185856905716197], [4.3738376971351727, 8.6766294923839542]]])        ref=msk_ref*numarray.array([[[54.611349170405944, 33.551816341891154], [0.016825760933191474, 208.00979874129121]], [[10.455137735826503, 1.0100372010979246], [20.958463298115625, 90.860711273194042]], [[0.031583528579419061, 281.94806992465448], [12.515953279940252, 16.361342175787566]], [[0.25711048110146106, 0.0015972351316030258], [229.9296414285823, 14.777410118323925]], [[278.96748872614285, 51.911088761839025], [0.39363525259421744, 2.8627384505791156]], [[145.85298054850662, 1.4164354746260404], [7.9869868217120832, 105.76186523993667]]])+(1.-msk_ref)*numarray.array([[[132.34735806170755, 0.032074955115904545], [3.643215388155344, 0.21731329247521483]], [[53.405342835947991, 1.0144990942028391], [8.3099079183543108, 399.82240904268821]], [[26.504634051058805, 157.77722575526394], [11.020782121972983, 26.290062276398668]], [[79.381573877626664, 171.86061546946161], [225.84646216243317, 0.70423922334287992]], [[5.2335663139405515, 238.3353173607245], [9.9924053355866782, 2.7623614919775887]], [[133.82698542544125, 2.0185856905716197], [4.3738376971351727, 8.6766294923839542]]])
2471        self.failUnless(isinstance(res,Symbol),"wrong type of result.")        self.failUnless(isinstance(res,Symbol),"wrong type of result.")
2472        self.failUnlessEqual(res.getShape(),(6, 2, 2),"wrong shape of result.")        self.failUnlessEqual(res.getShape(),(6, 2, 2),"wrong shape of result.")
# Line 2757  class Test_util_overloaded_binary_still_ Line 2479  class Test_util_overloaded_binary_still_
2479        res=arg0**arg1        res=arg0**arg1
2480        s1=numarray.array(3.00721465635)        s1=numarray.array(3.00721465635)
2481        sub=res.substitute({arg1:s1})        sub=res.substitute({arg1:s1})
2482        msk_ref=whereNegative(self.functionspace.getX()[0]-0.5)        msk_ref=1.-whereZero(self.functionspace.getX()[0],1.e-8)
2483        ref=msk_ref*numarray.array([[[[75.994976867439803, 12.50633121610999, 57.782599581306592, 0.2565945118887632], [23.084939750462468, 46.213277188139855, 13.705912822314609, 10.77824143665204], [91.645226942686008, 57.009759686387333, 49.327264383384161, 60.542076750768885]], [[26.108778957812682, 9.5588378006294121, 73.831580911631121, 51.160189377363373], [0.062479018571655304, 6.6622789152002282, 63.891565065975122, 0.0004675789126183552], [58.58085952446153, 51.758134982919799, 0.35336162394001208, 0.082528076782454038]]], [[[0.019297783239073128, 68.414857246086015, 1.9721043855197204, 11.101629409398022], [43.594504470870952, 0.9669355121908868, 44.80781776747363, 8.8235413438107848], [108.82730249961899, 2.5563580473041565, 25.095278510208956, 46.018142912233621]], [[85.961538704520152, 85.363798865089876, 89.272509062018315, 4.8379328339455574], [15.991504055444196, 10.32499108131171, 3.7664516474452041, 59.874566270699532], [11.491897023948152, 4.4729902471536089, 3.2852766859308606, 37.098390391152456]]], [[[111.93201389233471, 88.842594287004516, 51.041555891817247, 35.093575417317567], [6.9698524133185407, 124.49707945056491, 107.56575858008239, 93.215510790306027], [50.443173316528799, 46.816076667090435, 0.69412903294027151, 68.595920262571042]], [[7.8767746910450036, 42.978677215453878, 16.865979797461918, 5.4295686447304004], [101.159128946537, 1.3045774124821155, 15.261840560843588, 30.263739220960041], [80.34070323696676, 15.751581054399395, 18.353214527131929, 115.46250497279942]]]])+(1.-msk_ref)*numarray.array([[[[6.227635835295454e-05, 29.096843083285542, 1.7929473444459771, 95.503652502858856], [1.2811828278654707, 2.2720535806236151, 12.033000738069527, 63.016049222056161], [0.20648454901252414, 32.258280229865036, 3.3130174338816314, 48.063846177673497]], [[9.4414262588103739, 60.878150526760194, 42.148223517841103, 91.164240877455583], [8.1693359575756226, 59.138065030149569, 13.712359560482147, 103.93210257196748], [0.10972837322621674, 89.304645640604846, 0.14088565633753561, 0.31560056174522472]]], [[[72.279431633968372, 10.865183447156275, 50.427120149651856, 39.988713234801118], [0.79818308851312636, 8.6669110137735164, 13.195561190971887, 21.7592117054641], [18.615419706790959, 61.542823591376361, 88.227450699602016, 0.00034030814057911448]], [[1.7748901256399299, 3.0445779900074598e-06, 86.452387509998957, 8.3649048506225469e-06], [7.5652104456080727, 60.391280920939067, 18.583980127991737, 0.0020760439153237353], [15.79729403077487, 1.0091758491813847, 21.916329618863852, 0.070852061423832075]]], [[[112.63385954023728, 1.2328107836351652, 0.02316730022354687, 20.616623599453593], [16.736715422016417, 69.649817974873542, 0.017290067604402621, 18.892380231011206], [0.33037678392750758, 15.193363842122821, 3.0625090532330823, 113.3410267877975]], [[23.263648335824051, 48.332536178107922, 0.0016504437263980404, 2.4632563964751952], [11.641662938111672, 10.104916840913434, 10.212894104870339, 95.908921590674993], [0.10719597296797677, 0.0044669199408652526, 81.258618143030674, 26.891741309440064]]]])        ref=msk_ref*numarray.array([[[[75.994976867439803, 12.50633121610999, 57.782599581306592, 0.2565945118887632], [23.084939750462468, 46.213277188139855, 13.705912822314609, 10.77824143665204], [91.645226942686008, 57.009759686387333, 49.327264383384161, 60.542076750768885]], [[26.108778957812682, 9.5588378006294121, 73.831580911631121, 51.160189377363373], [0.062479018571655304, 6.6622789152002282, 63.891565065975122, 0.0004675789126183552], [58.58085952446153, 51.758134982919799, 0.35336162394001208, 0.082528076782454038]]], [[[0.019297783239073128, 68.414857246086015, 1.9721043855197204, 11.101629409398022], [43.594504470870952, 0.9669355121908868, 44.80781776747363, 8.8235413438107848], [108.82730249961899, 2.5563580473041565, 25.095278510208956, 46.018142912233621]], [[85.961538704520152, 85.363798865089876, 89.272509062018315, 4.8379328339455574], [15.991504055444196, 10.32499108131171, 3.7664516474452041, 59.874566270699532], [11.491897023948152, 4.4729902471536089, 3.2852766859308606, 37.098390391152456]]], [[[111.93201389233471, 88.842594287004516, 51.041555891817247, 35.093575417317567], [6.9698524133185407, 124.49707945056491, 107.56575858008239, 93.215510790306027], [50.443173316528799, 46.816076667090435, 0.69412903294027151, 68.595920262571042]], [[7.8767746910450036, 42.978677215453878, 16.865979797461918, 5.4295686447304004], [101.159128946537, 1.3045774124821155, 15.261840560843588, 30.263739220960041], [80.34070323696676, 15.751581054399395, 18.353214527131929, 115.46250497279942]]]])+(1.-msk_ref)*numarray.array([[[[6.227635835295454e-05, 29.096843083285542, 1.7929473444459771, 95.503652502858856], [1.2811828278654707, 2.2720535806236151, 12.033000738069527, 63.016049222056161], [0.20648454901252414, 32.258280229865036, 3.3130174338816314, 48.063846177673497]], [[9.4414262588103739, 60.878150526760194, 42.148223517841103, 91.164240877455583], [8.1693359575756226, 59.138065030149569, 13.712359560482147, 103.93210257196748], [0.10972837322621674, 89.304645640604846, 0.14088565633753561, 0.31560056174522472]]], [[[72.279431633968372, 10.865183447156275, 50.427120149651856, 39.988713234801118], [0.79818308851312636, 8.6669110137735164, 13.195561190971887, 21.7592117054641], [18.615419706790959, 61.542823591376361, 88.227450699602016, 0.00034030814057911448]], [[1.7748901256399299, 3.0445779900074598e-06, 86.452387509998957, 8.3649048506225469e-06], [7.5652104456080727, 60.391280920939067, 18.583980127991737, 0.0020760439153237353], [15.79729403077487, 1.0091758491813847, 21.916329618863852, 0.070852061423832075]]], [[[112.63385954023728, 1.2328107836351652, 0.02316730022354687, 20.616623599453593], [16.736715422016417, 69.649817974873542, 0.017290067604402621, 18.892380231011206], [0.33037678392750758, 15.193363842122821, 3.0625090532330823, 113.3410267877975]], [[23.263648335824051, 48.332536178107922, 0.0016504437263980404, 2.4632563964751952], [11.641662938111672, 10.104916840913434, 10.212894104870339, 95.908921590674993], [0.10719597296797677, 0.0044669199408652526, 81.258618143030674, 26.891741309440064]]]])
2484        self.failUnless(isinstance(res,Symbol),"wrong type of result.")        self.failUnless(isinstance(res,Symbol),"wrong type of result.")
2485        self.failUnlessEqual(res.getShape(),(3, 2, 3, 4),"wrong shape of result.")        self.failUnlessEqual(res.getShape(),(3, 2, 3, 4),"wrong shape of result.")
# Line 2770  class Test_util_overloaded_binary_still_ Line 2492  class Test_util_overloaded_binary_still_
2492        res=arg0**arg1        res=arg0**arg1
2493        s1=numarray.array([[[[2.0254726202872, 3.6919769974914662, 3.3813686691149161, 0.09373063287153327], [1.6162669611842946, 4.9709325713095014, 4.0088393152109481, 3.7424030376065787], [3.4901235779635638, 2.0539830752368236, 3.414996106475833, 0.39653630873783718]], [[1.6602396752962345, 3.4524174334885664, 2.3263906936168035, 4.0904786995602391], [3.5263053211774347, 2.6239447885040228, 0.19431283905255856, 0.012985596939993016], [0.30336677692584912, 3.3814046047237762, 1.8139491480051104, 1.7068169308963574]]], [[[3.7796058755742918, 0.5048138651560039, 4.1243863664103912, 4.4543337043262161], [4.7113584144666136, 1.2578628350113628, 2.4614775803231095, 4.9550787549975999], [3.9142217468685172, 1.223074455845053, 0.91758631769232324, 0.63590924526144332]], [[1.5426261315812613, 0.37308477051015732, 4.0416295548706698, 4.9972454781286366], [2.5622727884423768, 1.2723963365437676, 0.54675032085327935, 2.2747603647550592], [4.9319193527986416, 3.7113682336235283, 0.5774316017156943, 4.3210733276807245]]], [[[3.3395390932579105, 4.8861871770114211, 1.7279377363039217, 0.72713220720108918], [0.57694916336954549, 4.9349658201681228, 1.0306577039927605, 0.45152739831893446], [1.2720221945497059, 1.554592467497466, 0.29353486797752176, 2.3664226641838439]], [[3.1847561474031609, 4.1310775736116501, 4.4788521685746385, 1.2722456227629599], [2.2057576454442178, 3.530894953720086, 1.073018364096219, 4.8520723881119912], [1.3176068423805134, 1.2504792548799262, 4.876110890905319, 4.6619458105804341]]]])        s1=numarray.array([[[[2.0254726202872, 3.6919769974914662, 3.3813686691149161, 0.09373063287153327], [1.6162669611842946, 4.9709325713095014, 4.0088393152109481, 3.7424030376065787], [3.4901235779635638, 2.0539830752368236, 3.414996106475833, 0.39653630873783718]], [[1.6602396752962345, 3.4524174334885664, 2.3263906936168035, 4.0904786995602391], [3.5263053211774347, 2.6239447885040228, 0.19431283905255856, 0.012985596939993016], [0.30336677692584912, 3.3814046047237762, 1.8139491480051104, 1.7068169308963574]]], [[[3.7796058755742918, 0.5048138651560039, 4.1243863664103912, 4.4543337043262161], [4.7113584144666136, 1.2578628350113628, 2.4614775803231095, 4.9550787549975999], [3.9142217468685172, 1.223074455845053, 0.91758631769232324, 0.63590924526144332]], [[1.5426261315812613, 0.37308477051015732, 4.0416295548706698, 4.9972454781286366], [2.5622727884423768, 1.2723963365437676, 0.54675032085327935, 2.2747603647550592], [4.9319193527986416, 3.7113682336235283, 0.5774316017156943, 4.3210733276807245]]], [[[3.3395390932579105, 4.8861871770114211, 1.7279377363039217, 0.72713220720108918], [0.57694916336954549, 4.9349658201681228, 1.0306577039927605, 0.45152739831893446], [1.2720221945497059, 1.554592467497466, 0.29353486797752176, 2.3664226641838439]], [[3.1847561474031609, 4.1310775736116501, 4.4788521685746385, 1.2722456227629599], [2.2057576454442178, 3.530894953720086, 1.073018364096219, 4.8520723881119912], [1.3176068423805134, 1.2504792548799262, 4.876110890905319, 4.6619458105804341]]]])
2494        sub=res.substitute({arg1:s1})        sub=res.substitute({arg1:s1})
2495        msk_ref=whereNegative(self.functionspace.getX()[0]-0.5)        msk_ref=1.-whereZero(self.functionspace.getX()[0],1.e-8)
2496        ref=msk_ref*numarray.array([[[[16.613962329168, 0.0017486311486089434, 126.69063036727491, 1.1152171877115666], [3.5064109586864305, 550.42075885638508, 62.133555452100822, 8.4966065094058578], [148.01277927509608, 3.269525105620906, 47.063145201168908, 1.5030590809306388]], [[3.5453897266571519, 79.072666513352345, 14.682695727663457, 155.92116917194539], [134.02693074666809, 3.6839070193302299, 1.3341221841214275, 1.0209013213436253], [1.318706764357056, 1.1466185738458463, 14.815470274042406, 11.654224865734468]]], [[[152.34591889853269, 1.9197355212658576, 18.305659634578621, 856.59235604444245], [63.223779415997093, 3.5379957805086573, 0.46707731489374876, 2288.5846065945393], [49.74322894940898, 3.9424656742504154, 1.9971913605873199, 1.3988972384028238]], [[9.1207777229361628, 1.3481142712254719, 24.590656887978088, 1.7044869074222006e-06], [9.9459704275539202, 1.1489720373711589, 1.9688323547616904, 1.0632512140862307], [2356.22906167467, 329.2953355431639, 0.52839405082563173, 79.42832429292362]]], [[[7.7590926484431781, 7.8559270157256638, 4.2195615756873579, 1.6610213995770469], [1.6873647533234348, 435.57281863570262, 3.8127293996659732, 1.9183701053366202], [2.6779719353579701, 1.7527757710519118, 1.5546253576726097, 3.7622528418241332]], [[0.29090937370999143, 39.075342794630501, 0.068209231168206222, 0.26490106217761356], [0.7319115303721988, 0.018639648195352566, 1.487226641525681, 802.09239984700025], [1.8508678118182738, 0.94700788085623444, 1751.9238412049178, 620.05569094382963]]]])+(1.-msk_ref)*numarray.array([[[[13.856822049793017, 0.1698522615234575, 222.50343712128958, 1.1195664976441784], [9.9960868244070049, 16.443333318172524, 364.05869186298531, 168.38120432754178], [61.470491313669029, 7.7956349835148826, 189.13615479213124, 1.6330285111956921]], [[7.26188705507567, 246.82050235190837, 0.15293534435498729, 0.63345600430807603], [12.518574538497633, 4.4805273946663906, 1.0996896850839557, 0.99010814263927649], [1.1416620062301488, 5.0262201940346474, 12.39161493146015, 2.90396926889709]]], [[[2.4430889022943201, 1.7047018615804435, 2.735433708206461, 7.4921037130989347], [427.62797298014726, 3.5670030379673809, 0.18293758482727099, 2450.4757056595199], [0.0032770090774681578, 0.94030333258667465, 3.0554384486298329, 1.7621278935769478]], [[2.2943818903026822, 1.6693380489197964, 8.1007981718172797, 547.06551016331537], [8.8866562959414264, 2.9538697449771694, 1.6856526337855318, 14.531711428757538], [0.039028757184659611, 1.1494849825630689, 1.9537983088661117, 365.6111871732702]]], [[[41.487252198220233, 12.409271372600921, 14.477856649277644, 1.1160774287382553], [0.32944857634125907, 951.85642064916613, 4.7097294212465224, 0.88863208972274543], [5.397964054706577, 1.3973452674961897, 1.0251696549037674, 0.051538737074028972]], [[94.200810882618157, 255.44743759847563, 29.764980791325101, 7.5522628734351223], [32.899896048305123, 46.587640503793793, 1.109950949907152, 25.253014478094745], [8.2156055132226768, 1.552559066995099, 0.35889915295693109, 33.447260310417171]]]])        ref=msk_ref*numarray.array([[[[16.613962329168, 0.0017486311486089434, 126.69063036727491, 1.1152171877115666], [3.5064109586864305, 550.42075885638508, 62.133555452100822, 8.4966065094058578], [148.01277927509608, 3.269525105620906, 47.063145201168908, 1.5030590809306388]], [[3.5453897266571519, 79.072666513352345, 14.682695727663457, 155.92116917194539], [134.02693074666809, 3.6839070193302299, 1.3341221841214275, 1.0209013213436253], [1.318706764357056, 1.1466185738458463, 14.815470274042406, 11.654224865734468]]], [[[152.34591889853269, 1.9197355212658576, 18.305659634578621, 856.59235604444245], [63.223779415997093, 3.5379957805086573, 0.46707731489374876, 2288.5846065945393], [49.74322894940898, 3.9424656742504154, 1.9971913605873199, 1.3988972384028238]], [[9.1207777229361628, 1.3481142712254719, 24.590656887978088, 1.7044869074222006e-06], [9.9459704275539202, 1.1489720373711589, 1.9688323547616904, 1.0632512140862307], [2356.22906167467, 329.2953355431639, 0.52839405082563173, 79.42832429292362]]], [[[7.7590926484431781, 7.8559270157256638, 4.2195615756873579, 1.6610213995770469], [1.6873647533234348, 435.57281863570262, 3.8127293996659732, 1.9183701053366202], [2.6779719353579701, 1.7527757710519118, 1.5546253576726097, 3.7622528418241332]], [[0.29090937370999143, 39.075342794630501, 0.068209231168206222, 0.26490106217761356], [0.7319115303721988, 0.018639648195352566, 1.487226641525681, 802.09239984700025], [1.8508678118182738, 0.94700788085623444, 1751.9238412049178, 620.05569094382963]]]])+(1.-msk_ref)*numarray.array([[[[13.856822049793017, 0.1698522615234575, 222.50343712128958, 1.1195664976441784], [9.9960868244070049, 16.443333318172524, 364.05869186298531, 168.38120432754178], [61.470491313669029, 7.7956349835148826, 189.13615479213124, 1.6330285111956921]], [[7.26188705507567, 246.82050235190837, 0.15293534435498729, 0.63345600430807603], [12.518574538497633, 4.4805273946663906, 1.0996896850839557, 0.99010814263927649], [1.1416620062301488, 5.0262201940346474, 12.39161493146015, 2.90396926889709]]], [[[2.4430889022943201, 1.7047018615804435, 2.735433708206461, 7.4921037130989347], [427.62797298014726, 3.5670030379673809, 0.18293758482727099, 2450.4757056595199], [0.0032770090774681578, 0.94030333258667465, 3.0554384486298329, 1.7621278935769478]], [[2.2943818903026822, 1.6693380489197964, 8.1007981718172797, 547.06551016331537], [8.8866562959414264, 2.9538697449771694, 1.6856526337855318, 14.531711428757538], [0.039028757184659611, 1.1494849825630689, 1.9537983088661117, 365.6111871732702]]], [[[41.487252198220233, 12.409271372600921, 14.477856649277644, 1.1160774287382553], [0.32944857634125907, 951.85642064916613, 4.7097294212465224, 0.88863208972274543], [5.397964054706577, 1.3973452674961897, 1.0251696549037674, 0.051538737074028972]], [[94.200810882618157, 255.44743759847563, 29.764980791325101, 7.5522628734351223], [32.899896048305123, 46.587640503793793, 1.109950949907152, 25.253014478094745], [8.2156055132226768, 1.552559066995099, 0.35889915295693109, 33.447260310417171]]]])
2497        self.failUnless(isinstance(res,Symbol),"wrong type of result.")        self.failUnless(isinstance(res,Symbol),"wrong type of result.")
2498        self.failUnlessEqual(res.getShape(),(3, 2, 3, 4),"wrong shape of result.")        self.failUnlessEqual(res.getShape(),(3, 2, 3, 4),"wrong shape of result.")
2499        self.failUnless(Lsup(sub-ref)<=self.RES_TOL*Lsup(ref),"wrong result")        self.failUnless(Lsup(sub-ref)<=self.RES_TOL*Lsup(ref),"wrong result")
2500       #+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
2501       def test_add_overloaded_constData_rank0_Symbol_rank0(self):
2502          arg0=Data(0.499161085524,self.functionspace)
2503          arg1=Symbol(shape=())
2504          res=arg0+arg1
2505          s1=numarray.array(0.377874196418)
2506          sub=res.substitute({arg1:s1})
2507          ref=Data(0.877035281942,self.functionspace)
2508          self.failUnless(isinstance(res,Symbol),"wrong type of result.")
2509          self.failUnlessEqual(res.getShape(),(),"wrong shape of result.")
2510          self.failUnless(Lsup(sub-ref)<=self.RES_TOL*Lsup(ref),"wrong result")

Legend:
Removed from v.437  
changed lines
  Added in v.1312

  ViewVC Help
Powered by ViewVC 1.1.26