Ansys¶
What is Ansys?¶
Ansys is a comprehensive finite element analysis (FEA) and computational fluid dynamics (CFD) software suite for engineering simulation. It provides tools for structural mechanics, thermal analysis, fluid dynamics, electromagnetics, and multiphysics problems across various industries.
Base Environment
Ansys is provided via the environment modules system.
Available Tools¶
| Tool | Description |
|---|---|
| MAPDL | Mechanical APDL - structural FEA solver with CPU and GPU support |
| CFX | CFD solver for fluid dynamics (CPU only) |
| Workbench | Unified GUI interface for all Ansys tools |
| LS-DYNA | Explicit dynamics for crash and impact simulation |
| Aqwa | Marine and offshore hydrodynamics analysis |
| Autodyn | Explicit dynamics solver |
| ACP | Composite materials analysis |
Typical HPC Workflow¶
Ansys simulations on HPC follow a three-stage workflow:
-
Pre-processing (Local workstation recommended)
- Create geometry
- Generate mesh
- Define physics and boundary conditions
- Export solver input files (
.inp,.def, etc.)
-
Solving (HPC cluster)
- Upload input files to PERUN
- Submit batch jobs to CPU or GPU partitions
- Let solvers run on high-performance hardware
-
Post-processing (Local workstation recommended)
- Download result files from HPC
- Visualize and analyze in appropriate post-processor
Why Local GUI?
Using Ansys GUI locally provides:
- Better performance (no network lag)
- No internet connection required
- Full graphics acceleration
- Easier file management
Only the computationally expensive solver stage runs on HPC.
GUI Access via Workbench¶
Alternative: Remote GUI
You can use Workbench GUI on PERUN with X11 forwarding, but this is not recommended for regular use.
X11 Setup
- Windows: Use MobaXterm (X11 automatic)
- macOS:
ssh -X username@login01.perun.tuke.sk(requires XQuartz) - Linux:
ssh -X username@login01.perun.tuke.sk
Loading Ansys¶
Available executables
After loading, these commands become available:
Getting Help for Solvers¶
Command-line help
Most Ansys solvers provide help through the -h or --help flag:
Common MAPDL parameters
Key parameters for MAPDL:
-b: Batch mode (no GUI)-i <file>: Input file-o <file>: Output file-np <N>: Number of processors (must match SLURM--ntasks)-acc nvidia: Enable GPU acceleration-na <N>: Number of GPUs to use
Example: MAPDL Structural Analysis¶
Input File¶
simple_test.inp
Simple structural analysis
SLURM Job Script (CPU)¶
mapdl_cpu.sh
CPU parallel execution
Critical: Match ntasks and -np
The -np value must exactly match --ntasks:
SLURM Job Script (GPU)¶
mapdl_gpu.sh
GPU accelerated execution
Output Files¶
Solver-dependent output
Output file formats and names depend on the solver used. The files listed below are specific to MAPDL.
| File | Description |
|---|---|
*.rst |
Results file - contains solution data |
*.db |
Database file - contains model definition |
*.full |
Full file - complete model and results |
*.log |
Log file - execution details |
File Transfer¶
Using WinSCP (Windows)
Use WinSCP to transfer files with a graphical interface:
- Connect to
PERUN - Drag and drop files between local and remote
Using command line
Upload input files:
Download results: