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

Contents of /trunk/doc/examples/usersguide/quad.py

Parent Directory Parent Directory | Revision Log Revision Log


Revision 2695 - (show annotations)
Tue Sep 29 06:29:12 2009 UTC (9 years, 6 months ago) by gross
File MIME type: text/x-python
File size: 1540 byte(s)
pycad passes on more infromation from gmsh now.
1
2 ########################################################
3 #
4 # Copyright (c) 2003-2009 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-2009 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__="https://launchpad.net/escript-finley"
21
22 """
23 a simple 1x1 quad`
24
25 :var __author__: name of author
26 :var __licence__: licence agreement
27 :var __url__: url entry point on documentation
28 :var __version__: version
29 :var __date__: date of the version
30 """
31
32 __author__="Lutz Gross, l.gross@uq.edu.au"
33
34 from esys.pycad import *
35 from esys.pycad.gmsh import Design
36 from esys.finley import MakeDomain
37 p0=Point(0.,0.,0.)
38 p1=Point(1.,0.,0.)
39 p2=Point(1.,1.,0.)
40 p3=Point(0.,1.,0.)
41 l01=Line(p0,p1)
42 l12=Line(p1,p2)
43 l23=Line(p2,p3)
44 l30=Line(p3,p0)
45 c=CurveLoop(l01,l12,l23,l30)
46 s=PlaneSurface(c)
47
48 d=Design(dim=2,element_size=0.05)
49 d.setScriptFileName("quad.geo")
50 d.setMeshFileName("quad.msh")
51 d.addItems(s)
52
53 pl1=PropertySet("sides",l01,l23)
54 pl2=PropertySet("top_and_bottom",l12,l30)
55 d.addItems(pl1,pl2)
56
57 dom=MakeDomain(d)
58 dom.write("quad.fly")

Properties

Name Value
svn:mergeinfo /branches/restext/pycad/examples/quad.py:2610-2624 /branches/stage3.0/pycad/examples/quad.py:2569-2590 /release/3.0/pycad/examples/quad.py:2591-2601

  ViewVC Help
Powered by ViewVC 1.1.26