Diff of /trunk/finley/test/python/slip_stress_old.py

revision 887 by gross, Thu Nov 2 07:17:07 2006 UTC revision 888 by gross, Tue Nov 7 08:31:26 2006 UTC
67        def solve_f(self,u,p,tol=1.e-8):        def solve_f(self,u,p,tol=1.e-8):
68           self.__pde_u.setTolerance(tol)           self.__pde_u.setTolerance(tol)
69           self.__pde_u.setValue(y_contact=p)           self.__pde_u.setValue(y_contact=p)
70             print "p:",inf(p),sup(p)
71             print "u:",inf(u),sup(u)
72             self.__pde_u.setValue(y_contact=p)
73           return  self.__pde_u.getSolution()           return  self.__pde_u.getSolution()
74
75        def solve_g(self,u,tol=1.e-8):        def solve_g(self,u,tol=1.e-8):
76           dp=(self.slip-jump(u))*lam_lmbd/FunctionOnContactZero(self.domain).getX()           dp= (self.slip-jump(u))*lam_lmbd/FunctionOnContactZero(self.domain).getSize()**2
77           return  dp           return  dp
78
79
81  prop=SlippingFault(dom)  prop=SlippingFault(dom)
82  d=dom.getDim()  d=dom.getDim()
83  x=dom.getX()[d-1]  x=dom.getX()[0]
84    # x=dom.getX()[d-1]
86  s=numarray.array([0.,1.,1.])  s=numarray.array([0.,1.,1.])
87  x=FunctionOnContactZero(dom).getX()  x=FunctionOnContactZero(dom).getX()
# Line 93  for i in range(3): Line 97  for i in range(3):
97  u0=Vector(0.,Solution(dom))  u0=Vector(0.,Solution(dom))
98  p0=Vector(1.,FunctionOnContactZero(dom))  p0=Vector(1.,FunctionOnContactZero(dom))