Model.hm_getelementcheckmethod#
- Model.hm_getelementcheckmethod(check_name, get_method_mode=2)#
Returns the ID of the method (solver) used to calculate the specified element quality check. For element quality check parameters, their meanings and allowable values, see the
Model.elementchecksettings()function.- Parameters:
check_name (hwString) – Specifies the element quality check parameter to query. Valid values are angle, aspect_2d, aspect_3d, cell_squish_2d, cell_squish_3d, chord_dev, equi_skew_2d, equi_skew_3d, jacobian_2d jacobian_3d, min_len_2d, min_len_3d, ortho_3d, size_ratio_3d, skew_2d, skew_3d, solver, taper, tetra_collapse, time_step, warpage.
get_method_mode (int) –
An optional parameter specifying the mode of retrieving of the returned method. Valid values are:
0 - Returns the method stored globally, regardless of global or individual solver mode.
1 - Return the method specified by the global solver (if an individual solver mode is not being used).
2 - Return the actual method used in calculations. This is the default value.
- Returns:
hwReturnStatus- Status objectHmQueryResult- Result object containing the output values:calculationMethod (int)
Examples#
Retrieve the method currently be used for calculation of the aspect ratio for 2D elements#import hm import hm.entities as ent model = hm.Model() _, result = model.hm_getelementcheckmethod(check_name="aspect_2d") aspect2dmethod = result.calculationMethod print("Aspect 2d method:", aspect2dmethod)
Retrieve the method currently be used for calculation of the Jacobian for 2D elements#import hm import hm.entities as ent model = hm.Model() _, result = model.hm_getelementcheckmethod(check_name="jacobian_2d") jacobian_method = result.calculationMethod print("Jacobian method:", jacobian_method)