5 Jun 22:22
syntax change on trunk
From: Jonathan Guyer <guyer@...>
Subject: syntax change on trunk
Newsgroups: gmane.comp.python.fipy
Date: 2008-06-05 20:24:23 GMT
Subject: syntax change on trunk
Newsgroups: gmane.comp.python.fipy
Date: 2008-06-05 20:24:23 GMT
I've just committed a change to trunk that may affect some of you. Although there are many internal changes involved, they should hopefully not be of interest to FiPy users. On the other hand, you can see the few examples that changed at http://www.matforge.org/fipy/changeset?new=trunk%2Fexamples%402565&old=trunk%2Fexamples%402541 Basically, the change affects how you specify faces or cells for setting boundary conditions and initial conditions. The result of calls like `mesh.getExteriorFaces()` or `mesh.getFacesLeft()` is no longer a special `FaceIterator` class, but is now just a boolean mask. This makes it easy to specify a particular subset of faces with `&` and `|`, which could be a bit tricky in the old scheme. I've also done away with the `filter` argument of `getFaces()` and `getCells()`, as I don't think it's at all necessary anymore and it was massively inefficient. The new syntax is, IMNSHO, easier to read and more powerful than the old, but it's not 100% compatible, so I wanted to give people a heads- up. If you can't make sense of the new scheme, by all means let us know.
RSS Feed