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

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

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

revision 637 by gross, Thu Mar 23 10:55:31 2006 UTC revision 699 by gross, Fri Mar 31 06:27:56 2006 UTC
# Line 37317  class Test_util_binary_no_tagged_data(Te Line 37317  class Test_util_binary_no_tagged_data(Te
37317        self.failUnless(isinstance(res,Data),"wrong type of result.")        self.failUnless(isinstance(res,Data),"wrong type of result.")
37318        self.failUnlessEqual(res.getShape(),(4, 5, 4, 5),"wrong shape of result.")        self.failUnlessEqual(res.getShape(),(4, 5, 4, 5),"wrong shape of result.")
37319        self.failUnless(Lsup(res-ref)<=self.RES_TOL*Lsup(ref),"wrong result")        self.failUnless(Lsup(res-ref)<=self.RES_TOL*Lsup(ref),"wrong result")
37320       #+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
37321       def test_power_float_rank0_constData_rank0(self):
37322          arg0=4.35251522982
37323          arg1=Data(2.94566651719,self.functionspace)
37324          res=power(arg0,arg1)
37325          ref=Data(76.1230031099,self.functionspace)
37326          self.failUnless(isinstance(res,Data),"wrong type of result.")
37327          self.failUnlessEqual(res.getShape(),(),"wrong shape of result.")
37328          self.failUnless(Lsup(res-ref)<=self.RES_TOL*Lsup(ref),"wrong result")
37329       #+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
37330       def test_power_float_rank0_expandedData_rank0(self):
37331          arg0=3.41819405792
37332          msk_arg1=whereNegative(self.functionspace.getX()[0]-0.5)
37333          arg1=msk_arg1*(3.18794922769)+(1.-msk_arg1)*(0.35955973515)
37334          res=power(arg0,arg1)
37335          msk_ref=whereNegative(self.functionspace.getX()[0]-0.5)
37336          ref=msk_ref*(50.3172415941)+(1.-msk_ref)*(1.55572132713)
37337          self.failUnless(isinstance(res,Data),"wrong type of result.")
37338          self.failUnlessEqual(res.getShape(),(),"wrong shape of result.")
37339          self.failUnless(Lsup(res-ref)<=self.RES_TOL*Lsup(ref),"wrong result")

Legend:
Removed from v.637  
changed lines
  Added in v.699

  ViewVC Help
Powered by ViewVC 1.1.26