diff --git a/doc/source/user_guide/launcher.rst b/doc/source/user_guide/launcher.rst index f036cc995f..56b2c8cf1b 100644 --- a/doc/source/user_guide/launcher.rst +++ b/doc/source/user_guide/launcher.rst @@ -10,7 +10,7 @@ the :func:`launch_mapdl() `: .. code:: python - from ansys.mapdl import launch_mapdl + from ansys.mapdl.core import launch_mapdl mapdl = launch_mapdl() Python will automatically attempt to detect your MAPDL binary based on @@ -38,6 +38,35 @@ the path again. If you need to change the default ansys path Also see :func:`change_default_ansys_path() ` and :func:`find_ansys() `. +Additionally, it is possible to specify the executable using the keyword argument ``exec_file``. +In Linux: + +.. code:: python + + from ansys.mapdl.core import launch_mapdl + + mapdl = launch_mapdl(exec_file='/usr/ansys_inc/v212/ansys/bin/ansys212') + + +And in Windows: + +.. code:: python + + from ansys.mapdl.core import launch_mapdl + + mapdl = launch_mapdl(exec_file='C://Program Files//ANSYS Inc//v212//ANSYS//bin//winx64//ansys212.exe') + +You could also specify a custom executable by adding the correspondent flag (``-custom``) to the additional switches keyword argument. + +.. code:: python + + from ansys.mapdl.core import launch_mapdl + + custom_exec = '/usr/ansys_inc/v212/ansys/bin/ansys212t' + add_switch = f" -custom {custom_exec}" + mapdl = launch_mapdl(additional_switches=add_switch) + + API Reference ~~~~~~~~~~~~~