Checkpoint V5.11 shell redesign baseline
This commit is contained in:
@@ -402,20 +402,6 @@ contains
|
||||
integer :: unit_id
|
||||
integer :: ios
|
||||
integer :: pair
|
||||
integer :: active
|
||||
real(rk) :: max_pen
|
||||
real(rk) :: force_sum
|
||||
real(rk) :: work_sum
|
||||
integer :: search_facets
|
||||
integer :: search_masters
|
||||
integer :: search_broad
|
||||
integer :: search_active
|
||||
integer :: search_bvh_nodes
|
||||
real(rk) :: search_time
|
||||
real(rk) :: force_time
|
||||
real(rk) :: tangent_time
|
||||
integer :: cache_used
|
||||
integer :: cache_overflow
|
||||
|
||||
if (ncontact_plane .le. 0 .and. ncontact_pair .le. 0) then
|
||||
ierr = FEM_SUCCESS
|
||||
@@ -431,11 +417,26 @@ contains
|
||||
return
|
||||
end if
|
||||
|
||||
call contact_get_search_stats(search_facets, search_masters, &
|
||||
search_broad, search_active, &
|
||||
search_bvh_nodes)
|
||||
call contact_get_perf_stats(search_time, force_time, tangent_time)
|
||||
call contact_get_cache_stats(cache_used, cache_overflow)
|
||||
call output_csv_contact_header(unit_id, ierr)
|
||||
if (ierr .ne. FEM_SUCCESS) go to 900
|
||||
call output_csv_contact_summary(unit_id, ierr)
|
||||
if (ierr .ne. FEM_SUCCESS) go to 900
|
||||
|
||||
do pair = 1, ncontact_pair
|
||||
call output_csv_contact_pair(unit_id, pair, ierr)
|
||||
if (ierr .ne. FEM_SUCCESS) go to 900
|
||||
end do
|
||||
|
||||
900 continue
|
||||
close(unit_id)
|
||||
if (ierr .ne. FEM_SUCCESS) return
|
||||
ierr = FEM_SUCCESS
|
||||
end subroutine output_csv_write_contact
|
||||
|
||||
subroutine output_csv_contact_header(unit_id, ierr)
|
||||
integer, intent(in) :: unit_id
|
||||
integer, intent(out) :: ierr
|
||||
integer :: ios
|
||||
|
||||
write(unit_id,'(A)',iostat=ios) &
|
||||
'kind,pair_id,active_count,max_penetration,force_norm,work_estimate,'// &
|
||||
@@ -447,11 +448,25 @@ contains
|
||||
'search_cpu_time,contact_force_cpu_time,'// &
|
||||
'contact_tangent_cpu_time'
|
||||
if (ios .ne. 0) then
|
||||
close(unit_id)
|
||||
call error_set(FEM_ERR_OUTPUT, 'failed to write contact CSV header', ierr)
|
||||
return
|
||||
end if
|
||||
ierr = FEM_SUCCESS
|
||||
end subroutine output_csv_contact_header
|
||||
|
||||
subroutine output_csv_contact_summary(unit_id, ierr)
|
||||
integer, intent(in) :: unit_id
|
||||
integer, intent(out) :: ierr
|
||||
integer :: search_facets, search_masters, search_broad, search_active
|
||||
integer :: search_bvh_nodes, cache_used, cache_overflow
|
||||
real(rk) :: search_time, force_time, tangent_time
|
||||
integer :: ios
|
||||
|
||||
call contact_get_search_stats(search_facets, search_masters, &
|
||||
search_broad, search_active, &
|
||||
search_bvh_nodes)
|
||||
call contact_get_perf_stats(search_time, force_time, tangent_time)
|
||||
call contact_get_cache_stats(cache_used, cache_overflow)
|
||||
write(unit_id,'(A,A,I12,A,I12,4(A,ES24.16),2(A,I12),'// &
|
||||
'7(A,ES24.16),3(A,I12),3(A,ES24.16),7(A,I12),'// &
|
||||
'3(A,ES24.16))',iostat=ios) &
|
||||
@@ -466,58 +481,65 @@ contains
|
||||
',', search_active, ',', search_bvh_nodes, ',', cache_used, &
|
||||
',', cache_overflow, ',', search_time, ',', force_time, ',', tangent_time
|
||||
if (ios .ne. 0) then
|
||||
close(unit_id)
|
||||
call error_set(FEM_ERR_OUTPUT, 'failed to write contact CSV summary row', ierr)
|
||||
return
|
||||
end if
|
||||
|
||||
do pair = 1, ncontact_pair
|
||||
active = 0
|
||||
max_pen = ZERO
|
||||
force_sum = ZERO
|
||||
work_sum = ZERO
|
||||
if (allocated(contact_pair_active)) active = contact_pair_active(pair)
|
||||
if (allocated(contact_pair_max_penetration)) then
|
||||
max_pen = contact_pair_max_penetration(pair)
|
||||
end if
|
||||
if (allocated(contact_pair_force_norm)) force_sum = contact_pair_force_norm(pair)
|
||||
if (allocated(contact_pair_work)) work_sum = contact_pair_work(pair)
|
||||
call contact_get_pair_stats(pair, search_facets, search_masters, &
|
||||
search_broad, search_active, search_bvh_nodes, cache_used, &
|
||||
cache_overflow, search_time, force_time, tangent_time)
|
||||
|
||||
write(unit_id,'(A,A,I12,A,I12,4(A,ES24.16),2(A,I12),'// &
|
||||
'7(A,ES24.16),3(A,I12),3(A,ES24.16),7(A,I12),'// &
|
||||
'3(A,ES24.16))',iostat=ios) &
|
||||
'PAIR', ',', pair, ',', active, ',', max_pen, ',', force_sum, &
|
||||
',', work_sum, ',', ZERO, &
|
||||
',', contact_pair_stick_value(pair), ',', contact_pair_slip_value(pair), &
|
||||
',', contact_pair_accumulated_slip(pair), &
|
||||
',', contact_pair_fric_work_value(pair), &
|
||||
',', contact_pair_fric_total_value(pair), &
|
||||
',', contact_pair_fric_reg_value(pair), &
|
||||
',', contact_pair_tangent_component(pair, 1), &
|
||||
',', contact_pair_tangent_component(pair, 2), &
|
||||
',', contact_pair_tangent_component(pair, 3), &
|
||||
',', contact_pair_status_value(pair), &
|
||||
',', contact_pair_activation_value(pair), &
|
||||
',', contact_pair_release_value(pair), &
|
||||
',', contact_pair_gap_value(pair), &
|
||||
',', contact_pair_aug_factor_value(pair), &
|
||||
',', contact_pair_aug_lambda_value(pair), &
|
||||
',', search_facets, ',', search_masters, ',', search_broad, &
|
||||
',', search_active, ',', search_bvh_nodes, ',', cache_used, &
|
||||
',', cache_overflow, ',', search_time, ',', force_time, ',', tangent_time
|
||||
if (ios .ne. 0) then
|
||||
close(unit_id)
|
||||
call error_set(FEM_ERR_OUTPUT, 'failed to write contact CSV pair row', ierr)
|
||||
return
|
||||
end if
|
||||
end do
|
||||
|
||||
close(unit_id)
|
||||
ierr = FEM_SUCCESS
|
||||
end subroutine output_csv_write_contact
|
||||
end subroutine output_csv_contact_summary
|
||||
|
||||
subroutine output_csv_contact_pair(unit_id, pair, ierr)
|
||||
integer, intent(in) :: unit_id
|
||||
integer, intent(in) :: pair
|
||||
integer, intent(out) :: ierr
|
||||
integer :: active
|
||||
integer :: search_facets, search_masters, search_broad, search_active
|
||||
integer :: search_bvh_nodes, cache_used, cache_overflow
|
||||
real(rk) :: max_pen, force_sum, work_sum
|
||||
real(rk) :: search_time, force_time, tangent_time
|
||||
integer :: ios
|
||||
|
||||
active = 0
|
||||
max_pen = ZERO
|
||||
force_sum = ZERO
|
||||
work_sum = ZERO
|
||||
if (allocated(contact_pair_active)) active = contact_pair_active(pair)
|
||||
if (allocated(contact_pair_max_penetration)) then
|
||||
max_pen = contact_pair_max_penetration(pair)
|
||||
end if
|
||||
if (allocated(contact_pair_force_norm)) force_sum = contact_pair_force_norm(pair)
|
||||
if (allocated(contact_pair_work)) work_sum = contact_pair_work(pair)
|
||||
call contact_get_pair_stats(pair, search_facets, search_masters, &
|
||||
search_broad, search_active, search_bvh_nodes, cache_used, &
|
||||
cache_overflow, search_time, force_time, tangent_time)
|
||||
|
||||
write(unit_id,'(A,A,I12,A,I12,4(A,ES24.16),2(A,I12),'// &
|
||||
'7(A,ES24.16),3(A,I12),3(A,ES24.16),7(A,I12),'// &
|
||||
'3(A,ES24.16))',iostat=ios) &
|
||||
'PAIR', ',', pair, ',', active, ',', max_pen, ',', force_sum, &
|
||||
',', work_sum, ',', ZERO, &
|
||||
',', contact_pair_stick_value(pair), ',', contact_pair_slip_value(pair), &
|
||||
',', contact_pair_accumulated_slip(pair), &
|
||||
',', contact_pair_fric_work_value(pair), &
|
||||
',', contact_pair_fric_total_value(pair), &
|
||||
',', contact_pair_fric_reg_value(pair), &
|
||||
',', contact_pair_tangent_component(pair, 1), &
|
||||
',', contact_pair_tangent_component(pair, 2), &
|
||||
',', contact_pair_tangent_component(pair, 3), &
|
||||
',', contact_pair_status_value(pair), &
|
||||
',', contact_pair_activation_value(pair), &
|
||||
',', contact_pair_release_value(pair), &
|
||||
',', contact_pair_gap_value(pair), &
|
||||
',', contact_pair_aug_factor_value(pair), &
|
||||
',', contact_pair_aug_lambda_value(pair), &
|
||||
',', search_facets, ',', search_masters, ',', search_broad, &
|
||||
',', search_active, ',', search_bvh_nodes, ',', cache_used, &
|
||||
',', cache_overflow, ',', search_time, ',', force_time, ',', tangent_time
|
||||
if (ios .ne. 0) then
|
||||
call error_set(FEM_ERR_OUTPUT, 'failed to write contact CSV pair row', ierr)
|
||||
return
|
||||
end if
|
||||
ierr = FEM_SUCCESS
|
||||
end subroutine output_csv_contact_pair
|
||||
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user