Return the progress of simulation.
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| class(time_object), | intent(in) | :: | self | Time object. |
Actual progress value.
elemental function progress(self) result(prog)
!< Return the progress of simulation.
class(time_object), intent(in) :: self !< Time object.
real(R8P) :: prog !< Actual progress value.
if (self%n_max>0) then
prog = self%n*100/(self%n_max*1._R8P)
elseif (self%t_max>0._R8P) then
prog = 100*self%t/self%t_max
else
prog = 0._R8P
endif
endfunction progress