Dear Jonathan, How are you? Your help was very valuable to me! I am running a different model this time and I am using sort of a trial and error to simulate the real experiment and find the values that make a perfect fit to the experimental results.
The problem is that the first 2 seconds of the simulation are the same each time, as due to the mesh geometry are not affected by the different parameters I use each time. Is there a way to save the process until that stage, saving me a lot of extra time from each run? Finally, the timeStep = 2e-4 works perfect but its too slow, is there a better way to increase the time step, for example gradually? Thank you very much for your time! Kind regards, John On Thu, Jan 24, 2013 at 5:05 PM, Jonathan Guyer <[email protected]> wrote: > > On Jan 23, 2013, at 8:39 PM, John Assael wrote: > > > I think it its not a problem of properties as the same values are used > in COMSOL and they result different values. > > Moreover, I tried small changes like 5-10% and there was no big > difference... > > If you drop tc0 by a factor of 2, you get pretty close to your COMSOL > solution. I'm not saying that's what happened, just that this problem is > pretty sensitive to the thermal diffusivity. > > > could it be FiPy's Solver? > > It could be, but I think it's unlikely. FiPy is subjected to thousands of > tests, many of them much more rigorous than this fairly simple heat > transport problem. I suspect that there is some unintended difference in > the declaration of the COMSOL problem and the declaration of the FiPy > problem. > > One issue is that your solutions are not converged. Changing the timestep > changes the answer. If changing the timestep or the grid resolution changes > the answer, then your timestep or grid spacing are too large. Your > coefficients are all linear, so sweeping does not help, but dropping the > timestep does. You might not need that much, but dropping timeStep by a > factor of ten seems to give fairly converged results. > > Another thing that occurred to me is that you have declared the > coefficient of the DiffusionTerm at cell centers, but FiPy needs it at > faces. FiPy interpolates from cells to faces automatically, but the > particular interpolation chosen can make a difference. When I started > experimenting with different interpolations, I found that this simple > rearrangement of your equation: > > heatEq = (TransientTerm(coeff=denCell*cpCell) == > DiffusionTerm(coeff=tcCell) + QCell) > > is enough (combined with timeStep = 2e-4) to give pretty good agreement > with your Experimental and COMSOL results: > > 0.002 0.530949358814 > 0.004 0.798725006713 > 0.006 0.981455545597 > 0.008 1.11988469053 > 0.01 1.23100247808 > 0.012 1.32361096122 > 0.014 1.4028708204 > 0.016 1.47206568877 > 0.018 1.53341163428 > 0.02 1.58847282845 > > This comes back to my original point about the sensitivity of this problem > to the thermal diffusivity. By changing the interpolation of the > DiffusionTerm, you change the thermal diffusivity at the wire/fluid > boundary and so have a strong effect on the evolution of the problem. > _______________________________________________ > fipy mailing list > [email protected] > http://www.ctcms.nist.gov/fipy > [ NIST internal ONLY: https://email.nist.gov/mailman/listinfo/fipy ] > -- ..:: ic3man.gr ::.. software | design | development _/_/_/ email: [email protected] _/_/_/ www : http://www.ic3man.gr ------------------------------------------------------------------ This e-mail and any attachments are confidential. You may not copy or disseminate any information contained in them to anyone other than the intended recipient. If you are not the intended recipient please contact the sender by reply e-mail and destroy all copies of the original message immediately. ------------------------------------------------------------------
_______________________________________________ fipy mailing list [email protected] http://www.ctcms.nist.gov/fipy [ NIST internal ONLY: https://email.nist.gov/mailman/listinfo/fipy ]
