Discussion Closed This discussion was created more than 6 months ago and has been closed. To start a new discussion with a link back to this one, click here.

Time dependent Temperature

Please login with a confirmed email address before reporting spam

Hi all,
I am solving a time-dependent heat and mass transfer problem. When I solve it for time (0,10,1800), I am getting the expected results but when I change the time to (0,10,2500), the temperature profile turns out to be quite unexpected, even for the earlier times like 500 s or 1000 s etc. Why could this be happening? Any ideas?

Best,
Mahvash

P.S.: I am using comsol 5.2

2 Replies Last Post Mar 31, 2016, 2:37 AM EDT
Henrik Sönnerlind COMSOL Employee

Please login with a confirmed email address before reporting spam

Posted: 5 years ago Mar 30, 2016, 7:44 AM EDT
Hi,

The first time step taken by the solver is (as long as you do not specify it explicitly) is

initial_time_step=0.001*end_time

This can affect your solution in two ways:

a) You will not get the same time step history up to a certain earlier time when the end time is changed. This should however not change the result appreciably if you have tight enough tolerances so that the automatic time step control does a good job.

b) The Consistent Initialization procedure tries to reconcile inconsistent initial values. In doing that, it takes a small time step (default 0.001*initial_time_step).

If for example you have boundary conditions and initial conditions which do not match, the results of the consistent initialization is strongly dependent on the initial time step taken.

An example of a similar problem can be found in

www.comsol.com/community/forums/general/thread/107622/

But even if your problem is not inconsistent, there can be a sensitivity to the initial time step: If time derivatives at t=0 are very large, it is important to take small time steps there.

To control this manually, change 'Initial step' and/or "Fraction of initial step for Backward Euler' in the 'Time Stepping' section of the 'Time-Dependent Solver' settings.

Regards,
Henrik
Hi, The first time step taken by the solver is (as long as you do not specify it explicitly) is initial_time_step=0.001*end_time This can affect your solution in two ways: a) You will not get the same time step history up to a certain earlier time when the end time is changed. This should however not change the result appreciably if you have tight enough tolerances so that the automatic time step control does a good job. b) The Consistent Initialization procedure tries to reconcile inconsistent initial values. In doing that, it takes a small time step (default 0.001*initial_time_step). If for example you have boundary conditions and initial conditions which do not match, the results of the consistent initialization is strongly dependent on the initial time step taken. An example of a similar problem can be found in http://www.comsol.com/community/forums/general/thread/107622/ But even if your problem is not inconsistent, there can be a sensitivity to the initial time step: If time derivatives at t=0 are very large, it is important to take small time steps there. To control this manually, change 'Initial step' and/or "Fraction of initial step for Backward Euler' in the 'Time Stepping' section of the 'Time-Dependent Solver' settings. Regards, Henrik

Please login with a confirmed email address before reporting spam

Posted: 5 years ago Mar 31, 2016, 2:37 AM EDT
Hi Henrik,

Thanks for the response. I am already using Backward Euler with a 'Fraction of initial step for Backward Euler' as 0.001. I will tweak my boundary and initial conditions and see what happens. Thanks.

Best,
Mahvash
Hi Henrik, Thanks for the response. I am already using Backward Euler with a 'Fraction of initial step for Backward Euler' as 0.001. I will tweak my boundary and initial conditions and see what happens. Thanks. Best, Mahvash

Note that while COMSOL employees may participate in the discussion forum, COMSOL® software users who are on-subscription should submit their questions via the Support Center for a more comprehensive response from the Technical Support team.