/[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

revision 798 by gross, Fri Aug 4 01:05:36 2006 UTC revision 1174 by gross, Tue May 29 07:05:59 2007 UTC
# Line 46  from esys.escript import * Line 46  from esys.escript import *
46  from esys.escript.linearPDEs import LinearPDE  from esys.escript.linearPDEs import LinearPDE
47    
48  class Test_assemblage_2Do1(unittest.TestCase):  class Test_assemblage_2Do1(unittest.TestCase):
49      def setNormal(self,fs):
50         out=Vector(0.,fs)
51         out.setTaggedValue(2,[1,0])
52         out.setTaggedValue(1,[-1,0])
53         out.setTaggedValue(20, [0,1])
54         out.setTaggedValue(10, [0,-1])
55         return out
56    #==================================================    #==================================================
57    def test_assemblage_2D_solO1_coeffOFull_NEqu1_A_Const_typeStrong_comp00(self):    def test_assemblage_2D_solO1_coeffOFull_NEqu1_A_Const_typeStrong_comp00(self):
58      x=self.domain.getX()      x=self.domain.getX()
# Line 53  class Test_assemblage_2Do1(unittest.Test Line 60  class Test_assemblage_2Do1(unittest.Test
60      A_test=Data(0.,(2,2),Function(self.domain))      A_test=Data(0.,(2,2),Function(self.domain))
61      A_test[0,0]=7      A_test[0,0]=7
62      Y_test=0      Y_test=0
63      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.])  
64      y_test=n[0]*((-49))      y_test=n[0]*((-49))
65      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
66      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 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,1]=3      A_test[0,1]=3
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]*((-6))      y_test=n[0]*((-6))
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 85  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[1,0]=2      A_test[1,0]=2
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[1]*((-8))      y_test=n[1]*((-8))
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 101  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,1]=5      A_test[1,1]=5
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]*(15)      y_test=n[1]*(15)
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 117  class Test_assemblage_2Do1(unittest.Test Line 120  class Test_assemblage_2Do1(unittest.Test
120      B_test=Data(0.,(2,),Function(self.domain))      B_test=Data(0.,(2,),Function(self.domain))
121      B_test[0]=3      B_test[0]=3
122      Y_test=(-6)      Y_test=(-6)
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[0]*(15+15*x[1]+6*x[0])      y_test=n[0]*(15+15*x[1]+6*x[0])
125      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
126      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 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[1]=7      B_test[1]=7
137      Y_test=56      Y_test=56
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[1]*(35-56*x[1]+21*x[0])      y_test=n[1]*(35-56*x[1]+21*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 199  class Test_assemblage_2Do1(unittest.Test Line 200  class Test_assemblage_2Do1(unittest.Test
200      A_test=Data(0.,(2,2),Function(self.domain))      A_test=Data(0.,(2,2),Function(self.domain))
201      A_test[0,0]=x[0]      A_test[0,0]=x[0]
202      Y_test=(-7)      Y_test=(-7)
203      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.])  
204      y_test=n[0]*(7*x[0])      y_test=n[0]*(7*x[0])
205      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
206      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 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,1]=x[0]      A_test[0,1]=x[0]
217      Y_test=1      Y_test=1
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]*((-1)*x[0])      y_test=n[0]*((-1)*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 231  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[1,0]=x[1]      A_test[1,0]=x[1]
232      Y_test=(-4)      Y_test=(-4)
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[1]*(4*x[1])      y_test=n[1]*(4*x[1])
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 247  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,1]=x[1]      A_test[1,1]=x[1]
247      Y_test=6      Y_test=6
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]*((-6)*x[1])      y_test=n[1]*((-6)*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 263  class Test_assemblage_2Do1(unittest.Test Line 260  class Test_assemblage_2Do1(unittest.Test
260      B_test=Data(0.,(2,),Function(self.domain))      B_test=Data(0.,(2,),Function(self.domain))
261      B_test[0]=x[0]      B_test[0]=x[0]
262      Y_test=7-1*x[1]-12*x[0]      Y_test=7-1*x[1]-12*x[0]
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[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)
265      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
266      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 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[1]=x[1]      B_test[1]=x[1]
277      Y_test=1+2*x[1]-2*x[0]      Y_test=1+2*x[1]-2*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[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])
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 515  class Test_assemblage_2Do1(unittest.Test Line 510  class Test_assemblage_2Do1(unittest.Test
510      A_test=Data(0.,(2,2,2,2),Function(self.domain))      A_test=Data(0.,(2,2,2,2),Function(self.domain))
511      A_test[0,0,0,0]=1      A_test[0,0,0,0]=1
512      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
513      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.])  
514      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
515      y_test[0]=n[0]*((-1))      y_test[0]=n[0]*((-1))
516      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 534  class Test_assemblage_2Do1(unittest.Test Line 528  class Test_assemblage_2Do1(unittest.Test
528      A_test=Data(0.,(2,2,2,2),Function(self.domain))      A_test=Data(0.,(2,2,2,2),Function(self.domain))
529      A_test[0,0,0,1]=5      A_test[0,0,0,1]=5
530      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
531      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.])  
532      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
533      y_test[0]=n[0]*((-30))      y_test[0]=n[0]*((-30))
534      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 553  class Test_assemblage_2Do1(unittest.Test Line 546  class Test_assemblage_2Do1(unittest.Test
546      A_test=Data(0.,(2,2,2,2),Function(self.domain))      A_test=Data(0.,(2,2,2,2),Function(self.domain))
547      A_test[0,0,1,0]=4      A_test[0,0,1,0]=4
548      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
549      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.])  
550      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
551      y_test[0]=n[0]*((-4))      y_test[0]=n[0]*((-4))
552      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 572  class Test_assemblage_2Do1(unittest.Test Line 564  class Test_assemblage_2Do1(unittest.Test
564      A_test=Data(0.,(2,2,2,2),Function(self.domain))      A_test=Data(0.,(2,2,2,2),Function(self.domain))
565      A_test[0,0,1,1]=3      A_test[0,0,1,1]=3
566      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
567      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.])  
568      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
569      y_test[0]=n[0]*((-9))      y_test[0]=n[0]*((-9))
570      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 591  class Test_assemblage_2Do1(unittest.Test Line 582  class Test_assemblage_2Do1(unittest.Test
582      A_test=Data(0.,(2,2,2,2),Function(self.domain))      A_test=Data(0.,(2,2,2,2),Function(self.domain))
583      A_test[0,1,0,0]=8      A_test[0,1,0,0]=8
584      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
585      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.])  
586      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
587      y_test[0]=n[1]*(16)      y_test[0]=n[1]*(16)
588      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 610  class Test_assemblage_2Do1(unittest.Test Line 600  class Test_assemblage_2Do1(unittest.Test
600      A_test=Data(0.,(2,2,2,2),Function(self.domain))      A_test=Data(0.,(2,2,2,2),Function(self.domain))
601      A_test[0,1,0,1]=2      A_test[0,1,0,1]=2
602      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
603      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.])  
604      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
605      y_test[0]=n[1]*(8)      y_test[0]=n[1]*(8)
606      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 629  class Test_assemblage_2Do1(unittest.Test Line 618  class Test_assemblage_2Do1(unittest.Test
618      A_test=Data(0.,(2,2,2,2),Function(self.domain))      A_test=Data(0.,(2,2,2,2),Function(self.domain))
619      A_test[0,1,1,0]=4      A_test[0,1,1,0]=4
620      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
621      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.])  
622      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
623      y_test[0]=n[1]*(20)      y_test[0]=n[1]*(20)
624      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 648  class Test_assemblage_2Do1(unittest.Test Line 636  class Test_assemblage_2Do1(unittest.Test
636      A_test=Data(0.,(2,2,2,2),Function(self.domain))      A_test=Data(0.,(2,2,2,2),Function(self.domain))
637      A_test[0,1,1,1]=2      A_test[0,1,1,1]=2
638      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
639      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.])  
640      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
641      y_test[0]=n[1]*((-14))      y_test[0]=n[1]*((-14))
642      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 667  class Test_assemblage_2Do1(unittest.Test Line 654  class Test_assemblage_2Do1(unittest.Test
654      A_test=Data(0.,(2,2,2,2),Function(self.domain))      A_test=Data(0.,(2,2,2,2),Function(self.domain))
655      A_test[1,0,0,0]=2      A_test[1,0,0,0]=2
656      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
657      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.])  
658      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
659      y_test[1]=n[0]*(10)      y_test[1]=n[0]*(10)
660      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 686  class Test_assemblage_2Do1(unittest.Test Line 672  class Test_assemblage_2Do1(unittest.Test
672      A_test=Data(0.,(2,2,2,2),Function(self.domain))      A_test=Data(0.,(2,2,2,2),Function(self.domain))
673      A_test[1,0,0,1]=7      A_test[1,0,0,1]=7
674      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
675      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.])  
676      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
677      y_test[1]=n[0]*(49)      y_test[1]=n[0]*(49)
678      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 705  class Test_assemblage_2Do1(unittest.Test Line 690  class Test_assemblage_2Do1(unittest.Test
690      A_test=Data(0.,(2,2,2,2),Function(self.domain))      A_test=Data(0.,(2,2,2,2),Function(self.domain))
691      A_test[1,0,1,0]=7      A_test[1,0,1,0]=7
692      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
693      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.])  
694      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
695      y_test[1]=n[0]*((-49))      y_test[1]=n[0]*((-49))
696      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 724  class Test_assemblage_2Do1(unittest.Test Line 708  class Test_assemblage_2Do1(unittest.Test
708      A_test=Data(0.,(2,2,2,2),Function(self.domain))      A_test=Data(0.,(2,2,2,2),Function(self.domain))
709      A_test[1,0,1,1]=4      A_test[1,0,1,1]=4
710      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
711      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.])  
712      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
713      y_test[1]=n[0]*(16)      y_test[1]=n[0]*(16)
714      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 743  class Test_assemblage_2Do1(unittest.Test Line 726  class Test_assemblage_2Do1(unittest.Test
726      A_test=Data(0.,(2,2,2,2),Function(self.domain))      A_test=Data(0.,(2,2,2,2),Function(self.domain))
727      A_test[1,1,0,0]=6      A_test[1,1,0,0]=6
728      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
729      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.])  
730      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
731      y_test[1]=n[1]*((-12))      y_test[1]=n[1]*((-12))
732      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 762  class Test_assemblage_2Do1(unittest.Test Line 744  class Test_assemblage_2Do1(unittest.Test
744      A_test=Data(0.,(2,2,2,2),Function(self.domain))      A_test=Data(0.,(2,2,2,2),Function(self.domain))
745      A_test[1,1,0,1]=3      A_test[1,1,0,1]=3
746      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
747      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.])  
748      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
749      y_test[1]=n[1]*(18)      y_test[1]=n[1]*(18)
750      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 781  class Test_assemblage_2Do1(unittest.Test Line 762  class Test_assemblage_2Do1(unittest.Test
762      A_test=Data(0.,(2,2,2,2),Function(self.domain))      A_test=Data(0.,(2,2,2,2),Function(self.domain))
763      A_test[1,1,1,0]=6      A_test[1,1,1,0]=6
764      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
765      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.])  
766      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
767      y_test[1]=n[1]*(12)      y_test[1]=n[1]*(12)
768      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 800  class Test_assemblage_2Do1(unittest.Test Line 780  class Test_assemblage_2Do1(unittest.Test
780      A_test=Data(0.,(2,2,2,2),Function(self.domain))      A_test=Data(0.,(2,2,2,2),Function(self.domain))
781      A_test[1,1,1,1]=3      A_test[1,1,1,1]=3
782      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
783      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.])  
784      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
785      y_test[1]=n[1]*(24)      y_test[1]=n[1]*(24)
786      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 820  class Test_assemblage_2Do1(unittest.Test Line 799  class Test_assemblage_2Do1(unittest.Test
799      B_test[0,0,0]=3      B_test[0,0,0]=3
800      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
801      Y_test[0]=24      Y_test[0]=24
802      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.])  
803      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
804      y_test[0]=n[0]*((-15)-27*x[1]-24*x[0])      y_test[0]=n[0]*((-15)-27*x[1]-24*x[0])
805      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 840  class Test_assemblage_2Do1(unittest.Test Line 818  class Test_assemblage_2Do1(unittest.Test
818      B_test[0,0,1]=6      B_test[0,0,1]=6
819      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
820      Y_test[0]=30      Y_test[0]=30
821      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.])  
822      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
823      y_test[0]=n[0]*(30+36*x[1]-30*x[0])      y_test[0]=n[0]*(30+36*x[1]-30*x[0])
824      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 860  class Test_assemblage_2Do1(unittest.Test Line 837  class Test_assemblage_2Do1(unittest.Test
837      B_test[0,1,0]=7      B_test[0,1,0]=7
838      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
839      Y_test[0]=(-42)      Y_test[0]=(-42)
840      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.])  
841      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
842      y_test[0]=n[1]*((-35)+42*x[1]-7*x[0])      y_test[0]=n[1]*((-35)+42*x[1]-7*x[0])
843      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 880  class Test_assemblage_2Do1(unittest.Test Line 856  class Test_assemblage_2Do1(unittest.Test
856      B_test[0,1,1]=6      B_test[0,1,1]=6
857      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
858      Y_test[0]=(-30)      Y_test[0]=(-30)
859      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.])  
860      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
861      y_test[0]=n[1]*(6+30*x[1]+48*x[0])      y_test[0]=n[1]*(6+30*x[1]+48*x[0])
862      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 900  class Test_assemblage_2Do1(unittest.Test Line 875  class Test_assemblage_2Do1(unittest.Test
875      B_test[1,0,0]=8      B_test[1,0,0]=8
876      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
877      Y_test[1]=64      Y_test[1]=64
878      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.])  
879      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
880      y_test[1]=n[0]*(56-40*x[1]-64*x[0])      y_test[1]=n[0]*(56-40*x[1]-64*x[0])
881      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 920  class Test_assemblage_2Do1(unittest.Test Line 894  class Test_assemblage_2Do1(unittest.Test
894      B_test[1,0,1]=3      B_test[1,0,1]=3
895      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
896      Y_test[1]=(-3)      Y_test[1]=(-3)
897      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.])  
898      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
899      y_test[1]=n[0]*((-18)+12*x[1]+3*x[0])      y_test[1]=n[0]*((-18)+12*x[1]+3*x[0])
900      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 940  class Test_assemblage_2Do1(unittest.Test Line 913  class Test_assemblage_2Do1(unittest.Test
913      B_test[1,1,0]=3      B_test[1,1,0]=3
914      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
915      Y_test[1]=(-15)      Y_test[1]=(-15)
916      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.])  
917      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
918      y_test[1]=n[1]*((-15)+15*x[1]-15*x[0])      y_test[1]=n[1]*((-15)+15*x[1]-15*x[0])
919      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 960  class Test_assemblage_2Do1(unittest.Test Line 932  class Test_assemblage_2Do1(unittest.Test
932      B_test[1,1,1]=1      B_test[1,1,1]=1
933      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
934      Y_test[1]=(-7)      Y_test[1]=(-7)
935      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.])  
936      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
937      y_test[1]=n[1]*((-7)+7*x[1]-9*x[0])      y_test[1]=n[1]*((-7)+7*x[1]-9*x[0])
938      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 1236  class Test_assemblage_2Do1(unittest.Test Line 1207  class Test_assemblage_2Do1(unittest.Test
1207      A_test[0,0,0,0]=x[0]      A_test[0,0,0,0]=x[0]
1208      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
1209      Y_test[0]=2      Y_test[0]=2
1210      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.])  
1211      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
1212      y_test[0]=n[0]*((-2)*x[0])      y_test[0]=n[0]*((-2)*x[0])
1213      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 1256  class Test_assemblage_2Do1(unittest.Test Line 1226  class Test_assemblage_2Do1(unittest.Test
1226      A_test[0,0,0,1]=x[0]      A_test[0,0,0,1]=x[0]
1227      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
1228      Y_test[0]=2      Y_test[0]=2
1229      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.])  
1230      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
1231      y_test[0]=n[0]*((-2)*x[0])      y_test[0]=n[0]*((-2)*x[0])
1232      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 1276  class Test_assemblage_2Do1(unittest.Test Line 1245  class Test_assemblage_2Do1(unittest.Test
1245      A_test[0,0,1,0]=x[0]      A_test[0,0,1,0]=x[0]
1246      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
1247      Y_test[0]=(-8)      Y_test[0]=(-8)
1248      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.])  
1249      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
1250      y_test[0]=n[0]*(8*x[0])      y_test[0]=n[0]*(8*x[0])
1251      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 1296  class Test_assemblage_2Do1(unittest.Test Line 1264  class Test_assemblage_2Do1(unittest.Test
1264      A_test[0,0,1,1]=x[0]      A_test[0,0,1,1]=x[0]
1265      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
1266      Y_test[0]=2      Y_test[0]=2
1267      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.])  
1268      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
1269      y_test[0]=n[0]*((-2)*x[0])      y_test[0]=n[0]*((-2)*x[0])
1270      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 1316  class Test_assemblage_2Do1(unittest.Test Line 1283  class Test_assemblage_2Do1(unittest.Test
1283      A_test[0,1,0,0]=x[1]      A_test[0,1,0,0]=x[1]
1284      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
1285      Y_test[0]=3      Y_test[0]=3
1286      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.])  
1287      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
1288      y_test[0]=n[1]*((-3)*x[1])      y_test[0]=n[1]*((-3)*x[1])
1289      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 1336  class Test_assemblage_2Do1(unittest.Test Line 1302  class Test_assemblage_2Do1(unittest.Test
1302      A_test[0,1,0,1]=x[1]      A_test[0,1,0,1]=x[1]
1303      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
1304      Y_test[0]=(-6)      Y_test[0]=(-6)
1305      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.])  
1306      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
1307      y_test[0]=n[1]*(6*x[1])      y_test[0]=n[1]*(6*x[1])
1308      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 1356  class Test_assemblage_2Do1(unittest.Test Line 1321  class Test_assemblage_2Do1(unittest.Test
1321      A_test[0,1,1,0]=x[1]      A_test[0,1,1,0]=x[1]
1322      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
1323      Y_test[0]=2      Y_test[0]=2
1324      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.])  
1325      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
1326      y_test[0]=n[1]*((-2)*x[1])      y_test[0]=n[1]*((-2)*x[1])
1327      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 1376  class Test_assemblage_2Do1(unittest.Test Line 1340  class Test_assemblage_2Do1(unittest.Test
1340      A_test[0,1,1,1]=x[1]      A_test[0,1,1,1]=x[1]
1341      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
1342      Y_test[0]=6      Y_test[0]=6
1343      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.])  
1344      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
1345      y_test[0]=n[1]*((-6)*x[1])      y_test[0]=n[1]*((-6)*x[1])
1346      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 1396  class Test_assemblage_2Do1(unittest.Test Line 1359  class Test_assemblage_2Do1(unittest.Test
1359      A_test[1,0,0,0]=x[0]      A_test[1,0,0,0]=x[0]
1360      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
1361      Y_test[1]=1      Y_test[1]=1
1362      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.])  
1363      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
1364      y_test[1]=n[0]*((-1)*x[0])      y_test[1]=n[0]*((-1)*x[0])
1365      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 1416  class Test_assemblage_2Do1(unittest.Test Line 1378  class Test_assemblage_2Do1(unittest.Test
1378      A_test[1,0,0,1]=x[0]      A_test[1,0,0,1]=x[0]
1379      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
1380      Y_test[1]=3      Y_test[1]=3
1381      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.])  
1382      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
1383      y_test[1]=n[0]*((-3)*x[0])      y_test[1]=n[0]*((-3)*x[0])
1384      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 1436  class Test_assemblage_2Do1(unittest.Test Line 1397  class Test_assemblage_2Do1(unittest.Test
1397      A_test[1,0,1,0]=x[0]      A_test[1,0,1,0]=x[0]
1398      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
1399      Y_test[1]=1      Y_test[1]=1
1400      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.])  
1401      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
1402      y_test[1]=n[0]*((-1)*x[0])      y_test[1]=n[0]*((-1)*x[0])
1403      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 1456  class Test_assemblage_2Do1(unittest.Test Line 1416  class Test_assemblage_2Do1(unittest.Test
1416      A_test[1,0,1,1]=x[0]      A_test[1,0,1,1]=x[0]
1417      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
1418      Y_test[1]=9      Y_test[1]=9
1419      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.])  
1420      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
1421      y_test[1]=n[0]*((-9)*x[0])      y_test[1]=n[0]*((-9)*x[0])
1422      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 1476  class Test_assemblage_2Do1(unittest.Test Line 1435  class Test_assemblage_2Do1(unittest.Test
1435      A_test[1,1,0,0]=x[1]      A_test[1,1,0,0]=x[1]
1436      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
1437      Y_test[1]=(-1)      Y_test[1]=(-1)
1438      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.])  
1439      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
1440      y_test[1]=n[1]*(x[1])      y_test[1]=n[1]*(x[1])
1441      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 1496  class Test_assemblage_2Do1(unittest.Test Line 1454  class Test_assemblage_2Do1(unittest.Test
1454      A_test[1,1,0,1]=x[1]      A_test[1,1,0,1]=x[1]
1455      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
1456      Y_test[1]=(-2)      Y_test[1]=(-2)
1457      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.])  
1458      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
1459      y_test[1]=n[1]*(2*x[1])      y_test[1]=n[1]*(2*x[1])
1460      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 1516  class Test_assemblage_2Do1(unittest.Test Line 1473  class Test_assemblage_2Do1(unittest.Test
1473      A_test[1,1,1,0]=x[1]      A_test[1,1,1,0]=x[1]
1474      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
1475      Y_test[1]=(-5)      Y_test[1]=(-5)
1476      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.])  
1477      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
1478      y_test[1]=n[1]*(5*x[1])      y_test[1]=n[1]*(5*x[1])
1479      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 1536  class Test_assemblage_2Do1(unittest.Test Line 1492  class Test_assemblage_2Do1(unittest.Test
1492      A_test[1,1,1,1]=x[1]      A_test[1,1,1,1]=x[1]
1493      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
1494      Y_test[1]=8      Y_test[1]=8
1495      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.])  
1496      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
1497      y_test[1]=n[1]*((-8)*x[1])      y_test[1]=n[1]*((-8)*x[1])
1498      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 1556  class Test_assemblage_2Do1(unittest.Test Line 1511  class Test_assemblage_2Do1(unittest.Test
1511      B_test[0,0,0]=x[0]      B_test[0,0,0]=x[0]
1512      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
1513      Y_test[0]=1-8*x[1]+8*x[0]      Y_test[0]=1-8*x[1]+8*x[0]
1514      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.])  
1515      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
1516      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)
1517      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 1576  class Test_assemblage_2Do1(unittest.Test Line 1530  class Test_assemblage_2Do1(unittest.Test
1530      B_test[0,0,1]=x[0]      B_test[0,0,1]=x[0]
1531      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
1532      Y_test[0]=(-2)-1*x[1]+10*x[0]      Y_test[0]=(-2)-1*x[1]+10*x[0]
1533      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.])  
1534      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
1535      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)
1536      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 1596  class Test_assemblage_2Do1(unittest.Test Line 1549  class Test_assemblage_2Do1(unittest.Test
1549      B_test[0,1,0]=x[1]      B_test[0,1,0]=x[1]
1550      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
1551      Y_test[0]=3-12*x[1]+7*x[0]      Y_test[0]=3-12*x[1]+7*x[0]
1552      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.])  
1553      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
1554      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])
1555      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 1616  class Test_assemblage_2Do1(unittest.Test Line 1568  class Test_assemblage_2Do1(unittest.Test
1568      B_test[0,1,1]=x[1]      B_test[0,1,1]=x[1]
1569      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
1570      Y_test[0]=(-5)+14*x[1]-8*x[0]      Y_test[0]=(-5)+14*x[1]-8*x[0]
1571      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.])  
1572      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
1573      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])
1574      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 1636  class Test_assemblage_2Do1(unittest.Test Line 1587  class Test_assemblage_2Do1(unittest.Test
1587      B_test[1,0,0]=x[0]      B_test[1,0,0]=x[0]
1588      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
1589      Y_test[1]=(-6)-8*x[1]-4*x[0]      Y_test[1]=(-6)-8*x[1]-4*x[0]
1590      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.])  
1591      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
1592      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)
1593      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 1656  class Test_assemblage_2Do1(unittest.Test Line 1606  class Test_assemblage_2Do1(unittest.Test
1606      B_test[1,0,1]=x[0]      B_test[1,0,1]=x[0]
1607      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
1608      Y_test[1]=(-3)-4*x[1]-16*x[0]      Y_test[1]=(-3)-4*x[1]-16*x[0]
1609      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.])  
1610      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
1611      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)
1612      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 1676  class Test_assemblage_2Do1(unittest.Test Line 1625  class Test_assemblage_2Do1(unittest.Test
1625      B_test[1,1,0]=x[1]      B_test[1,1,0]=x[1]
1626      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
1627      Y_test[1]=(-2)-16*x[1]+3*x[0]      Y_test[1]=(-2)-16*x[1]+3*x[0]
1628      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.])  
1629      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
1630      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])
1631      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 1696  class Test_assemblage_2Do1(unittest.Test Line 1644  class Test_assemblage_2Do1(unittest.Test
1644      B_test[1,1,1]=x[1]      B_test[1,1,1]=x[1]
1645      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
1646      Y_test[1]=3+14*x[1]-7*x[0]      Y_test[1]=3+14*x[1]-7*x[0]
1647      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.])  
1648      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))
1649      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])
1650      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 2740  class Test_assemblage_2Do1(unittest.Test Line 2687  class Test_assemblage_2Do1(unittest.Test
2687      A_test=Data(0.,(3,2,3,2),Function(self.domain))      A_test=Data(0.,(3,2,3,2),Function(self.domain))
2688      A_test[0,0,0,0]=4      A_test[0,0,0,0]=4
2689      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
2690      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.])  
2691      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
2692      y_test[0]=n[0]*(28)      y_test[0]=n[0]*(28)
2693      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 2760  class Test_assemblage_2Do1(unittest.Test Line 2706  class Test_assemblage_2Do1(unittest.Test
2706      A_test=Data(0.,(3,2,3,2),Function(self.domain))      A_test=Data(0.,(3,2,3,2),Function(self.domain))
2707      A_test[0,0,0,1]=6      A_test[0,0,0,1]=6
2708      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
2709      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.])  
2710      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
2711      y_test[0]=n[0]*(6)      y_test[0]=n[0]*(6)
2712      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 2780  class Test_assemblage_2Do1(unittest.Test Line 2725  class Test_assemblage_2Do1(unittest.Test
2725      A_test=Data(0.,(3,2,3,2),Function(self.domain))      A_test=Data(0.,(3,2,3,2),Function(self.domain))
2726      A_test[0,0,1,0]=2      A_test[0,0,1,0]=2
2727      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
2728      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.])  
2729      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
2730      y_test[0]=n[0]*((-6))      y_test[0]=n[0]*((-6))
2731      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 2800  class Test_assemblage_2Do1(unittest.Test Line 2744  class Test_assemblage_2Do1(unittest.Test
2744      A_test=Data(0.,(3,2,3,2),Function(self.domain))      A_test=Data(0.,(3,2,3,2),Function(self.domain))
2745      A_test[0,0,1,1]=7      A_test[0,0,1,1]=7
2746      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
2747      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.])  
2748      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
2749      y_test[0]=n[0]*(21)      y_test[0]=n[0]*(21)
2750      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 2820  class Test_assemblage_2Do1(unittest.Test Line 2763  class Test_assemblage_2Do1(unittest.Test
2763      A_test=Data(0.,(3,2,3,2),Function(self.domain))      A_test=Data(0.,(3,2,3,2),Function(self.domain))
2764      A_test[0,0,2,0]=7      A_test[0,0,2,0]=7
2765      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
2766      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.])  
2767      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
2768      y_test[0]=n[0]*(56)      y_test[0]=n[0]*(56)
2769      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 2840  class Test_assemblage_2Do1(unittest.Test Line 2782  class Test_assemblage_2Do1(unittest.Test
2782      A_test=Data(0.,(3,2,3,2),Function(self.domain))      A_test=Data(0.,(3,2,3,2),Function(self.domain))
2783      A_test[0,0,2,1]=2      A_test[0,0,2,1]=2
2784      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
2785      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.])  
2786      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
2787      y_test[0]=n[0]*(16)      y_test[0]=n[0]*(16)
2788      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 2860  class Test_assemblage_2Do1(unittest.Test Line 2801  class Test_assemblage_2Do1(unittest.Test
2801      A_test=Data(0.,(3,2,3,2),Function(self.domain))      A_test=Data(0.,(3,2,3,2),Function(self.domain))
2802      A_test[0,1,0,0]=4      A_test[0,1,0,0]=4
2803      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
2804      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.])  
2805      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
2806      y_test[0]=n[1]*(8)      y_test[0]=n[1]*(8)
2807      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 2880  class Test_assemblage_2Do1(unittest.Test Line 2820  class Test_assemblage_2Do1(unittest.Test
2820      A_test=Data(0.,(3,2,3,2),Function(self.domain))      A_test=Data(0.,(3,2,3,2),Function(self.domain))
2821      A_test[0,1,0,1]=2      A_test[0,1,0,1]=2
2822      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
2823      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.])  
2824      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
2825      y_test[0]=n[1]*(10)      y_test[0]=n[1]*(10)
2826      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 2900  class Test_assemblage_2Do1(unittest.Test Line 2839  class Test_assemblage_2Do1(unittest.Test
2839      A_test=Data(0.,(3,2,3,2),Function(self.domain))      A_test=Data(0.,(3,2,3,2),Function(self.domain))
2840      A_test[0,1,1,0]=6      A_test[0,1,1,0]=6
2841      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
2842      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.])  
2843      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
2844      y_test[0]=n[1]*((-12))      y_test[0]=n[1]*((-12))
2845      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 2920  class Test_assemblage_2Do1(unittest.Test Line 2858  class Test_assemblage_2Do1(unittest.Test
2858      A_test=Data(0.,(3,2,3,2),Function(self.domain))      A_test=Data(0.,(3,2,3,2),Function(self.domain))
2859      A_test[0,1,1,1]=4      A_test[0,1,1,1]=4
2860      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
2861      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.])  
2862      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
2863      y_test[0]=n[1]*((-32))      y_test[0]=n[1]*((-32))
2864      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 2940  class Test_assemblage_2Do1(unittest.Test Line 2877  class Test_assemblage_2Do1(unittest.Test
2877      A_test=Data(0.,(3,2,3,2),Function(self.domain))      A_test=Data(0.,(3,2,3,2),Function(self.domain))
2878      A_test[0,1,2,0]=3      A_test[0,1,2,0]=3
2879      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
2880      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.])  
2881      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
2882      y_test[0]=n[1]*(9)      y_test[0]=n[1]*(9)
2883      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 2960  class Test_assemblage_2Do1(unittest.Test Line 2896  class Test_assemblage_2Do1(unittest.Test
2896      A_test=Data(0.,(3,2,3,2),Function(self.domain))      A_test=Data(0.,(3,2,3,2),Function(self.domain))
2897      A_test[0,1,2,1]=2      A_test[0,1,2,1]=2
2898      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
2899      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.])  
2900      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
2901      y_test[0]=n[1]*(2)      y_test[0]=n[1]*(2)
2902      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 2980  class Test_assemblage_2Do1(unittest.Test Line 2915  class Test_assemblage_2Do1(unittest.Test
2915      A_test=Data(0.,(3,2,3,2),Function(self.domain))      A_test=Data(0.,(3,2,3,2),Function(self.domain))
2916      A_test[1,0,0,0]=7      A_test[1,0,0,0]=7
2917      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
2918      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.])  
2919      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
2920      y_test[1]=n[0]*((-21))      y_test[1]=n[0]*((-21))
2921      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 3000  class Test_assemblage_2Do1(unittest.Test Line 2934  class Test_assemblage_2Do1(unittest.Test
2934      A_test=Data(0.,(3,2,3,2),Function(self.domain))      A_test=Data(0.,(3,2,3,2),Function(self.domain))
2935      A_test[1,0,0,1]=3      A_test[1,0,0,1]=3
2936      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
2937      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.])  
2938      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
2939      y_test[1]=n[0]*((-3))      y_test[1]=n[0]*((-3))
2940      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 3020  class Test_assemblage_2Do1(unittest.Test Line 2953  class Test_assemblage_2Do1(unittest.Test
2953      A_test=Data(0.,(3,2,3,2),Function(self.domain))      A_test=Data(0.,(3,2,3,2),Function(self.domain))
2954      A_test[1,0,1,0]=5      A_test[1,0,1,0]=5
2955      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
2956      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.])  
2957      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
2958      y_test[1]=n[0]*((-45))      y_test[1]=n[0]*((-45))
2959      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 3040  class Test_assemblage_2Do1(unittest.Test Line 2972  class Test_assemblage_2Do1(unittest.Test
2972      A_test=Data(0.,(3,2,3,2),Function(self.domain))      A_test=Data(0.,(3,2,3,2),Function(self.domain))
2973      A_test[1,0,1,1]=6      A_test[1,0,1,1]=6
2974      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
2975      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.])  
2976      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
2977      y_test[1]=n[0]*((-30))      y_test[1]=n[0]*((-30))
2978      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 3060  class Test_assemblage_2Do1(unittest.Test Line 2991  class Test_assemblage_2Do1(unittest.Test
2991      A_test=Data(0.,(3,2,3,2),Function(self.domain))      A_test=Data(0.,(3,2,3,2),Function(self.domain))
2992      A_test[1,0,2,0]=3      A_test[1,0,2,0]=3
2993      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
2994      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.])  
2995      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
2996      y_test[1]=n[0]*((-12))      y_test[1]=n[0]*((-12))
2997      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 3080  class Test_assemblage_2Do1(unittest.Test Line 3010  class Test_assemblage_2Do1(unittest.Test
3010      A_test=Data(0.,(3,2,3,2),Function(self.domain))      A_test=Data(0.,(3,2,3,2),Function(self.domain))
3011      A_test[1,0,2,1]=4      A_test[1,0,2,1]=4
3012      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
3013      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.])  
3014      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
3015      y_test[1]=n[0]*(4)      y_test[1]=n[0]*(4)
3016      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 3100  class Test_assemblage_2Do1(unittest.Test Line 3029  class Test_assemblage_2Do1(unittest.Test
3029      A_test=Data(0.,(3,2,3,2),Function(self.domain))      A_test=Data(0.,(3,2,3,2),Function(self.domain))
3030      A_test[1,1,0,0]=4      A_test[1,1,0,0]=4
3031      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
3032      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.])  
3033      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
3034      y_test[1]=n[1]*(24)      y_test[1]=n[1]*(24)
3035      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 3120  class Test_assemblage_2Do1(unittest.Test Line 3048  class Test_assemblage_2Do1(unittest.Test
3048      A_test=Data(0.,(3,2,3,2),Function(self.domain))      A_test=Data(0.,(3,2,3,2),Function(self.domain))
3049      A_test[1,1,0,1]=4      A_test[1,1,0,1]=4
3050      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
3051      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.])  
3052      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
3053      y_test[1]=n[1]*((-28))      y_test[1]=n[1]*((-28))
3054      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 3140  class Test_assemblage_2Do1(unittest.Test Line 3067  class Test_assemblage_2Do1(unittest.Test
3067      A_test=Data(0.,(3,2,3,2),Function(self.domain))      A_test=Data(0.,(3,2,3,2),Function(self.domain))
3068      A_test[1,1,1,0]=7      A_test[1,1,1,0]=7
3069      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
3070      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.])  
3071      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
3072      y_test[1]=n[1]*((-14))      y_test[1]=n[1]*((-14))
3073      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 3160  class Test_assemblage_2Do1(unittest.Test Line 3086  class Test_assemblage_2Do1(unittest.Test
3086      A_test=Data(0.,(3,2,3,2),Function(self.domain))      A_test=Data(0.,(3,2,3,2),Function(self.domain))
3087      A_test[1,1,1,1]=6      A_test[1,1,1,1]=6
3088      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
3089      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.])  
3090      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
3091      y_test[1]=n[1]*((-48))      y_test[1]=n[1]*((-48))
3092      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 3180  class Test_assemblage_2Do1(unittest.Test Line 3105  class Test_assemblage_2Do1(unittest.Test
3105      A_test=Data(0.,(3,2,3,2),Function(self.domain))      A_test=Data(0.,(3,2,3,2),Function(self.domain))
3106      A_test[1,1,2,0]=1      A_test[1,1,2,0]=1
3107      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
3108      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.])  
3109      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
3110      y_test[1]=n[1]*((-7))      y_test[1]=n[1]*((-7))
3111      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 3200  class Test_assemblage_2Do1(unittest.Test Line 3124  class Test_assemblage_2Do1(unittest.Test
3124      A_test=Data(0.,(3,2,3,2),Function(self.domain))      A_test=Data(0.,(3,2,3,2),Function(self.domain))
3125      A_test[1,1,2,1]=2      A_test[1,1,2,1]=2
3126      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
3127      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.])  
3128      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
3129      y_test[1]=n[1]*((-14))      y_test[1]=n[1]*((-14))
3130      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 3220  class Test_assemblage_2Do1(unittest.Test Line 3143  class Test_assemblage_2Do1(unittest.Test
3143      A_test=Data(0.,(3,2,3,2),Function(self.domain))      A_test=Data(0.,(3,2,3,2),Function(self.domain))
3144      A_test[2,0,0,0]=3      A_test[2,0,0,0]=3
3145      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
3146      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.])  
3147      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
3148      y_test[2]=n[0]*((-21))      y_test[2]=n[0]*((-21))
3149      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 3240  class Test_assemblage_2Do1(unittest.Test Line 3162  class Test_assemblage_2Do1(unittest.Test
3162      A_test=Data(0.,(3,2,3,2),Function(self.domain))      A_test=Data(0.,(3,2,3,2),Function(self.domain))
3163      A_test[2,0,0,1]=6      A_test[2,0,0,1]=6
3164      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
3165      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.])  
3166      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
3167      y_test[2]=n[0]*((-36))      y_test[2]=n[0]*((-36))
3168      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 3260  class Test_assemblage_2Do1(unittest.Test Line 3181  class Test_assemblage_2Do1(unittest.Test
3181      A_test=Data(0.,(3,2,3,2),Function(self.domain))      A_test=Data(0.,(3,2,3,2),Function(self.domain))
3182      A_test[2,0,1,0]=4      A_test[2,0,1,0]=4
3183      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
3184      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.])  
3185      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
3186      y_test[2]=n[0]*((-32))      y_test[2]=n[0]*((-32))
3187      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 3280  class Test_assemblage_2Do1(unittest.Test Line 3200  class Test_assemblage_2Do1(unittest.Test
3200      A_test=Data(0.,(3,2,3,2),Function(self.domain))      A_test=Data(0.,(3,2,3,2),Function(self.domain))
3201      A_test[2,0,1,1]=2      A_test[2,0,1,1]=2
3202      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
3203      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.])  
3204      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
3205      y_test[2]=n[0]*((-4))      y_test[2]=n[0]*((-4))
3206      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 3300  class Test_assemblage_2Do1(unittest.Test Line 3219  class Test_assemblage_2Do1(unittest.Test
3219      A_test=Data(0.,(3,2,3,2),Function(self.domain))      A_test=Data(0.,(3,2,3,2),Function(self.domain))
3220      A_test[2,0,2,0]=4      A_test[2,0,2,0]=4
3221      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
3222      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.])  
3223      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
3224      y_test[2]=n[0]*((-4))      y_test[2]=n[0]*((-4))
3225      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 3320  class Test_assemblage_2Do1(unittest.Test Line 3238  class Test_assemblage_2Do1(unittest.Test
3238      A_test=Data(0.,(3,2,3,2),Function(self.domain))      A_test=Data(0.,(3,2,3,2),Function(self.domain))
3239      A_test[2,0,2,1]=8      A_test[2,0,2,1]=8
3240      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
3241      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.])  
3242      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
3243      y_test[2]=n[0]*((-16))      y_test[2]=n[0]*((-16))
3244      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 3340  class Test_assemblage_2Do1(unittest.Test Line 3257  class Test_assemblage_2Do1(unittest.Test
3257      A_test=Data(0.,(3,2,3,2),Function(self.domain))      A_test=Data(0.,(3,2,3,2),Function(self.domain))
3258      A_test[2,1,0,0]=8      A_test[2,1,0,0]=8
3259      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
3260      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.])  
3261      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
3262      y_test[2]=n[1]*((-8))      y_test[2]=n[1]*((-8))
3263      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 3360  class Test_assemblage_2Do1(unittest.Test Line 3276  class Test_assemblage_2Do1(unittest.Test
3276      A_test=Data(0.,(3,2,3,2),Function(self.domain))      A_test=Data(0.,(3,2,3,2),Function(self.domain))
3277      A_test[2,1,0,1]=6      A_test[2,1,0,1]=6
3278      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
3279      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.])  
3280      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
3281      y_test[2]=n[1]*(36)      y_test[2]=n[1]*(36)
3282      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 3380  class Test_assemblage_2Do1(unittest.Test Line 3295  class Test_assemblage_2Do1(unittest.Test
3295      A_test=Data(0.,(3,2,3,2),Function(self.domain))      A_test=Data(0.,(3,2,3,2),Function(self.domain))
3296      A_test[2,1,1,0]=4      A_test[2,1,1,0]=4
3297      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
3298      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.])  
3299      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
3300      y_test[2]=n[1]*(28)      y_test[2]=n[1]*(28)
3301      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 3400  class Test_assemblage_2Do1(unittest.Test Line 3314  class Test_assemblage_2Do1(unittest.Test
3314      A_test=Data(0.,(3,2,3,2),Function(self.domain))      A_test=Data(0.,(3,2,3,2),Function(self.domain))
3315      A_test[2,1,1,1]=3      A_test[2,1,1,1]=3
3316      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
3317      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.])  
3318      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
3319      y_test[2]=n[1]*(9)      y_test[2]=n[1]*(9)
3320      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 3420  class Test_assemblage_2Do1(unittest.Test Line 3333  class Test_assemblage_2Do1(unittest.Test
3333      A_test=Data(0.,(3,2,3,2),Function(self.domain))      A_test=Data(0.,(3,2,3,2),Function(self.domain))
3334      A_test[2,1,2,0]=3      A_test[2,1,2,0]=3
3335      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
3336      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.])  
3337      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
3338      y_test[2]=n[1]*((-6))      y_test[2]=n[1]*((-6))
3339      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 3440  class Test_assemblage_2Do1(unittest.Test Line 3352  class Test_assemblage_2Do1(unittest.Test
3352      A_test=Data(0.,(3,2,3,2),Function(self.domain))      A_test=Data(0.,(3,2,3,2),Function(self.domain))
3353      A_test[2,1,2,1]=3      A_test[2,1,2,1]=3
3354      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
3355      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.])  
3356      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
3357      y_test[2]=n[1]*(15)      y_test[2]=n[1]*(15)
3358      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 3461  class Test_assemblage_2Do1(unittest.Test Line 3372  class Test_assemblage_2Do1(unittest.Test
3372      B_test[0,0,0]=6      B_test[0,0,0]=6
3373      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
3374      Y_test[0]=18      Y_test[0]=18
3375      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.])  
3376      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
3377      y_test[0]=n[0]*((-36)-36*x[1]-18*x[0])      y_test[0]=n[0]*((-36)-36*x[1]-18*x[0])
3378      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 3482  class Test_assemblage_2Do1(unittest.Test Line 3392  class Test_assemblage_2Do1(unittest.Test
3392      B_test[0,0,1]=4      B_test[0,0,1]=4
3393      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
3394      Y_test[0]=(-4)      Y_test[0]=(-4)
3395      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.])  
3396      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
3397      y_test[0]=n[0]*(8-8*x[1]+4*x[0])      y_test[0]=n[0]*(8-8*x[1]+4*x[0])
3398      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 3503  class Test_assemblage_2Do1(unittest.Test Line 3412  class Test_assemblage_2Do1(unittest.Test
3412      B_test[0,0,2]=7      B_test[0,0,2]=7
3413      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
3414      Y_test[0]=(-21)      Y_test[0]=(-21)
3415      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.])  
3416      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
3417      y_test[0]=n[0]*(35+49*x[1]+21*x[0])      y_test[0]=n[0]*(35+49*x[1]+21*x[0])
3418      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 3524  class Test_assemblage_2Do1(unittest.Test Line 3432  class Test_assemblage_2Do1(unittest.Test
3432      B_test[0,1,0]=6      B_test[0,1,0]=6
3433      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
3434      Y_test[0]=48      Y_test[0]=48
3435      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.])  
3436      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
3437      y_test[0]=n[1]*((-18)-48*x[1]-36*x[0])      y_test[0]=n[1]*((-18)-48*x[1]-36*x[0])
3438      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 3545  class Test_assemblage_2Do1(unittest.Test Line 3452  class Test_assemblage_2Do1(unittest.Test
3452      B_test[0,1,1]=3      B_test[0,1,1]=3
3453      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
3454      Y_test[0]=(-3)      Y_test[0]=(-3)
3455      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.])  
3456      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
3457      y_test[0]=n[1]*((-18)+3*x[1]-27*x[0])      y_test[0]=n[1]*((-18)+3*x[1]-27*x[0])
3458      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 3566  class Test_assemblage_2Do1(unittest.Test Line 3472  class Test_assemblage_2Do1(unittest.Test
3472      B_test[0,1,2]=1      B_test[0,1,2]=1
3473      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
3474      Y_test[0]=8      Y_test[0]=8
3475      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.])  
3476      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
3477      y_test[0]=n[1]*((-9)-8*x[1]-4*x[0])      y_test[0]=n[1]*((-9)-8*x[1]-4*x[0])
3478      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 3587  class Test_assemblage_2Do1(unittest.Test Line 3492  class Test_assemblage_2Do1(unittest.Test
3492      B_test[1,0,0]=2      B_test[1,0,0]=2
3493      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
3494      Y_test[1]=18      Y_test[1]=18
3495      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.])  
3496      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
3497      y_test[1]=n[0]*((-12)-18*x[1]-18*x[0])      y_test[1]=n[0]*((-12)-18*x[1]-18*x[0])
3498      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 3608  class Test_assemblage_2Do1(unittest.Test Line 3512  class Test_assemblage_2Do1(unittest.Test
3512      B_test[1,0,1]=5      B_test[1,0,1]=5
3513      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
3514      Y_test[1]=45      Y_test[1]=45
3515      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.])  
3516      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
3517      y_test[1]=n[0]*((-20)-45*x[1]-45*x[0])      y_test[1]=n[0]*((-20)-45*x[1]-45*x[0])
3518      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 3629  class Test_assemblage_2Do1(unittest.Test Line 3532  class Test_assemblage_2Do1(unittest.Test
3532      B_test[1,0,2]=8      B_test[1,0,2]=8
3533      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
3534      Y_test[1]=16      Y_test[1]=16
3535      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.])  
3536      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
3537      y_test[1]=n[0]*(40+24*x[1]-16*x[0])      y_test[1]=n[0]*(40+24*x[1]-16*x[0])
3538      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 3650  class Test_assemblage_2Do1(unittest.Test Line 3552  class Test_assemblage_2Do1(unittest.Test
3552      B_test[1,1,0]=2      B_test[1,1,0]=2
3553      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
3554      Y_test[1]=16      Y_test[1]=16
3555      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.])  
3556      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
3557      y_test[1]=n[1]*(12-16*x[1]+2*x[0])      y_test[1]=n[1]*(12-16*x[1]+2*x[0])
3558      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 3671  class Test_assemblage_2Do1(unittest.Test Line 3572  class Test_assemblage_2Do1(unittest.Test
3572      B_test[1,1,1]=3      B_test[1,1,1]=3
3573      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
3574      Y_test[1]=(-15)      Y_test[1]=(-15)
3575      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.])  
3576      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
3577      y_test[1]=n[1]*((-18)+15*x[1]+21*x[0])      y_test[1]=n[1]*((-18)+15*x[1]+21*x[0])
3578      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 3692  class Test_assemblage_2Do1(unittest.Test Line 3592  class Test_assemblage_2Do1(unittest.Test
3592      B_test[1,1,2]=6      B_test[1,1,2]=6
3593      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
3594      Y_test[1]=(-48)      Y_test[1]=(-48)
3595      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.])  
3596      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
3597      y_test[1]=n[1]*((-48)+48*x[1]+24*x[0])      y_test[1]=n[1]*((-48)+48*x[1]+24*x[0])
3598      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 3713  class Test_assemblage_2Do1(unittest.Test Line 3612  class Test_assemblage_2Do1(unittest.Test
3612      B_test[2,0,0]=1      B_test[2,0,0]=1
3613      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
3614      Y_test[2]=5      Y_test[2]=5
3615      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.])  
3616      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
3617      y_test[2]=n[0]*(4-3*x[1]-5*x[0])      y_test[2]=n[0]*(4-3*x[1]-5*x[0])
3618      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 3734  class Test_assemblage_2Do1(unittest.Test Line 3632  class Test_assemblage_2Do1(unittest.Test
3632      B_test[2,0,1]=5      B_test[2,0,1]=5
3633      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
3634      Y_test[2]=25      Y_test[2]=25
3635      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.])  
3636      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
3637      y_test[2]=n[0]*((-10)-15*x[1]-25*x[0])      y_test[2]=n[0]*((-10)-15*x[1]-25*x[0])
3638      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 3755  class Test_assemblage_2Do1(unittest.Test Line 3652  class Test_assemblage_2Do1(unittest.Test
3652      B_test[2,0,2]=8      B_test[2,0,2]=8
3653      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
3654      Y_test[2]=(-64)      Y_test[2]=(-64)
3655      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.])  
3656      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
3657      y_test[2]=n[0]*(40-72*x[1]+64*x[0])      y_test[2]=n[0]*(40-72*x[1]+64*x[0])
3658      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 3776  class Test_assemblage_2Do1(unittest.Test Line 3672  class Test_assemblage_2Do1(unittest.Test
3672      B_test[2,1,0]=2      B_test[2,1,0]=2
3673      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
3674      Y_test[2]=12      Y_test[2]=12
3675      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.])  
3676      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
3677      y_test[2]=n[1]*((-6)-12*x[1]-2*x[0])      y_test[2]=n[1]*((-6)-12*x[1]-2*x[0])
3678      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 3797  class Test_assemblage_2Do1(unittest.Test Line 3692  class Test_assemblage_2Do1(unittest.Test
3692      B_test[2,1,1]=1      B_test[2,1,1]=1
3693      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
3694      Y_test[2]=9      Y_test[2]=9
3695      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.])  
3696      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
3697      y_test[2]=n[1]*(2-9*x[1]-8*x[0])      y_test[2]=n[1]*(2-9*x[1]-8*x[0])
3698      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 3818  class Test_assemblage_2Do1(unittest.Test Line 3712  class Test_assemblage_2Do1(unittest.Test
3712      B_test[2,1,2]=5      B_test[2,1,2]=5
3713      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
3714      Y_test[2]=(-20)      Y_test[2]=(-20)
3715      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.])  
3716      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
3717      y_test[2]=n[1]*((-15)+20*x[1]+15*x[0])      y_test[2]=n[1]*((-15)+20*x[1]+15*x[0])
3718      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 4451  class Test_assemblage_2Do1(unittest.Test Line 4344  class Test_assemblage_2Do1(unittest.Test
4344      A_test[0,0,0,0]=x[0]      A_test[0,0,0,0]=x[0]
4345      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
4346      Y_test[0]=3      Y_test[0]=3
4347      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.])  
4348      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
4349      y_test[0]=n[0]*((-3)*x[0])      y_test[0]=n[0]*((-3)*x[0])
4350      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 4472  class Test_assemblage_2Do1(unittest.Test Line 4364  class Test_assemblage_2Do1(unittest.Test
4364      A_test[0,0,0,1]=x[0]      A_test[0,0,0,1]=x[0]
4365      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
4366      Y_test[0]=(-3)      Y_test[0]=(-3)
4367      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.])  
4368      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
4369      y_test[0]=n[0]*(3*x[0])      y_test[0]=n[0]*(3*x[0])
4370      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 4493  class Test_assemblage_2Do1(unittest.Test Line 4384  class Test_assemblage_2Do1(unittest.Test
4384      A_test[0,0,1,0]=x[0]      A_test[0,0,1,0]=x[0]
4385      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
4386      Y_test[0]=(-4)      Y_test[0]=(-4)
4387      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.])  
4388      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
4389      y_test[0]=n[0]*(4*x[0])      y_test[0]=n[0]*(4*x[0])
4390      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 4514  class Test_assemblage_2Do1(unittest.Test Line 4404  class Test_assemblage_2Do1(unittest.Test
4404      A_test[0,0,1,1]=x[0]      A_test[0,0,1,1]=x[0]
4405      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
4406      Y_test[0]=8      Y_test[0]=8
4407      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.])  
4408      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
4409      y_test[0]=n[0]*((-8)*x[0])      y_test[0]=n[0]*((-8)*x[0])
4410      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 4535  class Test_assemblage_2Do1(unittest.Test Line 4424  class Test_assemblage_2Do1(unittest.Test
4424      A_test[0,0,2,0]=x[0]      A_test[0,0,2,0]=x[0]
4425      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
4426      Y_test[0]=2      Y_test[0]=2
4427      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.])  
4428      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
4429      y_test[0]=n[0]*((-2)*x[0])      y_test[0]=n[0]*((-2)*x[0])
4430      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 4556  class Test_assemblage_2Do1(unittest.Test Line 4444  class Test_assemblage_2Do1(unittest.Test
4444      A_test[0,0,2,1]=x[0]      A_test[0,0,2,1]=x[0]
4445      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
4446      Y_test[0]=9      Y_test[0]=9
4447      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.])  
4448      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
4449      y_test[0]=n[0]*((-9)*x[0])      y_test[0]=n[0]*((-9)*x[0])
4450      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 4577  class Test_assemblage_2Do1(unittest.Test Line 4464  class Test_assemblage_2Do1(unittest.Test
4464      A_test[0,1,0,0]=x[1]      A_test[0,1,0,0]=x[1]
4465      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
4466      Y_test[0]=8      Y_test[0]=8
4467      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.])  
4468      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
4469      y_test[0]=n[1]*((-8)*x[1])      y_test[0]=n[1]*((-8)*x[1])
4470      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 4598  class Test_assemblage_2Do1(unittest.Test Line 4484  class Test_assemblage_2Do1(unittest.Test
4484      A_test[0,1,0,1]=x[1]      A_test[0,1,0,1]=x[1]
4485      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
4486      Y_test[0]=(-4)      Y_test[0]=(-4)
4487      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.])  
4488      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
4489      y_test[0]=n[1]*(4*x[1])      y_test[0]=n[1]*(4*x[1])
4490      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 4619  class Test_assemblage_2Do1(unittest.Test Line 4504  class Test_assemblage_2Do1(unittest.Test
4504      A_test[0,1,1,0]=x[1]      A_test[0,1,1,0]=x[1]
4505      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
4506      Y_test[0]=(-2)      Y_test[0]=(-2)
4507      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.])  
4508      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
4509      y_test[0]=n[1]*(2*x[1])      y_test[0]=n[1]*(2*x[1])
4510      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 4640  class Test_assemblage_2Do1(unittest.Test Line 4524  class Test_assemblage_2Do1(unittest.Test
4524      A_test[0,1,1,1]=x[1]      A_test[0,1,1,1]=x[1]
4525      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
4526      Y_test[0]=(-5)      Y_test[0]=(-5)
4527      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.])  
4528      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
4529      y_test[0]=n[1]*(5*x[1])      y_test[0]=n[1]*(5*x[1])
4530      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 4661  class Test_assemblage_2Do1(unittest.Test Line 4544  class Test_assemblage_2Do1(unittest.Test
4544      A_test[0,1,2,0]=x[1]      A_test[0,1,2,0]=x[1]
4545      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
4546      Y_test[0]=(-3)      Y_test[0]=(-3)
4547      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.])  
4548      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
4549      y_test[0]=n[1]*(3*x[1])      y_test[0]=n[1]*(3*x[1])
4550      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 4682  class Test_assemblage_2Do1(unittest.Test Line 4564  class Test_assemblage_2Do1(unittest.Test
4564      A_test[0,1,2,1]=x[1]      A_test[0,1,2,1]=x[1]
4565      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
4566      Y_test[0]=3      Y_test[0]=3
4567      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.])  
4568      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
4569      y_test[0]=n[1]*((-3)*x[1])      y_test[0]=n[1]*((-3)*x[1])
4570      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 4703  class Test_assemblage_2Do1(unittest.Test Line 4584  class Test_assemblage_2Do1(unittest.Test
4584      A_test[1,0,0,0]=x[0]      A_test[1,0,0,0]=x[0]
4585      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
4586      Y_test[1]=7      Y_test[1]=7
4587      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.])  
4588      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
4589      y_test[1]=n[0]*((-7)*x[0])      y_test[1]=n[0]*((-7)*x[0])
4590      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 4724  class Test_assemblage_2Do1(unittest.Test Line 4604  class Test_assemblage_2Do1(unittest.Test
4604      A_test[1,0,0,1]=x[0]      A_test[1,0,0,1]=x[0]
4605      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
4606      Y_test[1]=1      Y_test[1]=1
4607      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.])  
4608      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
4609      y_test[1]=n[0]*((-1)*x[0])      y_test[1]=n[0]*((-1)*x[0])
4610      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 4745  class Test_assemblage_2Do1(unittest.Test Line 4624  class Test_assemblage_2Do1(unittest.Test
4624      A_test[1,0,1,0]=x[0]      A_test[1,0,1,0]=x[0]
4625      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
4626      Y_test[1]=4      Y_test[1]=4
4627      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.])  
4628      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
4629      y_test[1]=n[0]*((-4)*x[0])      y_test[1]=n[0]*((-4)*x[0])
4630      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 4766  class Test_assemblage_2Do1(unittest.Test Line 4644  class Test_assemblage_2Do1(unittest.Test
4644      A_test[1,0,1,1]=x[0]      A_test[1,0,1,1]=x[0]
4645      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
4646      Y_test[1]=1      Y_test[1]=1
4647      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.])  
4648      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
4649      y_test[1]=n[0]*((-1)*x[0])      y_test[1]=n[0]*((-1)*x[0])
4650      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 4787  class Test_assemblage_2Do1(unittest.Test Line 4664  class Test_assemblage_2Do1(unittest.Test
4664      A_test[1,0,2,0]=x[0]      A_test[1,0,2,0]=x[0]
4665      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
4666      Y_test[1]=(-4)      Y_test[1]=(-4)
4667      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.])  
4668      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
4669      y_test[1]=n[0]*(4*x[0])      y_test[1]=n[0]*(4*x[0])
4670      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 4808  class Test_assemblage_2Do1(unittest.Test Line 4684  class Test_assemblage_2Do1(unittest.Test
4684      A_test[1,0,2,1]=x[0]      A_test[1,0,2,1]=x[0]
4685      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
4686      Y_test[1]=3      Y_test[1]=3
4687      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.])  
4688      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
4689      y_test[1]=n[0]*((-3)*x[0])      y_test[1]=n[0]*((-3)*x[0])
4690      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 4829  class Test_assemblage_2Do1(unittest.Test Line 4704  class Test_assemblage_2Do1(unittest.Test
4704      A_test[1,1,0,0]=x[1]      A_test[1,1,0,0]=x[1]
4705      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
4706      Y_test[1]=3      Y_test[1]=3
4707      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.])  
4708      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
4709      y_test[1]=n[1]*((-3)*x[1])      y_test[1]=n[1]*((-3)*x[1])
4710      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 4850  class Test_assemblage_2Do1(unittest.Test Line 4724  class Test_assemblage_2Do1(unittest.Test
4724      A_test[1,1,0,1]=x[1]      A_test[1,1,0,1]=x[1]
4725      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
4726      Y_test[1]=9      Y_test[1]=9
4727      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.])  
4728      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
4729      y_test[1]=n[1]*((-9)*x[1])      y_test[1]=n[1]*((-9)*x[1])
4730      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 4871  class Test_assemblage_2Do1(unittest.Test Line 4744  class Test_assemblage_2Do1(unittest.Test
4744      A_test[1,1,1,0]=x[1]      A_test[1,1,1,0]=x[1]
4745      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
4746      Y_test[1]=(-4)      Y_test[1]=(-4)
4747      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.])  
4748      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
4749      y_test[1]=n[1]*(4*x[1])      y_test[1]=n[1]*(4*x[1])
4750      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 4892  class Test_assemblage_2Do1(unittest.Test Line 4764  class Test_assemblage_2Do1(unittest.Test
4764      A_test[1,1,1,1]=x[1]      A_test[1,1,1,1]=x[1]
4765      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
4766      Y_test[1]=(-6)      Y_test[1]=(-6)
4767      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.])  
4768      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
4769      y_test[1]=n[1]*(6*x[1])      y_test[1]=n[1]*(6*x[1])
4770      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 4913  class Test_assemblage_2Do1(unittest.Test Line 4784  class Test_assemblage_2Do1(unittest.Test
4784      A_test[1,1,2,0]=x[1]      A_test[1,1,2,0]=x[1]
4785      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
4786      Y_test[1]=2      Y_test[1]=2
4787      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.])  
4788      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
4789      y_test[1]=n[1]*((-2)*x[1])      y_test[1]=n[1]*((-2)*x[1])
4790      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 4934  class Test_assemblage_2Do1(unittest.Test Line 4804  class Test_assemblage_2Do1(unittest.Test
4804      A_test[1,1,2,1]=x[1]      A_test[1,1,2,1]=x[1]
4805      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
4806      Y_test[1]=8      Y_test[1]=8
4807      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.])  
4808      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
4809      y_test[1]=n[1]*((-8)*x[1])      y_test[1]=n[1]*((-8)*x[1])
4810      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 4955  class Test_assemblage_2Do1(unittest.Test Line 4824  class Test_assemblage_2Do1(unittest.Test
4824      A_test[2,0,0,0]=x[0]      A_test[2,0,0,0]=x[0]
4825      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
4826      Y_test[2]=5      Y_test[2]=5
4827      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.])  
4828      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
4829      y_test[2]=n[0]*((-5)*x[0])      y_test[2]=n[0]*((-5)*x[0])
4830      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 4976  class Test_assemblage_2Do1(unittest.Test Line 4844  class Test_assemblage_2Do1(unittest.Test
4844      A_test[2,0,0,1]=x[0]      A_test[2,0,0,1]=x[0]
4845      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
4846      Y_test[2]=3      Y_test[2]=3
4847      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.])  
4848      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
4849      y_test[2]=n[0]*((-3)*x[0])      y_test[2]=n[0]*((-3)*x[0])
4850      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 4997  class Test_assemblage_2Do1(unittest.Test Line 4864  class Test_assemblage_2Do1(unittest.Test
4864      A_test[2,0,1,0]=x[0]      A_test[2,0,1,0]=x[0]
4865      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
4866      Y_test[2]=(-4)      Y_test[2]=(-4)
4867      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.])  
4868      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
4869      y_test[2]=n[0]*(4*x[0])      y_test[2]=n[0]*(4*x[0])
4870      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 5018  class Test_assemblage_2Do1(unittest.Test Line 4884  class Test_assemblage_2Do1(unittest.Test
4884      A_test[2,0,1,1]=x[0]      A_test[2,0,1,1]=x[0]
4885      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
4886      Y_test[2]=9      Y_test[2]=9
4887      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.])  
4888      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
4889      y_test[2]=n[0]*((-9)*x[0])      y_test[2]=n[0]*((-9)*x[0])
4890      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 5039  class Test_assemblage_2Do1(unittest.Test Line 4904  class Test_assemblage_2Do1(unittest.Test
4904      A_test[2,0,2,0]=x[0]      A_test[2,0,2,0]=x[0]
4905      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
4906      Y_test[2]=5      Y_test[2]=5
4907      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.])  
4908      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
4909      y_test[2]=n[0]*((-5)*x[0])      y_test[2]=n[0]*((-5)*x[0])
4910      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 5060  class Test_assemblage_2Do1(unittest.Test Line 4924  class Test_assemblage_2Do1(unittest.Test
4924      A_test[2,0,2,1]=x[0]      A_test[2,0,2,1]=x[0]
4925      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
4926      Y_test[2]=(-3)      Y_test[2]=(-3)
4927      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.])  
4928      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
4929      y_test[2]=n[0]*(3*x[0])      y_test[2]=n[0]*(3*x[0])
4930      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 5081  class Test_assemblage_2Do1(unittest.Test Line 4944  class Test_assemblage_2Do1(unittest.Test
4944      A_test[2,1,0,0]=x[1]      A_test[2,1,0,0]=x[1]
4945      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
4946      Y_test[2]=(-7)      Y_test[2]=(-7)
4947      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.])  
4948      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
4949      y_test[2]=n[1]*(7*x[1])      y_test[2]=n[1]*(7*x[1])
4950      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 5102  class Test_assemblage_2Do1(unittest.Test Line 4964  class Test_assemblage_2Do1(unittest.Test
4964      A_test[2,1,0,1]=x[1]      A_test[2,1,0,1]=x[1]
4965      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
4966      Y_test[2]=(-7)      Y_test[2]=(-7)
4967      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.])  
4968      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
4969      y_test[2]=n[1]*(7*x[1])      y_test[2]=n[1]*(7*x[1])
4970      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 5123  class Test_assemblage_2Do1(unittest.Test Line 4984  class Test_assemblage_2Do1(unittest.Test
4984      A_test[2,1,1,0]=x[1]      A_test[2,1,1,0]=x[1]
4985      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
4986      Y_test[2]=(-4)      Y_test[2]=(-4)
4987      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.])  
4988      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
4989      y_test[2]=n[1]*(4*x[1])      y_test[2]=n[1]*(4*x[1])
4990      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 5144  class Test_assemblage_2Do1(unittest.Test Line 5004  class Test_assemblage_2Do1(unittest.Test
5004      A_test[2,1,1,1]=x[1]      A_test[2,1,1,1]=x[1]
5005      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
5006      Y_test[2]=5      Y_test[2]=5
5007      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.])  
5008      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
5009      y_test[2]=n[1]*((-5)*x[1])      y_test[2]=n[1]*((-5)*x[1])
5010      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 5165  class Test_assemblage_2Do1(unittest.Test Line 5024  class Test_assemblage_2Do1(unittest.Test
5024      A_test[2,1,2,0]=x[1]      A_test[2,1,2,0]=x[1]
5025      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
5026      Y_test[2]=(-5)      Y_test[2]=(-5)
5027      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.])  
5028      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
5029      y_test[2]=n[1]*(5*x[1])      y_test[2]=n[1]*(5*x[1])
5030      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 5186  class Test_assemblage_2Do1(unittest.Test Line 5044  class Test_assemblage_2Do1(unittest.Test
5044      A_test[2,1,2,1]=x[1]      A_test[2,1,2,1]=x[1]
5045      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
5046      Y_test[2]=(-4)      Y_test[2]=(-4)
5047      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.])  
5048      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
5049      y_test[2]=n[1]*(4*x[1])      y_test[2]=n[1]*(4*x[1])
5050      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 5207  class Test_assemblage_2Do1(unittest.Test Line 5064  class Test_assemblage_2Do1(unittest.Test
5064      B_test[0,0,0]=x[0]      B_test[0,0,0]=x[0]
5065      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
5066      Y_test[0]=5-3*x[1]-2*x[0]      Y_test[0]=5-3*x[1]-2*x[0]
5067      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.])  
5068      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
5069      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)
5070      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 5228  class Test_assemblage_2Do1(unittest.Test Line 5084  class Test_assemblage_2Do1(unittest.Test
5084      B_test[0,0,1]=x[0]      B_test[0,0,1]=x[0]
5085      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
5086      Y_test[0]=5+x[1]+12*x[0]      Y_test[0]=5+x[1]+12*x[0]
5087      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.])  
5088      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
5089      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)
5090      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 5249  class Test_assemblage_2Do1(unittest.Test Line 5104  class Test_assemblage_2Do1(unittest.Test
5104      B_test[0,0,2]=x[0]      B_test[0,0,2]=x[0]
5105      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
5106      Y_test[0]=(-6)-2*x[1]+14*x[0]      Y_test[0]=(-6)-2*x[1]+14*x[0]
5107      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.])  
5108      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
5109      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)
5110      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 5270  class Test_assemblage_2Do1(unittest.Test Line 5124  class Test_assemblage_2Do1(unittest.Test
5124      B_test[0,1,0]=x[1]      B_test[0,1,0]=x[1]
5125      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
5126      Y_test[0]=(-5)-6*x[1]+9*x[0]      Y_test[0]=(-5)-6*x[1]+9*x[0]
5127      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.])  
5128      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
5129      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])
5130      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 5291  class Test_assemblage_2Do1(unittest.Test Line 5144  class Test_assemblage_2Do1(unittest.Test
5144      B_test[0,1,1]=x[1]      B_test[0,1,1]=x[1]
5145      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
5146      Y_test[0]=(-1)+8*x[1]-4*x[0]      Y_test[0]=(-1)+8*x[1]-4*x[0]
5147      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.])  
5148      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
5149      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])
5150      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 5312  class Test_assemblage_2Do1(unittest.Test Line 5164  class Test_assemblage_2Do1(unittest.Test
5164      B_test[0,1,2]=x[1]      B_test[0,1,2]=x[1]
5165      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
5166      Y_test[0]=1-6*x[1]+5*x[0]      Y_test[0]=1-6*x[1]+5*x[0]
5167      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.])  
5168      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
5169      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])
5170      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 5333  class Test_assemblage_2Do1(unittest.Test Line 5184  class Test_assemblage_2Do1(unittest.Test
5184      B_test[1,0,0]=x[0]      B_test[1,0,0]=x[0]
5185      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
5186      Y_test[1]=9+4*x[1]-12*x[0]      Y_test[1]=9+4*x[1]-12*x[0]
5187      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.])  
5188      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
5189      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)
5190      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 5354  class Test_assemblage_2Do1(unittest.Test Line 5204  class Test_assemblage_2Do1(unittest.Test
5204      B_test[1,0,1]=x[0]      B_test[1,0,1]=x[0]
5205      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
5206      Y_test[1]=(-5)-1*x[1]+10*x[0]      Y_test[1]=(-5)-1*x[1]+10*x[0]
5207      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.])  
5208      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
5209      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)
5210      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 5375  class Test_assemblage_2Do1(unittest.Test Line 5224  class Test_assemblage_2Do1(unittest.Test
5224      B_test[1,0,2]=x[0]      B_test[1,0,2]=x[0]
5225      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
5226      Y_test[1]=(-5)+9*x[1]+18*x[0]      Y_test[1]=(-5)+9*x[1]+18*x[0]
5227      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.])  
5228      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
5229      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)
5230      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 5396  class Test_assemblage_2Do1(unittest.Test Line 5244  class Test_assemblage_2Do1(unittest.Test
5244      B_test[1,1,0]=x[1]      B_test[1,1,0]=x[1]
5245      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
5246      Y_test[1]=1-14*x[1]-6*x[0]      Y_test[1]=1-14*x[1]-6*x[0]
5247      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.])  
5248      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
5249      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])
5250      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 5417  class Test_assemblage_2Do1(unittest.Test Line 5264  class Test_assemblage_2Do1(unittest.Test
5264      B_test[1,1,1]=x[1]      B_test[1,1,1]=x[1]
5265      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
5266      Y_test[1]=9-4*x[1]-1*x[0]      Y_test[1]=9-4*x[1]-1*x[0]
5267      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.])  
5268      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
5269      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])
5270      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 5438  class Test_assemblage_2Do1(unittest.Test Line 5284  class Test_assemblage_2Do1(unittest.Test
5284      B_test[1,1,2]=x[1]      B_test[1,1,2]=x[1]
5285      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
5286      Y_test[1]=(-7)-8*x[1]+7*x[0]      Y_test[1]=(-7)-8*x[1]+7*x[0]
5287      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.])  
5288      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
5289      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])
5290      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 5459  class Test_assemblage_2Do1(unittest.Test Line 5304  class Test_assemblage_2Do1(unittest.Test
5304      B_test[2,0,0]=x[0]      B_test[2,0,0]=x[0]
5305      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
5306      Y_test[2]=3+x[1]-2*x[0]      Y_test[2]=3+x[1]-2*x[0]
5307      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.])  
5308      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
5309      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)
5310      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 5480  class Test_assemblage_2Do1(unittest.Test Line 5324  class Test_assemblage_2Do1(unittest.Test
5324      B_test[2,0,1]=x[0]      B_test[2,0,1]=x[0]
5325      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
5326      Y_test[2]=(-8)-8*x[1]-6*x[0]      Y_test[2]=(-8)-8*x[1]-6*x[0]
5327      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.])  
5328      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
5329      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)
5330      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 5501  class Test_assemblage_2Do1(unittest.Test Line 5344  class Test_assemblage_2Do1(unittest.Test
5344      B_test[2,0,2]=x[0]      B_test[2,0,2]=x[0]
5345      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
5346      Y_test[2]=(-1)+2*x[1]-16*x[0]      Y_test[2]=(-1)+2*x[1]-16*x[0]
5347      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.])  
5348      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
5349      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)
5350      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 5522  class Test_assemblage_2Do1(unittest.Test Line 5364  class Test_assemblage_2Do1(unittest.Test
5364      B_test[2,1,0]=x[1]      B_test[2,1,0]=x[1]
5365      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
5366      Y_test[2]=(-8)-6*x[1]-2*x[0]      Y_test[2]=(-8)-6*x[1]-2*x[0]
5367      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.])  
5368      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
5369      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])
5370      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 5543  class Test_assemblage_2Do1(unittest.Test Line 5384  class Test_assemblage_2Do1(unittest.Test
5384      B_test[2,1,1]=x[1]      B_test[2,1,1]=x[1]
5385      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
5386      Y_test[2]=(-6)-14*x[1]+5*x[0]      Y_test[2]=(-6)-14*x[1]+5*x[0]
5387      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.])  
5388      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
5389      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])
5390      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 5564  class Test_assemblage_2Do1(unittest.Test Line 5404  class Test_assemblage_2Do1(unittest.Test
5404      B_test[2,1,2]=x[1]      B_test[2,1,2]=x[1]
5405      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))      Y_test=Data(0.,(3,),ContinuousFunction(self.domain))
5406      Y_test[2]=5-2*x[1]+7*x[0]      Y_test[2]=5-2*x[1]+7*x[0]
5407      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.])  
5408      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))      y_test=Data(0.,(3,),FunctionOnBoundary(self.domain))
5409      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])
5410      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
# Line 8022  class Test_assemblage_2Do1(unittest.Test Line 7861  class Test_assemblage_2Do1(unittest.Test
7861      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
7862      self.failUnless(Lsup(rhs)>0,"right hand side is zero")      self.failUnless(Lsup(rhs)>0,"right hand side is zero")
7863      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):  
7864    #==================================================    #==================================================
7865    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_A_Const_typeStrong_comp00(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_A_Const_typeStrong_comp00(self):
7866      x=self.domain.getX()      x=self.domain.getX()
7867      u=(-5)-9*x[1]-5*x[0]      u=(-1)+2*x[1]+6*x[0]
7868      A_test=Data(0.,(2,2),ReducedFunction(self.domain))      A_test=Data(0.,(2,2),ReducedFunction(self.domain))
7869      A_test[0,0]=6      A_test[0,0]=5
7870      Y_test=0      Y_test=0
7871      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(ReducedFunctionOnBoundary(self.domain))
7872      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))  
7873      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
7874      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)
7875      r=pde.getResidual(u)      r=pde.getResidual(u)
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")
# Line 8043  class Test_assemblage_2Do1_Reduced(unitt Line 7879  class Test_assemblage_2Do1_Reduced(unitt
7879    #==================================================    #==================================================
7880    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_A_Const_typeStrong_comp01(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_A_Const_typeStrong_comp01(self):
7881      x=self.domain.getX()      x=self.domain.getX()
7882      u=6+5*x[1]-1*x[0]      u=7-1*x[1]-8*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,1]=1      A_test[0,1]=6
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]*((-6))
     y_test=n[0]*(5)  
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 8059  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_comp10(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_A_Const_typeStrong_comp10(self):
7896      x=self.domain.getX()      x=self.domain.getX()
7897      u=2-6*x[1]-9*x[0]      u=(-7)+3*x[1]+3*x[0]
7898      A_test=Data(0.,(2,2),ReducedFunction(self.domain))      A_test=Data(0.,(2,2),ReducedFunction(self.domain))
7899      A_test[1,0]=2      A_test[1,0]=5
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[1]*(15)
     y_test=n[1]*((-18))  
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 8075  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_comp11(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_A_Const_typeStrong_comp11(self):
7911      x=self.domain.getX()      x=self.domain.getX()
7912      u=7+3*x[1]+8*x[0]      u=(-8)+7*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,1]=1      A_test[1,1]=2
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]*(14)
     y_test=n[1]*(3)  
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 8091  class Test_assemblage_2Do1_Reduced(unitt Line 7924  class Test_assemblage_2Do1_Reduced(unitt
7924    #==================================================    #==================================================
7925    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_B_Const_typeStrong_comp0(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_B_Const_typeStrong_comp0(self):
7926      x=self.domain.getX()      x=self.domain.getX()
7927      u=(-1)+6*x[1]+7*x[0]      u=(-5)
7928      B_test=Data(0.,(2,),ReducedFunction(self.domain))      B_test=Data(0.,(2,),ReducedFunction(self.domain))
7929      B_test[0]=8      B_test[0]=1
7930      Y_test=(-56)      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[0]*((-5))
     y_test=n[0]*((-8)+48*x[1]+56*x[0])  
7933      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
7934      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)
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 8107  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_comp1(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_B_Const_typeStrong_comp1(self):
7941      x=self.domain.getX()      x=self.domain.getX()
7942      u=8-2*x[1]-4*x[0]      u=(-7)
7943      B_test=Data(0.,(2,),ReducedFunction(self.domain))      B_test=Data(0.,(2,),ReducedFunction(self.domain))
7944      B_test[1]=1      B_test[1]=7
7945      Y_test=2      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[1]*((-49))
     y_test=n[1]*(8-2*x[1]-4*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 8123  class Test_assemblage_2Do1_Reduced(unitt Line 7954  class Test_assemblage_2Do1_Reduced(unitt
7954    #==================================================    #==================================================
7955    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_C_Const_typeStrong_comp0(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_C_Const_typeStrong_comp0(self):
7956      x=self.domain.getX()      x=self.domain.getX()
7957      u=(-8)+5*x[1]+8*x[0]      u=(-2)-4*x[1]+2*x[0]
7958      C_test=Data(0.,(2,),ReducedFunction(self.domain))      C_test=Data(0.,(2,),ReducedFunction(self.domain))
7959      C_test[0]=2      C_test[0]=3
7960      Y_test=16      Y_test=6
7961      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
7962      pde.setValue(C=C_test, Y=Y_test)      pde.setValue(C_reduced=C_test, Y_reduced=Y_test)
7963      r=pde.getResidual(u)      r=pde.getResidual(u)
7964      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
7965      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 7967  class Test_assemblage_2Do1_Reduced(unitt
7967    #==================================================    #==================================================
7968    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_C_Const_typeStrong_comp1(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_C_Const_typeStrong_comp1(self):
7969      x=self.domain.getX()      x=self.domain.getX()
7970      u=(-2)-3*x[1]-2*x[0]      u=(-6)+4*x[1]-2*x[0]
7971      C_test=Data(0.,(2,),ReducedFunction(self.domain))      C_test=Data(0.,(2,),ReducedFunction(self.domain))
7972      C_test[1]=3      C_test[1]=2
7973      Y_test=(-9)      Y_test=8
7974      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
7975      pde.setValue(C=C_test, Y=Y_test)      pde.setValue(C_reduced=C_test, Y_reduced=Y_test)
7976      r=pde.getResidual(u)      r=pde.getResidual(u)
7977      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
7978      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 7980  class Test_assemblage_2Do1_Reduced(unitt
7980    #==================================================    #==================================================
7981    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_D_Const_typeStrong(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_D_Const_typeStrong(self):
7982      x=self.domain.getX()      x=self.domain.getX()
7983      u=(-4)+4*x[1]-4*x[0]      u=(-8)-7*x[1]+4*x[0]
7984      D_test=Data(2,(),ReducedFunction(self.domain))      D_test=Data(5,(),ReducedFunction(self.domain))
7985      Y_test=(-8)+8*x[1]-8*x[0]      Y_test=(-40)-35*x[1]+20*x[0]
7986      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
7987      pde.setValue(D=D_test, Y=Y_test)      pde.setValue(D_reduced=D_test, Y_reduced=Y_test)
7988        r=pde.getResidual(u)
7989        rhs=pde.getRightHandSide()
7990        self.failUnless(Lsup(rhs)>0,"right hand side is zero")
7991        self.failUnless(Lsup(r)<=self.RES_TOL*Lsup(rhs),"residual is too big")
7992      #==================================================
7993      def test_assemblage_2D_solO1_coeffOReduced_NEqu1_d_Const_typeStrong(self):
7994        x=self.domain.getX()
7995        u=4+7*x[1]+3*x[0]
7996        d_test=Data(8,(),ReducedFunctionOnBoundary(self.domain))
7997        y_test=32+56*x[1]+24*x[0]
7998        pde=LinearPDE(self.domain)
7999        pde.setValue(d_reduced=d_test, y_reduced=y_test)
8000      r=pde.getResidual(u)      r=pde.getResidual(u)
8001      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8002      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 8004  class Test_assemblage_2Do1_Reduced(unitt
8004    #==================================================    #==================================================
8005    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_A_Vario_typeStrong_comp00(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_A_Vario_typeStrong_comp00(self):
8006      x=self.domain.getX()      x=self.domain.getX()
8007      u=1-7*x[1]-7*x[0]      u=(-5)+5*x[1]-1*x[0]
8008      A_test=Data(0.,(2,2),ReducedFunction(self.domain))      A_test=Data(0.,(2,2),ReducedFunction(self.domain))
8009      A_test[0,0]=x[0]      A_test[0,0]=x[0]
8010      Y_test=7      Y_test=1
8011      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(ReducedFunctionOnBoundary(self.domain))
8012      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])  
8013      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8014      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)
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 8177  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_comp01(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_A_Vario_typeStrong_comp01(self):
8021      x=self.domain.getX()      x=self.domain.getX()
8022      u=2+4*x[1]-7*x[0]      u=2-7*x[1]+2*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,1]=x[0]      A_test[0,1]=x[0]
8025      Y_test=(-4)      Y_test=7
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]*((-7)*x[0])
     y_test=n[0]*(4*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 8193  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_comp10(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_A_Vario_typeStrong_comp10(self):
8036      x=self.domain.getX()      x=self.domain.getX()
8037      u=7-5*x[1]-2*x[0]      u=8-4*x[1]-1*x[0]
8038      A_test=Data(0.,(2,2),ReducedFunction(self.domain))      A_test=Data(0.,(2,2),ReducedFunction(self.domain))
8039      A_test[1,0]=x[1]      A_test[1,0]=x[1]
8040      Y_test=2      Y_test=1
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[1]*((-1)*x[1])
     y_test=n[1]*((-2)*x[1])  
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 8209  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_comp11(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_A_Vario_typeStrong_comp11(self):
8051      x=self.domain.getX()      x=self.domain.getX()
8052      u=(-4)-9*x[1]+7*x[0]      u=(-6)+8*x[1]-2*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,1]=x[1]      A_test[1,1]=x[1]
8055      Y_test=9      Y_test=(-8)
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]*(8*x[1])
     y_test=n[1]*((-9)*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 8225  class Test_assemblage_2Do1_Reduced(unitt Line 8064  class Test_assemblage_2Do1_Reduced(unitt
8064    #==================================================    #==================================================
8065    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_B_Vario_typeStrong_comp0(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_B_Vario_typeStrong_comp0(self):
8066      x=self.domain.getX()      x=self.domain.getX()
8067      u=(-2)+2*x[1]+5*x[0]      u=(-7)
8068      B_test=Data(0.,(2,),ReducedFunction(self.domain))      B_test=Data(0.,(2,),ReducedFunction(self.domain))
8069      B_test[0]=x[0]      B_test[0]=x[0]
8070      Y_test=2-2*x[1]-10*x[0]      Y_test=7
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[0]*((-7)*x[0])
     y_test=n[0]*((-2)*x[0]+2*x[0]*x[1]+5*x[0]**2)  
8073      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8074      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)
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 8241  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_comp1(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_B_Vario_typeStrong_comp1(self):
8081      x=self.domain.getX()      x=self.domain.getX()
8082      u=(-9)+5*x[1]-7*x[0]      u=(-7)
8083      B_test=Data(0.,(2,),ReducedFunction(self.domain))      B_test=Data(0.,(2,),ReducedFunction(self.domain))
8084      B_test[1]=x[1]      B_test[1]=x[1]
8085      Y_test=9-10*x[1]+7*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[1]*((-7)*x[1])
     y_test=n[1]*((-9)*x[1]+5*x[1]**2-7*x[0]*x[1])  
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 8257  class Test_assemblage_2Do1_Reduced(unitt Line 8094  class Test_assemblage_2Do1_Reduced(unitt
8094    #==================================================    #==================================================
8095    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_C_Vario_typeStrong_comp0(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_C_Vario_typeStrong_comp0(self):
8096      x=self.domain.getX()      x=self.domain.getX()
8097      u=(-9)-9*x[1]-1*x[0]      u=5-7*x[1]-8*x[0]
8098      C_test=Data(0.,(2,),ReducedFunction(self.domain))      C_test=Data(0.,(2,),ReducedFunction(self.domain))
8099      C_test[0]=x[0]      C_test[0]=x[0]
8100      Y_test=(-1)*x[0]      Y_test=(-8)*x[0]
8101      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8102      pde.setValue(C=C_test, Y=Y_test)      pde.setValue(C_reduced=C_test, Y_reduced=Y_test)
8103      r=pde.getResidual(u)      r=pde.getResidual(u)
8104      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8105      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 8107  class Test_assemblage_2Do1_Reduced(unitt
8107    #==================================================    #==================================================
8108    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_C_Vario_typeStrong_comp1(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_C_Vario_typeStrong_comp1(self):
8109      x=self.domain.getX()      x=self.domain.getX()
8110      u=2-7*x[1]-6*x[0]      u=8-2*x[1]+2*x[0]
8111      C_test=Data(0.,(2,),ReducedFunction(self.domain))      C_test=Data(0.,(2,),ReducedFunction(self.domain))
8112      C_test[1]=x[1]      C_test[1]=x[1]
8113      Y_test=(-7)*x[1]      Y_test=(-2)*x[1]
8114      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8115      pde.setValue(C=C_test, Y=Y_test)      pde.setValue(C_reduced=C_test, Y_reduced=Y_test)
8116      r=pde.getResidual(u)      r=pde.getResidual(u)
8117      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8118      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 8120  class Test_assemblage_2Do1_Reduced(unitt
8120    #==================================================    #==================================================
8121    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_D_Vario_typeStrong(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_D_Vario_typeStrong(self):
8122      x=self.domain.getX()      x=self.domain.getX()
8123      u=(-3)      u=(-8)
8124      D_test=ReducedFunction(self.domain).getX()[0]      D_test=ReducedFunction(self.domain).getX()[0]
8125      Y_test=(-3)*x[0]      Y_test=(-8)*x[0]
8126      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8127      pde.setValue(D=D_test, Y=Y_test)      pde.setValue(D_reduced=D_test, Y_reduced=Y_test)
8128        r=pde.getResidual(u)
8129        rhs=pde.getRightHandSide()
8130        self.failUnless(Lsup(rhs)>0,"right hand side is zero")
8131        self.failUnless(Lsup(r)<=self.RES_TOL*Lsup(rhs),"residual is too big")
8132      #==================================================
8133      def test_assemblage_2D_solO1_coeffOReduced_NEqu1_d_Vario_typeStrong(self):
8134        x=self.domain.getX()
8135        u=3
8136        d_test=interpolate(x[0],ReducedFunctionOnBoundary(self.domain))
8137        y_test=3*x[0]
8138        pde=LinearPDE(self.domain)
8139        pde.setValue(d_reduced=d_test, y_reduced=y_test)
8140      r=pde.getResidual(u)      r=pde.getResidual(u)
8141      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8142      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 8144  class Test_assemblage_2Do1_Reduced(unitt
8144    #==================================================    #==================================================
8145    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_A_Const_typeWeak_comp00(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_A_Const_typeWeak_comp00(self):
8146      x=self.domain.getX()      x=self.domain.getX()
8147      u=(-1)+3*x[1]+6*x[0]      u=8-1*x[1]-6*x[0]
8148      A_test=Data(0.,(2,2),ReducedFunction(self.domain))      A_test=Data(0.,(2,2),ReducedFunction(self.domain))
8149      A_test[0,0]=8      A_test[0,0]=1
8150      X_test=Data(0.,(2,),ContinuousFunction(self.domain))      X_test=Data(0.,(2,),ContinuousFunction(self.domain))
8151      X_test[0]=48      X_test[0]=(-6)
8152      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8153      pde.setValue(A=A_test, X=X_test)      pde.setValue(A_reduced=A_test, X_reduced=X_test)
8154      r=pde.getResidual(u)      r=pde.getResidual(u)
8155      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8156      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 8158  class Test_assemblage_2Do1_Reduced(unitt
8158    #==================================================    #==================================================
8159    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_A_Const_typeWeak_comp01(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_A_Const_typeWeak_comp01(self):
8160      x=self.domain.getX()      x=self.domain.getX()
8161      u=(-9)-4*x[1]+4*x[0]      u=(-1)+5*x[1]-3*x[0]
8162      A_test=Data(0.,(2,2),ReducedFunction(self.domain))      A_test=Data(0.,(2,2),ReducedFunction(self.domain))
8163      A_test[0,1]=4      A_test[0,1]=4
8164      X_test=Data(0.,(2,),ContinuousFunction(self.domain))      X_test=Data(0.,(2,),ContinuousFunction(self.domain))
8165      X_test[0]=(-16)      X_test[0]=20
8166      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8167      pde.setValue(A=A_test, X=X_test)      pde.setValue(A_reduced=A_test, X_reduced=X_test)
8168      r=pde.getResidual(u)      r=pde.getResidual(u)
8169      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8170      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 8172  class Test_assemblage_2Do1_Reduced(unitt
8172    #==================================================    #==================================================
8173    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_A_Const_typeWeak_comp10(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_A_Const_typeWeak_comp10(self):
8174      x=self.domain.getX()      x=self.domain.getX()
8175      u=7-4*x[1]-7*x[0]      u=6+3*x[1]-2*x[0]
8176      A_test=Data(0.,(2,2),ReducedFunction(self.domain))      A_test=Data(0.,(2,2),ReducedFunction(self.domain))
8177      A_test[1,0]=5      A_test[1,0]=7
8178      X_test=Data(0.,(2,),ContinuousFunction(self.domain))      X_test=Data(0.,(2,),ContinuousFunction(self.domain))
8179      X_test[1]=(-35)      X_test[1]=(-14)
8180      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8181      pde.setValue(A=A_test, X=X_test)      pde.setValue(A_reduced=A_test, X_reduced=X_test)
8182      r=pde.getResidual(u)      r=pde.getResidual(u)
8183      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8184      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 8186  class Test_assemblage_2Do1_Reduced(unitt
8186    #==================================================    #==================================================
8187    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_A_Const_typeWeak_comp11(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_A_Const_typeWeak_comp11(self):
8188      x=self.domain.getX()      x=self.domain.getX()
8189      u=6+2*x[1]-6*x[0]      u=7-9*x[1]-2*x[0]
8190      A_test=Data(0.,(2,2),ReducedFunction(self.domain))      A_test=Data(0.,(2,2),ReducedFunction(self.domain))
8191      A_test[1,1]=7      A_test[1,1]=7
8192      X_test=Data(0.,(2,),ContinuousFunction(self.domain))      X_test=Data(0.,(2,),ContinuousFunction(self.domain))
8193      X_test[1]=14      X_test[1]=(-63)
8194      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8195      pde.setValue(A=A_test, X=X_test)      pde.setValue(A_reduced=A_test, X_reduced=X_test)
8196      r=pde.getResidual(u)      r=pde.getResidual(u)
8197      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8198      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 8200  class Test_assemblage_2Do1_Reduced(unitt
8200    #==================================================    #==================================================
8201    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_B_Const_typeWeak_comp0(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_B_Const_typeWeak_comp0(self):
8202      x=self.domain.getX()      x=self.domain.getX()
8203      u=(-1)-2*x[1]+4*x[0]      u=6
8204      B_test=Data(0.,(2,),ReducedFunction(self.domain))      B_test=Data(0.,(2,),ReducedFunction(self.domain))
8205      B_test[0]=2      B_test[0]=1
8206      X_test=Data(0.,(2,),ContinuousFunction(self.domain))      X_test=Data(0.,(2,),ContinuousFunction(self.domain))
8207      X_test[0]=(-2)-4*x[1]+8*x[0]      X_test[0]=6
8208      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8209      pde.setValue(B=B_test, X=X_test)      pde.setValue(B_reduced=B_test, X_reduced=X_test)
8210      r=pde.getResidual(u)      r=pde.getResidual(u)
8211      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8212      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 8214  class Test_assemblage_2Do1_Reduced(unitt
8214    #==================================================    #==================================================
8215    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_B_Const_typeWeak_comp1(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_B_Const_typeWeak_comp1(self):
8216      x=self.domain.getX()      x=self.domain.getX()
8217      u=4-9*x[1]-1*x[0]      u=(-6)
8218      B_test=Data(0.,(2,),ReducedFunction(self.domain))      B_test=Data(0.,(2,),ReducedFunction(self.domain))
8219      B_test[1]=1      B_test[1]=2
8220      X_test=Data(0.,(2,),ContinuousFunction(self.domain))      X_test=Data(0.,(2,),ContinuousFunction(self.domain))
8221      X_test[1]=4-9*x[1]-1*x[0]      X_test[1]=(-12)
8222      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8223      pde.setValue(B=B_test, X=X_test)      pde.setValue(B_reduced=B_test, X_reduced=X_test)
8224      r=pde.getResidual(u)      r=pde.getResidual(u)
8225      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8226      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 8228  class Test_assemblage_2Do1_Reduced(unitt
8228    #==================================================    #==================================================
8229    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_A_Vario_typeWeak_comp00(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_A_Vario_typeWeak_comp00(self):
8230      x=self.domain.getX()      x=self.domain.getX()
8231      u=(-9)+7*x[1]-4*x[0]      u=6-8*x[1]-9*x[0]
8232      A_test=Data(0.,(2,2),ReducedFunction(self.domain))      A_test=Data(0.,(2,2),ReducedFunction(self.domain))
8233      A_test[0,0]=x[0]      A_test[0,0]=x[0]
8234      X_test=Data(0.,(2,),ContinuousFunction(self.domain))      X_test=Data(0.,(2,),ContinuousFunction(self.domain))
8235      X_test[0]=(-4)*x[0]      X_test[0]=(-9)*x[0]
8236      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8237      pde.setValue(A=A_test, X=X_test)      pde.setValue(A_reduced=A_test, X_reduced=X_test)
8238      r=pde.getResidual(u)      r=pde.getResidual(u)
8239      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8240      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 8242  class Test_assemblage_2Do1_Reduced(unitt
8242    #==================================================    #==================================================
8243    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_A_Vario_typeWeak_comp01(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_A_Vario_typeWeak_comp01(self):
8244      x=self.domain.getX()      x=self.domain.getX()
8245      u=(-9)-3*x[1]+6*x[0]      u=7-5*x[1]-1*x[0]
8246      A_test=Data(0.,(2,2),ReducedFunction(self.domain))      A_test=Data(0.,(2,2),ReducedFunction(self.domain))
8247      A_test[0,1]=x[0]      A_test[0,1]=x[0]
8248      X_test=Data(0.,(2,),ContinuousFunction(self.domain))      X_test=Data(0.,(2,),ContinuousFunction(self.domain))
8249      X_test[0]=(-3)*x[0]      X_test[0]=(-5)*x[0]
8250      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8251      pde.setValue(A=A_test, X=X_test)      pde.setValue(A_reduced=A_test, X_reduced=X_test)
8252      r=pde.getResidual(u)      r=pde.getResidual(u)
8253      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8254      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 8256  class Test_assemblage_2Do1_Reduced(unitt
8256    #==================================================    #==================================================
8257    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_A_Vario_typeWeak_comp10(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_A_Vario_typeWeak_comp10(self):
8258      x=self.domain.getX()      x=self.domain.getX()
8259      u=(-6)-7*x[1]-3*x[0]      u=7-5*x[1]+2*x[0]
8260      A_test=Data(0.,(2,2),ReducedFunction(self.domain))      A_test=Data(0.,(2,2),ReducedFunction(self.domain))
8261      A_test[1,0]=x[1]      A_test[1,0]=x[1]
8262      X_test=Data(0.,(2,),ContinuousFunction(self.domain))      X_test=Data(0.,(2,),ContinuousFunction(self.domain))
8263      X_test[1]=(-3)*x[1]      X_test[1]=2*x[1]
8264      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8265      pde.setValue(A=A_test, X=X_test)      pde.setValue(A_reduced=A_test, X_reduced=X_test)
8266      r=pde.getResidual(u)      r=pde.getResidual(u)
8267      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8268      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 8270  class Test_assemblage_2Do1_Reduced(unitt
8270    #==================================================    #==================================================
8271    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_A_Vario_typeWeak_comp11(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_A_Vario_typeWeak_comp11(self):
8272      x=self.domain.getX()      x=self.domain.getX()
8273      u=(-6)+x[1]-5*x[0]      u=6-8*x[1]+x[0]
8274      A_test=Data(0.,(2,2),ReducedFunction(self.domain))      A_test=Data(0.,(2,2),ReducedFunction(self.domain))
8275      A_test[1,1]=x[1]      A_test[1,1]=x[1]
8276      X_test=Data(0.,(2,),ContinuousFunction(self.domain))      X_test=Data(0.,(2,),ContinuousFunction(self.domain))
8277      X_test[1]=x[1]      X_test[1]=(-8)*x[1]
8278      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8279      pde.setValue(A=A_test, X=X_test)      pde.setValue(A_reduced=A_test, X_reduced=X_test)
8280      r=pde.getResidual(u)      r=pde.getResidual(u)
8281      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8282      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 8284  class Test_assemblage_2Do1_Reduced(unitt
8284    #==================================================    #==================================================
8285    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_B_Vario_typeWeak_comp0(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_B_Vario_typeWeak_comp0(self):
8286      x=self.domain.getX()      x=self.domain.getX()
8287      u=4      u=(-4)
8288      B_test=Data(0.,(2,),ReducedFunction(self.domain))      B_test=Data(0.,(2,),ReducedFunction(self.domain))
8289      B_test[0]=x[0]      B_test[0]=x[0]
8290      X_test=Data(0.,(2,),ContinuousFunction(self.domain))      X_test=Data(0.,(2,),ContinuousFunction(self.domain))
8291      X_test[0]=4*x[0]      X_test[0]=(-4)*x[0]
8292      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8293      pde.setValue(B=B_test, X=X_test)      pde.setValue(B_reduced=B_test, X_reduced=X_test)
8294      r=pde.getResidual(u)      r=pde.getResidual(u)
8295      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8296      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 8298  class Test_assemblage_2Do1_Reduced(unitt
8298    #==================================================    #==================================================
8299    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_B_Vario_typeWeak_comp1(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu1_B_Vario_typeWeak_comp1(self):
8300      x=self.domain.getX()      x=self.domain.getX()
8301      u=(-6)      u=4
8302      B_test=Data(0.,(2,),ReducedFunction(self.domain))      B_test=Data(0.,(2,),ReducedFunction(self.domain))
8303      B_test[1]=x[1]      B_test[1]=x[1]
8304      X_test=Data(0.,(2,),ContinuousFunction(self.domain))      X_test=Data(0.,(2,),ContinuousFunction(self.domain))
8305      X_test[1]=(-6)*x[1]      X_test[1]=4*x[1]
8306      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8307      pde.setValue(B=B_test, X=X_test)      pde.setValue(B_reduced=B_test, X_reduced=X_test)
8308      r=pde.getResidual(u)      r=pde.getResidual(u)
8309      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8310      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 8313  class Test_assemblage_2Do1_Reduced(unitt
8313    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_A_Const_typeStrong_comp0000(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_A_Const_typeStrong_comp0000(self):
8314      x=self.domain.getX()      x=self.domain.getX()
8315      u=Data(0.,(2,),ContinuousFunction(self.domain))      u=Data(0.,(2,),ContinuousFunction(self.domain))
8316      u[0]=(-5)-7*x[1]-1*x[0]      u[0]=(-5)-4*x[1]+8*x[0]
8317      u[1]=(-6)-1*x[1]-2*x[0]      u[1]=1+5*x[1]+4*x[0]
8318      A_test=Data(0.,(2,2,2,2),ReducedFunction(self.domain))      A_test=Data(0.,(2,2,2,2),ReducedFunction(self.domain))
8319      A_test[0,0,0,0]=2      A_test[0,0,0,0]=6
8320      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
8321      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(ReducedFunctionOnBoundary(self.domain))
8322      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))
8323      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test[0]=n[0]*(48)
     y_test[0]=n[0]*((-2))  
8324      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8325      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)
8326      r=pde.getResidual(u)      r=pde.getResidual(u)
8327      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8328      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 8331  class Test_assemblage_2Do1_Reduced(unitt
8331    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_A_Const_typeStrong_comp0001(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_A_Const_typeStrong_comp0001(self):
8332      x=self.domain.getX()      x=self.domain.getX()
8333      u=Data(0.,(2,),ContinuousFunction(self.domain))      u=Data(0.,(2,),ContinuousFunction(self.domain))
8334      u[0]=(-4)+4*x[1]+8*x[0]      u[0]=2-5*x[1]-1*x[0]
8335      u[1]=2+5*x[1]-2*x[0]      u[1]=(-5)-5*x[1]+4*x[0]
8336      A_test=Data(0.,(2,2,2,2),ReducedFunction(self.domain))      A_test=Data(0.,(2,2,2,2),ReducedFunction(self.domain))
8337      A_test[0,0,0,1]=3      A_test[0,0,0,1]=8
8338      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
8339      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(ReducedFunctionOnBoundary(self.domain))
8340      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))
8341      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test[0]=n[0]*((-40))
     y_test[0]=n[0]*(12)  
8342      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8343      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)
8344      r=pde.getResidual(u)      r=pde.getResidual(u)
8345      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8346      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 8349  class Test_assemblage_2Do1_Reduced(unitt
8349    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_A_Const_typeStrong_comp0010(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_A_Const_typeStrong_comp0010(self):
8350      x=self.domain.getX()      x=self.domain.getX()
8351      u=Data(0.,(2,),ContinuousFunction(self.domain))      u=Data(0.,(2,),ContinuousFunction(self.domain))
8352      u[0]=1-2*x[1]+5*x[0]      u[0]=(-7)-1*x[1]+8*x[0]
8353      u[1]=(-7)+x[1]+3*x[0]      u[1]=(-2)-2*x[1]+4*x[0]
8354      A_test=Data(0.,(2,2,2,2),ReducedFunction(self.domain))      A_test=Data(0.,(2,2,2,2),ReducedFunction(self.domain))
8355      A_test[0,0,1,0]=2      A_test[0,0,1,0]=5
8356      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
8357      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(ReducedFunctionOnBoundary(self.domain))
8358      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))
8359      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test[0]=n[0]*(20)
     y_test[0]=n[0]*(6)  
8360      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8361      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)
8362      r=pde.getResidual(u)      r=pde.getResidual(u)
8363      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8364      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 8367  class Test_assemblage_2Do1_Reduced(unitt
8367    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_A_Const_typeStrong_comp0011(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_A_Const_typeStrong_comp0011(self):
8368      x=self.domain.getX()      x=self.domain.getX()
8369      u=Data(0.,(2,),ContinuousFunction(self.domain))      u=Data(0.,(2,),ContinuousFunction(self.domain))
8370      u[0]=(-5)-8*x[1]+6*x[0]      u[0]=(-1)-8*x[1]-8*x[0]
8371      u[1]=(-6)+2*x[1]-1*x[0]      u[1]=(-3)-6*x[1]+6*x[0]
8372      A_test=Data(0.,(2,2,2,2),ReducedFunction(self.domain))      A_test=Data(0.,(2,2,2,2),ReducedFunction(self.domain))
8373      A_test[0,0,1,1]=7      A_test[0,0,1,1]=1
8374      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
8375      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(ReducedFunctionOnBoundary(self.domain))
8376      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))
8377      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test[0]=n[0]*((-6))
     y_test[0]=n[0]*(14)  
8378      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8379      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)
8380      r=pde.getResidual(u)      r=pde.getResidual(u)
8381      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8382      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 8385  class Test_assemblage_2Do1_Reduced(unitt
8385    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_A_Const_typeStrong_comp0100(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_A_Const_typeStrong_comp0100(self):
8386      x=self.domain.getX()      x=self.domain.getX()
8387      u=Data(0.,(2,),ContinuousFunction(self.domain))      u=Data(0.,(2,),ContinuousFunction(self.domain))
8388      u[0]=(-5)-4*x[1]+4*x[0]      u[0]=8+3*x[1]+7*x[0]
8389      u[1]=2-8*x[1]-3*x[0]      u[1]=(-8)+2*x[1]-3*x[0]
8390      A_test=Data(0.,(2,2,2,2),ReducedFunction(self.domain))      A_test=Data(0.,(2,2,2,2),ReducedFunction(self.domain))
8391      A_test[0,1,0,0]=4      A_test[0,1,0,0]=4
8392      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
8393      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(ReducedFunctionOnBoundary(self.domain))
8394      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))
8395      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test[0]=n[1]*(28)
     y_test[0]=n[1]*(16)  
8396      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8397      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)
8398      r=pde.getResidual(u)      r=pde.getResidual(u)
8399      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8400      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 8403  class Test_assemblage_2Do1_Reduced(unitt
8403    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_A_Const_typeStrong_comp0101(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_A_Const_typeStrong_comp0101(self):
8404      x=self.domain.getX()      x=self.domain.getX()
8405      u=Data(0.,(2,),ContinuousFunction(self.domain))      u=Data(0.,(2,),ContinuousFunction(self.domain))
8406      u[0]=(-3)+6*x[1]-3*x[0]      u[0]=(-7)-9*x[1]-8*x[0]
8407      u[1]=4+8*x[1]-6*x[0]      u[1]=7-7*x[1]+8*x[0]
8408      A_test=Data(0.,(2,2,2,2),ReducedFunction(self.domain))      A_test=Data(0.,(2,2,2,2),ReducedFunction(self.domain))
8409      A_test[0,1,0,1]=2      A_test[0,1,0,1]=1
8410      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
8411      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(ReducedFunctionOnBoundary(self.domain))
8412      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))
8413      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test[0]=n[1]*((-9))
     y_test[0]=n[1]*(12)  
8414      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8415      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)
8416      r=pde.getResidual(u)      r=pde.getResidual(u)
8417      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8418      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 8421  class Test_assemblage_2Do1_Reduced(unitt
8421    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_A_Const_typeStrong_comp0110(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_A_Const_typeStrong_comp0110(self):
8422      x=self.domain.getX()      x=self.domain.getX()
8423      u=Data(0.,(2,),ContinuousFunction(self.domain))      u=Data(0.,(2,),ContinuousFunction(self.domain))
8424      u[0]=5+5*x[1]+4*x[0]      u[0]=1-8*x[1]+4*x[0]
8425      u[1]=(-2)+4*x[1]+6*x[0]      u[1]=6-6*x[1]-2*x[0]
8426      A_test=Data(0.,(2,2,2,2),ReducedFunction(self.domain))      A_test=Data(0.,(2,2,2,2),ReducedFunction(self.domain))
8427      A_test[0,1,1,0]=2      A_test[0,1,1,0]=5
8428      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
8429      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(ReducedFunctionOnBoundary(self.domain))
8430      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))
8431      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test[0]=n[1]*((-10))
     y_test[0]=n[1]*(12)  
8432      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8433      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)
8434      r=pde.getResidual(u)      r=pde.getResidual(u)
8435      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8436      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 8439  class Test_assemblage_2Do1_Reduced(unitt
8439    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_A_Const_typeStrong_comp0111(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_A_Const_typeStrong_comp0111(self):
8440      x=self.domain.getX()      x=self.domain.getX()
8441      u=Data(0.,(2,),ContinuousFunction(self.domain))      u=Data(0.,(2,),ContinuousFunction(self.domain))
8442      u[0]=(-2)+5*x[1]-2*x[0]      u[0]=3+5*x[1]+8*x[0]
8443      u[1]=8+x[1]-2*x[0]      u[1]=(-3)+3*x[1]-4*x[0]
8444      A_test=Data(0.,(2,2,2,2),ReducedFunction(self.domain))      A_test=Data(0.,(2,2,2,2),ReducedFunction(self.domain))
8445      A_test[0,1,1,1]=8      A_test[0,1,1,1]=1
8446      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
8447      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(ReducedFunctionOnBoundary(self.domain))
8448      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))
8449      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test[0]=n[1]*(3)
     y_test[0]=n[1]*(8)  
8450      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8451      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)
8452      r=pde.getResidual(u)      r=pde.getResidual(u)
8453      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8454      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 8457  class Test_assemblage_2Do1_Reduced(unitt
8457    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_A_Const_typeStrong_comp1000(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_A_Const_typeStrong_comp1000(self):
8458      x=self.domain.getX()      x=self.domain.getX()
8459      u=Data(0.,(2,),ContinuousFunction(self.domain))      u=Data(0.,(2,),ContinuousFunction(self.domain))
8460      u[0]=6-1*x[1]+3*x[0]      u[0]=1-1*x[1]-5*x[0]
8461      u[1]=(-6)-6*x[1]-7*x[0]      u[1]=4+2*x[1]-9*x[0]
8462      A_test=Data(0.,(2,2,2,2),ReducedFunction(self.domain))      A_test=Data(0.,(2,2,2,2),ReducedFunction(self.domain))
8463      A_test[1,0,0,0]=5      A_test[1,0,0,0]=2
8464      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
8465      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(ReducedFunctionOnBoundary(self.domain))
8466      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))
8467      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test[1]=n[0]*((-10))
     y_test[1]=n[0]*(15)  
8468      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8469      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)
8470      r=pde.getResidual(u)      r=pde.getResidual(u)
8471      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8472      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 8475  class Test_assemblage_2Do1_Reduced(unitt
8475    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_A_Const_typeStrong_comp1001(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_A_Const_typeStrong_comp1001(self):
8476      x=self.domain.getX()      x=self.domain.getX()
8477      u=Data(0.,(2,),ContinuousFunction(self.domain))      u=Data(0.,(2,),ContinuousFunction(self.domain))
8478      u[0]=(-7)+6*x[1]-6*x[0]      u[0]=(-7)+6*x[1]-7*x[0]
8479      u[1]=(-8)-4*x[1]+7*x[0]      u[1]=8+8*x[1]-9*x[0]
8480      A_test=Data(0.,(2,2,2,2),ReducedFunction(self.domain))      A_test=Data(0.,(2,2,2,2),ReducedFunction(self.domain))
8481      A_test[1,0,0,1]=6      A_test[1,0,0,1]=6
8482      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
8483      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(ReducedFunctionOnBoundary(self.domain))
8484      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))  
8485      y_test[1]=n[0]*(36)      y_test[1]=n[0]*(36)
8486      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8487      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)
8488      r=pde.getResidual(u)      r=pde.getResidual(u)
8489      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8490      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 8493  class Test_assemblage_2Do1_Reduced(unitt
8493    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_A_Const_typeStrong_comp1010(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_A_Const_typeStrong_comp1010(self):
8494      x=self.domain.getX()      x=self.domain.getX()
8495      u=Data(0.,(2,),ContinuousFunction(self.domain))      u=Data(0.,(2,),ContinuousFunction(self.domain))
8496      u[0]=4-4*x[1]+4*x[0]      u[0]=(-5)+6*x[1]+x[0]
8497      u[1]=(-9)+7*x[1]-8*x[0]      u[1]=(-7)-9*x[1]-4*x[0]
8498      A_test=Data(0.,(2,2,2,2),ReducedFunction(self.domain))      A_test=Data(0.,(2,2,2,2),ReducedFunction(self.domain))
8499      A_test[1,0,1,0]=3      A_test[1,0,1,0]=8
8500      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
8501      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(ReducedFunctionOnBoundary(self.domain))
8502      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))
8503      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test[1]=n[0]*((-32))
     y_test[1]=n[0]*((-24))  
8504      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8505      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)
8506      r=pde.getResidual(u)      r=pde.getResidual(u)
8507      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8508      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 8511  class Test_assemblage_2Do1_Reduced(unitt
8511    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_A_Const_typeStrong_comp1011(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_A_Const_typeStrong_comp1011(self):
8512      x=self.domain.getX()      x=self.domain.getX()
8513      u=Data(0.,(2,),ContinuousFunction(self.domain))      u=Data(0.,(2,),ContinuousFunction(self.domain))
8514      u[0]=3+7*x[1]-1*x[0]      u[0]=(-3)+x[1]-4*x[0]
8515      u[1]=8-8*x[1]-3*x[0]      u[1]=5-1*x[1]+5*x[0]
8516      A_test=Data(0.,(2,2,2,2),ReducedFunction(self.domain))      A_test=Data(0.,(2,2,2,2),ReducedFunction(self.domain))
8517      A_test[1,0,1,1]=6      A_test[1,0,1,1]=4
8518      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
8519      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(ReducedFunctionOnBoundary(self.domain))
8520      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))
8521      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test[1]=n[0]*((-4))
     y_test[1]=n[0]*((-48))  
8522      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8523      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)
8524      r=pde.getResidual(u)      r=pde.getResidual(u)
8525      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8526      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 8529  class Test_assemblage_2Do1_Reduced(unitt
8529    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_A_Const_typeStrong_comp1100(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_A_Const_typeStrong_comp1100(self):
8530      x=self.domain.getX()      x=self.domain.getX()
8531      u=Data(0.,(2,),ContinuousFunction(self.domain))      u=Data(0.,(2,),ContinuousFunction(self.domain))
8532      u[0]=1-1*x[1]+4*x[0]      u[0]=(-6)+4*x[1]+5*x[0]
8533      u[1]=7+2*x[1]+5*x[0]      u[1]=2+8*x[1]+4*x[0]
8534      A_test=Data(0.,(2,2,2,2),ReducedFunction(self.domain))      A_test=Data(0.,(2,2,2,2),ReducedFunction(self.domain))
8535      A_test[1,1,0,0]=6      A_test[1,1,0,0]=1
8536      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
8537      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(ReducedFunctionOnBoundary(self.domain))
8538      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))
8539      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test[1]=n[1]*(5)
     y_test[1]=n[1]*(24)  
8540      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8541      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)
8542      r=pde.getResidual(u)      r=pde.getResidual(u)
8543      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8544      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 8547  class Test_assemblage_2Do1_Reduced(unitt
8547    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_A_Const_typeStrong_comp1101(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_A_Const_typeStrong_comp1101(self):
8548      x=self.domain.getX()      x=self.domain.getX()
8549      u=Data(0.,(2,),ContinuousFunction(self.domain))      u=Data(0.,(2,),ContinuousFunction(self.domain))
8550      u[0]=8+3*x[1]-4*x[0]      u[0]=7-5*x[1]+6*x[0]
8551      u[1]=3-4*x[1]+x[0]      u[1]=4+4*x[1]+4*x[0]
8552      A_test=Data(0.,(2,2,2,2),ReducedFunction(self.domain))      A_test=Data(0.,(2,2,2,2),ReducedFunction(self.domain))
8553      A_test[1,1,0,1]=2      A_test[1,1,0,1]=4
8554      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
8555      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(ReducedFunctionOnBoundary(self.domain))
8556      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))
8557      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test[1]=n[1]*((-20))
     y_test[1]=n[1]*(6)  
8558      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8559      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)
8560      r=pde.getResidual(u)      r=pde.getResidual(u)
8561      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8562      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 8565  class Test_assemblage_2Do1_Reduced(unitt
8565    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_A_Const_typeStrong_comp1110(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_A_Const_typeStrong_comp1110(self):
8566      x=self.domain.getX()      x=self.domain.getX()
8567      u=Data(0.,(2,),ContinuousFunction(self.domain))      u=Data(0.,(2,),ContinuousFunction(self.domain))
8568      u[0]=(-7)+7*x[1]+x[0]      u[0]=(-1)+3*x[1]+x[0]
8569      u[1]=3+5*x[1]+7*x[0]      u[1]=1-8*x[1]-1*x[0]
8570      A_test=Data(0.,(2,2,2,2),ReducedFunction(self.domain))      A_test=Data(0.,(2,2,2,2),ReducedFunction(self.domain))
8571      A_test[1,1,1,0]=8      A_test[1,1,1,0]=3
8572      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
8573      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(ReducedFunctionOnBoundary(self.domain))
8574      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))
8575      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test[1]=n[1]*((-3))
     y_test[1]=n[1]*(56)  
8576      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8577      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)
8578      r=pde.getResidual(u)      r=pde.getResidual(u)
8579      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8580      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 8583  class Test_assemblage_2Do1_Reduced(unitt
8583    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_A_Const_typeStrong_comp1111(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_A_Const_typeStrong_comp1111(self):
8584      x=self.domain.getX()      x=self.domain.getX()
8585      u=Data(0.,(2,),ContinuousFunction(self.domain))      u=Data(0.,(2,),ContinuousFunction(self.domain))
8586      u[0]=(-2)-6*x[1]-6*x[0]      u[0]=7-1*x[1]+5*x[0]
8587      u[1]=5-9*x[1]-8*x[0]      u[1]=6+6*x[1]+x[0]
8588      A_test=Data(0.,(2,2,2,2),ReducedFunction(self.domain))      A_test=Data(0.,(2,2,2,2),ReducedFunction(self.domain))
8589      A_test[1,1,1,1]=1      A_test[1,1,1,1]=7
8590      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
8591      x_boundary=FunctionOnBoundary(self.domain).getX()      n=self.setNormal(ReducedFunctionOnBoundary(self.domain))
8592      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))
8593      y_test=Data(0.,(2,),FunctionOnBoundary(self.domain))      y_test[1]=n[1]*(42)
     y_test[1]=n[1]*((-9))  
8594      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8595      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)
8596      r=pde.getResidual(u)      r=pde.getResidual(u)
8597      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8598      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 8601  class Test_assemblage_2Do1_Reduced(unitt
8601    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_B_Const_typeStrong_comp000(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_B_Const_typeStrong_comp000(self):
8602      x=self.domain.getX()      x=self.domain.getX()
8603      u=Data(0.,(2,),ContinuousFunction(self.domain))      u=Data(0.,(2,),ContinuousFunction(self.domain))
8604      u[0]=(-7)-4*x[1]+6*x[0]      u[0]=6
8605      u[1]=(-7)-1*x[1]-8*x[0]      u[1]=2
8606      B_test=Data(0.,(2,2,2),ReducedFunction(self.domain))      B_test=Data(0.,(2,2,2),ReducedFunction(self.domain))
8607      B_test[0,0,0]=5      B_test[0,0,0]=8
8608      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
8609      Y_test[0]=(-30)      n=self.setNormal(ReducedFunctionOnBoundary(self.domain))
8610      x_boundary=FunctionOnBoundary(self.domain).getX()      y_test=Data(0.,(2,),ReducedFunctionOnBoundary(self.domain))
8611      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])  
8612      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8613      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)
8614      r=pde.getResidual(u)      r=pde.getResidual(u)
8615      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8616      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 8619  class Test_assemblage_2Do1_Reduced(unitt
8619    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_B_Const_typeStrong_comp001(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_B_Const_typeStrong_comp001(self):
8620      x=self.domain.getX()      x=self.domain.getX()
8621      u=Data(0.,(2,),ContinuousFunction(self.domain))      u=Data(0.,(2,),ContinuousFunction(self.domain))
8622      u[0]=(-7)-7*x[1]+8*x[0]      u[0]=3
8623      u[1]=(-3)-3*x[1]+6*x[0]      u[1]=(-5)
8624      B_test=Data(0.,(2,2,2),ReducedFunction(self.domain))      B_test=Data(0.,(2,2,2),ReducedFunction(self.domain))
8625      B_test[0,0,1]=6      B_test[0,0,1]=7
8626      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
8627      Y_test[0]=(-36)      n=self.setNormal(ReducedFunctionOnBoundary(self.domain))
8628      x_boundary=FunctionOnBoundary(self.domain).getX()      y_test=Data(0.,(2,),ReducedFunctionOnBoundary(self.domain))
8629      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])  
8630      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8631      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)
8632      r=pde.getResidual(u)      r=pde.getResidual(u)
8633      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8634      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 8637  class Test_assemblage_2Do1_Reduced(unitt
8637    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_B_Const_typeStrong_comp010(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_B_Const_typeStrong_comp010(self):
8638      x=self.domain.getX()      x=self.domain.getX()
8639      u=Data(0.,(2,),ContinuousFunction(self.domain))      u=Data(0.,(2,),ContinuousFunction(self.domain))
8640      u[0]=(-6)-6*x[1]-9*x[0]      u[0]=(-9)
8641      u[1]=1-4*x[1]+5*x[0]      u[1]=(-2)
8642      B_test=Data(0.,(2,2,2),ReducedFunction(self.domain))      B_test=Data(0.,(2,2,2),ReducedFunction(self.domain))
8643      B_test[0,1,0]=2      B_test[0,1,0]=6
8644      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
8645      Y_test[0]=12      n=self.setNormal(ReducedFunctionOnBoundary(self.domain))
8646      x_boundary=FunctionOnBoundary(self.domain).getX()      y_test=Data(0.,(2,),ReducedFunctionOnBoundary(self.domain))
8647      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])  
8648      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8649      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)
8650      r=pde.getResidual(u)      r=pde.getResidual(u)
8651      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8652      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 8655  class Test_assemblage_2Do1_Reduced(unitt
8655    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_B_Const_typeStrong_comp011(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_B_Const_typeStrong_comp011(self):
8656      x=self.domain.getX()      x=self.domain.getX()
8657      u=Data(0.,(2,),ContinuousFunction(self.domain))      u=Data(0.,(2,),ContinuousFunction(self.domain))
8658      u[0]=1+5*x[1]+6*x[0]      u[0]=(-8)
8659      u[1]=(-8)-5*x[1]-1*x[0]      u[1]=5
8660      B_test=Data(0.,(2,2,2),ReducedFunction(self.domain))      B_test=Data(0.,(2,2,2),ReducedFunction(self.domain))
8661      B_test[0,1,1]=5      B_test[0,1,1]=6
8662      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
8663      Y_test[0]=25      n=self.setNormal(ReducedFunctionOnBoundary(self.domain))
8664      x_boundary=FunctionOnBoundary(self.domain).getX()      y_test=Data(0.,(2,),ReducedFunctionOnBoundary(self.domain))
8665      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])  
8666      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8667      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)
8668      r=pde.getResidual(u)      r=pde.getResidual(u)
8669      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8670      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 8673  class Test_assemblage_2Do1_Reduced(unitt
8673    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_B_Const_typeStrong_comp100(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_B_Const_typeStrong_comp100(self):
8674      x=self.domain.getX()      x=self.domain.getX()
8675      u=Data(0.,(2,),ContinuousFunction(self.domain))      u=Data(0.,(2,),ContinuousFunction(self.domain))
8676      u[0]=3+7*x[1]-9*x[0]      u[0]=(-6)
8677      u[1]=(-6)-9*x[1]+6*x[0]      u[1]=(-6)
8678      B_test=Data(0.,(2,2,2),ReducedFunction(self.domain))      B_test=Data(0.,(2,2,2),ReducedFunction(self.domain))
8679      B_test[1,0,0]=2      B_test[1,0,0]=2
8680      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
8681      Y_test[1]=18      n=self.setNormal(ReducedFunctionOnBoundary(self.domain))
8682      x_boundary=FunctionOnBoundary(self.domain).getX()      y_test=Data(0.,(2,),ReducedFunctionOnBoundary(self.domain))
8683      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])  
8684      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8685      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)
8686      r=pde.getResidual(u)      r=pde.getResidual(u)
8687      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8688      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 8691  class Test_assemblage_2Do1_Reduced(unitt
8691    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_B_Const_typeStrong_comp101(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_B_Const_typeStrong_comp101(self):
8692      x=self.domain.getX()      x=self.domain.getX()
8693      u=Data(0.,(2,),ContinuousFunction(self.domain))      u=Data(0.,(2,),ContinuousFunction(self.domain))
8694      u[0]=(-9)+3*x[1]-7*x[0]      u[0]=6
8695      u[1]=(-8)-4*x[1]-9*x[0]      u[1]=(-7)
8696      B_test=Data(0.,(2,2,2),ReducedFunction(self.domain))      B_test=Data(0.,(2,2,2),ReducedFunction(self.domain))
8697      B_test[1,0,1]=4      B_test[1,0,1]=3
8698      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
8699      Y_test[1]=36      n=self.setNormal(ReducedFunctionOnBoundary(self.domain))
8700      x_boundary=FunctionOnBoundary(self.domain).getX()      y_test=Data(0.,(2,),ReducedFunctionOnBoundary(self.domain))
8701      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])  
8702      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8703      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)
8704      r=pde.getResidual(u)      r=pde.getResidual(u)
8705      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8706      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 8709  class Test_assemblage_2Do1_Reduced(unitt
8709    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_B_Const_typeStrong_comp110(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_B_Const_typeStrong_comp110(self):
8710      x=self.domain.getX()      x=self.domain.getX()
8711      u=Data(0.,(2,),ContinuousFunction(self.domain))      u=Data(0.,(2,),ContinuousFunction(self.domain))
8712      u[0]=(-1)-2*x[1]+3*x[0]      u[0]=(-8)
8713      u[1]=5-1*x[1]+7*x[0]      u[1]=7
8714      B_test=Data(0.,(2,2,2),ReducedFunction(self.domain))      B_test=Data(0.,(2,2,2),ReducedFunction(self.domain))
8715      B_test[1,1,0]=5      B_test[1,1,0]=4
8716      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
8717      Y_test[1]=10      n=self.setNormal(ReducedFunctionOnBoundary(self.domain))
8718      x_boundary=FunctionOnBoundary(self.domain).getX()      y_test=Data(0.,(2,),ReducedFunctionOnBoundary(self.domain))
8719      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])  
8720      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8721      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)
8722      r=pde.getResidual(u)      r=pde.getResidual(u)
8723      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8724      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 8727  class Test_assemblage_2Do1_Reduced(unitt
8727    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_B_Const_typeStrong_comp111(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_B_Const_typeStrong_comp111(self):
8728      x=self.domain.getX()      x=self.domain.getX()
8729      u=Data(0.,(2,),ContinuousFunction(self.domain))      u=Data(0.,(2,),ContinuousFunction(self.domain))
8730      u[0]=7+3*x[1]-2*x[0]      u[0]=(-8)
8731      u[1]=2+x[1]-1*x[0]      u[1]=(-4)
8732      B_test=Data(0.,(2,2,2),ReducedFunction(self.domain))      B_test=Data(0.,(2,2,2),ReducedFunction(self.domain))
8733      B_test[1,1,1]=3      B_test[1,1,1]=4
8734      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
8735      Y_test[1]=(-3)      n=self.setNormal(ReducedFunctionOnBoundary(self.domain))
8736      x_boundary=FunctionOnBoundary(self.domain).getX()      y_test=Data(0.,(2,),ReducedFunctionOnBoundary(self.domain))
8737      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])  
8738      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8739      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)
8740      r=pde.getResidual(u)      r=pde.getResidual(u)
8741      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8742      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 8745  class Test_assemblage_2Do1_Reduced(unitt
8745    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_C_Const_typeStrong_comp000(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_C_Const_typeStrong_comp000(self):
8746      x=self.domain.getX()      x=self.domain.getX()
8747      u=Data(0.,(2,),ContinuousFunction(self.domain))      u=Data(0.,(2,),ContinuousFunction(self.domain))
8748      u[0]=(-3)+6*x[1]-8*x[0]      u[0]=(-7)-1*x[1]-4*x[0]
8749      u[1]=2-8*x[1]-1*x[0]      u[1]=(-5)+x[1]+8*x[0]
8750      C_test=Data(0.,(2,2,2),ReducedFunction(self.domain))      C_test=Data(0.,(2,2,2),ReducedFunction(self.domain))
8751      C_test[0,0,0]=8      C_test[0,0,0]=2
8752      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
8753      Y_test[0]=(-64)      Y_test[0]=(-8)
8754      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8755      pde.setValue(C=C_test, Y=Y_test)      pde.setValue(C_reduced=C_test, Y_reduced=Y_test)
8756      r=pde.getResidual(u)      r=pde.getResidual(u)
8757      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8758      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 8761  class Test_assemblage_2Do1_Reduced(unitt
8761    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_C_Const_typeStrong_comp001(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_C_Const_typeStrong_comp001(self):
8762      x=self.domain.getX()      x=self.domain.getX()
8763      u=Data(0.,(2,),ContinuousFunction(self.domain))      u=Data(0.,(2,),ContinuousFunction(self.domain))
8764      u[0]=4+2*x[1]+3*x[0]      u[0]=(-7)+3*x[1]-5*x[0]
8765      u[1]=(-5)-9*x[1]-1*x[0]      u[1]=4-3*x[1]+4*x[0]
8766      C_test=Data(0.,(2,2,2),ReducedFunction(self.domain))      C_test=Data(0.,(2,2,2),ReducedFunction(self.domain))
8767      C_test[0,0,1]=7      C_test[0,0,1]=7
8768      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
8769      Y_test[0]=14      Y_test[0]=21
8770      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8771      pde.setValue(C=C_test, Y=Y_test)      pde.setValue(C_reduced=C_test, Y_reduced=Y_test)
8772      r=pde.getResidual(u)      r=pde.getResidual(u)
8773      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8774      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 8777  class Test_assemblage_2Do1_Reduced(unitt
8777    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_C_Const_typeStrong_comp010(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_C_Const_typeStrong_comp010(self):
8778      x=self.domain.getX()      x=self.domain.getX()
8779      u=Data(0.,(2,),ContinuousFunction(self.domain))      u=Data(0.,(2,),ContinuousFunction(self.domain))
8780      u[0]=(-6)-3*x[1]-9*x[0]      u[0]=(-7)+4*x[1]+8*x[0]
8781      u[1]=(-5)+5*x[1]-2*x[0]      u[1]=1+8*x[1]-1*x[0]
8782      C_test=Data(0.,(2,2,2),ReducedFunction(self.domain))      C_test=Data(0.,(2,2,2),ReducedFunction(self.domain))
8783      C_test[0,1,0]=1      C_test[0,1,0]=7
8784      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
8785      Y_test[0]=(-2)      Y_test[0]=(-7)
8786      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8787      pde.setValue(C=C_test, Y=Y_test)      pde.setValue(C_reduced=C_test, Y_reduced=Y_test)
8788      r=pde.getResidual(u)      r=pde.getResidual(u)
8789      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8790      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 8793  class Test_assemblage_2Do1_Reduced(unitt
8793    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_C_Const_typeStrong_comp011(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_C_Const_typeStrong_comp011(self):
8794      x=self.domain.getX()      x=self.domain.getX()
8795      u=Data(0.,(2,),ContinuousFunction(self.domain))      u=Data(0.,(2,),ContinuousFunction(self.domain))
8796      u[0]=1-4*x[1]-8*x[0]      u[0]=1-1*x[1]+3*x[0]
8797      u[1]=(-7)-4*x[1]+8*x[0]      u[1]=6+4*x[1]-6*x[0]
8798      C_test=Data(0.,(2,2,2),ReducedFunction(self.domain))      C_test=Data(0.,(2,2,2),ReducedFunction(self.domain))
8799      C_test[0,1,1]=1      C_test[0,1,1]=2
8800      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
8801      Y_test[0]=(-4)      Y_test[0]=8
8802      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8803      pde.setValue(C=C_test, Y=Y_test)      pde.setValue(C_reduced=C_test, Y_reduced=Y_test)
8804      r=pde.getResidual(u)      r=pde.getResidual(u)
8805      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8806      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 8809  class Test_assemblage_2Do1_Reduced(unitt
8809    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_C_Const_typeStrong_comp100(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_C_Const_typeStrong_comp100(self):
8810      x=self.domain.getX()      x=self.domain.getX()
8811      u=Data(0.,(2,),ContinuousFunction(self.domain))      u=Data(0.,(2,),ContinuousFunction(self.domain))
8812      u[0]=(-1)+8*x[1]+3*x[0]      u[0]=5-3*x[1]+6*x[0]
8813      u[1]=1-9*x[1]+5*x[0]      u[1]=(-7)-3*x[1]-9*x[0]
8814      C_test=Data(0.,(2,2,2),ReducedFunction(self.domain))      C_test=Data(0.,(2,2,2),ReducedFunction(self.domain))
8815      C_test[1,0,0]=6      C_test[1,0,0]=6
8816      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
8817      Y_test[1]=18      Y_test[1]=36
8818      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8819      pde.setValue(C=C_test, Y=Y_test)      pde.setValue(C_reduced=C_test, Y_reduced=Y_test)
8820      r=pde.getResidual(u)      r=pde.getResidual(u)
8821      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8822      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 8825  class Test_assemblage_2Do1_Reduced(unitt
8825    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_C_Const_typeStrong_comp101(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_C_Const_typeStrong_comp101(self):
8826      x=self.domain.getX()      x=self.domain.getX()
8827      u=Data(0.,(2,),ContinuousFunction(self.domain))      u=Data(0.,(2,),ContinuousFunction(self.domain))
8828      u[0]=(-2)+6*x[1]+6*x[0]      u[0]=(-5)-2*x[1]-2*x[0]
8829      u[1]=(-1)-8*x[1]-5*x[0]      u[1]=(-1)-2*x[1]+8*x[0]
8830      C_test=Data(0.,(2,2,2),ReducedFunction(self.domain))      C_test=Data(0.,(2,2,2),ReducedFunction(self.domain))
8831      C_test[1,0,1]=6      C_test[1,0,1]=3
8832      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
8833      Y_test[1]=36      Y_test[1]=(-6)
8834      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8835      pde.setValue(C=C_test, Y=Y_test)      pde.setValue(C_reduced=C_test, Y_reduced=Y_test)
8836      r=pde.getResidual(u)      r=pde.getResidual(u)
8837      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8838      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 8841  class Test_assemblage_2Do1_Reduced(unitt
8841    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_C_Const_typeStrong_comp110(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_C_Const_typeStrong_comp110(self):
8842      x=self.domain.getX()      x=self.domain.getX()
8843      u=Data(0.,(2,),ContinuousFunction(self.domain))      u=Data(0.,(2,),ContinuousFunction(self.domain))
8844      u[0]=(-5)-5*x[1]+3*x[0]      u[0]=(-2)-8*x[1]+2*x[0]
8845      u[1]=(-8)-2*x[1]-3*x[0]      u[1]=3+7*x[1]-6*x[0]
8846      C_test=Data(0.,(2,2,2),ReducedFunction(self.domain))      C_test=Data(0.,(2,2,2),ReducedFunction(self.domain))
8847      C_test[1,1,0]=2      C_test[1,1,0]=6
8848      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
8849      Y_test[1]=(-6)      Y_test[1]=(-36)
8850      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8851      pde.setValue(C=C_test, Y=Y_test)      pde.setValue(C_reduced=C_test, Y_reduced=Y_test)
8852      r=pde.getResidual(u)      r=pde.getResidual(u)
8853      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8854      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 8857  class Test_assemblage_2Do1_Reduced(unitt
8857    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_C_Const_typeStrong_comp111(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_C_Const_typeStrong_comp111(self):
8858      x=self.domain.getX()      x=self.domain.getX()
8859      u=Data(0.,(2,),ContinuousFunction(self.domain))      u=Data(0.,(2,),ContinuousFunction(self.domain))
8860      u[0]=(-2)+4*x[1]+5*x[0]      u[0]=7+4*x[1]+4*x[0]
8861      u[1]=(-4)+5*x[1]+x[0]      u[1]=(-8)+8*x[1]+8*x[0]
8862      C_test=Data(0.,(2,2,2),ReducedFunction(self.domain))      C_test=Data(0.,(2,2,2),ReducedFunction(self.domain))
8863      C_test[1,1,1]=4      C_test[1,1,1]=4
8864      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
8865      Y_test[1]=20      Y_test[1]=32
8866      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8867      pde.setValue(C=C_test, Y=Y_test)      pde.setValue(C_reduced=C_test, Y_reduced=Y_test)
8868      r=pde.getResidual(u)      r=pde.getResidual(u)
8869      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8870      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 8873  class Test_assemblage_2Do1_Reduced(unitt
8873    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_D_Const_typeStrong_comp00(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_D_Const_typeStrong_comp00(self):
8874      x=self.domain.getX()      x=self.domain.getX()
8875      u=Data(0.,(2,),ContinuousFunction(self.domain))      u=Data(0.,(2,),ContinuousFunction(self.domain))
8876      u[0]=8-8*x[1]+x[0]      u[0]=3-9*x[1]+6*x[0]
8877      u[1]=(-8)+2*x[1]-6*x[0]      u[1]=(-3)+6*x[1]-3*x[0]
8878      D_test=Data(0.,(2,2),ReducedFunction(self.domain))      D_test=Data(0.,(2,2),ReducedFunction(self.domain))
8879      D_test[0,0]=4      D_test[0,0]=3
8880      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
8881      Y_test[0]=32-32*x[1]+4*x[0]      Y_test[0]=9-27*x[1]+18*x[0]
8882      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8883      pde.setValue(D=D_test, Y=Y_test)      pde.setValue(D_reduced=D_test, Y_reduced=Y_test)
8884      r=pde.getResidual(u)      r=pde.getResidual(u)
8885      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8886      self.failUnless(Lsup(rhs)>0,"right hand side is zero")      self.failUnless(Lsup(rhs)>0,"right hand side is zero")
# Line 9072  class Test_assemblage_2Do1_Reduced(unitt Line 8889  class Test_assemblage_2Do1_Reduced(unitt
8889    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_D_Const_typeStrong_comp01(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_D_Const_typeStrong_comp01(self):
8890      x=self.domain.getX()      x=self.domain.getX()
8891      u=Data(0.,(2,),ContinuousFunction(self.domain))      u=Data(0.,(2,),ContinuousFunction(self.domain))
8892      u[0]=(-1)+4*x[1]-7*x[0]      u[0]=(-5)+2*x[1]-5*x[0]
8893      u[1]=7-3*x[1]-6*x[0]      u[1]=(-5)-8*x[1]-2*x[0]
8894      D_test=Data(0.,(2,2),ReducedFunction(self.domain))      D_test=Data(0.,(2,2),ReducedFunction(self.domain))
8895      D_test[0,1]=8      D_test[0,1]=2
8896      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
8897      Y_test[0]=56-24*x[1]-48*x[0]      Y_test[0]=(-10)-16*x[1]-4*x[0]
8898      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8899      pde.setValue(D=D_test, Y=Y_test)      pde.setValue(D_reduced=D_test, Y_reduced=Y_test)
8900      r=pde.getResidual(u)      r=pde.getResidual(u)
8901      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8902      self.failUnless(Lsup(rhs)>0,"right hand side is zero")      self.failUnless(Lsup(rhs)>0,"right hand side is zero")
# Line 9088  class Test_assemblage_2Do1_Reduced(unitt Line 8905  class Test_assemblage_2Do1_Reduced(unitt
8905    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_D_Const_typeStrong_comp10(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_D_Const_typeStrong_comp10(self):
8906      x=self.domain.getX()      x=self.domain.getX()
8907      u=Data(0.,(2,),ContinuousFunction(self.domain))      u=Data(0.,(2,),ContinuousFunction(self.domain))
8908      u[0]=(-5)+6*x[1]+3*x[0]      u[0]=(-3)+5*x[1]+x[0]
8909      u[1]=(-3)-9*x[1]-8*x[0]      u[1]=(-5)+x[1]+3*x[0]
8910      D_test=Data(0.,(2,2),ReducedFunction(self.domain))      D_test=Data(0.,(2,2),ReducedFunction(self.domain))
8911      D_test[1,0]=1      D_test[1,0]=3
8912      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
8913      Y_test[1]=(-5)+6*x[1]+3*x[0]      Y_test[1]=(-9)+15*x[1]+3*x[0]
8914      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8915      pde.setValue(D=D_test, Y=Y_test)      pde.setValue(D_reduced=D_test, Y_reduced=Y_test)
8916      r=pde.getResidual(u)      r=pde.getResidual(u)
8917      rhs=pde.getRightHandSide()      rhs=pde.getRightHandSide()
8918      self.failUnless(Lsup(rhs)>0,"right hand side is zero")      self.failUnless(Lsup(rhs)>0,"right hand side is zero")
# Line 9104  class Test_assemblage_2Do1_Reduced(unitt Line 8921  class Test_assemblage_2Do1_Reduced(unitt
8921    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_D_Const_typeStrong_comp11(self):    def test_assemblage_2D_solO1_coeffOReduced_NEqu2_D_Const_typeStrong_comp11(self):
8922      x=self.domain.getX()      x=self.domain.getX()
8923      u=Data(0.,(2,),ContinuousFunction(self.domain))      u=Data(0.,(2,),ContinuousFunction(self.domain))
8924      u[0]=(-8)-3*x[1]-3*x[0]      u[0]=(-2)+4*x[1]-8*x[0]
8925      u[1]=(-3)-1*x[1]-9*x[0]      u[1]=(-7)-7*x[1]+4*x[0]
8926      D_test=Data(0.,(2,2),ReducedFunction(self.domain))      D_test=Data(0.,(2,2),ReducedFunction(self.domain))
8927      D_test[1,1]=3      D_test[1,1]=4
8928      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))      Y_test=Data(0.,(2,),ContinuousFunction(self.domain))
8929      Y_test[1]=(-9)-3*x[1]-27*x[0]      Y_test[1]=(-28)-28*x[1]+16*x[0]
8930      pde=LinearPDE(self.domain)      pde=LinearPDE(self.domain)
8931      pde.setValue(D=D_test, Y=Y_test)      pde.setValue(D_reduced=D_test, Y_reduced=Y_test)
8932        r=pde.getResidual(u)
8933        rhs=pde.getRightHandSide()
8934        self.failUnless(Lsup(rhs)>0,"right hand side is zero")
8935        self.failUnless(Lsup(r)<=self.RES_TOL*Lsup(rhs),"residual is too big")
8936      #==================================================
8937      def test_assemblage_2D_solO1_coeffOReduced_NEqu2_d_Const_typeStrong_comp00(self):
8938        x=self.domain.getX()
8939        u=Data(0.,(2,),ContinuousFunction(self.domain))
8940        u[0]=1-8*x[1]-1*x[0]
8941        u[1]=6-1*x[1]+2*x[0]
8942        d_test=Data(0.,(2,2),ReducedFunctionOnBoundary(self.domain))
8943        d_test[0,0]=3
8944        y_test=Data(0.,(2,),ContinuousFunction(self.domain))
8945        y_test[0]=3-24*x[1]-3*x[0]
8946        pde=LinearPDE(self.domain)
8947        pde.setValue(d_reduced=d_test, y_reduced=y_test)