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

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

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

trunk/escript/test/python/test_assemblage.py revision 798 by gross, Fri Aug 4 01:05:36 2006 UTC temp_trunk_copy/escript/test/python/test_assemblage.py revision 1384 by phornby, Fri Jan 11 02:29:38 2008 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  """  """
19  Test suite for linearPDEs class  Test suite for linearPDEs class
# Line 46  from esys.escript import * Line 61  from esys.escript import *
61  from esys.escript.linearPDEs import LinearPDE  from esys.escript.linearPDEs import LinearPDE
62    
63  class Test_assemblage_2Do1(unittest.TestCase):  class Test_assemblage_2Do1(unittest.TestCase):
64      def setNormal(self,fs):
65         out=Vector(0.,fs)
66         out.setTaggedValue(2,[1,0])
67         out.setTaggedValue(1,[-1,0])
68         out.setTaggedValue(20, [0,1])
69         out.setTaggedValue(10, [0,-1])
70         return out
71    #==================================================    #==================================================
72    def test_assemblage_2D_solO1_coeffOFull_NEqu1_A_Const_typeStrong_comp00(self):    def test_assemblage_2D_solO1_coeffOFull_NEqu1_A_Const_typeStrong_comp00(self):
73      x=self.domain.getX()      x=self.domain.getX()
# Line 53  class Test_assemblage_2Do1(unittest.Test Line 75  class Test_assemblage_2Do1(unittest.Test
75      A_test=Data(0.,(2,2),Function(self.domain))      A_test=Data(0.,(2,2),Function(self.domain))
76      A_test[0,0]=7      A_test[0,0]=7
77      Y_test=0      Y_test=0
78      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
79      y_test=n[0]*((-49))      y_test=n[0]*((-49))
80      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
81      pde.setValue(A=A_test, Y=Y_test, y=y_test)      pde.setValue(A=A_test, Y=Y_test, y=y_test)
# Line 69  class Test_assemblage_2Do1(unittest.Test Line 90  class Test_assemblage_2Do1(unittest.Test
90      A_test=Data(0.,(2,2),Function(self.domain))      A_test=Data(0.,(2,2),Function(self.domain))
91      A_test[0,1]=3      A_test[0,1]=3
92      Y_test=0      Y_test=0
93      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
94      y_test=n[0]*((-6))      y_test=n[0]*((-6))
95      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
96      pde.setValue(A=A_test, Y=Y_test, y=y_test)      pde.setValue(A=A_test, Y=Y_test, y=y_test)
# Line 85  class Test_assemblage_2Do1(unittest.Test Line 105  class Test_assemblage_2Do1(unittest.Test
105      A_test=Data(0.,(2,2),Function(self.domain))      A_test=Data(0.,(2,2),Function(self.domain))
106      A_test[1,0]=2      A_test[1,0]=2
107      Y_test=0      Y_test=0
108      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
109      y_test=n[1]*((-8))      y_test=n[1]*((-8))
110      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
111      pde.setValue(A=A_test, Y=Y_test, y=y_test)      pde.setValue(A=A_test, Y=Y_test, y=y_test)
# Line 101  class Test_assemblage_2Do1(unittest.Test Line 120  class Test_assemblage_2Do1(unittest.Test
120      A_test=Data(0.,(2,2),Function(self.domain))      A_test=Data(0.,(2,2),Function(self.domain))
121      A_test[1,1]=5      A_test[1,1]=5
122      Y_test=0      Y_test=0
123      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
124      y_test=n[1]*(15)      y_test=n[1]*(15)
125      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
126      pde.setValue(A=A_test, Y=Y_test, y=y_test)      pde.setValue(A=A_test, Y=Y_test, y=y_test)
# Line 117  class Test_assemblage_2Do1(unittest.Test Line 135  class Test_assemblage_2Do1(unittest.Test
135      B_test=Data(0.,(2,),Function(self.domain))      B_test=Data(0.,(2,),Function(self.domain))
136      B_test[0]=3      B_test[0]=3
137      Y_test=(-6)      Y_test=(-6)
138      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
139      y_test=n[0]*(15+15*x[1]+6*x[0])      y_test=n[0]*(15+15*x[1]+6*x[0])
140      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
141      pde.setValue(B=B_test, Y=Y_test, y=y_test)      pde.setValue(B=B_test, Y=Y_test, y=y_test)
# Line 133  class Test_assemblage_2Do1(unittest.Test Line 150  class Test_assemblage_2Do1(unittest.Test
150      B_test=Data(0.,(2,),Function(self.domain))      B_test=Data(0.,(2,),Function(self.domain))
151      B_test[1]=7      B_test[1]=7
152      Y_test=56      Y_test=56
153      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
154      y_test=n[1]*(35-56*x[1]+21*x[0])      y_test=n[1]*(35-56*x[1]+21*x[0])
155      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
156      pde.setValue(B=B_test, Y=Y_test, y=y_test)      pde.setValue(B=B_test, Y=Y_test, y=y_test)
# Line 199  class Test_assemblage_2Do1(unittest.Test Line 215  class Test_assemblage_2Do1(unittest.Test
215      A_test=Data(0.,(2,2),Function(self.domain))      A_test=Data(0.,(2,2),Function(self.domain))
216      A_test[0,0]=x[0]      A_test[0,0]=x[0]
217      Y_test=(-7)      Y_test=(-7)
218      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
219      y_test=n[0]*(7*x[0])      y_test=n[0]*(7*x[0])
220      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
221      pde.setValue(A=A_test, Y=Y_test, y=y_test)      pde.setValue(A=A_test, Y=Y_test, y=y_test)
# Line 215  class Test_assemblage_2Do1(unittest.Test Line 230  class Test_assemblage_2Do1(unittest.Test
230      A_test=Data(0.,(2,2),Function(self.domain))      A_test=Data(0.,(2,2),Function(self.domain))
231      A_test[0,1]=x[0]      A_test[0,1]=x[0]
232      Y_test=1      Y_test=1
233      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
234      y_test=n[0]*((-1)*x[0])      y_test=n[0]*((-1)*x[0])
235      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
236      pde.setValue(A=A_test, Y=Y_test, y=y_test)      pde.setValue(A=A_test, Y=Y_test, y=y_test)
# Line 231  class Test_assemblage_2Do1(unittest.Test Line 245  class Test_assemblage_2Do1(unittest.Test
245      A_test=Data(0.,(2,2),Function(self.domain))      A_test=Data(0.,(2,2),Function(self.domain))
246      A_test[1,0]=x[1]      A_test[1,0]=x[1]
247      Y_test=(-4)      Y_test=(-4)
248      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
249      y_test=n[1]*(4*x[1])      y_test=n[1]*(4*x[1])
250      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
251      pde.setValue(A=A_test, Y=Y_test, y=y_test)      pde.setValue(A=A_test, Y=Y_test, y=y_test)
# Line 247  class Test_assemblage_2Do1(unittest.Test Line 260  class Test_assemblage_2Do1(unittest.Test
260      A_test=Data(0.,(2,2),Function(self.domain))      A_test=Data(0.,(2,2),Function(self.domain))
261      A_test[1,1]=x[1]      A_test[1,1]=x[1]
262      Y_test=6      Y_test=6
263      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
264      y_test=n[1]*((-6)*x[1])      y_test=n[1]*((-6)*x[1])
265      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
266      pde.setValue(A=A_test, Y=Y_test, y=y_test)      pde.setValue(A=A_test, Y=Y_test, y=y_test)
# Line 263  class Test_assemblage_2Do1(unittest.Test Line 275  class Test_assemblage_2Do1(unittest.Test
275      B_test=Data(0.,(2,),Function(self.domain))      B_test=Data(0.,(2,),Function(self.domain))
276      B_test[0]=x[0]      B_test[0]=x[0]
277      Y_test=7-1*x[1]-12*x[0]      Y_test=7-1*x[1]-12*x[0]
278      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
279      y_test=n[0]*((-7)*x[0]+x[0]*x[1]+6*x[0]**2)      y_test=n[0]*((-7)*x[0]+x[0]*x[1]+6*x[0]**2)
280      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
281      pde.setValue(B=B_test, Y=Y_test, y=y_test)      pde.setValue(B=B_test, Y=Y_test, y=y_test)
# Line 279  class Test_assemblage_2Do1(unittest.Test Line 290  class Test_assemblage_2Do1(unittest.Test
290      B_test=Data(0.,(2,),Function(self.domain))      B_test=Data(0.,(2,),Function(self.domain))
291      B_test[1]=x[1]      B_test[1]=x[1]
292      Y_test=1+2*x[1]-2*x[0]      Y_test=1+2*x[1]-2*x[0]
293      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
294      y_test=n[1]*((-1)*x[1]-1*x[1]**2+2*x[0]*x[1])      y_test=n[1]*((-1)*x[1]-1*x[1]**2+2*x[0]*x[1])
295      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
296      pde.setValue(B=B_test, Y=Y_test, y=y_test)      pde.setValue(B=B_test, Y=Y_test, y=y_test)
# Line 515  class Test_assemblage_2Do1(unittest.Test Line 525  class Test_assemblage_2Do1(unittest.Test
525      A_test=Data(0.,(2,2,2,2),Function(self.domain))      A_test=Data(0.,(2,2,2,2),Function(self.domain))
526      A_test[0,0,0,0]=1      A_test[0,0,0,0]=1
527      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
528      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
529      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
530      y_test[0]=n[0]*((-1))      y_test[0]=n[0]*((-1))
531      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 534  class Test_assemblage_2Do1(unittest.Test Line 543  class Test_assemblage_2Do1(unittest.Test
543      A_test=Data(0.,(2,2,2,2),Function(self.domain))      A_test=Data(0.,(2,2,2,2),Function(self.domain))
544      A_test[0,0,0,1]=5      A_test[0,0,0,1]=5
545      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
546      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
547      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
548      y_test[0]=n[0]*((-30))      y_test[0]=n[0]*((-30))
549      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 553  class Test_assemblage_2Do1(unittest.Test Line 561  class Test_assemblage_2Do1(unittest.Test
561      A_test=Data(0.,(2,2,2,2),Function(self.domain))      A_test=Data(0.,(2,2,2,2),Function(self.domain))
562      A_test[0,0,1,0]=4      A_test[0,0,1,0]=4
563      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
564      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
565      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
566      y_test[0]=n[0]*((-4))      y_test[0]=n[0]*((-4))
567      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 572  class Test_assemblage_2Do1(unittest.Test Line 579  class Test_assemblage_2Do1(unittest.Test
579      A_test=Data(0.,(2,2,2,2),Function(self.domain))      A_test=Data(0.,(2,2,2,2),Function(self.domain))
580      A_test[0,0,1,1]=3      A_test[0,0,1,1]=3
581      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
582      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
583      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
584      y_test[0]=n[0]*((-9))      y_test[0]=n[0]*((-9))
585      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 591  class Test_assemblage_2Do1(unittest.Test Line 597  class Test_assemblage_2Do1(unittest.Test
597      A_test=Data(0.,(2,2,2,2),Function(self.domain))      A_test=Data(0.,(2,2,2,2),Function(self.domain))
598      A_test[0,1,0,0]=8      A_test[0,1,0,0]=8
599      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
600      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
601      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
602      y_test[0]=n[1]*(16)      y_test[0]=n[1]*(16)
603      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 610  class Test_assemblage_2Do1(unittest.Test Line 615  class Test_assemblage_2Do1(unittest.Test
615      A_test=Data(0.,(2,2,2,2),Function(self.domain))      A_test=Data(0.,(2,2,2,2),Function(self.domain))
616      A_test[0,1,0,1]=2      A_test[0,1,0,1]=2
617      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
618      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
619      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
620      y_test[0]=n[1]*(8)      y_test[0]=n[1]*(8)
621      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 629  class Test_assemblage_2Do1(unittest.Test Line 633  class Test_assemblage_2Do1(unittest.Test
633      A_test=Data(0.,(2,2,2,2),Function(self.domain))      A_test=Data(0.,(2,2,2,2),Function(self.domain))
634      A_test[0,1,1,0]=4      A_test[0,1,1,0]=4
635      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
636      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
637      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
638      y_test[0]=n[1]*(20)      y_test[0]=n[1]*(20)
639      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 648  class Test_assemblage_2Do1(unittest.Test Line 651  class Test_assemblage_2Do1(unittest.Test
651      A_test=Data(0.,(2,2,2,2),Function(self.domain))      A_test=Data(0.,(2,2,2,2),Function(self.domain))
652      A_test[0,1,1,1]=2      A_test[0,1,1,1]=2
653      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
654      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
655      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
656      y_test[0]=n[1]*((-14))      y_test[0]=n[1]*((-14))
657      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 667  class Test_assemblage_2Do1(unittest.Test Line 669  class Test_assemblage_2Do1(unittest.Test
669      A_test=Data(0.,(2,2,2,2),Function(self.domain))      A_test=Data(0.,(2,2,2,2),Function(self.domain))
670      A_test[1,0,0,0]=2      A_test[1,0,0,0]=2
671      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
672      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
673      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
674      y_test[1]=n[0]*(10)      y_test[1]=n[0]*(10)
675      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 686  class Test_assemblage_2Do1(unittest.Test Line 687  class Test_assemblage_2Do1(unittest.Test
687      A_test=Data(0.,(2,2,2,2),Function(self.domain))      A_test=Data(0.,(2,2,2,2),Function(self.domain))
688      A_test[1,0,0,1]=7      A_test[1,0,0,1]=7
689      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
690      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
691      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
692      y_test[1]=n[0]*(49)      y_test[1]=n[0]*(49)
693      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 705  class Test_assemblage_2Do1(unittest.Test Line 705  class Test_assemblage_2Do1(unittest.Test
705      A_test=Data(0.,(2,2,2,2),Function(self.domain))      A_test=Data(0.,(2,2,2,2),Function(self.domain))
706      A_test[1,0,1,0]=7      A_test[1,0,1,0]=7
707      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
708      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
709      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
710      y_test[1]=n[0]*((-49))      y_test[1]=n[0]*((-49))
711      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 724  class Test_assemblage_2Do1(unittest.Test Line 723  class Test_assemblage_2Do1(unittest.Test
723      A_test=Data(0.,(2,2,2,2),Function(self.domain))      A_test=Data(0.,(2,2,2,2),Function(self.domain))
724      A_test[1,0,1,1]=4      A_test[1,0,1,1]=4
725      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
726      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
727      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
728      y_test[1]=n[0]*(16)      y_test[1]=n[0]*(16)
729      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 743  class Test_assemblage_2Do1(unittest.Test Line 741  class Test_assemblage_2Do1(unittest.Test
741      A_test=Data(0.,(2,2,2,2),Function(self.domain))      A_test=Data(0.,(2,2,2,2),Function(self.domain))
742      A_test[1,1,0,0]=6      A_test[1,1,0,0]=6
743      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
744      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
745      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
746      y_test[1]=n[1]*((-12))      y_test[1]=n[1]*((-12))
747      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 762  class Test_assemblage_2Do1(unittest.Test Line 759  class Test_assemblage_2Do1(unittest.Test
759      A_test=Data(0.,(2,2,2,2),Function(self.domain))      A_test=Data(0.,(2,2,2,2),Function(self.domain))
760      A_test[1,1,0,1]=3      A_test[1,1,0,1]=3
761      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
762      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
763      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
764      y_test[1]=n[1]*(18)      y_test[1]=n[1]*(18)
765      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 781  class Test_assemblage_2Do1(unittest.Test Line 777  class Test_assemblage_2Do1(unittest.Test
777      A_test=Data(0.,(2,2,2,2),Function(self.domain))      A_test=Data(0.,(2,2,2,2),Function(self.domain))
778      A_test[1,1,1,0]=6      A_test[1,1,1,0]=6
779      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
780      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
781      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
782      y_test[1]=n[1]*(12)      y_test[1]=n[1]*(12)
783      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 800  class Test_assemblage_2Do1(unittest.Test Line 795  class Test_assemblage_2Do1(unittest.Test
795      A_test=Data(0.,(2,2,2,2),Function(self.domain))      A_test=Data(0.,(2,2,2,2),Function(self.domain))
796      A_test[1,1,1,1]=3      A_test[1,1,1,1]=3
797      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
798      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
799      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
800      y_test[1]=n[1]*(24)      y_test[1]=n[1]*(24)
801      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 820  class Test_assemblage_2Do1(unittest.Test Line 814  class Test_assemblage_2Do1(unittest.Test
814      B_test[0,0,0]=3      B_test[0,0,0]=3
815      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
816      Y_test[0]=24      Y_test[0]=24
817      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
818      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
819      y_test[0]=n[0]*((-15)-27*x[1]-24*x[0])      y_test[0]=n[0]*((-15)-27*x[1]-24*x[0])
820      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 840  class Test_assemblage_2Do1(unittest.Test Line 833  class Test_assemblage_2Do1(unittest.Test
833      B_test[0,0,1]=6      B_test[0,0,1]=6
834      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
835      Y_test[0]=30      Y_test[0]=30
836      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
837      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
838      y_test[0]=n[0]*(30+36*x[1]-30*x[0])      y_test[0]=n[0]*(30+36*x[1]-30*x[0])
839      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 860  class Test_assemblage_2Do1(unittest.Test Line 852  class Test_assemblage_2Do1(unittest.Test
852      B_test[0,1,0]=7      B_test[0,1,0]=7
853      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
854      Y_test[0]=(-42)      Y_test[0]=(-42)
855      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
856      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
857      y_test[0]=n[1]*((-35)+42*x[1]-7*x[0])      y_test[0]=n[1]*((-35)+42*x[1]-7*x[0])
858      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 880  class Test_assemblage_2Do1(unittest.Test Line 871  class Test_assemblage_2Do1(unittest.Test
871      B_test[0,1,1]=6      B_test[0,1,1]=6
872      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
873      Y_test[0]=(-30)      Y_test[0]=(-30)
874      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
875      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
876      y_test[0]=n[1]*(6+30*x[1]+48*x[0])      y_test[0]=n[1]*(6+30*x[1]+48*x[0])
877      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 900  class Test_assemblage_2Do1(unittest.Test Line 890  class Test_assemblage_2Do1(unittest.Test
890      B_test[1,0,0]=8      B_test[1,0,0]=8
891      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
892      Y_test[1]=64      Y_test[1]=64
893      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
894      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
895      y_test[1]=n[0]*(56-40*x[1]-64*x[0])      y_test[1]=n[0]*(56-40*x[1]-64*x[0])
896      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 920  class Test_assemblage_2Do1(unittest.Test Line 909  class Test_assemblage_2Do1(unittest.Test
909      B_test[1,0,1]=3      B_test[1,0,1]=3
910      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
911      Y_test[1]=(-3)      Y_test[1]=(-3)
912      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
913      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
914      y_test[1]=n[0]*((-18)+12*x[1]+3*x[0])      y_test[1]=n[0]*((-18)+12*x[1]+3*x[0])
915      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 940  class Test_assemblage_2Do1(unittest.Test Line 928  class Test_assemblage_2Do1(unittest.Test
928      B_test[1,1,0]=3      B_test[1,1,0]=3
929      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
930      Y_test[1]=(-15)      Y_test[1]=(-15)
931      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
932      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
933      y_test[1]=n[1]*((-15)+15*x[1]-15*x[0])      y_test[1]=n[1]*((-15)+15*x[1]-15*x[0])
934      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 960  class Test_assemblage_2Do1(unittest.Test Line 947  class Test_assemblage_2Do1(unittest.Test
947      B_test[1,1,1]=1      B_test[1,1,1]=1
948      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
949      Y_test[1]=(-7)      Y_test[1]=(-7)
950      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
951      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
952      y_test[1]=n[1]*((-7)+7*x[1]-9*x[0])      y_test[1]=n[1]*((-7)+7*x[1]-9*x[0])
953      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 1236  class Test_assemblage_2Do1(unittest.Test Line 1222  class Test_assemblage_2Do1(unittest.Test
1222      A_test[0,0,0,0]=x[0]      A_test[0,0,0,0]=x[0]
1223      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
1224      Y_test[0]=2      Y_test[0]=2
1225      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
1226      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
1227      y_test[0]=n[0]*((-2)*x[0])      y_test[0]=n[0]*((-2)*x[0])
1228      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 1256  class Test_assemblage_2Do1(unittest.Test Line 1241  class Test_assemblage_2Do1(unittest.Test
1241      A_test[0,0,0,1]=x[0]      A_test[0,0,0,1]=x[0]
1242      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
1243      Y_test[0]=2      Y_test[0]=2
1244      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
1245      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
1246      y_test[0]=n[0]*((-2)*x[0])      y_test[0]=n[0]*((-2)*x[0])
1247      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 1276  class Test_assemblage_2Do1(unittest.Test Line 1260  class Test_assemblage_2Do1(unittest.Test
1260      A_test[0,0,1,0]=x[0]      A_test[0,0,1,0]=x[0]
1261      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
1262      Y_test[0]=(-8)      Y_test[0]=(-8)
1263      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
1264      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
1265      y_test[0]=n[0]*(8*x[0])      y_test[0]=n[0]*(8*x[0])
1266      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 1296  class Test_assemblage_2Do1(unittest.Test Line 1279  class Test_assemblage_2Do1(unittest.Test
1279      A_test[0,0,1,1]=x[0]      A_test[0,0,1,1]=x[0]
1280      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
1281      Y_test[0]=2      Y_test[0]=2
1282      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
1283      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
1284      y_test[0]=n[0]*((-2)*x[0])      y_test[0]=n[0]*((-2)*x[0])
1285      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 1316  class Test_assemblage_2Do1(unittest.Test Line 1298  class Test_assemblage_2Do1(unittest.Test
1298      A_test[0,1,0,0]=x[1]      A_test[0,1,0,0]=x[1]
1299      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
1300      Y_test[0]=3      Y_test[0]=3
1301      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
1302      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
1303      y_test[0]=n[1]*((-3)*x[1])      y_test[0]=n[1]*((-3)*x[1])
1304      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 1336  class Test_assemblage_2Do1(unittest.Test Line 1317  class Test_assemblage_2Do1(unittest.Test
1317      A_test[0,1,0,1]=x[1]      A_test[0,1,0,1]=x[1]
1318      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
1319      Y_test[0]=(-6)      Y_test[0]=(-6)
1320      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
1321      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
1322      y_test[0]=n[1]*(6*x[1])      y_test[0]=n[1]*(6*x[1])
1323      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 1356  class Test_assemblage_2Do1(unittest.Test Line 1336  class Test_assemblage_2Do1(unittest.Test
1336      A_test[0,1,1,0]=x[1]      A_test[0,1,1,0]=x[1]
1337      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
1338      Y_test[0]=2      Y_test[0]=2
1339      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
1340      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
1341      y_test[0]=n[1]*((-2)*x[1])      y_test[0]=n[1]*((-2)*x[1])
1342      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 1376  class Test_assemblage_2Do1(unittest.Test Line 1355  class Test_assemblage_2Do1(unittest.Test
1355      A_test[0,1,1,1]=x[1]      A_test[0,1,1,1]=x[1]
1356      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
1357      Y_test[0]=6      Y_test[0]=6
1358      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
1359      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
1360      y_test[0]=n[1]*((-6)*x[1])      y_test[0]=n[1]*((-6)*x[1])
1361      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 1396  class Test_assemblage_2Do1(unittest.Test Line 1374  class Test_assemblage_2Do1(unittest.Test
1374      A_test[1,0,0,0]=x[0]      A_test[1,0,0,0]=x[0]
1375      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
1376      Y_test[1]=1      Y_test[1]=1
1377      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
1378      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
1379      y_test[1]=n[0]*((-1)*x[0])      y_test[1]=n[0]*((-1)*x[0])
1380      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 1416  class Test_assemblage_2Do1(unittest.Test Line 1393  class Test_assemblage_2Do1(unittest.Test
1393      A_test[1,0,0,1]=x[0]      A_test[1,0,0,1]=x[0]
1394      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
1395      Y_test[1]=3      Y_test[1]=3
1396      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
1397      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
1398      y_test[1]=n[0]*((-3)*x[0])      y_test[1]=n[0]*((-3)*x[0])
1399      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 1436  class Test_assemblage_2Do1(unittest.Test Line 1412  class Test_assemblage_2Do1(unittest.Test
1412      A_test[1,0,1,0]=x[0]      A_test[1,0,1,0]=x[0]
1413      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
1414      Y_test[1]=1      Y_test[1]=1
1415      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
1416      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
1417      y_test[1]=n[0]*((-1)*x[0])      y_test[1]=n[0]*((-1)*x[0])
1418      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 1456  class Test_assemblage_2Do1(unittest.Test Line 1431  class Test_assemblage_2Do1(unittest.Test
1431      A_test[1,0,1,1]=x[0]      A_test[1,0,1,1]=x[0]
1432      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
1433      Y_test[1]=9      Y_test[1]=9
1434      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
1435      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
1436      y_test[1]=n[0]*((-9)*x[0])      y_test[1]=n[0]*((-9)*x[0])
1437      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 1476  class Test_assemblage_2Do1(unittest.Test Line 1450  class Test_assemblage_2Do1(unittest.Test
1450      A_test[1,1,0,0]=x[1]      A_test[1,1,0,0]=x[1]
1451      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
1452      Y_test[1]=(-1)      Y_test[1]=(-1)
1453      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
1454      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
1455      y_test[1]=n[1]*(x[1])      y_test[1]=n[1]*(x[1])
1456      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 1496  class Test_assemblage_2Do1(unittest.Test Line 1469  class Test_assemblage_2Do1(unittest.Test
1469      A_test[1,1,0,1]=x[1]      A_test[1,1,0,1]=x[1]
1470      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
1471      Y_test[1]=(-2)      Y_test[1]=(-2)
1472      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
1473      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
1474      y_test[1]=n[1]*(2*x[1])      y_test[1]=n[1]*(2*x[1])
1475      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 1516  class Test_assemblage_2Do1(unittest.Test Line 1488  class Test_assemblage_2Do1(unittest.Test
1488      A_test[1,1,1,0]=x[1]      A_test[1,1,1,0]=x[1]
1489      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
1490      Y_test[1]=(-5)      Y_test[1]=(-5)
1491      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
1492      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
1493      y_test[1]=n[1]*(5*x[1])      y_test[1]=n[1]*(5*x[1])
1494      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 1536  class Test_assemblage_2Do1(unittest.Test Line 1507  class Test_assemblage_2Do1(unittest.Test
1507      A_test[1,1,1,1]=x[1]      A_test[1,1,1,1]=x[1]
1508      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
1509      Y_test[1]=8      Y_test[1]=8
1510      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
1511      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
1512      y_test[1]=n[1]*((-8)*x[1])      y_test[1]=n[1]*((-8)*x[1])
1513      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 1556  class Test_assemblage_2Do1(unittest.Test Line 1526  class Test_assemblage_2Do1(unittest.Test
1526      B_test[0,0,0]=x[0]      B_test[0,0,0]=x[0]
1527      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
1528      Y_test[0]=1-8*x[1]+8*x[0]      Y_test[0]=1-8*x[1]+8*x[0]
1529      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
1530      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
1531      y_test[0]=n[0]*((-1)*x[0]+8*x[0]*x[1]-4*x[0]**2)      y_test[0]=n[0]*((-1)*x[0]+8*x[0]*x[1]-4*x[0]**2)
1532      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 1576  class Test_assemblage_2Do1(unittest.Test Line 1545  class Test_assemblage_2Do1(unittest.Test
1545      B_test[0,0,1]=x[0]      B_test[0,0,1]=x[0]
1546      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
1547      Y_test[0]=(-2)-1*x[1]+10*x[0]      Y_test[0]=(-2)-1*x[1]+10*x[0]
1548      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
1549      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
1550      y_test[0]=n[0]*(2*x[0]+x[0]*x[1]-5*x[0]**2)      y_test[0]=n[0]*(2*x[0]+x[0]*x[1]-5*x[0]**2)
1551      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 1596  class Test_assemblage_2Do1(unittest.Test Line 1564  class Test_assemblage_2Do1(unittest.Test
1564      B_test[0,1,0]=x[1]      B_test[0,1,0]=x[1]
1565      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
1566      Y_test[0]=3-12*x[1]+7*x[0]      Y_test[0]=3-12*x[1]+7*x[0]
1567      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
1568      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
1569      y_test[0]=n[1]*((-3)*x[1]+6*x[1]**2-7*x[0]*x[1])      y_test[0]=n[1]*((-3)*x[1]+6*x[1]**2-7*x[0]*x[1])
1570      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 1616  class Test_assemblage_2Do1(unittest.Test Line 1583  class Test_assemblage_2Do1(unittest.Test
1583      B_test[0,1,1]=x[1]      B_test[0,1,1]=x[1]
1584      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
1585      Y_test[0]=(-5)+14*x[1]-8*x[0]      Y_test[0]=(-5)+14*x[1]-8*x[0]
1586      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
1587      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
1588      y_test[0]=n[1]*(5*x[1]-7*x[1]**2+8*x[0]*x[1])      y_test[0]=n[1]*(5*x[1]-7*x[1]**2+8*x[0]*x[1])
1589      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 1636  class Test_assemblage_2Do1(unittest.Test Line 1602  class Test_assemblage_2Do1(unittest.Test
1602      B_test[1,0,0]=x[0]      B_test[1,0,0]=x[0]
1603      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
1604      Y_test[1]=(-6)-8*x[1]-4*x[0]      Y_test[1]=(-6)-8*x[1]-4*x[0]
1605      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
1606      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
1607      y_test[1]=n[0]*(6*x[0]+8*x[0]*x[1]+2*x[0]**2)      y_test[1]=n[0]*(6*x[0]+8*x[0]*x[1]+2*x[0]**2)
1608      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 1656  class Test_assemblage_2Do1(unittest.Test Line 1621  class Test_assemblage_2Do1(unittest.Test
1621      B_test[1,0,1]=x[0]      B_test[1,0,1]=x[0]
1622      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
1623      Y_test[1]=(-3)-4*x[1]-16*x[0]      Y_test[1]=(-3)-4*x[1]-16*x[0]
1624      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
1625      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
1626      y_test[1]=n[0]*(3*x[0]+4*x[0]*x[1]+8*x[0]**2)      y_test[1]=n[0]*(3*x[0]+4*x[0]*x[1]+8*x[0]**2)
1627      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 1676  class Test_assemblage_2Do1(unittest.Test Line 1640  class Test_assemblage_2Do1(unittest.Test
1640      B_test[1,1,0]=x[1]      B_test[1,1,0]=x[1]
1641      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
1642      Y_test[1]=(-2)-16*x[1]+3*x[0]      Y_test[1]=(-2)-16*x[1]+3*x[0]
1643      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
1644      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
1645      y_test[1]=n[1]*(2*x[1]+8*x[1]**2-3*x[0]*x[1])      y_test[1]=n[1]*(2*x[1]+8*x[1]**2-3*x[0]*x[1])
1646      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 1696  class Test_assemblage_2Do1(unittest.Test Line 1659  class Test_assemblage_2Do1(unittest.Test
1659      B_test[1,1,1]=x[1]      B_test[1,1,1]=x[1]
1660      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
1661      Y_test[1]=3+14*x[1]-7*x[0]      Y_test[1]=3+14*x[1]-7*x[0]
1662      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
1663      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
1664      y_test[1]=n[1]*((-3)*x[1]-7*x[1]**2+7*x[0]*x[1])      y_test[1]=n[1]*((-3)*x[1]-7*x[1]**2+7*x[0]*x[1])
1665      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 2740  class Test_assemblage_2Do1(unittest.Test Line 2702  class Test_assemblage_2Do1(unittest.Test
2702      A_test=Data(0.,(3,2,3,2),Function(self.domain))      A_test=Data(0.,(3,2,3,2),Function(self.domain))
2703      A_test[0,0,0,0]=4      A_test[0,0,0,0]=4
2704      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
2705      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
2706      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
2707      y_test[0]=n[0]*(28)      y_test[0]=n[0]*(28)
2708      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 2760  class Test_assemblage_2Do1(unittest.Test Line 2721  class Test_assemblage_2Do1(unittest.Test
2721      A_test=Data(0.,(3,2,3,2),Function(self.domain))      A_test=Data(0.,(3,2,3,2),Function(self.domain))
2722      A_test[0,0,0,1]=6      A_test[0,0,0,1]=6
2723      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
2724      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
2725      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
2726      y_test[0]=n[0]*(6)      y_test[0]=n[0]*(6)
2727      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 2780  class Test_assemblage_2Do1(unittest.Test Line 2740  class Test_assemblage_2Do1(unittest.Test
2740      A_test=Data(0.,(3,2,3,2),Function(self.domain))      A_test=Data(0.,(3,2,3,2),Function(self.domain))
2741      A_test[0,0,1,0]=2      A_test[0,0,1,0]=2
2742      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
2743      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
2744      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
2745      y_test[0]=n[0]*((-6))      y_test[0]=n[0]*((-6))
2746      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 2800  class Test_assemblage_2Do1(unittest.Test Line 2759  class Test_assemblage_2Do1(unittest.Test
2759      A_test=Data(0.,(3,2,3,2),Function(self.domain))      A_test=Data(0.,(3,2,3,2),Function(self.domain))
2760      A_test[0,0,1,1]=7      A_test[0,0,1,1]=7
2761      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
2762      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
2763      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
2764      y_test[0]=n[0]*(21)      y_test[0]=n[0]*(21)
2765      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 2820  class Test_assemblage_2Do1(unittest.Test Line 2778  class Test_assemblage_2Do1(unittest.Test
2778      A_test=Data(0.,(3,2,3,2),Function(self.domain))      A_test=Data(0.,(3,2,3,2),Function(self.domain))
2779      A_test[0,0,2,0]=7      A_test[0,0,2,0]=7
2780      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
2781      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
2782      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
2783      y_test[0]=n[0]*(56)      y_test[0]=n[0]*(56)
2784      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 2840  class Test_assemblage_2Do1(unittest.Test Line 2797  class Test_assemblage_2Do1(unittest.Test
2797      A_test=Data(0.,(3,2,3,2),Function(self.domain))      A_test=Data(0.,(3,2,3,2),Function(self.domain))
2798      A_test[0,0,2,1]=2      A_test[0,0,2,1]=2
2799      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
2800      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
2801      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
2802      y_test[0]=n[0]*(16)      y_test[0]=n[0]*(16)
2803      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 2860  class Test_assemblage_2Do1(unittest.Test Line 2816  class Test_assemblage_2Do1(unittest.Test
2816      A_test=Data(0.,(3,2,3,2),Function(self.domain))      A_test=Data(0.,(3,2,3,2),Function(self.domain))
2817      A_test[0,1,0,0]=4      A_test[0,1,0,0]=4
2818      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
2819      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
2820      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
2821      y_test[0]=n[1]*(8)      y_test[0]=n[1]*(8)
2822      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 2880  class Test_assemblage_2Do1(unittest.Test Line 2835  class Test_assemblage_2Do1(unittest.Test
2835      A_test=Data(0.,(3,2,3,2),Function(self.domain))      A_test=Data(0.,(3,2,3,2),Function(self.domain))
2836      A_test[0,1,0,1]=2      A_test[0,1,0,1]=2
2837      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
2838      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
2839      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
2840      y_test[0]=n[1]*(10)      y_test[0]=n[1]*(10)
2841      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 2900  class Test_assemblage_2Do1(unittest.Test Line 2854  class Test_assemblage_2Do1(unittest.Test
2854      A_test=Data(0.,(3,2,3,2),Function(self.domain))      A_test=Data(0.,(3,2,3,2),Function(self.domain))
2855      A_test[0,1,1,0]=6      A_test[0,1,1,0]=6
2856      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
2857      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
2858      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
2859      y_test[0]=n[1]*((-12))      y_test[0]=n[1]*((-12))
2860      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 2920  class Test_assemblage_2Do1(unittest.Test Line 2873  class Test_assemblage_2Do1(unittest.Test
2873      A_test=Data(0.,(3,2,3,2),Function(self.domain))      A_test=Data(0.,(3,2,3,2),Function(self.domain))
2874      A_test[0,1,1,1]=4      A_test[0,1,1,1]=4
2875      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
2876      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
2877      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
2878      y_test[0]=n[1]*((-32))      y_test[0]=n[1]*((-32))
2879      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 2940  class Test_assemblage_2Do1(unittest.Test Line 2892  class Test_assemblage_2Do1(unittest.Test
2892      A_test=Data(0.,(3,2,3,2),Function(self.domain))      A_test=Data(0.,(3,2,3,2),Function(self.domain))
2893      A_test[0,1,2,0]=3      A_test[0,1,2,0]=3
2894      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
2895      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
2896      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
2897      y_test[0]=n[1]*(9)      y_test[0]=n[1]*(9)
2898      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 2960  class Test_assemblage_2Do1(unittest.Test Line 2911  class Test_assemblage_2Do1(unittest.Test
2911      A_test=Data(0.,(3,2,3,2),Function(self.domain))      A_test=Data(0.,(3,2,3,2),Function(self.domain))
2912      A_test[0,1,2,1]=2      A_test[0,1,2,1]=2
2913      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
2914      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
2915      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
2916      y_test[0]=n[1]*(2)      y_test[0]=n[1]*(2)
2917      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 2980  class Test_assemblage_2Do1(unittest.Test Line 2930  class Test_assemblage_2Do1(unittest.Test
2930      A_test=Data(0.,(3,2,3,2),Function(self.domain))      A_test=Data(0.,(3,2,3,2),Function(self.domain))
2931      A_test[1,0,0,0]=7      A_test[1,0,0,0]=7
2932      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
2933      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
2934      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
2935      y_test[1]=n[0]*((-21))      y_test[1]=n[0]*((-21))
2936      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 3000  class Test_assemblage_2Do1(unittest.Test Line 2949  class Test_assemblage_2Do1(unittest.Test
2949      A_test=Data(0.,(3,2,3,2),Function(self.domain))      A_test=Data(0.,(3,2,3,2),Function(self.domain))
2950      A_test[1,0,0,1]=3      A_test[1,0,0,1]=3
2951      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
2952      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
2953      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
2954      y_test[1]=n[0]*((-3))      y_test[1]=n[0]*((-3))
2955      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 3020  class Test_assemblage_2Do1(unittest.Test Line 2968  class Test_assemblage_2Do1(unittest.Test
2968      A_test=Data(0.,(3,2,3,2),Function(self.domain))      A_test=Data(0.,(3,2,3,2),Function(self.domain))
2969      A_test[1,0,1,0]=5      A_test[1,0,1,0]=5
2970      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
2971      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
2972      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
2973      y_test[1]=n[0]*((-45))      y_test[1]=n[0]*((-45))
2974      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 3040  class Test_assemblage_2Do1(unittest.Test Line 2987  class Test_assemblage_2Do1(unittest.Test
2987      A_test=Data(0.,(3,2,3,2),Function(self.domain))      A_test=Data(0.,(3,2,3,2),Function(self.domain))
2988      A_test[1,0,1,1]=6      A_test[1,0,1,1]=6
2989      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
2990      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
2991      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
2992      y_test[1]=n[0]*((-30))      y_test[1]=n[0]*((-30))
2993      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 3060  class Test_assemblage_2Do1(unittest.Test Line 3006  class Test_assemblage_2Do1(unittest.Test
3006      A_test=Data(0.,(3,2,3,2),Function(self.domain))      A_test=Data(0.,(3,2,3,2),Function(self.domain))
3007      A_test[1,0,2,0]=3      A_test[1,0,2,0]=3
3008      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
3009      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
3010      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
3011      y_test[1]=n[0]*((-12))      y_test[1]=n[0]*((-12))
3012      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 3080  class Test_assemblage_2Do1(unittest.Test Line 3025  class Test_assemblage_2Do1(unittest.Test
3025      A_test=Data(0.,(3,2,3,2),Function(self.domain))      A_test=Data(0.,(3,2,3,2),Function(self.domain))
3026      A_test[1,0,2,1]=4      A_test[1,0,2,1]=4
3027      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
3028      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
3029      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
3030      y_test[1]=n[0]*(4)      y_test[1]=n[0]*(4)
3031      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 3100  class Test_assemblage_2Do1(unittest.Test Line 3044  class Test_assemblage_2Do1(unittest.Test
3044      A_test=Data(0.,(3,2,3,2),Function(self.domain))      A_test=Data(0.,(3,2,3,2),Function(self.domain))
3045      A_test[1,1,0,0]=4      A_test[1,1,0,0]=4
3046      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
3047      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
3048      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
3049      y_test[1]=n[1]*(24)      y_test[1]=n[1]*(24)
3050      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 3120  class Test_assemblage_2Do1(unittest.Test Line 3063  class Test_assemblage_2Do1(unittest.Test
3063      A_test=Data(0.,(3,2,3,2),Function(self.domain))      A_test=Data(0.,(3,2,3,2),Function(self.domain))
3064      A_test[1,1,0,1]=4      A_test[1,1,0,1]=4
3065      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
3066      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
3067      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
3068      y_test[1]=n[1]*((-28))      y_test[1]=n[1]*((-28))
3069      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 3140  class Test_assemblage_2Do1(unittest.Test Line 3082  class Test_assemblage_2Do1(unittest.Test
3082      A_test=Data(0.,(3,2,3,2),Function(self.domain))      A_test=Data(0.,(3,2,3,2),Function(self.domain))
3083      A_test[1,1,1,0]=7      A_test[1,1,1,0]=7
3084      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
3085      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
3086      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
3087      y_test[1]=n[1]*((-14))      y_test[1]=n[1]*((-14))
3088      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 3160  class Test_assemblage_2Do1(unittest.Test Line 3101  class Test_assemblage_2Do1(unittest.Test
3101      A_test=Data(0.,(3,2,3,2),Function(self.domain))      A_test=Data(0.,(3,2,3,2),Function(self.domain))
3102      A_test[1,1,1,1]=6      A_test[1,1,1,1]=6
3103      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
3104      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
3105      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
3106      y_test[1]=n[1]*((-48))      y_test[1]=n[1]*((-48))
3107      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 3180  class Test_assemblage_2Do1(unittest.Test Line 3120  class Test_assemblage_2Do1(unittest.Test
3120      A_test=Data(0.,(3,2,3,2),Function(self.domain))      A_test=Data(0.,(3,2,3,2),Function(self.domain))
3121      A_test[1,1,2,0]=1      A_test[1,1,2,0]=1
3122      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
3123      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
3124      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
3125      y_test[1]=n[1]*((-7))      y_test[1]=n[1]*((-7))
3126      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 3200  class Test_assemblage_2Do1(unittest.Test Line 3139  class Test_assemblage_2Do1(unittest.Test
3139      A_test=Data(0.,(3,2,3,2),Function(self.domain))      A_test=Data(0.,(3,2,3,2),Function(self.domain))
3140      A_test[1,1,2,1]=2      A_test[1,1,2,1]=2
3141      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
3142      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
3143      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
3144      y_test[1]=n[1]*((-14))      y_test[1]=n[1]*((-14))
3145      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 3220  class Test_assemblage_2Do1(unittest.Test Line 3158  class Test_assemblage_2Do1(unittest.Test
3158      A_test=Data(0.,(3,2,3,2),Function(self.domain))      A_test=Data(0.,(3,2,3,2),Function(self.domain))
3159      A_test[2,0,0,0]=3      A_test[2,0,0,0]=3
3160      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
3161      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
3162      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
3163      y_test[2]=n[0]*((-21))      y_test[2]=n[0]*((-21))
3164      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 3240  class Test_assemblage_2Do1(unittest.Test Line 3177  class Test_assemblage_2Do1(unittest.Test
3177      A_test=Data(0.,(3,2,3,2),Function(self.domain))      A_test=Data(0.,(3,2,3,2),Function(self.domain))
3178      A_test[2,0,0,1]=6      A_test[2,0,0,1]=6
3179      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
3180      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
3181      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
3182      y_test[2]=n[0]*((-36))      y_test[2]=n[0]*((-36))
3183      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 3260  class Test_assemblage_2Do1(unittest.Test Line 3196  class Test_assemblage_2Do1(unittest.Test
3196      A_test=Data(0.,(3,2,3,2),Function(self.domain))      A_test=Data(0.,(3,2,3,2),Function(self.domain))
3197      A_test[2,0,1,0]=4      A_test[2,0,1,0]=4
3198      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
3199      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
3200      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
3201      y_test[2]=n[0]*((-32))      y_test[2]=n[0]*((-32))
3202      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 3280  class Test_assemblage_2Do1(unittest.Test Line 3215  class Test_assemblage_2Do1(unittest.Test
3215      A_test=Data(0.,(3,2,3,2),Function(self.domain))      A_test=Data(0.,(3,2,3,2),Function(self.domain))
3216      A_test[2,0,1,1]=2      A_test[2,0,1,1]=2
3217      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
3218      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
3219      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
3220      y_test[2]=n[0]*((-4))      y_test[2]=n[0]*((-4))
3221      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 3300  class Test_assemblage_2Do1(unittest.Test Line 3234  class Test_assemblage_2Do1(unittest.Test
3234      A_test=Data(0.,(3,2,3,2),Function(self.domain))      A_test=Data(0.,(3,2,3,2),Function(self.domain))
3235      A_test[2,0,2,0]=4      A_test[2,0,2,0]=4
3236      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
3237      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
3238      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
3239      y_test[2]=n[0]*((-4))      y_test[2]=n[0]*((-4))
3240      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 3320  class Test_assemblage_2Do1(unittest.Test Line 3253  class Test_assemblage_2Do1(unittest.Test
3253      A_test=Data(0.,(3,2,3,2),Function(self.domain))      A_test=Data(0.,(3,2,3,2),Function(self.domain))
3254      A_test[2,0,2,1]=8      A_test[2,0,2,1]=8
3255      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
3256      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
3257      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
3258      y_test[2]=n[0]*((-16))      y_test[2]=n[0]*((-16))
3259      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 3340  class Test_assemblage_2Do1(unittest.Test Line 3272  class Test_assemblage_2Do1(unittest.Test
3272      A_test=Data(0.,(3,2,3,2),Function(self.domain))      A_test=Data(0.,(3,2,3,2),Function(self.domain))
3273      A_test[2,1,0,0]=8      A_test[2,1,0,0]=8
3274      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
3275      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
3276      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
3277      y_test[2]=n[1]*((-8))      y_test[2]=n[1]*((-8))
3278      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 3360  class Test_assemblage_2Do1(unittest.Test Line 3291  class Test_assemblage_2Do1(unittest.Test
3291      A_test=Data(0.,(3,2,3,2),Function(self.domain))      A_test=Data(0.,(3,2,3,2),Function(self.domain))
3292      A_test[2,1,0,1]=6      A_test[2,1,0,1]=6
3293      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
3294      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
3295      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
3296      y_test[2]=n[1]*(36)      y_test[2]=n[1]*(36)
3297      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 3380  class Test_assemblage_2Do1(unittest.Test Line 3310  class Test_assemblage_2Do1(unittest.Test
3310      A_test=Data(0.,(3,2,3,2),Function(self.domain))      A_test=Data(0.,(3,2,3,2),Function(self.domain))
3311      A_test[2,1,1,0]=4      A_test[2,1,1,0]=4
3312      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
3313      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
3314      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
3315      y_test[2]=n[1]*(28)      y_test[2]=n[1]*(28)
3316      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 3400  class Test_assemblage_2Do1(unittest.Test Line 3329  class Test_assemblage_2Do1(unittest.Test
3329      A_test=Data(0.,(3,2,3,2),Function(self.domain))      A_test=Data(0.,(3,2,3,2),Function(self.domain))
3330      A_test[2,1,1,1]=3      A_test[2,1,1,1]=3
3331      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
3332      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
3333      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
3334      y_test[2]=n[1]*(9)      y_test[2]=n[1]*(9)
3335      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 3420  class Test_assemblage_2Do1(unittest.Test Line 3348  class Test_assemblage_2Do1(unittest.Test
3348      A_test=Data(0.,(3,2,3,2),Function(self.domain))      A_test=Data(0.,(3,2,3,2),Function(self.domain))
3349      A_test[2,1,2,0]=3      A_test[2,1,2,0]=3
3350      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
3351      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
3352      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
3353      y_test[2]=n[1]*((-6))      y_test[2]=n[1]*((-6))
3354      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 3440  class Test_assemblage_2Do1(unittest.Test Line 3367  class Test_assemblage_2Do1(unittest.Test
3367      A_test=Data(0.,(3,2,3,2),Function(self.domain))      A_test=Data(0.,(3,2,3,2),Function(self.domain))
3368      A_test[2,1,2,1]=3      A_test[2,1,2,1]=3
3369      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
3370      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
3371      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
3372      y_test[2]=n[1]*(15)      y_test[2]=n[1]*(15)
3373      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 3461  class Test_assemblage_2Do1(unittest.Test Line 3387  class Test_assemblage_2Do1(unittest.Test
3387      B_test[0,0,0]=6      B_test[0,0,0]=6
3388      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
3389      Y_test[0]=18      Y_test[0]=18
3390      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
3391      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
3392      y_test[0]=n[0]*((-36)-36*x[1]-18*x[0])      y_test[0]=n[0]*((-36)-36*x[1]-18*x[0])
3393      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 3482  class Test_assemblage_2Do1(unittest.Test Line 3407  class Test_assemblage_2Do1(unittest.Test
3407      B_test[0,0,1]=4      B_test[0,0,1]=4
3408      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
3409      Y_test[0]=(-4)      Y_test[0]=(-4)
3410      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
3411      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
3412      y_test[0]=n[0]*(8-8*x[1]+4*x[0])      y_test[0]=n[0]*(8-8*x[1]+4*x[0])
3413      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 3503  class Test_assemblage_2Do1(unittest.Test Line 3427  class Test_assemblage_2Do1(unittest.Test
3427      B_test[0,0,2]=7      B_test[0,0,2]=7
3428      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
3429      Y_test[0]=(-21)      Y_test[0]=(-21)
3430      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
3431      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
3432      y_test[0]=n[0]*(35+49*x[1]+21*x[0])      y_test[0]=n[0]*(35+49*x[1]+21*x[0])
3433      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 3524  class Test_assemblage_2Do1(unittest.Test Line 3447  class Test_assemblage_2Do1(unittest.Test
3447      B_test[0,1,0]=6      B_test[0,1,0]=6
3448      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
3449      Y_test[0]=48      Y_test[0]=48
3450      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
3451      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
3452      y_test[0]=n[1]*((-18)-48*x[1]-36*x[0])      y_test[0]=n[1]*((-18)-48*x[1]-36*x[0])
3453      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 3545  class Test_assemblage_2Do1(unittest.Test Line 3467  class Test_assemblage_2Do1(unittest.Test
3467      B_test[0,1,1]=3      B_test[0,1,1]=3
3468      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
3469      Y_test[0]=(-3)      Y_test[0]=(-3)
3470      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
3471      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
3472      y_test[0]=n[1]*((-18)+3*x[1]-27*x[0])      y_test[0]=n[1]*((-18)+3*x[1]-27*x[0])
3473      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 3566  class Test_assemblage_2Do1(unittest.Test Line 3487  class Test_assemblage_2Do1(unittest.Test
3487      B_test[0,1,2]=1      B_test[0,1,2]=1
3488      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
3489      Y_test[0]=8      Y_test[0]=8
3490      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
3491      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
3492      y_test[0]=n[1]*((-9)-8*x[1]-4*x[0])      y_test[0]=n[1]*((-9)-8*x[1]-4*x[0])
3493      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 3587  class Test_assemblage_2Do1(unittest.Test Line 3507  class Test_assemblage_2Do1(unittest.Test
3507      B_test[1,0,0]=2      B_test[1,0,0]=2
3508      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
3509      Y_test[1]=18      Y_test[1]=18
3510      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
3511      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
3512      y_test[1]=n[0]*((-12)-18*x[1]-18*x[0])      y_test[1]=n[0]*((-12)-18*x[1]-18*x[0])
3513      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 3608  class Test_assemblage_2Do1(unittest.Test Line 3527  class Test_assemblage_2Do1(unittest.Test
3527      B_test[1,0,1]=5      B_test[1,0,1]=5
3528      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
3529      Y_test[1]=45      Y_test[1]=45
3530      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
3531      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
3532      y_test[1]=n[0]*((-20)-45*x[1]-45*x[0])      y_test[1]=n[0]*((-20)-45*x[1]-45*x[0])
3533      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 3629  class Test_assemblage_2Do1(unittest.Test Line 3547  class Test_assemblage_2Do1(unittest.Test
3547      B_test[1,0,2]=8      B_test[1,0,2]=8
3548      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
3549      Y_test[1]=16      Y_test[1]=16
3550      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
3551      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
3552      y_test[1]=n[0]*(40+24*x[1]-16*x[0])      y_test[1]=n[0]*(40+24*x[1]-16*x[0])
3553      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 3650  class Test_assemblage_2Do1(unittest.Test Line 3567  class Test_assemblage_2Do1(unittest.Test
3567      B_test[1,1,0]=2      B_test[1,1,0]=2
3568      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
3569      Y_test[1]=16      Y_test[1]=16
3570      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
3571      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
3572      y_test[1]=n[1]*(12-16*x[1]+2*x[0])      y_test[1]=n[1]*(12-16*x[1]+2*x[0])
3573      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 3671  class Test_assemblage_2Do1(unittest.Test Line 3587  class Test_assemblage_2Do1(unittest.Test
3587      B_test[1,1,1]=3      B_test[1,1,1]=3
3588      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
3589      Y_test[1]=(-15)      Y_test[1]=(-15)
3590      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
3591      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
3592      y_test[1]=n[1]*((-18)+15*x[1]+21*x[0])      y_test[1]=n[1]*((-18)+15*x[1]+21*x[0])
3593      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 3692  class Test_assemblage_2Do1(unittest.Test Line 3607  class Test_assemblage_2Do1(unittest.Test
3607      B_test[1,1,2]=6      B_test[1,1,2]=6
3608      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
3609      Y_test[1]=(-48)      Y_test[1]=(-48)
3610      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
3611      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
3612      y_test[1]=n[1]*((-48)+48*x[1]+24*x[0])      y_test[1]=n[1]*((-48)+48*x[1]+24*x[0])
3613      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 3713  class Test_assemblage_2Do1(unittest.Test Line 3627  class Test_assemblage_2Do1(unittest.Test
3627      B_test[2,0,0]=1      B_test[2,0,0]=1
3628      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
3629      Y_test[2]=5      Y_test[2]=5
3630      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
3631      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
3632      y_test[2]=n[0]*(4-3*x[1]-5*x[0])      y_test[2]=n[0]*(4-3*x[1]-5*x[0])
3633      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 3734  class Test_assemblage_2Do1(unittest.Test Line 3647  class Test_assemblage_2Do1(unittest.Test
3647      B_test[2,0,1]=5      B_test[2,0,1]=5
3648      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
3649      Y_test[2]=25      Y_test[2]=25
3650      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
3651      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
3652      y_test[2]=n[0]*((-10)-15*x[1]-25*x[0])      y_test[2]=n[0]*((-10)-15*x[1]-25*x[0])
3653      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 3755  class Test_assemblage_2Do1(unittest.Test Line 3667  class Test_assemblage_2Do1(unittest.Test
3667      B_test[2,0,2]=8      B_test[2,0,2]=8
3668      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
3669      Y_test[2]=(-64)      Y_test[2]=(-64)
3670      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
3671      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
3672      y_test[2]=n[0]*(40-72*x[1]+64*x[0])      y_test[2]=n[0]*(40-72*x[1]+64*x[0])
3673      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 3776  class Test_assemblage_2Do1(unittest.Test Line 3687  class Test_assemblage_2Do1(unittest.Test
3687      B_test[2,1,0]=2      B_test[2,1,0]=2
3688      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
3689      Y_test[2]=12      Y_test[2]=12
3690      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
3691      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
3692      y_test[2]=n[1]*((-6)-12*x[1]-2*x[0])      y_test[2]=n[1]*((-6)-12*x[1]-2*x[0])
3693      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 3797  class Test_assemblage_2Do1(unittest.Test Line 3707  class Test_assemblage_2Do1(unittest.Test
3707      B_test[2,1,1]=1      B_test[2,1,1]=1
3708      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
3709      Y_test[2]=9      Y_test[2]=9
3710      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
3711      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
3712      y_test[2]=n[1]*(2-9*x[1]-8*x[0])      y_test[2]=n[1]*(2-9*x[1]-8*x[0])
3713      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 3818  class Test_assemblage_2Do1(unittest.Test Line 3727  class Test_assemblage_2Do1(unittest.Test
3727      B_test[2,1,2]=5      B_test[2,1,2]=5
3728      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
3729      Y_test[2]=(-20)      Y_test[2]=(-20)
3730      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
3731      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
3732      y_test[2]=n[1]*((-15)+20*x[1]+15*x[0])      y_test[2]=n[1]*((-15)+20*x[1]+15*x[0])
3733      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 4451  class Test_assemblage_2Do1(unittest.Test Line 4359  class Test_assemblage_2Do1(unittest.Test
4359      A_test[0,0,0,0]=x[0]      A_test[0,0,0,0]=x[0]
4360      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
4361      Y_test[0]=3      Y_test[0]=3
4362      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
4363      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
4364      y_test[0]=n[0]*((-3)*x[0])      y_test[0]=n[0]*((-3)*x[0])
4365      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 4472  class Test_assemblage_2Do1(unittest.Test Line 4379  class Test_assemblage_2Do1(unittest.Test
4379      A_test[0,0,0,1]=x[0]      A_test[0,0,0,1]=x[0]
4380      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
4381      Y_test[0]=(-3)      Y_test[0]=(-3)
4382      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
4383      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
4384      y_test[0]=n[0]*(3*x[0])      y_test[0]=n[0]*(3*x[0])
4385      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 4493  class Test_assemblage_2Do1(unittest.Test Line 4399  class Test_assemblage_2Do1(unittest.Test
4399      A_test[0,0,1,0]=x[0]      A_test[0,0,1,0]=x[0]
4400      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
4401      Y_test[0]=(-4)      Y_test[0]=(-4)
4402      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
4403      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
4404      y_test[0]=n[0]*(4*x[0])      y_test[0]=n[0]*(4*x[0])
4405      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 4514  class Test_assemblage_2Do1(unittest.Test Line 4419  class Test_assemblage_2Do1(unittest.Test
4419      A_test[0,0,1,1]=x[0]      A_test[0,0,1,1]=x[0]
4420      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
4421      Y_test[0]=8      Y_test[0]=8
4422      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
4423      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
4424      y_test[0]=n[0]*((-8)*x[0])      y_test[0]=n[0]*((-8)*x[0])
4425      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 4535  class Test_assemblage_2Do1(unittest.Test Line 4439  class Test_assemblage_2Do1(unittest.Test
4439      A_test[0,0,2,0]=x[0]      A_test[0,0,2,0]=x[0]
4440      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
4441      Y_test[0]=2      Y_test[0]=2
4442      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
4443      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
4444      y_test[0]=n[0]*((-2)*x[0])      y_test[0]=n[0]*((-2)*x[0])
4445      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 4556  class Test_assemblage_2Do1(unittest.Test Line 4459  class Test_assemblage_2Do1(unittest.Test
4459      A_test[0,0,2,1]=x[0]      A_test[0,0,2,1]=x[0]
4460      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
4461      Y_test[0]=9      Y_test[0]=9
4462      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
4463      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
4464      y_test[0]=n[0]*((-9)*x[0])      y_test[0]=n[0]*((-9)*x[0])
4465      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 4577  class Test_assemblage_2Do1(unittest.Test Line 4479  class Test_assemblage_2Do1(unittest.Test
4479      A_test[0,1,0,0]=x[1]      A_test[0,1,0,0]=x[1]
4480      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
4481      Y_test[0]=8      Y_test[0]=8
4482      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
4483      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
4484      y_test[0]=n[1]*((-8)*x[1])      y_test[0]=n[1]*((-8)*x[1])
4485      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 4598  class Test_assemblage_2Do1(unittest.Test Line 4499  class Test_assemblage_2Do1(unittest.Test
4499      A_test[0,1,0,1]=x[1]      A_test[0,1,0,1]=x[1]
4500      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
4501      Y_test[0]=(-4)      Y_test[0]=(-4)
4502      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
4503      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
4504      y_test[0]=n[1]*(4*x[1])      y_test[0]=n[1]*(4*x[1])
4505      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 4619  class Test_assemblage_2Do1(unittest.Test Line 4519  class Test_assemblage_2Do1(unittest.Test
4519      A_test[0,1,1,0]=x[1]      A_test[0,1,1,0]=x[1]
4520      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
4521      Y_test[0]=(-2)      Y_test[0]=(-2)
4522      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
4523      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
4524      y_test[0]=n[1]*(2*x[1])      y_test[0]=n[1]*(2*x[1])
4525      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 4640  class Test_assemblage_2Do1(unittest.Test Line 4539  class Test_assemblage_2Do1(unittest.Test
4539      A_test[0,1,1,1]=x[1]      A_test[0,1,1,1]=x[1]
4540      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
4541      Y_test[0]=(-5)      Y_test[0]=(-5)
4542      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
4543      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
4544      y_test[0]=n[1]*(5*x[1])      y_test[0]=n[1]*(5*x[1])
4545      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 4661  class Test_assemblage_2Do1(unittest.Test Line 4559  class Test_assemblage_2Do1(unittest.Test
4559      A_test[0,1,2,0]=x[1]      A_test[0,1,2,0]=x[1]
4560      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
4561      Y_test[0]=(-3)      Y_test[0]=(-3)
4562      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
4563      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
4564      y_test[0]=n[1]*(3*x[1])      y_test[0]=n[1]*(3*x[1])
4565      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 4682  class Test_assemblage_2Do1(unittest.Test Line 4579  class Test_assemblage_2Do1(unittest.Test
4579      A_test[0,1,2,1]=x[1]      A_test[0,1,2,1]=x[1]
4580      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
4581      Y_test[0]=3      Y_test[0]=3
4582      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
4583      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
4584      y_test[0]=n[1]*((-3)*x[1])      y_test[0]=n[1]*((-3)*x[1])
4585      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 4703  class Test_assemblage_2Do1(unittest.Test Line 4599  class Test_assemblage_2Do1(unittest.Test
4599      A_test[1,0,0,0]=x[0]      A_test[1,0,0,0]=x[0]
4600      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
4601      Y_test[1]=7      Y_test[1]=7
4602      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
4603      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
4604      y_test[1]=n[0]*((-7)*x[0])      y_test[1]=n[0]*((-7)*x[0])
4605      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 4724  class Test_assemblage_2Do1(unittest.Test Line 4619  class Test_assemblage_2Do1(unittest.Test
4619      A_test[1,0,0,1]=x[0]      A_test[1,0,0,1]=x[0]
4620      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
4621      Y_test[1]=1      Y_test[1]=1
4622      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
4623      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
4624      y_test[1]=n[0]*((-1)*x[0])      y_test[1]=n[0]*((-1)*x[0])
4625      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 4745  class Test_assemblage_2Do1(unittest.Test Line 4639  class Test_assemblage_2Do1(unittest.Test
4639      A_test[1,0,1,0]=x[0]      A_test[1,0,1,0]=x[0]
4640      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
4641      Y_test[1]=4      Y_test[1]=4
4642      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
4643      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
4644      y_test[1]=n[0]*((-4)*x[0])      y_test[1]=n[0]*((-4)*x[0])
4645      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 4766  class Test_assemblage_2Do1(unittest.Test Line 4659  class Test_assemblage_2Do1(unittest.Test
4659      A_test[1,0,1,1]=x[0]      A_test[1,0,1,1]=x[0]
4660      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
4661      Y_test[1]=1      Y_test[1]=1
4662      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
4663      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
4664      y_test[1]=n[0]*((-1)*x[0])      y_test[1]=n[0]*((-1)*x[0])
4665      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 4787  class Test_assemblage_2Do1(unittest.Test Line 4679  class Test_assemblage_2Do1(unittest.Test
4679      A_test[1,0,2,0]=x[0]      A_test[1,0,2,0]=x[0]
4680      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
4681      Y_test[1]=(-4)      Y_test[1]=(-4)
4682      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
4683      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
4684      y_test[1]=n[0]*(4*x[0])      y_test[1]=n[0]*(4*x[0])
4685      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 4808  class Test_assemblage_2Do1(unittest.Test Line 4699  class Test_assemblage_2Do1(unittest.Test
4699      A_test[1,0,2,1]=x[0]      A_test[1,0,2,1]=x[0]
4700      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
4701      Y_test[1]=3      Y_test[1]=3
4702      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
4703      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
4704      y_test[1]=n[0]*((-3)*x[0])      y_test[1]=n[0]*((-3)*x[0])
4705      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 4829  class Test_assemblage_2Do1(unittest.Test Line 4719  class Test_assemblage_2Do1(unittest.Test
4719      A_test[1,1,0,0]=x[1]      A_test[1,1,0,0]=x[1]
4720      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
4721      Y_test[1]=3      Y_test[1]=3
4722      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
4723      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
4724      y_test[1]=n[1]*((-3)*x[1])      y_test[1]=n[1]*((-3)*x[1])
4725      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 4850  class Test_assemblage_2Do1(unittest.Test Line 4739  class Test_assemblage_2Do1(unittest.Test
4739      A_test[1,1,0,1]=x[1]      A_test[1,1,0,1]=x[1]
4740      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
4741      Y_test[1]=9      Y_test[1]=9
4742      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
4743      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
4744      y_test[1]=n[1]*((-9)*x[1])      y_test[1]=n[1]*((-9)*x[1])
4745      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 4871  class Test_assemblage_2Do1(unittest.Test Line 4759  class Test_assemblage_2Do1(unittest.Test
4759      A_test[1,1,1,0]=x[1]      A_test[1,1,1,0]=x[1]
4760      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
4761      Y_test[1]=(-4)      Y_test[1]=(-4)
4762      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
4763      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
4764      y_test[1]=n[1]*(4*x[1])      y_test[1]=n[1]*(4*x[1])
4765      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 4892  class Test_assemblage_2Do1(unittest.Test Line 4779  class Test_assemblage_2Do1(unittest.Test
4779      A_test[1,1,1,1]=x[1]      A_test[1,1,1,1]=x[1]
4780      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
4781      Y_test[1]=(-6)      Y_test[1]=(-6)
4782      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
4783      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
4784      y_test[1]=n[1]*(6*x[1])      y_test[1]=n[1]*(6*x[1])
4785      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 4913  class Test_assemblage_2Do1(unittest.Test Line 4799  class Test_assemblage_2Do1(unittest.Test
4799      A_test[1,1,2,0]=x[1]      A_test[1,1,2,0]=x[1]
4800      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
4801      Y_test[1]=2      Y_test[1]=2
4802      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
4803      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
4804      y_test[1]=n[1]*((-2)*x[1])      y_test[1]=n[1]*((-2)*x[1])
4805      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 4934  class Test_assemblage_2Do1(unittest.Test Line 4819  class Test_assemblage_2Do1(unittest.Test
4819      A_test[1,1,2,1]=x[1]      A_test[1,1,2,1]=x[1]
4820      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
4821      Y_test[1]=8      Y_test[1]=8
4822      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
4823      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
4824      y_test[1]=n[1]*((-8)*x[1])      y_test[1]=n[1]*((-8)*x[1])
4825      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 4955  class Test_assemblage_2Do1(unittest.Test Line 4839  class Test_assemblage_2Do1(unittest.Test
4839      A_test[2,0,0,0]=x[0]      A_test[2,0,0,0]=x[0]
4840      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
4841      Y_test[2]=5      Y_test[2]=5
4842      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
4843      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
4844      y_test[2]=n[0]*((-5)*x[0])      y_test[2]=n[0]*((-5)*x[0])
4845      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 4976  class Test_assemblage_2Do1(unittest.Test Line 4859  class Test_assemblage_2Do1(unittest.Test
4859      A_test[2,0,0,1]=x[0]      A_test[2,0,0,1]=x[0]
4860      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
4861      Y_test[2]=3      Y_test[2]=3
4862      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
4863      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
4864      y_test[2]=n[0]*((-3)*x[0])      y_test[2]=n[0]*((-3)*x[0])
4865      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 4997  class Test_assemblage_2Do1(unittest.Test Line 4879  class Test_assemblage_2Do1(unittest.Test
4879      A_test[2,0,1,0]=x[0]      A_test[2,0,1,0]=x[0]
4880      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
4881      Y_test[2]=(-4)      Y_test[2]=(-4)
4882      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
4883      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
4884      y_test[2]=n[0]*(4*x[0])      y_test[2]=n[0]*(4*x[0])
4885      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 5018  class Test_assemblage_2Do1(unittest.Test Line 4899  class Test_assemblage_2Do1(unittest.Test
4899      A_test[2,0,1,1]=x[0]      A_test[2,0,1,1]=x[0]
4900      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
4901      Y_test[2]=9      Y_test[2]=9
4902      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
4903      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
4904      y_test[2]=n[0]*((-9)*x[0])      y_test[2]=n[0]*((-9)*x[0])
4905      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 5039  class Test_assemblage_2Do1(unittest.Test Line 4919  class Test_assemblage_2Do1(unittest.Test
4919      A_test[2,0,2,0]=x[0]      A_test[2,0,2,0]=x[0]
4920      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
4921      Y_test[2]=5      Y_test[2]=5
4922      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
4923      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
4924      y_test[2]=n[0]*((-5)*x[0])      y_test[2]=n[0]*((-5)*x[0])
4925      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 5060  class Test_assemblage_2Do1(unittest.Test Line 4939  class Test_assemblage_2Do1(unittest.Test
4939      A_test[2,0,2,1]=x[0]      A_test[2,0,2,1]=x[0]
4940      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
4941      Y_test[2]=(-3)      Y_test[2]=(-3)
4942      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
4943      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
4944      y_test[2]=n[0]*(3*x[0])      y_test[2]=n[0]*(3*x[0])
4945      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 5081  class Test_assemblage_2Do1(unittest.Test Line 4959  class Test_assemblage_2Do1(unittest.Test
4959      A_test[2,1,0,0]=x[1]      A_test[2,1,0,0]=x[1]
4960      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
4961      Y_test[2]=(-7)      Y_test[2]=(-7)
4962      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
4963      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
4964      y_test[2]=n[1]*(7*x[1])      y_test[2]=n[1]*(7*x[1])
4965      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 5102  class Test_assemblage_2Do1(unittest.Test Line 4979  class Test_assemblage_2Do1(unittest.Test
4979      A_test[2,1,0,1]=x[1]      A_test[2,1,0,1]=x[1]
4980      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
4981      Y_test[2]=(-7)      Y_test[2]=(-7)
4982      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
4983      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
4984      y_test[2]=n[1]*(7*x[1])      y_test[2]=n[1]*(7*x[1])
4985      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 5123  class Test_assemblage_2Do1(unittest.Test Line 4999  class Test_assemblage_2Do1(unittest.Test
4999      A_test[2,1,1,0]=x[1]      A_test[2,1,1,0]=x[1]
5000      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
5001      Y_test[2]=(-4)      Y_test[2]=(-4)
5002      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
5003      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
5004      y_test[2]=n[1]*(4*x[1])      y_test[2]=n[1]*(4*x[1])
5005      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 5144  class Test_assemblage_2Do1(unittest.Test Line 5019  class Test_assemblage_2Do1(unittest.Test
5019      A_test[2,1,1,1]=x[1]      A_test[2,1,1,1]=x[1]
5020      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
5021      Y_test[2]=5      Y_test[2]=5
5022      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
5023      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
5024      y_test[2]=n[1]*((-5)*x[1])      y_test[2]=n[1]*((-5)*x[1])
5025      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 5165  class Test_assemblage_2Do1(unittest.Test Line 5039  class Test_assemblage_2Do1(unittest.Test
5039      A_test[2,1,2,0]=x[1]      A_test[2,1,2,0]=x[1]
5040      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
5041      Y_test[2]=(-5)      Y_test[2]=(-5)
5042      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
5043      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
5044      y_test[2]=n[1]*(5*x[1])      y_test[2]=n[1]*(5*x[1])
5045      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 5186  class Test_assemblage_2Do1(unittest.Test Line 5059  class Test_assemblage_2Do1(unittest.Test
5059      A_test[2,1,2,1]=x[1]      A_test[2,1,2,1]=x[1]
5060      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
5061      Y_test[2]=(-4)      Y_test[2]=(-4)
5062      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
5063      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
5064      y_test[2]=n[1]*(4*x[1])      y_test[2]=n[1]*(4*x[1])
5065      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 5207  class Test_assemblage_2Do1(unittest.Test Line 5079  class Test_assemblage_2Do1(unittest.Test
5079      B_test[0,0,0]=x[0]      B_test[0,0,0]=x[0]
5080      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
5081      Y_test[0]=5-3*x[1]-2*x[0]      Y_test[0]=5-3*x[1]-2*x[0]
5082      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
5083      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
5084      y_test[0]=n[0]*((-5)*x[0]+3*x[0]*x[1]+x[0]**2)      y_test[0]=n[0]*((-5)*x[0]+3*x[0]*x[1]+x[0]**2)
5085      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 5228  class Test_assemblage_2Do1(unittest.Test Line 5099  class Test_assemblage_2Do1(unittest.Test
5099      B_test[0,0,1]=x[0]      B_test[0,0,1]=x[0]
5100      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
5101      Y_test[0]=5+x[1]+12*x[0]      Y_test[0]=5+x[1]+12*x[0]
5102      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
5103      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
5104      y_test[0]=n[0]*((-5)*x[0]-1*x[0]*x[1]-6*x[0]**2)      y_test[0]=n[0]*((-5)*x[0]-1*x[0]*x[1]-6*x[0]**2)
5105      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 5249  class Test_assemblage_2Do1(unittest.Test Line 5119  class Test_assemblage_2Do1(unittest.Test
5119      B_test[0,0,2]=x[0]      B_test[0,0,2]=x[0]
5120      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
5121      Y_test[0]=(-6)-2*x[1]+14*x[0]      Y_test[0]=(-6)-2*x[1]+14*x[0]
5122      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
5123      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
5124      y_test[0]=n[0]*(6*x[0]+2*x[0]*x[1]-7*x[0]**2)      y_test[0]=n[0]*(6*x[0]+2*x[0]*x[1]-7*x[0]**2)
5125      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 5270  class Test_assemblage_2Do1(unittest.Test Line 5139  class Test_assemblage_2Do1(unittest.Test
5139      B_test[0,1,0]=x[1]      B_test[0,1,0]=x[1]
5140      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
5141      Y_test[0]=(-5)-6*x[1]+9*x[0]      Y_test[0]=(-5)-6*x[1]+9*x[0]
5142      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
5143      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
5144      y_test[0]=n[1]*(5*x[1]+3*x[1]**2-9*x[0]*x[1])      y_test[0]=n[1]*(5*x[1]+3*x[1]**2-9*x[0]*x[1])
5145      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 5291  class Test_assemblage_2Do1(unittest.Test Line 5159  class Test_assemblage_2Do1(unittest.Test
5159      B_test[0,1,1]=x[1]      B_test[0,1,1]=x[1]
5160      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
5161      Y_test[0]=(-1)+8*x[1]-4*x[0]      Y_test[0]=(-1)+8*x[1]-4*x[0]
5162      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
5163      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
5164      y_test[0]=n[1]*(x[1]-4*x[1]**2+4*x[0]*x[1])      y_test[0]=n[1]*(x[1]-4*x[1]**2+4*x[0]*x[1])
5165      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 5312  class Test_assemblage_2Do1(unittest.Test Line 5179  class Test_assemblage_2Do1(unittest.Test
5179      B_test[0,1,2]=x[1]      B_test[0,1,2]=x[1]
5180      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
5181      Y_test[0]=1-6*x[1]+5*x[0]      Y_test[0]=1-6*x[1]+5*x[0]
5182      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
5183      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
5184      y_test[0]=n[1]*((-1)*x[1]+3*x[1]**2-5*x[0]*x[1])      y_test[0]=n[1]*((-1)*x[1]+3*x[1]**2-5*x[0]*x[1])
5185      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 5333  class Test_assemblage_2Do1(unittest.Test Line 5199  class Test_assemblage_2Do1(unittest.Test
5199      B_test[1,0,0]=x[0]      B_test[1,0,0]=x[0]
5200      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
5201      Y_test[1]=9+4*x[1]-12*x[0]      Y_test[1]=9+4*x[1]-12*x[0]
5202      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
5203      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
5204      y_test[1]=n[0]*((-9)*x[0]-4*x[0]*x[1]+6*x[0]**2)      y_test[1]=n[0]*((-9)*x[0]-4*x[0]*x[1]+6*x[0]**2)
5205      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 5354  class Test_assemblage_2Do1(unittest.Test Line 5219  class Test_assemblage_2Do1(unittest.Test
5219      B_test[1,0,1]=x[0]      B_test[1,0,1]=x[0]
5220      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
5221      Y_test[1]=(-5)-1*x[1]+10*x[0]      Y_test[1]=(-5)-1*x[1]+10*x[0]
5222      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
5223      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
5224      y_test[1]=n[0]*(5*x[0]+x[0]*x[1]-5*x[0]**2)      y_test[1]=n[0]*(5*x[0]+x[0]*x[1]-5*x[0]**2)
5225      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 5375  class Test_assemblage_2Do1(unittest.Test Line 5239  class Test_assemblage_2Do1(unittest.Test
5239      B_test[1,0,2]=x[0]      B_test[1,0,2]=x[0]
5240      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
5241      Y_test[1]=(-5)+9*x[1]+18*x[0]      Y_test[1]=(-5)+9*x[1]+18*x[0]
5242      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
5243      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
5244      y_test[1]=n[0]*(5*x[0]-9*x[0]*x[1]-9*x[0]**2)      y_test[1]=n[0]*(5*x[0]-9*x[0]*x[1]-9*x[0]**2)
5245      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 5396  class Test_assemblage_2Do1(unittest.Test Line 5259  class Test_assemblage_2Do1(unittest.Test
5259      B_test[1,1,0]=x[1]      B_test[1,1,0]=x[1]
5260      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
5261      Y_test[1]=1-14*x[1]-6*x[0]      Y_test[1]=1-14*x[1]-6*x[0]
5262      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
5263      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
5264      y_test[1]=n[1]*((-1)*x[1]+7*x[1]**2+6*x[0]*x[1])      y_test[1]=n[1]*((-1)*x[1]+7*x[1]**2+6*x[0]*x[1])
5265      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 5417  class Test_assemblage_2Do1(unittest.Test Line 5279  class Test_assemblage_2Do1(unittest.Test
5279      B_test[1,1,1]=x[1]      B_test[1,1,1]=x[1]
5280      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
5281      Y_test[1]=9-4*x[1]-1*x[0]      Y_test[1]=9-4*x[1]-1*x[0]
5282      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
5283      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
5284      y_test[1]=n[1]*((-9)*x[1]+2*x[1]**2+x[0]*x[1])      y_test[1]=n[1]*((-9)*x[1]+2*x[1]**2+x[0]*x[1])
5285      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 5438  class Test_assemblage_2Do1(unittest.Test Line 5299  class Test_assemblage_2Do1(unittest.Test
5299      B_test[1,1,2]=x[1]      B_test[1,1,2]=x[1]
5300      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
5301      Y_test[1]=(-7)-8*x[1]+7*x[0]      Y_test[1]=(-7)-8*x[1]+7*x[0]
5302      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
5303      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
5304      y_test[1]=n[1]*(7*x[1]+4*x[1]**2-7*x[0]*x[1])      y_test[1]=n[1]*(7*x[1]+4*x[1]**2-7*x[0]*x[1])
5305      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 5459  class Test_assemblage_2Do1(unittest.Test Line 5319  class Test_assemblage_2Do1(unittest.Test
5319      B_test[2,0,0]=x[0]      B_test[2,0,0]=x[0]
5320      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
5321      Y_test[2]=3+x[1]-2*x[0]      Y_test[2]=3+x[1]-2*x[0]
5322      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
5323      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
5324      y_test[2]=n[0]*((-3)*x[0]-1*x[0]*x[1]+x[0]**2)      y_test[2]=n[0]*((-3)*x[0]-1*x[0]*x[1]+x[0]**2)
5325      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 5480  class Test_assemblage_2Do1(unittest.Test Line 5339  class Test_assemblage_2Do1(unittest.Test
5339      B_test[2,0,1]=x[0]      B_test[2,0,1]=x[0]
5340      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
5341      Y_test[2]=(-8)-8*x[1]-6*x[0]      Y_test[2]=(-8)-8*x[1]-6*x[0]
5342      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
5343      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
5344      y_test[2]=n[0]*(8*x[0]+8*x[0]*x[1]+3*x[0]**2)      y_test[2]=n[0]*(8*x[0]+8*x[0]*x[1]+3*x[0]**2)
5345      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 5501  class Test_assemblage_2Do1(unittest.Test Line 5359  class Test_assemblage_2Do1(unittest.Test
5359      B_test[2,0,2]=x[0]      B_test[2,0,2]=x[0]
5360      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
5361      Y_test[2]=(-1)+2*x[1]-16*x[0]      Y_test[2]=(-1)+2*x[1]-16*x[0]
5362      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
5363      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
5364      y_test[2]=n[0]*(x[0]-2*x[0]*x[1]+8*x[0]**2)      y_test[2]=n[0]*(x[0]-2*x[0]*x[1]+8*x[0]**2)
5365      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 5522  class Test_assemblage_2Do1(unittest.Test Line 5379  class Test_assemblage_2Do1(unittest.Test
5379      B_test[2,1,0]=x[1]      B_test[2,1,0]=x[1]
5380      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
5381      Y_test[2]=(-8)-6*x[1]-2*x[0]      Y_test[2]=(-8)-6*x[1]-2*x[0]
5382      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
5383      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
5384      y_test[2]=n[1]*(8*x[1]+3*x[1]**2+2*x[0]*x[1])      y_test[2]=n[1]*(8*x[1]+3*x[1]**2+2*x[0]*x[1])
5385      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 5543  class Test_assemblage_2Do1(unittest.Test Line 5399  class Test_assemblage_2Do1(unittest.Test
5399      B_test[2,1,1]=x[1]      B_test[2,1,1]=x[1]
5400      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
5401      Y_test[2]=(-6)-14*x[1]+5*x[0]      Y_test[2]=(-6)-14*x[1]+5*x[0]
5402      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
5403      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
5404      y_test[2]=n[1]*(6*x[1]+7*x[1]**2-5*x[0]*x[1])      y_test[2]=n[1]*(6*x[1]+7*x[1]**2-5*x[0]*x[1])
5405      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 5564  class Test_assemblage_2Do1(unittest.Test Line 5419  class Test_assemblage_2Do1(unittest.Test
5419      B_test[2,1,2]=x[1]      B_test[2,1,2]=x[1]
5420      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
5421      Y_test[2]=5-2*x[1]+7*x[0]      Y_test[2]=5-2*x[1]+7*x[0]
5422      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(FunctionOnBoundary(self.domain))
     n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])  
5423      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
5424      y_test[2]=n[1]*((-5)*x[1]+x[1]**2-7*x[0]*x[1])      y_test[2]=n[1]*((-5)*x[1]+x[1]**2-7*x[0]*x[1])
5425      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 8022  class Test_assemblage_2Do1(unittest.Test Line 7876  class Test_assemblage_2Do1(unittest.Test
7876      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
7877      self.failUnless(Lsup(rhs)>0,"right hand side is zero")      self.failUnless(Lsup(rhs)>0,"right hand side is zero")
7878      self.failUnless(Lsup(r)<=self.RES_TOL*Lsup(rhs),"residual is too big")      self.failUnless(Lsup(r)<=self.RES_TOL*Lsup(rhs),"residual is too big")
   
 class Test_assemblage_2Do1_Reduced(unittest.TestCase):  
7879    #==================================================    #==================================================
7880    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_A_Const_typeStrong_comp00(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_A_Const_typeStrong_comp00(self):
7881      x=self.domain.getX()      x=self.domain.getX()
7882      u=(-5)-9*x[1]-5*x[0]      u=(-1)+2*x[1]+6*x[0]
7883      A_test=Data(0.,(2,2),ReducedFunction(self.domain))      A_test=Data(0.,(2,2),ReducedFunction(self.domain))
7884      A_test[0,0]=6      A_test[0,0]=5
7885      Y_test=0      Y_test=0
7886      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(ReducedFunctionOnBoundary(self.domain))
7887      n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])      y_test=n[0]*(30)
     y_test=n[0]*((-30))  
7888      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
7889      pde.setValue(A=A_test, Y=Y_test, y=y_test)      pde.setValue(A_reduced=A_test, Y_reduced=Y_test, y_reduced=y_test)
7890      r=pde.getResidual(u)      r=pde.getResidual(u)
7891      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
7892      self.failUnless(Lsup(rhs)>0,"right hand side is zero")      self.failUnless(Lsup(rhs)>0,"right hand side is zero")
# Line 8043  class Test_assemblage_2Do1_Reduced(unitt Line 7894  class Test_assemblage_2Do1_Reduced(unitt
7894    #==================================================    #==================================================
7895    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_A_Const_typeStrong_comp01(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_A_Const_typeStrong_comp01(self):
7896      x=self.domain.getX()      x=self.domain.getX()
7897      u=6+5*x[1]-1*x[0]      u=7-1*x[1]-8*x[0]
7898      A_test=Data(0.,(2,2),ReducedFunction(self.domain))      A_test=Data(0.,(2,2),ReducedFunction(self.domain))
7899      A_test[0,1]=1      A_test[0,1]=6
7900      Y_test=0      Y_test=0
7901      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(ReducedFunctionOnBoundary(self.domain))
7902      n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])      y_test=n[0]*((-6))
     y_test=n[0]*(5)  
7903      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
7904      pde.setValue(A=A_test, Y=Y_test, y=y_test)      pde.setValue(A_reduced=A_test, Y_reduced=Y_test, y_reduced=y_test)
7905      r=pde.getResidual(u)      r=pde.getResidual(u)
7906      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
7907      self.failUnless(Lsup(rhs)>0,"right hand side is zero")      self.failUnless(Lsup(rhs)>0,"right hand side is zero")
# Line 8059  class Test_assemblage_2Do1_Reduced(unitt Line 7909  class Test_assemblage_2Do1_Reduced(unitt
7909    #==================================================    #==================================================
7910    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_A_Const_typeStrong_comp10(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_A_Const_typeStrong_comp10(self):
7911      x=self.domain.getX()      x=self.domain.getX()
7912      u=2-6*x[1]-9*x[0]      u=(-7)+3*x[1]+3*x[0]
7913      A_test=Data(0.,(2,2),ReducedFunction(self.domain))      A_test=Data(0.,(2,2),ReducedFunction(self.domain))
7914      A_test[1,0]=2      A_test[1,0]=5
7915      Y_test=0      Y_test=0
7916      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(ReducedFunctionOnBoundary(self.domain))
7917      n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])      y_test=n[1]*(15)
     y_test=n[1]*((-18))  
7918      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
7919      pde.setValue(A=A_test, Y=Y_test, y=y_test)      pde.setValue(A_reduced=A_test, Y_reduced=Y_test, y_reduced=y_test)
7920      r=pde.getResidual(u)      r=pde.getResidual(u)
7921      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
7922      self.failUnless(Lsup(rhs)>0,"right hand side is zero")      self.failUnless(Lsup(rhs)>0,"right hand side is zero")
# Line 8075  class Test_assemblage_2Do1_Reduced(unitt Line 7924  class Test_assemblage_2Do1_Reduced(unitt
7924    #==================================================    #==================================================
7925    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_A_Const_typeStrong_comp11(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_A_Const_typeStrong_comp11(self):
7926      x=self.domain.getX()      x=self.domain.getX()
7927      u=7+3*x[1]+8*x[0]      u=(-8)+7*x[1]+3*x[0]
7928      A_test=Data(0.,(2,2),ReducedFunction(self.domain))      A_test=Data(0.,(2,2),ReducedFunction(self.domain))
7929      A_test[1,1]=1      A_test[1,1]=2
7930      Y_test=0      Y_test=0
7931      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(ReducedFunctionOnBoundary(self.domain))
7932      n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])      y_test=n[1]*(14)
     y_test=n[1]*(3)  
7933      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
7934      pde.setValue(A=A_test, Y=Y_test, y=y_test)      pde.setValue(A_reduced=A_test, Y_reduced=Y_test, y_reduced=y_test)
7935      r=pde.getResidual(u)      r=pde.getResidual(u)
7936      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
7937      self.failUnless(Lsup(rhs)>0,"right hand side is zero")      self.failUnless(Lsup(rhs)>0,"right hand side is zero")
# Line 8091  class Test_assemblage_2Do1_Reduced(unitt Line 7939  class Test_assemblage_2Do1_Reduced(unitt
7939    #==================================================    #==================================================
7940    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_B_Const_typeStrong_comp0(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_B_Const_typeStrong_comp0(self):
7941      x=self.domain.getX()      x=self.domain.getX()
7942      u=(-1)+6*x[1]+7*x[0]      u=(-5)
7943      B_test=Data(0.,(2,),ReducedFunction(self.domain))      B_test=Data(0.,(2,),ReducedFunction(self.domain))
7944      B_test[0]=8      B_test[0]=1
7945      Y_test=(-56)      Y_test=0
7946      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(ReducedFunctionOnBoundary(self.domain))
7947      n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])      y_test=n[0]*((-5))
     y_test=n[0]*((-8)+48*x[1]+56*x[0])  
7948      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
7949      pde.setValue(B=B_test, Y=Y_test, y=y_test)      pde.setValue(B_reduced=B_test, Y_reduced=Y_test, y_reduced=y_test)
7950      r=pde.getResidual(u)      r=pde.getResidual(u)
7951      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
7952      self.failUnless(Lsup(rhs)>0,"right hand side is zero")      self.failUnless(Lsup(rhs)>0,"right hand side is zero")
# Line 8107  class Test_assemblage_2Do1_Reduced(unitt Line 7954  class Test_assemblage_2Do1_Reduced(unitt
7954    #==================================================    #==================================================
7955    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_B_Const_typeStrong_comp1(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_B_Const_typeStrong_comp1(self):
7956      x=self.domain.getX()      x=self.domain.getX()
7957      u=8-2*x[1]-4*x[0]      u=(-7)
7958      B_test=Data(0.,(2,),ReducedFunction(self.domain))      B_test=Data(0.,(2,),ReducedFunction(self.domain))
7959      B_test[1]=1      B_test[1]=7
7960      Y_test=2      Y_test=0
7961      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(ReducedFunctionOnBoundary(self.domain))
7962      n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])      y_test=n[1]*((-49))
     y_test=n[1]*(8-2*x[1]-4*x[0])  
7963      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
7964      pde.setValue(B=B_test, Y=Y_test, y=y_test)      pde.setValue(B_reduced=B_test, Y_reduced=Y_test, y_reduced=y_test)
7965      r=pde.getResidual(u)      r=pde.getResidual(u)
7966      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
7967      self.failUnless(Lsup(rhs)>0,"right hand side is zero")      self.failUnless(Lsup(rhs)>0,"right hand side is zero")
# Line 8123  class Test_assemblage_2Do1_Reduced(unitt Line 7969  class Test_assemblage_2Do1_Reduced(unitt
7969    #==================================================    #==================================================
7970    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_C_Const_typeStrong_comp0(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_C_Const_typeStrong_comp0(self):
7971      x=self.domain.getX()      x=self.domain.getX()
7972      u=(-8)+5*x[1]+8*x[0]      u=(-2)-4*x[1]+2*x[0]
7973      C_test=Data(0.,(2,),ReducedFunction(self.domain))      C_test=Data(0.,(2,),ReducedFunction(self.domain))
7974      C_test[0]=2      C_test[0]=3
7975      Y_test=16      Y_test=6
7976      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
7977      pde.setValue(C=C_test, Y=Y_test)      pde.setValue(C_reduced=C_test, Y_reduced=Y_test)
7978      r=pde.getResidual(u)      r=pde.getResidual(u)
7979      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
7980      self.failUnless(Lsup(rhs)>0,"right hand side is zero")      self.failUnless(Lsup(rhs)>0,"right hand side is zero")
# Line 8136  class Test_assemblage_2Do1_Reduced(unitt Line 7982  class Test_assemblage_2Do1_Reduced(unitt
7982    #==================================================    #==================================================
7983    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_C_Const_typeStrong_comp1(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_C_Const_typeStrong_comp1(self):
7984      x=self.domain.getX()      x=self.domain.getX()
7985      u=(-2)-3*x[1]-2*x[0]      u=(-6)+4*x[1]-2*x[0]
7986      C_test=Data(0.,(2,),ReducedFunction(self.domain))      C_test=Data(0.,(2,),ReducedFunction(self.domain))
7987      C_test[1]=3      C_test[1]=2
7988      Y_test=(-9)      Y_test=8
7989      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
7990      pde.setValue(C=C_test, Y=Y_test)      pde.setValue(C_reduced=C_test, Y_reduced=Y_test)
7991      r=pde.getResidual(u)      r=pde.getResidual(u)
7992      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
7993      self.failUnless(Lsup(rhs)>0,"right hand side is zero")      self.failUnless(Lsup(rhs)>0,"right hand side is zero")
# Line 8149  class Test_assemblage_2Do1_Reduced(unitt Line 7995  class Test_assemblage_2Do1_Reduced(unitt
7995    #==================================================    #==================================================
7996    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_D_Const_typeStrong(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_D_Const_typeStrong(self):
7997      x=self.domain.getX()      x=self.domain.getX()
7998      u=(-4)+4*x[1]-4*x[0]      u=(-8)-7*x[1]+4*x[0]
7999      D_test=Data(2,(),ReducedFunction(self.domain))      D_test=Data(5,(),ReducedFunction(self.domain))
8000      Y_test=(-8)+8*x[1]-8*x[0]      Y_test=(-40)-35*x[1]+20*x[0]
8001      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8002      pde.setValue(D=D_test, Y=Y_test)      pde.setValue(D_reduced=D_test, Y_reduced=Y_test)
8003        r=pde.getResidual(u)
8004        rhs=pde.getRightHandSide()
8005        self.failUnless(Lsup(rhs)>0,"right hand side is zero")
8006        self.failUnless(Lsup(r)<=self.RES_TOL*Lsup(rhs),"residual is too big")
8007      #==================================================
8008      def test_assemblage_2D_solO1_coeffOReduced_NEqu1_d_Const_typeStrong(self):
8009        x=self.domain.getX()
8010        u=4+7*x[1]+3*x[0]
8011        d_test=Data(8,(),ReducedFunctionOnBoundary(self.domain))
8012        y_test=32+56*x[1]+24*x[0]
8013        pde=LinearPDE(self.domain)
8014        pde.setValue(d_reduced=d_test, y_reduced=y_test)
8015      r=pde.getResidual(u)      r=pde.getResidual(u)
8016      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8017      self.failUnless(Lsup(rhs)>0,"right hand side is zero")      self.failUnless(Lsup(rhs)>0,"right hand side is zero")
# Line 8161  class Test_assemblage_2Do1_Reduced(unitt Line 8019  class Test_assemblage_2Do1_Reduced(unitt
8019    #==================================================    #==================================================
8020    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_A_Vario_typeStrong_comp00(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_A_Vario_typeStrong_comp00(self):
8021      x=self.domain.getX()      x=self.domain.getX()
8022      u=1-7*x[1]-7*x[0]      u=(-5)+5*x[1]-1*x[0]
8023      A_test=Data(0.,(2,2),ReducedFunction(self.domain))      A_test=Data(0.,(2,2),ReducedFunction(self.domain))
8024      A_test[0,0]=x[0]      A_test[0,0]=x[0]
8025      Y_test=7      Y_test=1
8026      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(ReducedFunctionOnBoundary(self.domain))
8027      n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])      y_test=n[0]*((-1)*x[0])
     y_test=n[0]*((-7)*x[0])  
8028      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8029      pde.setValue(A=A_test, Y=Y_test, y=y_test)      pde.setValue(A_reduced=A_test, Y_reduced=Y_test, y_reduced=y_test)
8030      r=pde.getResidual(u)      r=pde.getResidual(u)
8031      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8032      self.failUnless(Lsup(rhs)>0,"right hand side is zero")      self.failUnless(Lsup(rhs)>0,"right hand side is zero")
# Line 8177  class Test_assemblage_2Do1_Reduced(unitt Line 8034  class Test_assemblage_2Do1_Reduced(unitt
8034    #==================================================    #==================================================
8035    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_A_Vario_typeStrong_comp01(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_A_Vario_typeStrong_comp01(self):
8036      x=self.domain.getX()      x=self.domain.getX()
8037      u=2+4*x[1]-7*x[0]      u=2-7*x[1]+2*x[0]
8038      A_test=Data(0.,(2,2),ReducedFunction(self.domain))      A_test=Data(0.,(2,2),ReducedFunction(self.domain))
8039      A_test[0,1]=x[0]      A_test[0,1]=x[0]
8040      Y_test=(-4)      Y_test=7
8041      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(ReducedFunctionOnBoundary(self.domain))
8042      n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])      y_test=n[0]*((-7)*x[0])
     y_test=n[0]*(4*x[0])  
8043      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8044      pde.setValue(A=A_test, Y=Y_test, y=y_test)      pde.setValue(A_reduced=A_test, Y_reduced=Y_test, y_reduced=y_test)
8045      r=pde.getResidual(u)      r=pde.getResidual(u)
8046      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8047      self.failUnless(Lsup(rhs)>0,"right hand side is zero")      self.failUnless(Lsup(rhs)>0,"right hand side is zero")
# Line 8193  class Test_assemblage_2Do1_Reduced(unitt Line 8049  class Test_assemblage_2Do1_Reduced(unitt
8049    #==================================================    #==================================================
8050    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_A_Vario_typeStrong_comp10(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_A_Vario_typeStrong_comp10(self):
8051      x=self.domain.getX()      x=self.domain.getX()
8052      u=7-5*x[1]-2*x[0]      u=8-4*x[1]-1*x[0]
8053      A_test=Data(0.,(2,2),ReducedFunction(self.domain))      A_test=Data(0.,(2,2),ReducedFunction(self.domain))
8054      A_test[1,0]=x[1]      A_test[1,0]=x[1]
8055      Y_test=2      Y_test=1
8056      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(ReducedFunctionOnBoundary(self.domain))
8057      n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])      y_test=n[1]*((-1)*x[1])
     y_test=n[1]*((-2)*x[1])  
8058      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8059      pde.setValue(A=A_test, Y=Y_test, y=y_test)      pde.setValue(A_reduced=A_test, Y_reduced=Y_test, y_reduced=y_test)
8060      r=pde.getResidual(u)      r=pde.getResidual(u)
8061      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8062      self.failUnless(Lsup(rhs)>0,"right hand side is zero")      self.failUnless(Lsup(rhs)>0,"right hand side is zero")
# Line 8209  class Test_assemblage_2Do1_Reduced(unitt Line 8064  class Test_assemblage_2Do1_Reduced(unitt
8064    #==================================================    #==================================================
8065    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_A_Vario_typeStrong_comp11(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_A_Vario_typeStrong_comp11(self):
8066      x=self.domain.getX()      x=self.domain.getX()
8067      u=(-4)-9*x[1]+7*x[0]      u=(-6)+8*x[1]-2*x[0]
8068      A_test=Data(0.,(2,2),ReducedFunction(self.domain))      A_test=Data(0.,(2,2),ReducedFunction(self.domain))
8069      A_test[1,1]=x[1]      A_test[1,1]=x[1]
8070      Y_test=9      Y_test=(-8)
8071      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(ReducedFunctionOnBoundary(self.domain))
8072      n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])      y_test=n[1]*(8*x[1])
     y_test=n[1]*((-9)*x[1])  
8073      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8074      pde.setValue(A=A_test, Y=Y_test, y=y_test)      pde.setValue(A_reduced=A_test, Y_reduced=Y_test, y_reduced=y_test)
8075      r=pde.getResidual(u)      r=pde.getResidual(u)
8076      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8077      self.failUnless(Lsup(rhs)>0,"right hand side is zero")      self.failUnless(Lsup(rhs)>0,"right hand side is zero")
# Line 8225  class Test_assemblage_2Do1_Reduced(unitt Line 8079  class Test_assemblage_2Do1_Reduced(unitt
8079    #==================================================    #==================================================
8080    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_B_Vario_typeStrong_comp0(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_B_Vario_typeStrong_comp0(self):
8081      x=self.domain.getX()      x=self.domain.getX()
8082      u=(-2)+2*x[1]+5*x[0]      u=(-7)
8083      B_test=Data(0.,(2,),ReducedFunction(self.domain))      B_test=Data(0.,(2,),ReducedFunction(self.domain))
8084      B_test[0]=x[0]      B_test[0]=x[0]
8085      Y_test=2-2*x[1]-10*x[0]      Y_test=7
8086      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(ReducedFunctionOnBoundary(self.domain))
8087      n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])      y_test=n[0]*((-7)*x[0])
     y_test=n[0]*((-2)*x[0]+2*x[0]*x[1]+5*x[0]**2)  
8088      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8089      pde.setValue(B=B_test, Y=Y_test, y=y_test)      pde.setValue(B_reduced=B_test, Y_reduced=Y_test, y_reduced=y_test)
8090      r=pde.getResidual(u)      r=pde.getResidual(u)
8091      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8092      self.failUnless(Lsup(rhs)>0,"right hand side is zero")      self.failUnless(Lsup(rhs)>0,"right hand side is zero")
# Line 8241  class Test_assemblage_2Do1_Reduced(unitt Line 8094  class Test_assemblage_2Do1_Reduced(unitt
8094    #==================================================    #==================================================
8095    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_B_Vario_typeStrong_comp1(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_B_Vario_typeStrong_comp1(self):
8096      x=self.domain.getX()      x=self.domain.getX()
8097      u=(-9)+5*x[1]-7*x[0]      u=(-7)
8098      B_test=Data(0.,(2,),ReducedFunction(self.domain))      B_test=Data(0.,(2,),ReducedFunction(self.domain))
8099      B_test[1]=x[1]      B_test[1]=x[1]
8100      Y_test=9-10*x[1]+7*x[0]      Y_test=7
8101      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(ReducedFunctionOnBoundary(self.domain))
8102      n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])      y_test=n[1]*((-7)*x[1])
     y_test=n[1]*((-9)*x[1]+5*x[1]**2-7*x[0]*x[1])  
8103      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8104      pde.setValue(B=B_test, Y=Y_test, y=y_test)      pde.setValue(B_reduced=B_test, Y_reduced=Y_test, y_reduced=y_test)
8105      r=pde.getResidual(u)      r=pde.getResidual(u)
8106      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8107      self.failUnless(Lsup(rhs)>0,"right hand side is zero")      self.failUnless(Lsup(rhs)>0,"right hand side is zero")
# Line 8257  class Test_assemblage_2Do1_Reduced(unitt Line 8109  class Test_assemblage_2Do1_Reduced(unitt
8109    #==================================================    #==================================================
8110    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_C_Vario_typeStrong_comp0(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_C_Vario_typeStrong_comp0(self):
8111      x=self.domain.getX()      x=self.domain.getX()
8112      u=(-9)-9*x[1]-1*x[0]      u=5-7*x[1]-8*x[0]
8113      C_test=Data(0.,(2,),ReducedFunction(self.domain))      C_test=Data(0.,(2,),ReducedFunction(self.domain))
8114      C_test[0]=x[0]      C_test[0]=x[0]
8115      Y_test=(-1)*x[0]      Y_test=(-8)*x[0]
8116      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8117      pde.setValue(C=C_test, Y=Y_test)      pde.setValue(C_reduced=C_test, Y_reduced=Y_test)
8118      r=pde.getResidual(u)      r=pde.getResidual(u)
8119      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8120      self.failUnless(Lsup(rhs)>0,"right hand side is zero")      self.failUnless(Lsup(rhs)>0,"right hand side is zero")
# Line 8270  class Test_assemblage_2Do1_Reduced(unitt Line 8122  class Test_assemblage_2Do1_Reduced(unitt
8122    #==================================================    #==================================================
8123    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_C_Vario_typeStrong_comp1(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_C_Vario_typeStrong_comp1(self):
8124      x=self.domain.getX()      x=self.domain.getX()
8125      u=2-7*x[1]-6*x[0]      u=8-2*x[1]+2*x[0]
8126      C_test=Data(0.,(2,),ReducedFunction(self.domain))      C_test=Data(0.,(2,),ReducedFunction(self.domain))
8127      C_test[1]=x[1]      C_test[1]=x[1]
8128      Y_test=(-7)*x[1]      Y_test=(-2)*x[1]
8129      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8130      pde.setValue(C=C_test, Y=Y_test)      pde.setValue(C_reduced=C_test, Y_reduced=Y_test)
8131      r=pde.getResidual(u)      r=pde.getResidual(u)
8132      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8133      self.failUnless(Lsup(rhs)>0,"right hand side is zero")      self.failUnless(Lsup(rhs)>0,"right hand side is zero")
# Line 8283  class Test_assemblage_2Do1_Reduced(unitt Line 8135  class Test_assemblage_2Do1_Reduced(unitt
8135    #==================================================    #==================================================
8136    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_D_Vario_typeStrong(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_D_Vario_typeStrong(self):
8137      x=self.domain.getX()      x=self.domain.getX()
8138      u=(-3)      u=(-8)
8139      D_test=ReducedFunction(self.domain).getX()[0]      D_test=ReducedFunction(self.domain).getX()[0]
8140      Y_test=(-3)*x[0]      Y_test=(-8)*x[0]
8141      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8142      pde.setValue(D=D_test, Y=Y_test)      pde.setValue(D_reduced=D_test, Y_reduced=Y_test)
8143        r=pde.getResidual(u)
8144        rhs=pde.getRightHandSide()
8145        self.failUnless(Lsup(rhs)>0,"right hand side is zero")
8146        self.failUnless(Lsup(r)<=self.RES_TOL*Lsup(rhs),"residual is too big")
8147      #==================================================
8148      def test_assemblage_2D_solO1_coeffOReduced_NEqu1_d_Vario_typeStrong(self):
8149        x=self.domain.getX()
8150        u=3
8151        d_test=interpolate(x[0],ReducedFunctionOnBoundary(self.domain))
8152        y_test=3*x[0]
8153        pde=LinearPDE(self.domain)
8154        pde.setValue(d_reduced=d_test, y_reduced=y_test)
8155      r=pde.getResidual(u)      r=pde.getResidual(u)
8156      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8157      self.failUnless(Lsup(rhs)>0,"right hand side is zero")      self.failUnless(Lsup(rhs)>0,"right hand side is zero")
# Line 8295  class Test_assemblage_2Do1_Reduced(unitt Line 8159  class Test_assemblage_2Do1_Reduced(unitt
8159    #==================================================    #==================================================
8160    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_A_Const_typeWeak_comp00(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_A_Const_typeWeak_comp00(self):
8161      x=self.domain.getX()      x=self.domain.getX()
8162      u=(-1)+3*x[1]+6*x[0]      u=8-1*x[1]-6*x[0]
8163      A_test=Data(0.,(2,2),ReducedFunction(self.domain))      A_test=Data(0.,(2,2),ReducedFunction(self.domain))
8164      A_test[0,0]=8      A_test[0,0]=1
8165      X_test=Data(0.,(2,),ContinuousFunction(self.domain))      X_test=Data(0.,(2,),ContinuousFunction(self.domain))
8166      X_test[0]=48      X_test[0]=(-6)
8167      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8168      pde.setValue(A=A_test, X=X_test)      pde.setValue(A_reduced=A_test, X_reduced=X_test)
8169      r=pde.getResidual(u)      r=pde.getResidual(u)
8170      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8171      self.failUnless(Lsup(rhs)>0,"right hand side is zero")      self.failUnless(Lsup(rhs)>0,"right hand side is zero")
# Line 8309  class Test_assemblage_2Do1_Reduced(unitt Line 8173  class Test_assemblage_2Do1_Reduced(unitt
8173    #==================================================    #==================================================
8174    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_A_Const_typeWeak_comp01(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_A_Const_typeWeak_comp01(self):
8175      x=self.domain.getX()      x=self.domain.getX()
8176      u=(-9)-4*x[1]+4*x[0]      u=(-1)+5*x[1]-3*x[0]
8177      A_test=Data(0.,(2,2),ReducedFunction(self.domain))      A_test=Data(0.,(2,2),ReducedFunction(self.domain))
8178      A_test[0,1]=4      A_test[0,1]=4
8179      X_test=Data(0.,(2,),ContinuousFunction(self.domain))      X_test=Data(0.,(2,),ContinuousFunction(self.domain))
8180      X_test[0]=(-16)      X_test[0]=20
8181      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8182      pde.setValue(A=A_test, X=X_test)      pde.setValue(A_reduced=A_test, X_reduced=X_test)
8183      r=pde.getResidual(u)      r=pde.getResidual(u)
8184      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8185      self.failUnless(Lsup(rhs)>0,"right hand side is zero")      self.failUnless(Lsup(rhs)>0,"right hand side is zero")
# Line 8323  class Test_assemblage_2Do1_Reduced(unitt Line 8187  class Test_assemblage_2Do1_Reduced(unitt
8187    #==================================================    #==================================================
8188    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_A_Const_typeWeak_comp10(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_A_Const_typeWeak_comp10(self):
8189      x=self.domain.getX()      x=self.domain.getX()
8190      u=7-4*x[1]-7*x[0]      u=6+3*x[1]-2*x[0]
8191      A_test=Data(0.,(2,2),ReducedFunction(self.domain))      A_test=Data(0.,(2,2),ReducedFunction(self.domain))
8192      A_test[1,0]=5      A_test[1,0]=7
8193      X_test=Data(0.,(2,),ContinuousFunction(self.domain))      X_test=Data(0.,(2,),ContinuousFunction(self.domain))
8194      X_test[1]=(-35)      X_test[1]=(-14)
8195      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8196      pde.setValue(A=A_test, X=X_test)      pde.setValue(A_reduced=A_test, X_reduced=X_test)
8197      r=pde.getResidual(u)      r=pde.getResidual(u)
8198      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8199      self.failUnless(Lsup(rhs)>0,"right hand side is zero")      self.failUnless(Lsup(rhs)>0,"right hand side is zero")
# Line 8337  class Test_assemblage_2Do1_Reduced(unitt Line 8201  class Test_assemblage_2Do1_Reduced(unitt
8201    #==================================================    #==================================================
8202    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_A_Const_typeWeak_comp11(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_A_Const_typeWeak_comp11(self):
8203      x=self.domain.getX()      x=self.domain.getX()
8204      u=6+2*x[1]-6*x[0]      u=7-9*x[1]-2*x[0]
8205      A_test=Data(0.,(2,2),ReducedFunction(self.domain))      A_test=Data(0.,(2,2),ReducedFunction(self.domain))
8206      A_test[1,1]=7      A_test[1,1]=7
8207      X_test=Data(0.,(2,),ContinuousFunction(self.domain))      X_test=Data(0.,(2,),ContinuousFunction(self.domain))
8208      X_test[1]=14      X_test[1]=(-63)
8209      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8210      pde.setValue(A=A_test, X=X_test)      pde.setValue(A_reduced=A_test, X_reduced=X_test)
8211      r=pde.getResidual(u)      r=pde.getResidual(u)
8212      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8213      self.failUnless(Lsup(rhs)>0,"right hand side is zero")      self.failUnless(Lsup(rhs)>0,"right hand side is zero")
# Line 8351  class Test_assemblage_2Do1_Reduced(unitt Line 8215  class Test_assemblage_2Do1_Reduced(unitt
8215    #==================================================    #==================================================
8216    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_B_Const_typeWeak_comp0(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_B_Const_typeWeak_comp0(self):
8217      x=self.domain.getX()      x=self.domain.getX()
8218      u=(-1)-2*x[1]+4*x[0]      u=6
8219      B_test=Data(0.,(2,),ReducedFunction(self.domain))      B_test=Data(0.,(2,),ReducedFunction(self.domain))
8220      B_test[0]=2      B_test[0]=1
8221      X_test=Data(0.,(2,),ContinuousFunction(self.domain))      X_test=Data(0.,(2,),ContinuousFunction(self.domain))
8222      X_test[0]=(-2)-4*x[1]+8*x[0]      X_test[0]=6
8223      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8224      pde.setValue(B=B_test, X=X_test)      pde.setValue(B_reduced=B_test, X_reduced=X_test)
8225      r=pde.getResidual(u)      r=pde.getResidual(u)
8226      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8227      self.failUnless(Lsup(rhs)>0,"right hand side is zero")      self.failUnless(Lsup(rhs)>0,"right hand side is zero")
# Line 8365  class Test_assemblage_2Do1_Reduced(unitt Line 8229  class Test_assemblage_2Do1_Reduced(unitt
8229    #==================================================    #==================================================
8230    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_B_Const_typeWeak_comp1(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_B_Const_typeWeak_comp1(self):
8231      x=self.domain.getX()      x=self.domain.getX()
8232      u=4-9*x[1]-1*x[0]      u=(-6)
8233      B_test=Data(0.,(2,),ReducedFunction(self.domain))      B_test=Data(0.,(2,),ReducedFunction(self.domain))
8234      B_test[1]=1      B_test[1]=2
8235      X_test=Data(0.,(2,),ContinuousFunction(self.domain))      X_test=Data(0.,(2,),ContinuousFunction(self.domain))
8236      X_test[1]=4-9*x[1]-1*x[0]      X_test[1]=(-12)
8237      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8238      pde.setValue(B=B_test, X=X_test)      pde.setValue(B_reduced=B_test, X_reduced=X_test)
8239      r=pde.getResidual(u)      r=pde.getResidual(u)
8240      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8241      self.failUnless(Lsup(rhs)>0,"right hand side is zero")      self.failUnless(Lsup(rhs)>0,"right hand side is zero")
# Line 8379  class Test_assemblage_2Do1_Reduced(unitt Line 8243  class Test_assemblage_2Do1_Reduced(unitt
8243    #==================================================    #==================================================
8244    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_A_Vario_typeWeak_comp00(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_A_Vario_typeWeak_comp00(self):
8245      x=self.domain.getX()      x=self.domain.getX()
8246      u=(-9)+7*x[1]-4*x[0]      u=6-8*x[1]-9*x[0]
8247      A_test=Data(0.,(2,2),ReducedFunction(self.domain))      A_test=Data(0.,(2,2),ReducedFunction(self.domain))
8248      A_test[0,0]=x[0]      A_test[0,0]=x[0]
8249      X_test=Data(0.,(2,),ContinuousFunction(self.domain))      X_test=Data(0.,(2,),ContinuousFunction(self.domain))
8250      X_test[0]=(-4)*x[0]      X_test[0]=(-9)*x[0]
8251      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8252      pde.setValue(A=A_test, X=X_test)      pde.setValue(A_reduced=A_test, X_reduced=X_test)
8253      r=pde.getResidual(u)      r=pde.getResidual(u)
8254      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8255      self.failUnless(Lsup(rhs)>0,"right hand side is zero")      self.failUnless(Lsup(rhs)>0,"right hand side is zero")
# Line 8393  class Test_assemblage_2Do1_Reduced(unitt Line 8257  class Test_assemblage_2Do1_Reduced(unitt
8257    #==================================================    #==================================================
8258    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_A_Vario_typeWeak_comp01(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_A_Vario_typeWeak_comp01(self):
8259      x=self.domain.getX()      x=self.domain.getX()
8260      u=(-9)-3*x[1]+6*x[0]      u=7-5*x[1]-1*x[0]
8261      A_test=Data(0.,(2,2),ReducedFunction(self.domain))      A_test=Data(0.,(2,2),ReducedFunction(self.domain))
8262      A_test[0,1]=x[0]      A_test[0,1]=x[0]
8263      X_test=Data(0.,(2,),ContinuousFunction(self.domain))      X_test=Data(0.,(2,),ContinuousFunction(self.domain))
8264      X_test[0]=(-3)*x[0]      X_test[0]=(-5)*x[0]
8265      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8266      pde.setValue(A=A_test, X=X_test)      pde.setValue(A_reduced=A_test, X_reduced=X_test)
8267      r=pde.getResidual(u)      r=pde.getResidual(u)
8268      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8269      self.failUnless(Lsup(rhs)>0,"right hand side is zero")      self.failUnless(Lsup(rhs)>0,"right hand side is zero")
# Line 8407  class Test_assemblage_2Do1_Reduced(unitt Line 8271  class Test_assemblage_2Do1_Reduced(unitt
8271    #==================================================    #==================================================
8272    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_A_Vario_typeWeak_comp10(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_A_Vario_typeWeak_comp10(self):
8273      x=self.domain.getX()      x=self.domain.getX()
8274      u=(-6)-7*x[1]-3*x[0]      u=7-5*x[1]+2*x[0]
8275      A_test=Data(0.,(2,2),ReducedFunction(self.domain))      A_test=Data(0.,(2,2),ReducedFunction(self.domain))
8276      A_test[1,0]=x[1]      A_test[1,0]=x[1]
8277      X_test=Data(0.,(2,),ContinuousFunction(self.domain))      X_test=Data(0.,(2,),ContinuousFunction(self.domain))
8278      X_test[1]=(-3)*x[1]      X_test[1]=2*x[1]
8279      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8280      pde.setValue(A=A_test, X=X_test)      pde.setValue(A_reduced=A_test, X_reduced=X_test)
8281      r=pde.getResidual(u)      r=pde.getResidual(u)
8282      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8283      self.failUnless(Lsup(rhs)>0,"right hand side is zero")      self.failUnless(Lsup(rhs)>0,"right hand side is zero")
# Line 8421  class Test_assemblage_2Do1_Reduced(unitt Line 8285  class Test_assemblage_2Do1_Reduced(unitt
8285    #==================================================    #==================================================
8286    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_A_Vario_typeWeak_comp11(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_A_Vario_typeWeak_comp11(self):
8287      x=self.domain.getX()      x=self.domain.getX()
8288      u=(-6)+x[1]-5*x[0]      u=6-8*x[1]+x[0]
8289      A_test=Data(0.,(2,2),ReducedFunction(self.domain))      A_test=Data(0.,(2,2),ReducedFunction(self.domain))
8290      A_test[1,1]=x[1]      A_test[1,1]=x[1]
8291      X_test=Data(0.,(2,),ContinuousFunction(self.domain))      X_test=Data(0.,(2,),ContinuousFunction(self.domain))
8292      X_test[1]=x[1]      X_test[1]=(-8)*x[1]
8293      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8294      pde.setValue(A=A_test, X=X_test)      pde.setValue(A_reduced=A_test, X_reduced=X_test)
8295      r=pde.getResidual(u)      r=pde.getResidual(u)
8296      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8297      self.failUnless(Lsup(rhs)>0,"right hand side is zero")      self.failUnless(Lsup(rhs)>0,"right hand side is zero")
# Line 8435  class Test_assemblage_2Do1_Reduced(unitt Line 8299  class Test_assemblage_2Do1_Reduced(unitt
8299    #==================================================    #==================================================
8300    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_B_Vario_typeWeak_comp0(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_B_Vario_typeWeak_comp0(self):
8301      x=self.domain.getX()      x=self.domain.getX()
8302      u=4      u=(-4)
8303      B_test=Data(0.,(2,),ReducedFunction(self.domain))      B_test=Data(0.,(2,),ReducedFunction(self.domain))
8304      B_test[0]=x[0]      B_test[0]=x[0]
8305      X_test=Data(0.,(2,),ContinuousFunction(self.domain))      X_test=Data(0.,(2,),ContinuousFunction(self.domain))
8306      X_test[0]=4*x[0]      X_test[0]=(-4)*x[0]
8307      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8308      pde.setValue(B=B_test, X=X_test)      pde.setValue(B_reduced=B_test, X_reduced=X_test)
8309      r=pde.getResidual(u)      r=pde.getResidual(u)
8310      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8311      self.failUnless(Lsup(rhs)>0,"right hand side is zero")      self.failUnless(Lsup(rhs)>0,"right hand side is zero")
# Line 8449  class Test_assemblage_2Do1_Reduced(unitt Line 8313  class Test_assemblage_2Do1_Reduced(unitt
8313    #==================================================    #==================================================
8314    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_B_Vario_typeWeak_comp1(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_B_Vario_typeWeak_comp1(self):
8315      x=self.domain.getX()      x=self.domain.getX()
8316      u=(-6)      u=4
8317      B_test=Data(0.,(2,),ReducedFunction(self.domain))      B_test=Data(0.,(2,),ReducedFunction(self.domain))
8318      B_test[1]=x[1]      B_test[1]=x[1]
8319      X_test=Data(0.,(2,),ContinuousFunction(self.domain))      X_test=Data(0.,(2,),ContinuousFunction(self.domain))
8320      X_test[1]=(-6)*x[1]      X_test[1]=4*x[1]
8321      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8322      pde.setValue(B=B_test, X=X_test)      pde.setValue(B_reduced=B_test, X_reduced=X_test)
8323      r=pde.getResidual(u)      r=pde.getResidual(u)
8324      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8325      self.failUnless(Lsup(rhs)>0,"right hand side is zero")      self.failUnless(Lsup(rhs)>0,"right hand side is zero")
# Line 8464  class Test_assemblage_2Do1_Reduced(unitt Line 8328  class Test_assemblage_2Do1_Reduced(unitt
8328    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_A_Const_typeStrong_comp0000(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_A_Const_typeStrong_comp0000(self):
8329      x=self.domain.getX()      x=self.domain.getX()
8330      u=Data(0.,(2,),ContinuousFunction(self.domain))      u=Data(0.,(2,),ContinuousFunction(self.domain))
8331      u[0]=(-5)-7*x[1]-1*x[0]      u[0]=(-5)-4*x[1]+8*x[0]
8332      u[1]=(-6)-1*x[1]-2*x[0]      u[1]=1+5*x[1]+4*x[0]
8333      A_test=Data(0.,(2,2,2,2),ReducedFunction(self.domain))      A_test=Data(0.,(2,2,2,2),ReducedFunction(self.domain))
8334      A_test[0,0,0,0]=2      A_test[0,0,0,0]=6
8335      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
8336      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(ReducedFunctionOnBoundary(self.domain))
8337      n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])      y_test=Data(0.,(2,),ReducedFunctionOnBoundary(self.domain))
8338      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test[0]=n[0]*(48)
     y_test[0]=n[0]*((-2))  
8339      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8340      pde.setValue(A=A_test, Y=Y_test, y=y_test)      pde.setValue(A_reduced=A_test, Y_reduced=Y_test, y_reduced=y_test)
8341      r=pde.getResidual(u)      r=pde.getResidual(u)
8342      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8343      self.failUnless(Lsup(rhs)>0,"right hand side is zero")      self.failUnless(Lsup(rhs)>0,"right hand side is zero")
# Line 8483  class Test_assemblage_2Do1_Reduced(unitt Line 8346  class Test_assemblage_2Do1_Reduced(unitt
8346    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_A_Const_typeStrong_comp0001(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_A_Const_typeStrong_comp0001(self):
8347      x=self.domain.getX()      x=self.domain.getX()
8348      u=Data(0.,(2,),ContinuousFunction(self.domain))      u=Data(0.,(2,),ContinuousFunction(self.domain))
8349      u[0]=(-4)+4*x[1]+8*x[0]      u[0]=2-5*x[1]-1*x[0]
8350      u[1]=2+5*x[1]-2*x[0]      u[1]=(-5)-5*x[1]+4*x[0]
8351      A_test=Data(0.,(2,2,2,2),ReducedFunction(self.domain))      A_test=Data(0.,(2,2,2,2),ReducedFunction(self.domain))
8352      A_test[0,0,0,1]=3      A_test[0,0,0,1]=8
8353      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
8354      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(ReducedFunctionOnBoundary(self.domain))
8355      n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])      y_test=Data(0.,(2,),ReducedFunctionOnBoundary(self.domain))
8356      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test[0]=n[0]*((-40))
     y_test[0]=n[0]*(12)  
8357      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8358      pde.setValue(A=A_test, Y=Y_test, y=y_test)      pde.setValue(A_reduced=A_test, Y_reduced=Y_test, y_reduced=y_test)
8359      r=pde.getResidual(u)      r=pde.getResidual(u)
8360      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8361      self.failUnless(Lsup(rhs)>0,"right hand side is zero")      self.failUnless(Lsup(rhs)>0,"right hand side is zero")
# Line 8502  class Test_assemblage_2Do1_Reduced(unitt Line 8364  class Test_assemblage_2Do1_Reduced(unitt
8364    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_A_Const_typeStrong_comp0010(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_A_Const_typeStrong_comp0010(self):
8365      x=self.domain.getX()      x=self.domain.getX()
8366      u=Data(0.,(2,),ContinuousFunction(self.domain))      u=Data(0.,(2,),ContinuousFunction(self.domain))
8367      u[0]=1-2*x[1]+5*x[0]      u[0]=(-7)-1*x[1]+8*x[0]
8368      u[1]=(-7)+x[1]+3*x[0]      u[1]=(-2)-2*x[1]+4*x[0]
8369      A_test=Data(0.,(2,2,2,2),ReducedFunction(self.domain))      A_test=Data(0.,(2,2,2,2),ReducedFunction(self.domain))
8370      A_test[0,0,1,0]=2      A_test[0,0,1,0]=5
8371      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
8372      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(ReducedFunctionOnBoundary(self.domain))
8373      n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])      y_test=Data(0.,(2,),ReducedFunctionOnBoundary(self.domain))
8374      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test[0]=n[0]*(20)
     y_test[0]=n[0]*(6)  
8375      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8376      pde.setValue(A=A_test, Y=Y_test, y=y_test)      pde.setValue(A_reduced=A_test, Y_reduced=Y_test, y_reduced=y_test)
8377      r=pde.getResidual(u)      r=pde.getResidual(u)
8378      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8379      self.failUnless(Lsup(rhs)>0,"right hand side is zero")      self.failUnless(Lsup(rhs)>0,"right hand side is zero")
# Line 8521  class Test_assemblage_2Do1_Reduced(unitt Line 8382  class Test_assemblage_2Do1_Reduced(unitt
8382    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_A_Const_typeStrong_comp0011(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_A_Const_typeStrong_comp0011(self):
8383      x=self.domain.getX()      x=self.domain.getX()
8384      u=Data(0.,(2,),ContinuousFunction(self.domain))      u=Data(0.,(2,),ContinuousFunction(self.domain))
8385      u[0]=(-5)-8*x[1]+6*x[0]      u[0]=(-1)-8*x[1]-8*x[0]
8386      u[1]=(-6)+2*x[1]-1*x[0]      u[1]=(-3)-6*x[1]+6*x[0]
8387      A_test=Data(0.,(2,2,2,2),ReducedFunction(self.domain))      A_test=Data(0.,(2,2,2,2),ReducedFunction(self.domain))
8388      A_test[0,0,1,1]=7      A_test[0,0,1,1]=1
8389      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
8390      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(ReducedFunctionOnBoundary(self.domain))
8391      n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])      y_test=Data(0.,(2,),ReducedFunctionOnBoundary(self.domain))
8392      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test[0]=n[0]*((-6))
     y_test[0]=n[0]*(14)  
8393      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8394      pde.setValue(A=A_test, Y=Y_test, y=y_test)      pde.setValue(A_reduced=A_test, Y_reduced=Y_test, y_reduced=y_test)
8395      r=pde.getResidual(u)      r=pde.getResidual(u)
8396      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8397      self.failUnless(Lsup(rhs)>0,"right hand side is zero")      self.failUnless(Lsup(rhs)>0,"right hand side is zero")
# Line 8540  class Test_assemblage_2Do1_Reduced(unitt Line 8400  class Test_assemblage_2Do1_Reduced(unitt
8400    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_A_Const_typeStrong_comp0100(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_A_Const_typeStrong_comp0100(self):
8401      x=self.domain.getX()      x=self.domain.getX()
8402      u=Data(0.,(2,),ContinuousFunction(self.domain))      u=Data(0.,(2,),ContinuousFunction(self.domain))
8403      u[0]=(-5)-4*x[1]+4*x[0]      u[0]=8+3*x[1]+7*x[0]
8404      u[1]=2-8*x[1]-3*x[0]      u[1]=(-8)+2*x[1]-3*x[0]
8405      A_test=Data(0.,(2,2,2,2),ReducedFunction(self.domain))      A_test=Data(0.,(2,2,2,2),ReducedFunction(self.domain))
8406      A_test[0,1,0,0]=4      A_test[0,1,0,0]=4
8407      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
8408      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(ReducedFunctionOnBoundary(self.domain))
8409      n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])      y_test=Data(0.,(2,),ReducedFunctionOnBoundary(self.domain))
8410      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test[0]=n[1]*(28)
     y_test[0]=n[1]*(16)  
8411      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8412      pde.setValue(A=A_test, Y=Y_test, y=y_test)      pde.setValue(A_reduced=A_test, Y_reduced=Y_test, y_reduced=y_test)
8413      r=pde.getResidual(u)      r=pde.getResidual(u)
8414      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8415      self.failUnless(Lsup(rhs)>0,"right hand side is zero")      self.failUnless(Lsup(rhs)>0,"right hand side is zero")
# Line 8559  class Test_assemblage_2Do1_Reduced(unitt Line 8418  class Test_assemblage_2Do1_Reduced(unitt
8418    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_A_Const_typeStrong_comp0101(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_A_Const_typeStrong_comp0101(self):
8419      x=self.domain.getX()      x=self.domain.getX()
8420      u=Data(0.,(2,),ContinuousFunction(self.domain))      u=Data(0.,(2,),ContinuousFunction(self.domain))
8421      u[0]=(-3)+6*x[1]-3*x[0]      u[0]=(-7)-9*x[1]-8*x[0]
8422      u[1]=4+8*x[1]-6*x[0]      u[1]=7-7*x[1]+8*x[0]
8423      A_test=Data(0.,(2,2,2,2),ReducedFunction(self.domain))      A_test=Data(0.,(2,2,2,2),ReducedFunction(self.domain))
8424      A_test[0,1,0,1]=2      A_test[0,1,0,1]=1
8425      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
8426      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(ReducedFunctionOnBoundary(self.domain))
8427      n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])      y_test=Data(0.,(2,),ReducedFunctionOnBoundary(self.domain))
8428      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test[0]=n[1]*((-9))
     y_test[0]=n[1]*(12)  
8429      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8430      pde.setValue(A=A_test, Y=Y_test, y=y_test)      pde.setValue(A_reduced=A_test, Y_reduced=Y_test, y_reduced=y_test)
8431      r=pde.getResidual(u)      r=pde.getResidual(u)
8432      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8433      self.failUnless(Lsup(rhs)>0,"right hand side is zero")      self.failUnless(Lsup(rhs)>0,"right hand side is zero")
# Line 8578  class Test_assemblage_2Do1_Reduced(unitt Line 8436  class Test_assemblage_2Do1_Reduced(unitt
8436    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_A_Const_typeStrong_comp0110(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_A_Const_typeStrong_comp0110(self):
8437      x=self.domain.getX()      x=self.domain.getX()
8438      u=Data(0.,(2,),ContinuousFunction(self.domain))      u=Data(0.,(2,),ContinuousFunction(self.domain))
8439      u[0]=5+5*x[1]+4*x[0]      u[0]=1-8*x[1]+4*x[0]
8440      u[1]=(-2)+4*x[1]+6*x[0]      u[1]=6-6*x[1]-2*x[0]
8441      A_test=Data(0.,(2,2,2,2),ReducedFunction(self.domain))      A_test=Data(0.,(2,2,2,2),ReducedFunction(self.domain))
8442      A_test[0,1,1,0]=2      A_test[0,1,1,0]=5
8443      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
8444      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(ReducedFunctionOnBoundary(self.domain))
8445      n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])      y_test=Data(0.,(2,),ReducedFunctionOnBoundary(self.domain))
8446      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test[0]=n[1]*((-10))
     y_test[0]=n[1]*(12)  
8447      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8448      pde.setValue(A=A_test, Y=Y_test, y=y_test)      pde.setValue(A_reduced=A_test, Y_reduced=Y_test, y_reduced=y_test)
8449      r=pde.getResidual(u)      r=pde.getResidual(u)
8450      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8451      self.failUnless(Lsup(rhs)>0,"right hand side is zero")      self.failUnless(Lsup(rhs)>0,"right hand side is zero")
# Line 8597  class Test_assemblage_2Do1_Reduced(unitt Line 8454  class Test_assemblage_2Do1_Reduced(unitt
8454    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_A_Const_typeStrong_comp0111(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_A_Const_typeStrong_comp0111(self):
8455      x=self.domain.getX()      x=self.domain.getX()
8456      u=Data(0.,(2,),ContinuousFunction(self.domain))      u=Data(0.,(2,),ContinuousFunction(self.domain))
8457      u[0]=(-2)+5*x[1]-2*x[0]      u[0]=3+5*x[1]+8*x[0]
8458      u[1]=8+x[1]-2*x[0]      u[1]=(-3)+3*x[1]-4*x[0]
8459      A_test=Data(0.,(2,2,2,2),ReducedFunction(self.domain))      A_test=Data(0.,(2,2,2,2),ReducedFunction(self.domain))
8460      A_test[0,1,1,1]=8      A_test[0,1,1,1]=1
8461      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
8462      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(ReducedFunctionOnBoundary(self.domain))
8463      n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])      y_test=Data(0.,(2,),ReducedFunctionOnBoundary(self.domain))
8464      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test[0]=n[1]*(3)
     y_test[0]=n[1]*(8)  
8465      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8466      pde.setValue(A=A_test, Y=Y_test, y=y_test)      pde.setValue(A_reduced=A_test, Y_reduced=Y_test, y_reduced=y_test)
8467      r=pde.getResidual(u)      r=pde.getResidual(u)
8468      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8469      self.failUnless(Lsup(rhs)>0,"right hand side is zero")      self.failUnless(Lsup(rhs)>0,"right hand side is zero")
# Line 8616  class Test_assemblage_2Do1_Reduced(unitt Line 8472  class Test_assemblage_2Do1_Reduced(unitt
8472    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_A_Const_typeStrong_comp1000(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_A_Const_typeStrong_comp1000(self):
8473      x=self.domain.getX()      x=self.domain.getX()
8474      u=Data(0.,(2,),ContinuousFunction(self.domain))      u=Data(0.,(2,),ContinuousFunction(self.domain))
8475      u[0]=6-1*x[1]+3*x[0]      u[0]=1-1*x[1]-5*x[0]
8476      u[1]=(-6)-6*x[1]-7*x[0]      u[1]=4+2*x[1]-9*x[0]
8477      A_test=Data(0.,(2,2,2,2),ReducedFunction(self.domain))      A_test=Data(0.,(2,2,2,2),ReducedFunction(self.domain))
8478      A_test[1,0,0,0]=5      A_test[1,0,0,0]=2
8479      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
8480      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(ReducedFunctionOnBoundary(self.domain))
8481      n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])      y_test=Data(0.,(2,),ReducedFunctionOnBoundary(self.domain))
8482      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test[1]=n[0]*((-10))
     y_test[1]=n[0]*(15)  
8483      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8484      pde.setValue(A=A_test, Y=Y_test, y=y_test)      pde.setValue(A_reduced=A_test, Y_reduced=Y_test, y_reduced=y_test)
8485      r=pde.getResidual(u)      r=pde.getResidual(u)
8486      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8487      self.failUnless(Lsup(rhs)>0,"right hand side is zero")      self.failUnless(Lsup(rhs)>0,"right hand side is zero")
# Line 8635  class Test_assemblage_2Do1_Reduced(unitt Line 8490  class Test_assemblage_2Do1_Reduced(unitt
8490    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_A_Const_typeStrong_comp1001(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_A_Const_typeStrong_comp1001(self):
8491      x=self.domain.getX()      x=self.domain.getX()
8492      u=Data(0.,(2,),ContinuousFunction(self.domain))      u=Data(0.,(2,),ContinuousFunction(self.domain))
8493      u[0]=(-7)+6*x[1]-6*x[0]      u[0]=(-7)+6*x[1]-7*x[0]
8494      u[1]=(-8)-4*x[1]+7*x[0]      u[1]=8+8*x[1]-9*x[0]
8495      A_test=Data(0.,(2,2,2,2),ReducedFunction(self.domain))      A_test=Data(0.,(2,2,2,2),ReducedFunction(self.domain))
8496      A_test[1,0,0,1]=6      A_test[1,0,0,1]=6
8497      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
8498      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(ReducedFunctionOnBoundary(self.domain))
8499      n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])      y_test=Data(0.,(2,),ReducedFunctionOnBoundary(self.domain))
     y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))  
8500      y_test[1]=n[0]*(36)      y_test[1]=n[0]*(36)
8501      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8502      pde.setValue(A=A_test, Y=Y_test, y=y_test)      pde.setValue(A_reduced=A_test, Y_reduced=Y_test, y_reduced=y_test)
8503      r=pde.getResidual(u)      r=pde.getResidual(u)
8504      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8505      self.failUnless(Lsup(rhs)>0,"right hand side is zero")      self.failUnless(Lsup(rhs)>0,"right hand side is zero")
# Line 8654  class Test_assemblage_2Do1_Reduced(unitt Line 8508  class Test_assemblage_2Do1_Reduced(unitt
8508    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_A_Const_typeStrong_comp1010(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_A_Const_typeStrong_comp1010(self):
8509      x=self.domain.getX()      x=self.domain.getX()
8510      u=Data(0.,(2,),ContinuousFunction(self.domain))      u=Data(0.,(2,),ContinuousFunction(self.domain))
8511      u[0]=4-4*x[1]+4*x[0]      u[0]=(-5)+6*x[1]+x[0]
8512      u[1]=(-9)+7*x[1]-8*x[0]      u[1]=(-7)-9*x[1]-4*x[0]
8513      A_test=Data(0.,(2,2,2,2),ReducedFunction(self.domain))      A_test=Data(0.,(2,2,2,2),ReducedFunction(self.domain))
8514      A_test[1,0,1,0]=3      A_test[1,0,1,0]=8
8515      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
8516      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(ReducedFunctionOnBoundary(self.domain))
8517      n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])      y_test=Data(0.,(2,),ReducedFunctionOnBoundary(self.domain))
8518      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test[1]=n[0]*((-32))
     y_test[1]=n[0]*((-24))  
8519      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8520      pde.setValue(A=A_test, Y=Y_test, y=y_test)      pde.setValue(A_reduced=A_test, Y_reduced=Y_test, y_reduced=y_test)
8521      r=pde.getResidual(u)      r=pde.getResidual(u)
8522      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8523      self.failUnless(Lsup(rhs)>0,"right hand side is zero")      self.failUnless(Lsup(rhs)>0,"right hand side is zero")
# Line 8673  class Test_assemblage_2Do1_Reduced(unitt Line 8526  class Test_assemblage_2Do1_Reduced(unitt
8526    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_A_Const_typeStrong_comp1011(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_A_Const_typeStrong_comp1011(self):
8527      x=self.domain.getX()      x=self.domain.getX()
8528      u=Data(0.,(2,),ContinuousFunction(self.domain))      u=Data(0.,(2,),ContinuousFunction(self.domain))
8529      u[0]=3+7*x[1]-1*x[0]      u[0]=(-3)+x[1]-4*x[0]
8530      u[1]=8-8*x[1]-3*x[0]      u[1]=5-1*x[1]+5*x[0]
8531      A_test=Data(0.,(2,2,2,2),ReducedFunction(self.domain))      A_test=Data(0.,(2,2,2,2),ReducedFunction(self.domain))
8532      A_test[1,0,1,1]=6      A_test[1,0,1,1]=4
8533      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
8534      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(ReducedFunctionOnBoundary(self.domain))
8535      n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])      y_test=Data(0.,(2,),ReducedFunctionOnBoundary(self.domain))
8536      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test[1]=n[0]*((-4))
     y_test[1]=n[0]*((-48))  
8537      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8538      pde.setValue(A=A_test, Y=Y_test, y=y_test)      pde.setValue(A_reduced=A_test, Y_reduced=Y_test, y_reduced=y_test)
8539      r=pde.getResidual(u)      r=pde.getResidual(u)
8540      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8541      self.failUnless(Lsup(rhs)>0,"right hand side is zero")      self.failUnless(Lsup(rhs)>0,"right hand side is zero")
# Line 8692  class Test_assemblage_2Do1_Reduced(unitt Line 8544  class Test_assemblage_2Do1_Reduced(unitt
8544    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_A_Const_typeStrong_comp1100(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_A_Const_typeStrong_comp1100(self):
8545      x=self.domain.getX()      x=self.domain.getX()
8546      u=Data(0.,(2,),ContinuousFunction(self.domain))      u=Data(0.,(2,),ContinuousFunction(self.domain))
8547      u[0]=1-1*x[1]+4*x[0]      u[0]=(-6)+4*x[1]+5*x[0]
8548      u[1]=7+2*x[1]+5*x[0]      u[1]=2+8*x[1]+4*x[0]
8549      A_test=Data(0.,(2,2,2,2),ReducedFunction(self.domain))      A_test=Data(0.,(2,2,2,2),ReducedFunction(self.domain))
8550      A_test[1,1,0,0]=6      A_test[1,1,0,0]=1
8551      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
8552      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(ReducedFunctionOnBoundary(self.domain))
8553      n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])      y_test=Data(0.,(2,),ReducedFunctionOnBoundary(self.domain))
8554      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test[1]=n[1]*(5)
     y_test[1]=n[1]*(24)  
8555      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8556      pde.setValue(A=A_test, Y=Y_test, y=y_test)      pde.setValue(A_reduced=A_test, Y_reduced=Y_test, y_reduced=y_test)
8557      r=pde.getResidual(u)      r=pde.getResidual(u)
8558      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8559      self.failUnless(Lsup(rhs)>0,"right hand side is zero")      self.failUnless(Lsup(rhs)>0,"right hand side is zero")
# Line 8711  class Test_assemblage_2Do1_Reduced(unitt Line 8562  class Test_assemblage_2Do1_Reduced(unitt
8562    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_A_Const_typeStrong_comp1101(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_A_Const_typeStrong_comp1101(self):
8563      x=self.domain.getX()      x=self.domain.getX()
8564      u=Data(0.,(2,),ContinuousFunction(self.domain))      u=Data(0.,(2,),ContinuousFunction(self.domain))
8565      u[0]=8+3*x[1]-4*x[0]      u[0]=7-5*x[1]+6*x[0]
8566      u[1]=3-4*x[1]+x[0]      u[1]=4+4*x[1]+4*x[0]
8567      A_test=Data(0.,(2,2,2,2),ReducedFunction(self.domain))      A_test=Data(0.,(2,2,2,2),ReducedFunction(self.domain))
8568      A_test[1,1,0,1]=2      A_test[1,1,0,1]=4
8569      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
8570      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(ReducedFunctionOnBoundary(self.domain))
8571      n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])      y_test=Data(0.,(2,),ReducedFunctionOnBoundary(self.domain))
8572      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test[1]=n[1]*((-20))
     y_test[1]=n[1]*(6)  
8573      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8574      pde.setValue(A=A_test, Y=Y_test, y=y_test)      pde.setValue(A_reduced=A_test, Y_reduced=Y_test, y_reduced=y_test)
8575      r=pde.getResidual(u)      r=pde.getResidual(u)
8576      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8577      self.failUnless(Lsup(rhs)>0,"right hand side is zero")      self.failUnless(Lsup(rhs)>0,"right hand side is zero")
# Line 8730  class Test_assemblage_2Do1_Reduced(unitt Line 8580  class Test_assemblage_2Do1_Reduced(unitt
8580    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_A_Const_typeStrong_comp1110(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_A_Const_typeStrong_comp1110(self):
8581      x=self.domain.getX()      x=self.domain.getX()
8582      u=Data(0.,(2,),ContinuousFunction(self.domain))      u=Data(0.,(2,),ContinuousFunction(self.domain))
8583      u[0]=(-7)+7*x[1]+x[0]      u[0]=(-1)+3*x[1]+x[0]
8584      u[1]=3+5*x[1]+7*x[0]      u[1]=1-8*x[1]-1*x[0]
8585      A_test=Data(0.,(2,2,2,2),ReducedFunction(self.domain))      A_test=Data(0.,(2,2,2,2),ReducedFunction(self.domain))
8586      A_test[1,1,1,0]=8      A_test[1,1,1,0]=3
8587      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
8588      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(ReducedFunctionOnBoundary(self.domain))
8589      n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])      y_test=Data(0.,(2,),ReducedFunctionOnBoundary(self.domain))
8590      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test[1]=n[1]*((-3))
     y_test[1]=n[1]*(56)  
8591      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8592      pde.setValue(A=A_test, Y=Y_test, y=y_test)      pde.setValue(A_reduced=A_test, Y_reduced=Y_test, y_reduced=y_test)
8593      r=pde.getResidual(u)      r=pde.getResidual(u)
8594      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8595      self.failUnless(Lsup(rhs)>0,"right hand side is zero")      self.failUnless(Lsup(rhs)>0,"right hand side is zero")
# Line 8749  class Test_assemblage_2Do1_Reduced(unitt Line 8598  class Test_assemblage_2Do1_Reduced(unitt
8598    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_A_Const_typeStrong_comp1111(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_A_Const_typeStrong_comp1111(self):
8599      x=self.domain.getX()      x=self.domain.getX()
8600      u=Data(0.,(2,),ContinuousFunction(self.domain))      u=Data(0.,(2,),ContinuousFunction(self.domain))
8601      u[0]=(-2)-6*x[1]-6*x[0]      u[0]=7-1*x[1]+5*x[0]
8602      u[1]=5-9*x[1]-8*x[0]      u[1]=6+6*x[1]+x[0]
8603      A_test=Data(0.,(2,2,2,2),ReducedFunction(self.domain))      A_test=Data(0.,(2,2,2,2),ReducedFunction(self.domain))
8604      A_test[1,1,1,1]=1      A_test[1,1,1,1]=7
8605      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
8606      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(ReducedFunctionOnBoundary(self.domain))
8607      n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])      y_test=Data(0.,(2,),ReducedFunctionOnBoundary(self.domain))
8608      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test[1]=n[1]*(42)
     y_test[1]=n[1]*((-9))  
8609      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8610      pde.setValue(A=A_test, Y=Y_test, y=y_test)      pde.setValue(A_reduced=A_test, Y_reduced=Y_test, y_reduced=y_test)
8611      r=pde.getResidual(u)      r=pde.getResidual(u)
8612      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8613      self.failUnless(Lsup(rhs)>0,"right hand side is zero")      self.failUnless(Lsup(rhs)>0,"right hand side is zero")
# Line 8768  class Test_assemblage_2Do1_Reduced(unitt Line 8616  class Test_assemblage_2Do1_Reduced(unitt
8616    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_B_Const_typeStrong_comp000(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_B_Const_typeStrong_comp000(self):
8617      x=self.domain.getX()      x=self.domain.getX()
8618      u=Data(0.,(2,),ContinuousFunction(self.domain))      u=Data(0.,(2,),ContinuousFunction(self.domain))
8619      u[0]=(-7)-4*x[1]+6*x[0]      u[0]=6
8620      u[1]=(-7)-1*x[1]-8*x[0]      u[1]=2
8621      B_test=Data(0.,(2,2,2),ReducedFunction(self.domain))      B_test=Data(0.,(2,2,2),ReducedFunction(self.domain))
8622      B_test[0,0,0]=5      B_test[0,0,0]=8
8623      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
8624      Y_test[0]=(-30)      n=self.setNormal(ReducedFunctionOnBoundary(self.domain))
8625      x_boundary=FunctionOnBoundary(self.domain).getX()      y_test=Data(0.,(2,),ReducedFunctionOnBoundary(self.domain))
8626      n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])      y_test[0]=n[0]*(48)
     y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))  
     y_test[0]=n[0]*((-35)-20*x[1]+30*x[0])  
8627      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8628      pde.setValue(B=B_test, Y=Y_test, y=y_test)      pde.setValue(B_reduced=B_test, Y_reduced=Y_test, y_reduced=y_test)
8629      r=pde.getResidual(u)      r=pde.getResidual(u)
8630      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8631      self.failUnless(Lsup(rhs)>0,"right hand side is zero")      self.failUnless(Lsup(rhs)>0,"right hand side is zero")
# Line 8788  class Test_assemblage_2Do1_Reduced(unitt Line 8634  class Test_assemblage_2Do1_Reduced(unitt
8634    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_B_Const_typeStrong_comp001(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_B_Const_typeStrong_comp001(self):
8635      x=self.domain.getX()      x=self.domain.getX()
8636      u=Data(0.,(2,),ContinuousFunction(self.domain))      u=Data(0.,(2,),ContinuousFunction(self.domain))
8637      u[0]=(-7)-7*x[1]+8*x[0]      u[0]=3
8638      u[1]=(-3)-3*x[1]+6*x[0]      u[1]=(-5)
8639      B_test=Data(0.,(2,2,2),ReducedFunction(self.domain))      B_test=Data(0.,(2,2,2),ReducedFunction(self.domain))
8640      B_test[0,0,1]=6      B_test[0,0,1]=7
8641      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
8642      Y_test[0]=(-36)      n=self.setNormal(ReducedFunctionOnBoundary(self.domain))
8643      x_boundary=FunctionOnBoundary(self.domain).getX()      y_test=Data(0.,(2,),ReducedFunctionOnBoundary(self.domain))
8644      n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])      y_test[0]=n[0]*((-35))
     y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))  
     y_test[0]=n[0]*((-18)-18*x[1]+36*x[0])  
8645      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8646      pde.setValue(B=B_test, Y=Y_test, y=y_test)      pde.setValue(B_reduced=B_test, Y_reduced=Y_test, y_reduced=y_test)
8647      r=pde.getResidual(u)      r=pde.getResidual(u)
8648      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8649      self.failUnless(Lsup(rhs)>0,"right hand side is zero")      self.failUnless(Lsup(rhs)>0,"right hand side is zero")
# Line 8808  class Test_assemblage_2Do1_Reduced(unitt Line 8652  class Test_assemblage_2Do1_Reduced(unitt
8652    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_B_Const_typeStrong_comp010(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_B_Const_typeStrong_comp010(self):
8653      x=self.domain.getX()      x=self.domain.getX()
8654      u=Data(0.,(2,),ContinuousFunction(self.domain))      u=Data(0.,(2,),ContinuousFunction(self.domain))
8655      u[0]=(-6)-6*x[1]-9*x[0]      u[0]=(-9)
8656      u[1]=1-4*x[1]+5*x[0]      u[1]=(-2)
8657      B_test=Data(0.,(2,2,2),ReducedFunction(self.domain))      B_test=Data(0.,(2,2,2),ReducedFunction(self.domain))
8658      B_test[0,1,0]=2      B_test[0,1,0]=6
8659      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
8660      Y_test[0]=12      n=self.setNormal(ReducedFunctionOnBoundary(self.domain))
8661      x_boundary=FunctionOnBoundary(self.domain).getX()      y_test=Data(0.,(2,),ReducedFunctionOnBoundary(self.domain))
8662      n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])      y_test[0]=n[1]*((-54))
     y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))  
     y_test[0]=n[1]*((-12)-12*x[1]-18*x[0])  
8663      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8664      pde.setValue(B=B_test, Y=Y_test, y=y_test)      pde.setValue(B_reduced=B_test, Y_reduced=Y_test, y_reduced=y_test)
8665      r=pde.getResidual(u)      r=pde.getResidual(u)
8666      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8667      self.failUnless(Lsup(rhs)>0,"right hand side is zero")      self.failUnless(Lsup(rhs)>0,"right hand side is zero")
# Line 8828  class Test_assemblage_2Do1_Reduced(unitt Line 8670  class Test_assemblage_2Do1_Reduced(unitt
8670    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_B_Const_typeStrong_comp011(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_B_Const_typeStrong_comp011(self):
8671      x=self.domain.getX()      x=self.domain.getX()
8672      u=Data(0.,(2,),ContinuousFunction(self.domain))      u=Data(0.,(2,),ContinuousFunction(self.domain))
8673      u[0]=1+5*x[1]+6*x[0]      u[0]=(-8)
8674      u[1]=(-8)-5*x[1]-1*x[0]      u[1]=5
8675      B_test=Data(0.,(2,2,2),ReducedFunction(self.domain))      B_test=Data(0.,(2,2,2),ReducedFunction(self.domain))
8676      B_test[0,1,1]=5      B_test[0,1,1]=6
8677      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
8678      Y_test[0]=25      n=self.setNormal(ReducedFunctionOnBoundary(self.domain))
8679      x_boundary=FunctionOnBoundary(self.domain).getX()      y_test=Data(0.,(2,),ReducedFunctionOnBoundary(self.domain))
8680      n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])      y_test[0]=n[1]*(30)
     y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))  
     y_test[0]=n[1]*((-40)-25*x[1]-5*x[0])  
8681      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8682      pde.setValue(B=B_test, Y=Y_test, y=y_test)      pde.setValue(B_reduced=B_test, Y_reduced=Y_test, y_reduced=y_test)
8683      r=pde.getResidual(u)      r=pde.getResidual(u)
8684      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8685      self.failUnless(Lsup(rhs)>0,"right hand side is zero")      self.failUnless(Lsup(rhs)>0,"right hand side is zero")
# Line 8848  class Test_assemblage_2Do1_Reduced(unitt Line 8688  class Test_assemblage_2Do1_Reduced(unitt
8688    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_B_Const_typeStrong_comp100(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_B_Const_typeStrong_comp100(self):
8689      x=self.domain.getX()      x=self.domain.getX()
8690      u=Data(0.,(2,),ContinuousFunction(self.domain))      u=Data(0.,(2,),ContinuousFunction(self.domain))
8691      u[0]=3+7*x[1]-9*x[0]      u[0]=(-6)
8692      u[1]=(-6)-9*x[1]+6*x[0]      u[1]=(-6)
8693      B_test=Data(0.,(2,2,2),ReducedFunction(self.domain))      B_test=Data(0.,(2,2,2),ReducedFunction(self.domain))
8694      B_test[1,0,0]=2      B_test[1,0,0]=2
8695      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
8696      Y_test[1]=18      n=self.setNormal(ReducedFunctionOnBoundary(self.domain))
8697      x_boundary=FunctionOnBoundary(self.domain).getX()      y_test=Data(0.,(2,),ReducedFunctionOnBoundary(self.domain))
8698      n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])      y_test[1]=n[0]*((-12))
     y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))  
     y_test[1]=n[0]*(6+14*x[1]-18*x[0])  
8699      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8700      pde.setValue(B=B_test, Y=Y_test, y=y_test)      pde.setValue(B_reduced=B_test, Y_reduced=Y_test, y_reduced=y_test)
8701      r=pde.getResidual(u)      r=pde.getResidual(u)
8702      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8703      self.failUnless(Lsup(rhs)>0,"right hand side is zero")      self.failUnless(Lsup(rhs)>0,"right hand side is zero")
# Line 8868  class Test_assemblage_2Do1_Reduced(unitt Line 8706  class Test_assemblage_2Do1_Reduced(unitt
8706    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_B_Const_typeStrong_comp101(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_B_Const_typeStrong_comp101(self):
8707      x=self.domain.getX()      x=self.domain.getX()
8708      u=Data(0.,(2,),ContinuousFunction(self.domain))      u=Data(0.,(2,),ContinuousFunction(self.domain))
8709      u[0]=(-9)+3*x[1]-7*x[0]      u[0]=6
8710      u[1]=(-8)-4*x[1]-9*x[0]      u[1]=(-7)
8711      B_test=Data(0.,(2,2,2),ReducedFunction(self.domain))      B_test=Data(0.,(2,2,2),ReducedFunction(self.domain))
8712      B_test[1,0,1]=4      B_test[1,0,1]=3
8713      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
8714      Y_test[1]=36      n=self.setNormal(ReducedFunctionOnBoundary(self.domain))
8715      x_boundary=FunctionOnBoundary(self.domain).getX()      y_test=Data(0.,(2,),ReducedFunctionOnBoundary(self.domain))
8716      n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])      y_test[1]=n[0]*((-21))
     y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))  
     y_test[1]=n[0]*((-32)-16*x[1]-36*x[0])  
8717      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8718      pde.setValue(B=B_test, Y=Y_test, y=y_test)      pde.setValue(B_reduced=B_test, Y_reduced=Y_test, y_reduced=y_test)
8719      r=pde.getResidual(u)      r=pde.getResidual(u)
8720      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8721      self.failUnless(Lsup(rhs)>0,"right hand side is zero")      self.failUnless(Lsup(rhs)>0,"right hand side is zero")
# Line 8888  class Test_assemblage_2Do1_Reduced(unitt Line 8724  class Test_assemblage_2Do1_Reduced(unitt
8724    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_B_Const_typeStrong_comp110(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_B_Const_typeStrong_comp110(self):
8725      x=self.domain.getX()      x=self.domain.getX()
8726      u=Data(0.,(2,),ContinuousFunction(self.domain))      u=Data(0.,(2,),ContinuousFunction(self.domain))
8727      u[0]=(-1)-2*x[1]+3*x[0]      u[0]=(-8)
8728      u[1]=5-1*x[1]+7*x[0]      u[1]=7
8729      B_test=Data(0.,(2,2,2),ReducedFunction(self.domain))      B_test=Data(0.,(2,2,2),ReducedFunction(self.domain))
8730      B_test[1,1,0]=5      B_test[1,1,0]=4
8731      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
8732      Y_test[1]=10      n=self.setNormal(ReducedFunctionOnBoundary(self.domain))
8733      x_boundary=FunctionOnBoundary(self.domain).getX()      y_test=Data(0.,(2,),ReducedFunctionOnBoundary(self.domain))
8734      n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])      y_test[1]=n[1]*((-32))
     y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))  
     y_test[1]=n[1]*((-5)-10*x[1]+15*x[0])  
8735      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8736      pde.setValue(B=B_test, Y=Y_test, y=y_test)      pde.setValue(B_reduced=B_test, Y_reduced=Y_test, y_reduced=y_test)
8737      r=pde.getResidual(u)      r=pde.getResidual(u)
8738      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8739      self.failUnless(Lsup(rhs)>0,"right hand side is zero")      self.failUnless(Lsup(rhs)>0,"right hand side is zero")
# Line 8908  class Test_assemblage_2Do1_Reduced(unitt Line 8742  class Test_assemblage_2Do1_Reduced(unitt
8742    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_B_Const_typeStrong_comp111(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_B_Const_typeStrong_comp111(self):
8743      x=self.domain.getX()      x=self.domain.getX()
8744      u=Data(0.,(2,),ContinuousFunction(self.domain))      u=Data(0.,(2,),ContinuousFunction(self.domain))
8745      u[0]=7+3*x[1]-2*x[0]      u[0]=(-8)
8746      u[1]=2+x[1]-1*x[0]      u[1]=(-4)
8747      B_test=Data(0.,(2,2,2),ReducedFunction(self.domain))      B_test=Data(0.,(2,2,2),ReducedFunction(self.domain))
8748      B_test[1,1,1]=3      B_test[1,1,1]=4
8749      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
8750      Y_test[1]=(-3)      n=self.setNormal(ReducedFunctionOnBoundary(self.domain))
8751      x_boundary=FunctionOnBoundary(self.domain).getX()      y_test=Data(0.,(2,),ReducedFunctionOnBoundary(self.domain))
8752      n=whereZero(x_boundary[0]   ,self.ABS_TOL)*numarray.array([-1., 0.])+whereZero(x_boundary[0]-1.,self.ABS_TOL)*numarray.array([ 1., 0.])+whereZero(x_boundary[1]   ,self.ABS_TOL)*numarray.array([ 0.,-1.])+whereZero(x_boundary[1]-1.,self.ABS_TOL)*numarray.array([ 0., 1.])      y_test[1]=n[1]*((-16))
     y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))  
     y_test[1]=n[1]*(6+3*x[1]-3*x[0])  
8753      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8754      pde.setValue(B=B_test, Y=Y_test, y=y_test)      pde.setValue(B_reduced=B_test, Y_reduced=Y_test, y_reduced=y_test)
8755      r=pde.getResidual(u)      r=pde.getResidual(u)
8756      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8757      self.failUnless(Lsup(rhs)>0,"right hand side is zero")      self.failUnless(Lsup(rhs)>0,"right hand side is zero")
# Line 8928  class Test_assemblage_2Do1_Reduced(unitt Line 8760  class Test_assemblage_2Do1_Reduced(unitt
8760    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_C_Const_typeStrong_comp000(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_C_Const_typeStrong_comp000(self):
8761      x=self.domain.getX()      x=self.domain.getX()
8762      u=Data(0.,(2,),ContinuousFunction(self.domain))      u=Data(0.,(2,),ContinuousFunction(self.domain))
8763      u[0]=(-3)+6*x[1]-8*x[0]      u[0]=(-7)-1*x[1]-4*x[0]
8764      u[1]=2-8*x[1]-1*x[0]      u[1]=(-5)+x[1]+8*x[0]
8765      C_test=Data(0.,(2,2,2),ReducedFunction(self.domain))      C_test=Data(0.,(2,2,2),ReducedFunction(self.domain))
8766      C_test[0,0,0]=8      C_test[0,0,0]=2
8767      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
8768      Y_test[0]=(-64)      Y_test[0]=(-8)
8769      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8770      pde.setValue(C=C_test, Y=Y_test)      pde.setValue(C_reduced=C_test, Y_reduced=Y_test)
8771      r=pde.getResidual(u)      r=pde.getResidual(u)
8772      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8773      self.failUnless(Lsup(rhs)>0,"right hand side is zero")      self.failUnless(Lsup(rhs)>0,"right hand side is zero")
# Line 8944  class Test_assemblage_2Do1_Reduced(unitt Line 8776  class Test_assemblage_2Do1_Reduced(unitt
8776    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_C_Const_typeStrong_comp001(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_C_Const_typeStrong_comp001(self):
8777      x=self.domain.getX()      x=self.domain.getX()
8778      u=Data(0.,(2,),ContinuousFunction(self.domain))      u=Data(0.,(2,),ContinuousFunction(self.domain))
8779      u[0]=4+2*x[1]+3*x[0]      u[0]=(-7)+3*x[1]-5*x[0]
8780      u[1]=(-5)-9*x[1]-1*x[0]      u[1]=4-3*x[1]+4*x[0]
8781      C_test=Data(0.,(2,2,2),ReducedFunction(self.domain))      C_test=Data(0.,(2,2,2),ReducedFunction(self.domain))
8782      C_test[0,0,1]=7      C_test[0,0,1]=7
8783      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
8784      Y_test[0]=14      Y_test[0]=21
8785      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8786      pde.setValue(C=C_test, Y=Y_test)      pde.setValue(C_reduced=C_test, Y_reduced=Y_test)
8787      r=pde.getResidual(u)      r=pde.getResidual(u)
8788      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8789      self.failUnless(Lsup(rhs)>0,"right hand side is zero")      self.failUnless(Lsup(rhs)>0,"right hand side is zero")
# Line 8960  class Test_assemblage_2Do1_Reduced(unitt Line 8792  class Test_assemblage_2Do1_Reduced(unitt
8792    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_C_Const_typeStrong_comp010(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_C_Const_typeStrong_comp010(self):
8793      x=self.domain.getX()      x=self.domain.getX()
8794      u=Data(0.,(2,),ContinuousFunction(self.domain))      u=Data(0.,(2,),ContinuousFunction(self.domain))
8795      u[0]=(-6)-3*x[1]-9*x[0]      u[0]=(-7)+4*x[1]+8*x[0]
8796      u[1]=(-5)+5*x[1]-2*x[0]      u[1]=1+8*x[1]-1*x[0]
8797      C_test=Data(0.,(2,2,2),ReducedFunction(self.domain))      C_test=Data(0.,(2,2,2),ReducedFunction(self.domain))
8798      C_test[0,1,0]=1      C_test[0,1,0]=7
8799      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
8800      Y_test[0]=(-2)      Y_test[0]=(-7)
8801      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8802      pde.setValue(C=C_test, Y=Y_test)      pde.setValue(C_reduced=C_test, Y_reduced=Y_test)
8803      r=pde.getResidual(u)      r=pde.getResidual(u)
8804      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8805      self.failUnless(Lsup(rhs)>0,"right hand side is zero")      self.failUnless(Lsup(rhs)>0,"right hand side is zero")
# Line 8976  class Test_assemblage_2Do1_Reduced(unitt Line 8808  class Test_assemblage_2Do1_Reduced(unitt
8808    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_C_Const_typeStrong_comp011(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_C_Const_typeStrong_comp011(self):
8809      x=self.domain.getX()      x=self.domain.getX()
8810      u=Data(0.,(2,),ContinuousFunction(self.domain))      u=Data(0.,(2,),ContinuousFunction(self.domain))
8811      u[0]=1-4*x[1]-8*x[0]      u[0]=1-1*x[1]+3*x[0]
8812      u[1]=(-7)-4*x[1]+8*x[0]      u[1]=6+4*x[1]-6*x[0]
8813      C_test=Data(0.,(2,2,2),ReducedFunction(self.domain))      C_test=Data(0.,(2,2,2),ReducedFunction(self.domain))
8814      C_test[0,1,1]=1      C_test[0,1,1]=2
8815      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
8816      Y_test[0]=(-4)      Y_test[0]=8
8817      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8818      pde.setValue(C=C_test, Y=Y_test)      pde.setValue(C_reduced=C_test, Y_reduced=Y_test)
8819      r=pde.getResidual(u)      r=pde.getResidual(u)
8820      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8821      self.failUnless(Lsup(rhs)>0,"right hand side is zero")      self.failUnless(Lsup(rhs)>0,"right hand side is zero")
# Line 8992  class Test_assemblage_2Do1_Reduced(unitt Line 8824  class Test_assemblage_2Do1_Reduced(unitt
8824    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_C_Const_typeStrong_comp100(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_C_Const_typeStrong_comp100(self):
8825      x=self.domain.getX()      x=self.domain.getX()
8826      u=Data(0.,(2,),ContinuousFunction(self.domain))      u=Data(0.,(2,),ContinuousFunction(self.domain))
8827      u[0]=(-1)+8*x[1]+3*x[0]      u[0]=5-3*x[1]+6*x[0]
8828      u[1]=1-9*x[1]+5*x[0]      u[1]=(-7)-3*x[1]-9*x[0]
8829      C_test=Data(0.,(2,2,2),ReducedFunction(self.domain))      C_test=Data(0.,(2,2,2),ReducedFunction(self.domain))
8830      C_test[1,0,0]=6      C_test[1,0,0]=6
8831      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
8832      Y_test[1]=18      Y_test[1]=36
8833      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8834      pde.setValue(C=C_test, Y=Y_test)      pde.setValue(C_reduced=C_test, Y_reduced=Y_test)
8835      r=pde.getResidual(u)      r=pde.getResidual(u)
8836      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8837      self.failUnless(Lsup(rhs)>0,"right hand side is zero")      self.failUnless(Lsup(rhs)>0,"right hand side is zero")
# Line 9008  class Test_assemblage_2Do1_Reduced(unitt Line 8840  class Test_assemblage_2Do1_Reduced(unitt
8840    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_C_Const_typeStrong_comp101(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_C_Const_typeStrong_comp101(self):
8841      x=self.domain.getX()      x=self.domain.getX()
8842      u=Data(0.,(2,),ContinuousFunction(self.domain))      u=Data(0.,(2,),ContinuousFunction(self.domain))
8843      u[0]=(-2)+6*x[1]+6*x[0]      u[0]=(-5)-2*x[1]-2*x[0]
8844      u[1]=(-1)-8*x[1]-5*x[0]      u[1]=(-1)-2*x[1]+8*x[0]
8845      C_test=Data(0.,(2,2,2),ReducedFunction(self.domain))      C_test=Data(0.,(2,2,2),ReducedFunction(self.domain))
8846      C_test[1,0,1]=6      C_test[1,0,1]=3
8847      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
8848      Y_test[1]=36      Y_test[1]=(-6)
8849      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8850      pde.setValue(C=C_test, Y=Y_test)      pde.setValue(C_reduced=C_test, Y_reduced=Y_test)
8851      r=pde.getResidual(u)      r=pde.getResidual(u)
8852      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8853      self.failUnless(Lsup(rhs)>0,"right hand side is zero")      self.failUnless(Lsup(rhs)>0,"right hand side is zero")
# Line 9024  class Test_assemblage_2Do1_Reduced(unitt Line 8856  class Test_assemblage_2Do1_Reduced(unitt
8856    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_C_Const_typeStrong_comp110(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_C_Const_typeStrong_comp110(self):
8857      x=self.domain.getX()      x=self.domain.getX()
8858      u=Data(0.,(2,),ContinuousFunction(self.domain))      u=Data(0.,(2,),ContinuousFunction(self.domain))
8859      u[0]=(-5)-5*x[1]+3*x[0]      u[0]=(-2)-8*x[1]+2*x[0]
8860      u[1]=(-8)-2*x[1]-3*x[0]      u[1]=3+7*x[1]-6*x[0]
8861      C_test=Data(0.,(2,2,2),ReducedFunction(self.domain))      C_test=Data(0.,(2,2,2),ReducedFunction(self.domain))
8862      C_test[1,1,0]=2      C_test[1,1,0]=6
8863      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
8864      Y_test[1]=(-6)      Y_test[1]=(-36)
8865      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8866      pde.setValue(C=C_test, Y=Y_test)      pde.setValue(C_reduced=C_test, Y_reduced=Y_test)
8867      r=pde.getResidual(u)      r=pde.getResidual(u)
8868      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8869      self.failUnless(Lsup(rhs)>0,"right hand side is zero")      self.failUnless(Lsup(rhs)>0,"right hand side is zero")
# Line 9040  class Test_assemblage_2Do1_Reduced(unitt Line 8872  class Test_assemblage_2Do1_Reduced(unitt
8872    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_C_Const_typeStrong_comp111(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_C_Const_typeStrong_comp111(self):
8873      x=self.domain.getX()      x=self.domain.getX()
8874      u=Data(0.,(2,),ContinuousFunction(self.domain))      u=Data(0.,(2,),ContinuousFunction(self.domain))
8875      u[0]=(-2)+4*x[1]+5*x[0]      u[0]=7+4*x[1]+4*x[0]
8876      u[1]=(-4)+5*x[1]+x[0]      u[1]=(-8)+8*x[1]+8*x[0]
8877      C_test=Data(0.,(2,2,2),ReducedFunction(self.domain))      C_test=Data(0.,(2,2,2),ReducedFunction(self.domain))
8878      C_test[1,1,1]=4      C_test[1,1,1]=4
8879      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
8880      Y_test[1]=20      Y_test[1]=32
8881      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8882      pde.setValue(C=C_test, Y=Y_test)      pde.setValue(C_reduced=C_test, Y_reduced=Y_test)
8883      r=pde.getResidual(u)      r=pde.getResidual(u)
8884      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8885      self.failUnless(Lsup(rhs)>0,"right hand side is zero")      self.failUnless(Lsup(rhs)>0,"right hand side is zero")
# Line 9056  class Test_assemblage_2Do1_Reduced(unitt Line 8888  class Test_assemblage_2Do1_Reduced(unitt
8888    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_D_Const_typeStrong_comp00(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_D_Const_typeStrong_comp00(self):
8889      x=self.domain.getX()      x=self.domain.getX()
8890      u=Data(0.,(2,),ContinuousFunction(self.domain))      u=Data(0.,(2,),ContinuousFunction(self.domain))
8891      u[0]=8-8*x[1]+x[0]      u[0]=3-9*x[1]+6*x[0]
8892      u[1]=(-8)+2*x[1]-6*x[0]      u[1]=(-3)+6*x[1]-3*x[0]
8893      D_test=Data(0.,(2,2),ReducedFunction(self.domain))      D_test=Data(0.,(2,2),ReducedFunction(self.domain))
8894      D_test[0,0]=4      D_test[0,0]=3
8895      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
8896      Y_test[0]=32-32*x[1]+4*x[0]      Y_test[0]=9-27*x[1]+18*x[0]
8897      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8898      pde.setValue(D=D_test, Y=Y_test)      pde.setValue(D_reduced=D_test, Y_reduced=Y_test)
8899      r=pde.getResidual(u)      r=pde.getResidual(u)