~njansson/dolfin/hpc

« back to all changes in this revision

Viewing changes to demo/mesh/refinement/python/demo.py

  • Committer: Garth N. Wells
  • Date: 2008-03-29 09:34:25 UTC
  • Revision ID: gnw20@cam.ac.uk-20080329093425-3ea2vhjvccq56zvi
Add some basic build & install instructions.

Show diffs side-by-side

added added

removed removed

Lines of Context:
7
7
 
8
8
# Create mesh of unit square
9
9
mesh = UnitSquare(5, 5)
10
 
plot(mesh, interactive=True)
 
10
plot(mesh)
11
11
 
12
12
# Uniform refinement
13
13
mesh.refine()
14
 
plot(mesh, interactive=True)
 
14
plot(mesh)
15
15
 
16
16
# Refine mesh close to x = (0.5, 0.5)
17
17
p = Point(0.5, 0.5)
32
32
    mesh.smooth()
33
33
 
34
34
    # Plot mesh
35
 
    plot(mesh, interactive=True)
 
35
    plot(mesh)