/[escript]/trunk/doc/examples/heatedblock.py
ViewVC logotype

Diff of /trunk/doc/examples/heatedblock.py

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

revision 1811 by ksteube, Thu Sep 25 23:11:13 2008 UTC revision 1892 by artak, Fri Oct 17 00:55:59 2008 UTC
# Line 50  msk=whereZero(x[0])*[1.,0.,0.] \ Line 50  msk=whereZero(x[0])*[1.,0.,0.] \
50     +whereZero(x[2])*[0.,0.,1.]     +whereZero(x[2])*[0.,0.,1.]
51  sigma0=(lam+2./3.*mu)*alpha*(T-T_ref)*kronecker(mydomain)  sigma0=(lam+2./3.*mu)*alpha*(T-T_ref)*kronecker(mydomain)
52  mypde.setValue(A=C,X=sigma0,q=msk)  mypde.setValue(A=C,X=sigma0,q=msk)
53    mypde.setSolverMethod(mypde.PCG,mypde.AMG)
54  #... solve pde ...  #... solve pde ...
55  u=mypde.getSolution()  u=mypde.getSolution(verbose=True)
56  #... calculate von-Misses  #... calculate von-Misses
57  g=grad(u)  g=grad(u)
58  sigma=mu*(g+transpose(g))+lam*trace(g)*kronecker(mydomain)-sigma0  sigma=mu*(g+transpose(g))+lam*trace(g)*kronecker(mydomain)-sigma0

Legend:
Removed from v.1811  
changed lines
  Added in v.1892

  ViewVC Help
Powered by ViewVC 1.1.26