# Diff of /trunk/doc/examples/cookbook/example09a.py

revision 3089 by ahallam, Mon Aug 9 07:20:58 2010 UTC revision 3346 by caltinay, Fri Nov 12 01:19:02 2010 UTC
# Line 33  import os Line 33  import os
33  from esys.escript.pdetools import Projector, Locator  from esys.escript.pdetools import Projector, Locator
34  from esys.escript.unitsSI import *  from esys.escript.unitsSI import *
35  import numpy as np  import numpy as np
36    import matplotlib
37    matplotlib.use('agg') #It's just here for automated testing
38
39  import pylab as pl  import pylab as pl
40  import matplotlib.cm as cm  import matplotlib.cm as cm
41  from esys.escript.linearPDEs import LinearPDE  from esys.escript.linearPDEs import LinearPDE
43    from esys.weipa import saveVTK
44
45  ########################################################MPI WORLD CHECK  ########################################################MPI WORLD CHECK
46  if getMPISizeWorld() > 1:  if getMPISizeWorld() > 1:
# Line 63  mu2=vel2**2.*rho2/4.;  mu1=vel1**2.*rho1 Line 67  mu2=vel2**2.*rho2/4.;  mu1=vel1**2.*rho1
67  lam2=vel2**2.*rho2/2.; lam1=vel1**2.*rho1/2.  #lames constant  lam2=vel2**2.*rho2/2.; lam1=vel1**2.*rho1/2.  #lames constant
68
69  # Time related variables.  # Time related variables.
70  tend=0.1    # end time  testing=True
71    if testing:
72        print 'The testing end time is curerntly sellected this severely limits the number of time iterations.'
73        print "Try changing testing to False for more iterations."
74        tend=0.001
75    else:
76        tend=0.1    # end time
77
78  h=0.0001    # time step  h=0.0001    # time step
79  # data recording times  # data recording times
80  rtime=0.0 # first time to record  rtime=0.0 # first time to record

Legend:
 Removed from v.3089 changed lines Added in v.3346