run#
- Mapdl.run(command, write_to_log=True, mute=None, **kwargs)#
Run single APDL command.
For multiple commands, use
Mapdl.input_strings()
.- Parameters:
- Returns:
str
Command output from MAPDL.
- Return type:
Notes
Running non-interactive commands
When two or more commands need to be run non-interactively (i.e.
*VWRITE
) use>>> with mapdl.non_interactive: ... mapdl.run("*VWRITE,LABEL(1),VALUE(1,1),VALUE(1,2),VALUE(1,3)") ... mapdl.run("(1X,A8,' ',F10.1,' ',F10.1,' ',1F5.3)")
Alternatively, you can simply run a block of commands with:
>>> mapdl.input_strings(cmd)
Examples
>>> mapdl.run('/PREP7')
Equivalent Pythonic method:
>>> mapdl.prep7()