/
ansys fluent

ansys fluent

Introduction


Usage



module load ansys/2024R1
(version 241)
Old ones: module load ansys/v212 , module load ansys/v195 OR module load ansys/v202

To get a list of all versions: module avail ansys



Installation


Sample PBS script

# This is an example of PBS script file for ansys
#PBS -N FluentTest
#PBS -m e
#PBS -M yourEmail@griffith.edu.au
# specifies number of CPUs (ncpus) used in PBS
#PBS -l select=1:ncpus=1:mem=10g,walltime=24:00:00

# specifies the job name, input file and output file
jobname=MyAnsysRun
jobInput=/sw/ansys/2022R2/v222/ansys/data/models/casting.inp
###jobOutput=/export/home/s123456/pbs/output/ansysOUTput.txt
# specifies working directory
work_dir=/export/home/s123456/pbs/workdir
## sets up the anys environment
module load ansys/v202
module load intel/intelmpi
module list
# starts simulation
cd $work_dir
#Must be set to INTELMPI or OPENMPI
###ansys161 -b -p aa_r -j $jobname -I $jobInput -o $jobOutput -np 4
ansys161 -b -mpi=INTELMPI -p infiniband aa_r -j $jobname -I $jobInput  -np 4

Special Notes

We recommend using infiniband for interconnect and intel mpi. You may use the following options in the pbs script
module load intel/intelmpi
-p infiniband
-mpi=intel


Another sample pbs script

#!/bin/bash
#PBS -N floor01M1052
#PBS -m bea
#PBS -M YOUREMAILID@griffithuni.edu.au
# specifies number of CPUs (ncpus) used in PBS
#PBS -l select=1:ncpus=16:mem=48g,walltime=300:00:00
#######################################################
# setup variables for names
#######################################################
jobnam=$PBS_JOBNAME
jobloc=/lscratch/s123456/$jobnam
inputfile="${jobnam}.in"
casefile=${jobnam%??}
casefile1="${casefile}.cas.gz"
resulttext="${jobnam}.txt"
resultcas="${jobnam}result.cas.gz"
resultdat="${jobnam}result.dat.gz"
runfile="${jobnam}.run"
#######################################################
# Check if scratch dir exists and create if not
#######################################################
jobloc=/lscratch/s123456/$jobnam
if [ ! -d "jobloc" ]; then
        mkdir $jobloc
fi
#######################################################
# load modules
#######################################################
module load ansys/v202
module load intel/intelmpi
#######################################################
# copy case file and input file to scratch
#######################################################
cp $PBS_O_WORKDIR/$inputfile $jobloc
cp $PBS_O_WORKDIR/$casefile1 $jobloc
echo copy to scratch complete
#######################################################
# run fluent
#######################################################
echo running fluent
cd $jobloc
fluent 3ddp -t16 -cflush -pinfiniband -mpi=intel -g -i $inputfile > $runfile
cd $PBS_O_WORKDIR
#######################################################
# copy result files back to working directory
#######################################################
cp -r $jobloc/* $PBS_O_WORKDIR
#######################################################
# list output
#######################################################
echo $jobnam
echo $jobloc
echo $inputfile
echo $casefile
echo $resulttext
echo $resultcas
echo $resultdat
echo $runfile
echo job finished


Check available license


/sw/ansys/2020R2/shared_files/licensing/linx64/ansysli_util -statli 2325@gc-prd-erslic.corp.griffith.edu.au

/sw/ansys/2020R2/shared_files/licensing/linx64/ansysli_util -checkout FLUENT_SOLVER


Reference

  1. https://www.cityu.edu.hk/acim/facilities/pbs_submit.htm
  2. https://www.sharcnet.ca/Software/Fluent6/html/ug/node1232.htm#tab-unix-platforms
  3. https://confluence.cornell.edu/display/SIMULATION/Home