← Back to team overview

dolfin team mailing list archive

[HG DOLFIN] Allow simple specification of subdomains in Python without needing to subclass SubDomain.

 

One or more new changesets pushed to the primary dolfin repository.
A short summary of the last three changesets is included below.

changeset:   7399:ce910223d8a0
tag:         tip
user:        Anders Logg <logg@xxxxxxxxx>
date:        Thu Oct 22 18:53:41 2009 +0200
files:       ChangeLog demo/pde/poisson/python/demo.py dolfin/mesh/SubDomain.h site-packages/dolfin/__init__.py site-packages/dolfin/bcs.py site-packages/dolfin/utils.py
description:
Allow simple specification of subdomains in Python without needing to subclass SubDomain.
Feature request from the president (of SIAM) and HPL. Thanks to Johan Hake for some help
with the Python magic.

One may now specify a SubDomain for a DirichletBC as follows:

  def my_boundary(x):
      return x[0] == 0.0

or optionally

  def my_boundary(x):
      return x[0] == 0.0 and on_boundary

Old-style subclassing works as before.


changeset:   7398:172fee97816c
user:        "Johan Hake <hake@xxxxxxxxx>"
date:        Thu Oct 22 13:56:01 2009 +0200
files:       dolfin/swig/docstrings.i dolfin/swig/fem_post.i dolfin/swig/fem_pre.i dolfin/swig/function_post.i dolfin/swig/function_pre.i dolfin/swig/kernel_modules.i site-packages/dolfin/expression.py site-packages/dolfin/function.py
description:
More consistant handling of FunctionSpace in Function
  - We now do not sotre the local FunctionSpace, previous self._V
  - Use self.function_space() instead.


changeset:   7397:7b163b1674d4
user:        Anders Logg <logg@xxxxxxxxx>
date:        Thu Oct 22 13:18:37 2009 +0200
files:       site-packages/dolfin/utils.py
description:
Add missing file.

----------------------------------------------------------------------
For more details, visit http://www.fenics.org/hg/dolfin


Follow ups