Dear all,

I have time dependent coefficients in a diffusion-convection problem.
In the manual I found the description (given below) of the way to
implement time dependent BCs. Will coefficients of the Terms in
equation automatically update if I use the same approach?

Thanks for the answers,

Regards,
Igor.

>>> time = Variable()
and then declare our boundary condition as a function of this Variable
>>> BCs = (FixedValue(faces=mesh.getFacesLeft(), value=0.5 * (1 + sin(time))),
.. FixedValue(faces=mesh.getFacesRight(), value=0.))
When we update time at each timestep, the left-hand boundary condition
will automatically update,
>>> dt = .1
>>> while time() < 15:
.. time.setValue(time() + dt)
.. eqI.solve(var=phi, dt=dt, boundaryConditions=BCs)
.. if __name__ == ’__main__’:
.. viewer.plot()


Reply via email to