On Oct 20, 2009, at 1:24 AM, weasky wrote:
Hi,
I found out if I replace it with
mesh1 = Grid2D(nx=6, ny=2) + ((-3.0,), (6.0,))
Correct. The ordering of dimensions changed in FiPy 2.0
it will work. Then what about the boundary conditions? for a T shape,
the left, right, top, bot BCs is for what face? The combined one?
Good question!
For all intents and purposes, getFacesTop() et al. are defined by:
>>> X, Y = mesh.getFaceCenters()
>>> top = (Y == max(Y))
>>> bottom = (Y == min(Y))
>>> left = (X == min(X))
>>> right = (X == max(X))
It looks like they don't even restrict themselves to exterior faces,
which is wrong.
So, they are just the faces at the extrema. For anything other than
rectangular grids, this is probably not useful, and you are better off
just defining the faces you want explicitily:
>>> myFaces = mesh.getExteriorFaces() & (X == 3.5)
or whatever is appropriate.