2.1. Activating Parallel Processing in a Shared-Memory Architecture

  1. By default, SMP processing uses four cores and does not require any HPC licenses. Additional HPC licenses are required to run with more than four cores. Several HPC license options are available. See HPC Licensing for more information.

  2. Open the Mechanical APDL Product Launcher:

    Windows:

    Start >Programs >Ansys 2024 R2 >Mechanical APDL Product Launcher

    Linux:
    launcher242
  3. Select the correct environment and license.

  4. Go to the High Performance Computing Setup tab. Select Use Shared-Memory Parallel (SMP). Specify the number of threads (or CPU cores) to use.

  5. Alternatively, you can specify the number of cores to use via the -np command line option:

    ansys242 -smp -np N

    where N represents the number of threads (or CPU cores) to use. For a general discussion on processes, threads, and cores in parallel processing, see Specifying Processes, Threads, and Cores in SMP, DMP, and Hybrid Parallel in the overview section.

    For large multiprocessor servers, Ansys, Inc. recommends setting N to a value no higher than the number of available cores minus one. For example, on an eight-core system, set N to 7. However, on multiprocessor workstations, you may want to use all available cores to minimize the total solution time. The program automatically limits the maximum number of cores used to be less than or equal to the number of physical cores on the machine. This is done to avoid running the program on virtual cores (for example, by means of hyperthreading), which typically results in poor per-core performance. For optimal performance, consider closing down all other applications before launching Ansys.

    If you have more than one HPC license feature, you can use the -ppf command line option to specify which HPC license to use for the parallel run. See HPC Licensing for more information.

  6. If working from the launcher, click Run to launch Ansys.

  7. Set up and run your analysis as you normally would.

2.1.1. System-Specific Considerations

For shared-memory parallel processing, the number of cores that the program uses is limited to the lesser of one of the following:

  • The number of Ansys HPC licenses available (plus the first four cores which do not require any licenses)

  • The number of cores indicated via the -np command line argument

  • The actual number of cores available

You can specify multiple settings for the number of cores to use during a session. However, Ansys, Inc. recommends that you issue the /CLEAR command before resetting the number of cores for subsequent analyses.