pywfm.IWFMModel.get_subregion_ids#

IWFMModel.get_subregion_ids()#

Return an array of IDs for subregions identified in an IWFM model

Returns:

array containing integer IDs for the subregions specified in the IWFM model

Return type:

np.ndarray

Note

The resulting integer array will have a length equal to the value returned by the get_n_subregions method

See also

IWFMModel.get_n_subregions

Return the number of subregions in an IWFM model

IWFMModel.get_subregion_name

Return the name corresponding to the subregion_id in an IWFM model

IWFMModel.get_subregions_by_element

Example

>>> from pywfm import IWFMModel
>>> pp_file = '../Preprocessor/PreProcessor_MAIN.IN'
>>> sim_file = 'Simulation_MAIN.IN'
>>> model = IWFMModel(pp_file, sim_file)
>>> model.get_subregion_ids()
array([1, 2])
>>> model.kill()
>>> model.close_log_file()