I think, i found a bug in main3d. When i run the model (revision 737) in coupling mode (coupled with atmospheric model) the model is not run correctly. For example, if i set coupling interval as 1-hour the model runs 30 step (in my case dt = 120 s) for first 1-hour but after that it runs until end time and it does not stop in next 1-hour. I check the code and add following statement to it just before reading required data
Code: Select all
IF (tile == 0) then
PRINT*, Time_Step, step_counter(ng), Rsteps, RunInterval
END IF
First iteration (1-hour) - F 30 30 3480.00000000000
Second iteration (1-hour) - T 60 30 3480.00000000000
I think that following statement is wrong,
Code: Select all
IF (step_counter(ng).eq.Rsteps) Time_Step=.FALSE.
Code: Select all
IF (MOD(step_counter(ng),Rsteps).eq.0) Time_Step=.FALSE.
PS: If you use the model in standalone mode, probably you won't see any problem.
Regards,
--ufuk