Hello, I am modelling nonlinear heat conduction using time steps and sweeps.
Basic equation is: du/dt = A(u) * d2u/dx2 + S(x, t) where u(x, t) I have functions written for A(u), the DiffusionTerm coefficient, and S(x, t), the ImplicitSourceTerm. I implement them with the following snippet: eq = TransientTerm() == DiffusionTerm(coeff=A) + ImplicitSourceTerm(coeff=S) S is really the whole source term, not the coefficient, so have I coded this correctly? I have declared A as a FaceVariable (because diffusion happens from cell to cell, and S as a CellVariable, is this correct? Since S depends on t as well, I created a Variable t. I then created a small function and included it with S with this snippet: B = 50 * numerix.exp(-t) S.setValue(B) After sweeping, I increment the elapsed time and then t, with t.setValue(elapsedTime) I can print B's value to see that it does decay. I provide an initial distribution: u(x, 0). For simplicity, I will choose no boundary conditions. The first set of sweeps causes u to zero out. What is happening? Have I not set this up correctly? What examples could I use to iron this out? Thanks, Chris
_______________________________________________ fipy mailing list [email protected] http://www.ctcms.nist.gov/fipy [ NIST internal ONLY: https://email.nist.gov/mailman/listinfo/fipy ]
