Andrew, The pysparse solver has given me convergence problems when I used heterogeneous diffusion coefficients in simple steady-state diffusion problem. I have found that the Trilinos solvers overcome these problems and deliver stable results. I haven't upgraded to scipy 0.7.0 yet so I can't run your code on my machine to check...
Best Regards, Angus Hendrick On Wed, Feb 4, 2009 at 10:09 AM, A.S.Reeve <[email protected]> wrote: > Daniel and Jonathan, > > I'm having some difficulty getting fipy to converge for a fairly > simple problem when I include a modest amount of heterogeneity. I've > simplified things down to a transient diffusion equation with a source > term across selected cells along the 'top' of the model, and type 1 > boundary conditions elsewhere across the top of the model. > > I've tried doing this on a couple of different grids generated by > gmsh. One was created by writing a script to great the geometry file > (both points and line segments, merging the files from my script into > gmsh, then defining plane surfaces in gmsh and creating the grid. As > I'd had problem making proper grids before, I thought this might be > the problem and remade a simpler grid just from point data. Each grid > has a separate file associated with it used to define different > regions within the model. Both sets of files are attached. > > When I run a model with no heterogeneity, the results look half-way > reasonable, but when I add a modest amount of heterogeneity (based on > the zones), the model blows up and doesn't converge. I was able to get > something to run many months ago (or so I thought), but now am trying > to redo these models to address reviewer comments and things are not > working out... > > I'd assume FiPy should be able to handle heterogeneity. Does this have > something to do with using a gmsh grid (should I always use > rectangular grids when using fipy)? > > My script and supporting files are attached if you have time to look > at then to see if this is my stupidity or a problem with FiPy. I think > there are a few things in the file that are holdovers from the case I > was initially trying to solve (ie sweeping instead of solving, > importing rbf), but I don't think they are impacting the results. > Heterogeneity is assigned in lines 55 to 57 of the attached script. > > I'm using very recent versions of fipy(2982) > > Andy > > Andrew Reeve > Associate Prof. > Dept. of Earth Sciences > University of Maine > 207-581-2353 >
