On Feb 11, 2011, at 9:43 AM, Benny Malengier wrote:
> Hence I conclude I don't understand the code. > > I rewrote the code to what I can understand myself and to what I think it is > supposed to do, using the repeat function of fipy, which I think is more > correct that the resize and newaxis combination. > I also added the chunk trick that was posted some days ago so as to prevent > to original memoryerror I wanted to avoid. I can now add the two 3D meshes > without a mem error, and it is actually quite fast which I was not expecting > as I am using chunks of only 10. > To reduce memory further, I added a method to pass the vertices over which to > add, which is used when set, and otherwise exteriorFaces is used like before > (so the code was already adding only over the external edges). I've finally found the time to sit down and both understand the old algorithm and what you provided. I've merged your changes to trunk and put some comments at http://matforge.org/fipy/ticket/348. Many thanks for the contribution!
