Hi,

First, I'd like to mention I'm happy with how fipy is handling the problem
I'm throwing at it.
I just write here to offer some insight from a user using fipy for the first
time.

I would just like to mention that I do not like the design chosen for the
UniformGrid2D structure.

I have struggled with a bug for a long time because it was unclear that a
Grid2D created from
from fipy import *
can be a Grid2D or a UniformGrid2D

I think it would be a better design if Grid2D in meshes.numMesh is renamed
NonUniformGrid2D.

I also find it impossible to write generic code that can work on all meshes.
UniformGrid2D does not call the __init__ method of it's parent class. I find
that a dangerous way of writing inheritance. Eg, for UniformGrid2D,
self.areaProjections attribute is not present, altough it is an attribute of
the parent object (it is set in __init__ of /meshes/common/mesh.py).

The fix for me is easy of course:

from fipy import *
from fipy.meshes.numMesh.grid2D import Grid2D

but it would be nice if this is not needed, eg by adding the __init__ or by
making in the manual mush clearer that Grid2D is not the nummesh/Grid2D.

Greetings,
Benny

Reply via email to