This commit is contained in:
@@ -30,6 +30,17 @@ int main(void)
|
||||
int max_face_nodes = 0;
|
||||
int step = 0;
|
||||
int active_contact = -1;
|
||||
int active_pair_count = -1;
|
||||
int activated_pair_count = -1;
|
||||
int maintained_pair_count = -1;
|
||||
int released_pair_count = -1;
|
||||
int contact_search_facets = -1;
|
||||
int contact_search_masters = -1;
|
||||
int contact_search_broad = -1;
|
||||
int contact_search_active = -1;
|
||||
int contact_search_bvh_nodes = -1;
|
||||
int contact_cache_used = -1;
|
||||
int contact_cache_overflow = -1;
|
||||
int node_ids[1] = {2};
|
||||
int facet_id[8];
|
||||
int elem_id[8];
|
||||
@@ -50,13 +61,25 @@ int main(void)
|
||||
double contact_work_total = -1.0;
|
||||
double contact_max_penetration = -1.0;
|
||||
double contact_force_norm = -1.0;
|
||||
double contact_gap_residual = -1.0;
|
||||
double contact_aug_lambda = -1.0;
|
||||
double contact_friction_work_step = -1.0;
|
||||
double contact_friction_work_total = -1.0;
|
||||
double contact_max_slip = -1.0;
|
||||
int contact_history_slots = -1;
|
||||
double max_slot_slip = -1.0;
|
||||
double max_slot_work = -1.0;
|
||||
double max_tangent_force = -1.0;
|
||||
double contact_search_time = -1.0;
|
||||
double contact_force_time = -1.0;
|
||||
double contact_tangent_time = -1.0;
|
||||
|
||||
ierr = femlite_initialize();
|
||||
if (ierr != 0) return check_ierr(ierr, 1);
|
||||
|
||||
ierr = femlite_get_version(&major, &minor, &patch);
|
||||
if (ierr != 0) return check_ierr(ierr, 2);
|
||||
if (major != 0 || minor != 4 || patch != 1) return 3;
|
||||
if (major != 0 || minor != 4 || patch != 3) return 3;
|
||||
|
||||
ierr = femlite_read_inp("examples/c3d4_one_element.inp");
|
||||
if (ierr != 0) return check_ierr(ierr, 4);
|
||||
@@ -76,6 +99,55 @@ int main(void)
|
||||
contact_work_total != 0.0 || contact_max_penetration != 0.0 ||
|
||||
contact_force_norm != 0.0) return 25;
|
||||
|
||||
ierr = femlite_get_contact_diagnostics(&active_pair_count,
|
||||
&activated_pair_count,
|
||||
&maintained_pair_count,
|
||||
&released_pair_count,
|
||||
&contact_gap_residual,
|
||||
&contact_aug_lambda);
|
||||
if (ierr != 0) return check_ierr(ierr, 26);
|
||||
if (active_pair_count != 0 || activated_pair_count != 0 ||
|
||||
maintained_pair_count != 0 || released_pair_count != 0 ||
|
||||
contact_gap_residual != 0.0 || contact_aug_lambda != 0.0) return 27;
|
||||
|
||||
ierr = femlite_get_contact_friction_summary(&contact_friction_work_step,
|
||||
&contact_friction_work_total,
|
||||
&contact_max_slip);
|
||||
if (ierr != 0) return check_ierr(ierr, 28);
|
||||
if (contact_friction_work_step != 0.0 ||
|
||||
contact_friction_work_total != 0.0 ||
|
||||
contact_max_slip != 0.0) return 29;
|
||||
|
||||
ierr = femlite_get_contact_history_stats(&contact_history_slots,
|
||||
&max_slot_slip,
|
||||
&max_slot_work,
|
||||
&max_tangent_force);
|
||||
if (ierr != 0) return check_ierr(ierr, 30);
|
||||
if (contact_history_slots != 0 || max_slot_slip != 0.0 ||
|
||||
max_slot_work != 0.0 || max_tangent_force != 0.0) return 31;
|
||||
|
||||
ierr = femlite_get_contact_search_stats(&contact_search_facets,
|
||||
&contact_search_masters,
|
||||
&contact_search_broad,
|
||||
&contact_search_active,
|
||||
&contact_search_bvh_nodes);
|
||||
if (ierr != 0) return check_ierr(ierr, 32);
|
||||
if (contact_search_facets != 0 || contact_search_masters != 0 ||
|
||||
contact_search_broad != 0 || contact_search_active != 0 ||
|
||||
contact_search_bvh_nodes != 0) return 33;
|
||||
|
||||
ierr = femlite_get_contact_perf_stats(&contact_search_time,
|
||||
&contact_force_time,
|
||||
&contact_tangent_time);
|
||||
if (ierr != 0) return check_ierr(ierr, 34);
|
||||
if (contact_search_time != 0.0 || contact_force_time != 0.0 ||
|
||||
contact_tangent_time != 0.0) return 35;
|
||||
|
||||
ierr = femlite_get_contact_cache_stats(&contact_cache_used,
|
||||
&contact_cache_overflow);
|
||||
if (ierr != 0) return check_ierr(ierr, 36);
|
||||
if (contact_cache_used != 0 || contact_cache_overflow != 0) return 37;
|
||||
|
||||
ierr = femlite_compute_lumped_mass();
|
||||
if (ierr != 0) return check_ierr(ierr, 8);
|
||||
ierr = femlite_estimate_stable_dt(&dtcrit);
|
||||
|
||||
Reference in New Issue
Block a user