Integrate water explicit stepping and dt limits

This commit is contained in:
Codex
2026-07-02 20:52:05 +08:00
parent 662129d2bb
commit 4809701068
10 changed files with 226 additions and 33 deletions
+5 -1
View File
@@ -462,10 +462,12 @@ contains
real(rk) :: dt
real(rk) :: total_time
integer :: steps
real(rk) :: safety
dt = -1.0_rk
total_time = -1.0_rk
steps = -1
safety = -1.0_rk
call sph_inp_split_csv(line, fields, nfields)
do i = 1, nfields
item = adjustl(fields(i))
@@ -479,9 +481,11 @@ contains
read(value, *, iostat=ios) total_time
else if (index(key, 'STEPS') == 1 .or. index(key, 'MAX STEPS') == 1) then
read(value, *, iostat=ios) steps
else if (index(key, 'SAFETY') == 1) then
read(value, *, iostat=ios) safety
end if
end do
call sph_control_set_time(dt, total_time, steps)
call sph_control_set_time(dt, total_time, steps, safety)
end subroutine sph_input_parse_time_control
subroutine sph_input_parse_node(line, node_index, ierr)