init Subroutine

private subroutine init(self)

初始化时间积分器

Type Bound

time_integrator

Arguments

Type IntentOptional Attributes Name
class(time_integrator), intent(inout) :: self

Contents

Source Code


Source Code

    subroutine init(self)
        class(time_integrator), intent(inout) :: self

        self%dt = tic_obj%cfl*rgn_obj%hsml/spc_obj%c0
        dt = self%dt
        self%cur_time = 0.0_rk
        if (cli_obj%debug_mode) write (lgr_obj%unit, lgr_obj%fmt) 'dt', self%dt

        call display(pif_obj%numbers(4), 'number of total particles:', inline=.true.)
        call display(rgn_obj%hsml, 'smoothing length (m):', inline=.true.)
        call display(tic_obj%stop_time, 'simulation duration (sec):', inline=.true.)
        call display(self%dt, 'time step (sec):', inline=.true.)

    end subroutine init