rvesimulator.abaqus2py¶
rvesimulator.abaqus2py.abaqus_simulator¶
Module for calling abaqus simulation and post processing
- class AbaqusSimulator(sim_info, folder_info)[source]¶
Bases:
Simulator
,AssertInputs
Abaqus simulator
- Parameters:
Simulator (class) – simulator interface
AssertInputs (class) – assert inputs
Examples
>>> from rvesimulator.abaqus2py.simulator_interface import AbaqusSimulator >>> sim_info = {} >>> folder_info = {} >>> simulator = AbaqusSimulator(sim_info=sim_info, folder_info=folder_info) >>> simulator.run() >>> simulator.read_back_results()
initialization of abaqus simulator class
- Parameters:
- _run_abaqus_simulation(command, max_time=inf, sleep_time=20.0, refresh_time=5.0)[source]¶
run abaqus simulation
- Parameters:
- Returns:
simulation status
- Return type:
- Raises:
NotImplementedError – platform not be implemented
- execute(max_time=inf, sleep_time=20.0, refresh_time=5.0)[source]¶
execute the abaqus simulation
- Parameters:
max_time (float, optional) – maximum simulation time, kill the simulation when time reaches the given maximum simulation time, by default inf
sleep_time (float, optional) – sleep time, let abaqus run for 20s first, by default 20.0
refresh_time (float, optional) – detect if the simulation is finished or not every given refresh time, by default 5.0
- Returns:
simulation status
- Return type:
- make_new_script(file_name, status='simulation')[source]¶
make a small python script for running abaqus
rvesimulator.abaqus2py.simulator_interface¶
Abstract class for a FEM simulator and assert inputs
- class AssertInputs[source]¶
Bases:
object
- classmethod is_cwd_in_folder_info(folder_info)[source]¶
assert current_work_directory in folder_info dict
- classmethod is_inputs_proper_defined(folder_info, sim_info)[source]¶
assert inputs are properly defined
- Return type:
- classmethod is_mwd_in_folder_info(folder_info)[source]¶
assert main_work_directory in folder_info dict
- classmethod is_post_script_in_folder_info(folder_info)[source]¶
assert post script in the folder_info dict
- classmethod is_script_path_in_folder_info(folder_info)[source]¶
assert script_path in folder_info dict
rvesimulator.abaqus2py.utils¶
Functions for general use for abaqus2py module