/[escript]/trunk/finley/test/python/FCT_test2.py
ViewVC logotype

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

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

revision 1371 by gross, Thu Jan 3 06:11:21 2008 UTC revision 1375 by gross, Wed Jan 9 00:15:05 2008 UTC
# Line 70  for i in range(dom.getDim()): Line 70  for i in range(dom.getDim()):
70      u=u*exp(-(x[i]-x_0[i])**2/sigma**2)      u=u*exp(-(x[i]-x_0[i])**2/sigma**2)
71  u/=Lsup(u)  u/=Lsup(u)
72    
73  u=whereNonPositive(abs(x[0]-0.3)-0.2)*whereNonPositive(abs(x[1]-0.5)-0.2)  # u=whereNonPositive(abs(x[0]-0.3)-0.2)*whereNonPositive(abs(x[1]-0.5)-0.2)
74  c=0  c=0
75  saveVTK("u.%s.xml"%c,u=u)  saveVTK("u.%s.xml"%c,u=u)
76  fc.setInitialSolution(u)  fc.setInitialSolution(u)
# Line 80  t=0. Line 80  t=0.
80  while t<15*dt:  while t<15*dt:
81      print "time step t=",t+dt        print "time step t=",t+dt  
82      u=fc.solve(dt)        u=fc.solve(dt)  
83      print "range u",inf(u),sup(u)      print "range u",inf(u),sup(u),integrate(u,Function(dom))
84      c+=1      c+=1
85      saveVTK("u.%s.xml"%c,u=u)      saveVTK("u.%s.xml"%c,u=u)
86      t+=dt      t+=dt

Legend:
Removed from v.1371  
changed lines
  Added in v.1375

  ViewVC Help
Powered by ViewVC 1.1.26