/[escript]/trunk/doc/examples/usersguide/poisson.py
ViewVC logotype

Diff of /trunk/doc/examples/usersguide/poisson.py

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

trunk/doc/user/examples/mypoisson.py revision 327 by gross, Wed Dec 7 04:32:28 2005 UTC trunk/doc/examples/poisson.py revision 1811 by ksteube, Thu Sep 25 23:11:13 2008 UTC
# Line 1  Line 1 
1  # $Id$  
2  from esys.finley import Rectangle  ########################################################
3    #
4    # Copyright (c) 2003-2008 by University of Queensland
5    # Earth Systems Science Computational Center (ESSCC)
6    # http://www.uq.edu.au/esscc
7    #
8    # Primary Business: Queensland, Australia
9    # Licensed under the Open Software License version 3.0
10    # http://www.opensource.org/licenses/osl-3.0.php
11    #
12    ########################################################
13    
14    __copyright__="""Copyright (c) 2003-2008 by University of Queensland
15    Earth Systems Science Computational Center (ESSCC)
16    http://www.uq.edu.au/esscc
17    Primary Business: Queensland, Australia"""
18    __license__="""Licensed under the Open Software License version 3.0
19    http://www.opensource.org/licenses/osl-3.0.php"""
20    __url__="http://www.uq.edu.au/esscc/escript-finley"
21    
22    from esys.escript import *
23  from esys.escript.linearPDEs import Poisson  from esys.escript.linearPDEs import Poisson
24  from esys.escript import whereZero,saveVTK  from esys.finley import Rectangle
25  # generate domain:  # generate domain:
26  mydomain = Rectangle(l0=1.,l1=1.,n0=40, n1=20)  mydomain = Rectangle(l0=1.,l1=1.,n0=40, n1=20)
27  # define characteristic function of Gamma^D  # define characteristic function of Gamma^D
# Line 12  mypde = Poisson(domain=mydomain) Line 32  mypde = Poisson(domain=mydomain)
32  mypde.setValue(f=1,q=gammaD)  mypde.setValue(f=1,q=gammaD)
33  u = mypde.getSolution()  u = mypde.getSolution()
34  # write u to an external file  # write u to an external file
35  saveVTK("u.xml",solution=u)  saveVTK("u.xml",sol=u)

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

  ViewVC Help
Powered by ViewVC 1.1.26