/[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/examples/poisson.py revision 1811 by ksteube, Thu Sep 25 23:11:13 2008 UTC trunk/doc/examples/usersguide/poisson.py revision 4657 by jfenwick, Thu Feb 6 06:12:20 2014 UTC
# Line 1  Line 1 
1    
2  ########################################################  ##############################################################################
3  #  #
4  # Copyright (c) 2003-2008 by University of Queensland  # Copyright (c) 2003-2014 by University of Queensland
5  # Earth Systems Science Computational Center (ESSCC)  # http://www.uq.edu.au
 # http://www.uq.edu.au/esscc  
6  #  #
7  # Primary Business: Queensland, Australia  # Primary Business: Queensland, Australia
8  # Licensed under the Open Software License version 3.0  # Licensed under the Open Software License version 3.0
9  # http://www.opensource.org/licenses/osl-3.0.php  # http://www.opensource.org/licenses/osl-3.0.php
10  #  #
11  ########################################################  # Development until 2012 by Earth Systems Science Computational Center (ESSCC)
12    # Development 2012-2013 by School of Earth Sciences
13    # Development from 2014 by Centre for Geoscience Computing (GeoComp)
14    #
15    ##############################################################################
16    
17  __copyright__="""Copyright (c) 2003-2008 by University of Queensland  __copyright__="""Copyright (c) 2003-2014 by University of Queensland
18  Earth Systems Science Computational Center (ESSCC)  http://www.uq.edu.au
 http://www.uq.edu.au/esscc  
19  Primary Business: Queensland, Australia"""  Primary Business: Queensland, Australia"""
20  __license__="""Licensed under the Open Software License version 3.0  __license__="""Licensed under the Open Software License version 3.0
21  http://www.opensource.org/licenses/osl-3.0.php"""  http://www.opensource.org/licenses/osl-3.0.php"""
22  __url__="http://www.uq.edu.au/esscc/escript-finley"  __url__="https://launchpad.net/escript-finley"
23    
24  from esys.escript import *  from esys.escript import *
25  from esys.escript.linearPDEs import Poisson  from esys.escript.linearPDEs import Poisson
26  from esys.finley import Rectangle  from esys.finley import Rectangle
27    from esys.weipa import saveVTK
28  # generate domain:  # generate domain:
29  mydomain = Rectangle(l0=1.,l1=1.,n0=40, n1=20)  mydomain = Rectangle(l0=1.,l1=1.,n0=40, n1=20)
30  # define characteristic function of Gamma^D  # define characteristic function of Gamma^D
# Line 32  mypde = Poisson(domain=mydomain) Line 35  mypde = Poisson(domain=mydomain)
35  mypde.setValue(f=1,q=gammaD)  mypde.setValue(f=1,q=gammaD)
36  u = mypde.getSolution()  u = mypde.getSolution()
37  # write u to an external file  # write u to an external file
38  saveVTK("u.xml",sol=u)  saveVTK("u.vtu",sol=u)
39    

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

  ViewVC Help
Powered by ViewVC 1.1.26