ANSYS Batch Tutorial

This tutorial will introduce you to submitting ANSYS jobs in batch to the Rescale platform. We will create an input file from the respective ANSYS software, start a Rescale job, submit, and transfer the results back to ANSYS.

Pre-processing activities (e.g. geometry, mesh/model) are already completed and all solver and setup settings are already determined as well. Unlike job submission through RSM, you do not need to launch Rescale Desktops. You can use your own ANSYS software and license or reach out to us and purchase some Elastic License Units (ELUs).

Important: ANSYS Workbench converts all input data into one unit system. To avoid any confusing conversions, specify a consistent unit system throughout your workflow (e.g. Geometry, Engineering data).

In this section, we will solve an ANSYS Fluent job in batch. To obtain the files needed to follow this tutorial, click on the "Job Setup" link below and clone the job hosting the file. Next, click "Save" on the job to have a copy of the files in your Rescale cloud files.

Import Job Setup Get Job Results

The input files are:

tjunction_plot.cas.gz - Compressed Case File

run_plot.jou - Journal File

Creating Case and Journal files

The tutorial example is a T-junction of two fluids at different temperatures using ANSYS Fluent version 18. The case file tjunction_plot.cas.gz is already available to you. The steps involved to create a case file are:

  • On Fluent, go to the File tab, then select Export > Case..., and this will open a window browser

  • Name the file with a .cas or .cas.gz extension and select the location where this file will be exported to.

This file contains all pre-processing settings, and solver and physics setup that have been configured in the GUI, as per your standard workflow.

Fluent Export Case File

You will also need a journal file which contains all the necessary commands that you would like to execute using Fluent during a batch run. The journal file run_plot.jou is already available to you. The steps involved to create a journal file are:

  • On a Windows Explorer window, right mouse click > New > Text Document (or similar for other OS).

  • Give the file a name, with extension .jou. Accept the change to file extension.

  • Double-click the file to open it and enter the journal commands, then save the file.

The journal file will look like this:

/file/read-case tjunction_plot.cas
/file/set-batch-options no yes yes no
/solve/initialize/initialize/
/solve/iterate 500
/file/write-case-data tjunction_plot%i.cas.gz
/exit yes

The journal file shown above reads the case file, sets the batch options, initializes, runs the calculation for 500 iterations, and finally writes a case and a data file when the solution has converged to a prescribed limit.

This file is written using the ANSYS FLuent Text User Interface (TUI). For more information about using specific text interface commands, please refer to ANSYS Online Documentation here.

Rescale Job Setup

After obtaining the necessary ANSYS Fluent files, we will now submit a Basic job on Rescale. For more information on launching a basic job, please refer to the tutorial here.

Setup: Input File(s)

  • Go onto the Rescale plaftorm, click on + New Job on the top left. Name your job and make sure the Job Type is set to Basic.

  • Next upload the journal and case files as input files.

Fluent Input Files

Setup: Software Settings

Click Next to move onto the Software Settings section of the setup.

  • You can scroll down or use the search bar to select ANSYS Fluent. The Analysis Options will display and select version 18.0.

  • In the command window, you will need to specify the journal file name under the angle bracket <journal filnename>. We would also like to see the solution residual. To do this, we command to keep the graphics windows using the -gu option.

  • Next under Licensing Options, select Use Existing License and enter your ANSYS server connection port numbers under License and ANSYS License Interconnect respectively.

For this tutorial, the software settings page will look as shown below.

Fluent Software Settings

Setup: Hardware Settings

The next step is to select the desired hardware for the job. Click on the Hardware Settings icon.

  • Select your desired core type and the numbers of cores that you want to use for this job. For this tutorial, select Onyx and 4 cores.

Your Hardware Settings screen screen should look like this:

Fluent Hardware Settings

Setup: Review

There are no post-processing settings in this tutorial. Click on the Review icon. Check that the setup is correct by reviewing the Basic Job Summary table. It should look like this:

Fluent Job Review

Job Submission and Monitor

Once you have reviewed your setup, you are ready to submit your job. Click Submit and you will move on from the Setup page to the Status page in the Rescale platform. Here, you will be able to monitor the job progress in a gantt chart like format, see a date and time stamped log and live-tail the status and output of your job using the Live-tail window. A guide on "Monitoring Status" on Rescale is found here.

Fluent live tailing example

In this example, we have configured the simulation to output a residual plot at every iteration, which will show up under the Live Tailing window as a residual.jpeg file. You can open this graph at any time to monitor the progress of the solution's convergence.

Fluent Simulation Residual

Downloading Results

Once the job is completed, you can select the file(s) that you wish to download. If you have large output files, it is recommended that you use Rescale Transfer Manager (RTM) to download files faster onto your on-premise workstation. More information about RTM can be found here.

For this simulation, the solution is expected to converge at 245 iterations. To obtain the final data file, do the following:

  • Go to the results page of the completed job, find and select the tjunction_plot0245.dat.gz.

  • Go to Actions and click on Download selected files, give it a few seconds for it download to your computer.

Fluent Download Results

  • You can now go back to Fluent, go to the File tab, then select Import > Data..., to load the solution data file.

Fluent Import Data

At this point, you may now proceed to your post-processing activities as you would normally do after solving an Ansys Fluent simulation interactively.

Fluent contour result

The focus in this section is on ANSYS Mechanica1 18.0 systems such as Linear Perturbation Eigenvalue Buckling. To obtain the Workbench project file (.wbpz), click on the "Import Workbench project" link below and clone the job hosting the file. Next, click "save" on the job to have a copy of this file in your Rescale cloud files.

Import Workbench Project Import Job Setup Get Job Results

Creating input file from Workbench

Make sure the status of all pre-processing cells are complete (green check marks). The example model is a 15-foot long tapered I-beam made of steel. It's fixed at the larger end and a 200-lb force is applied at the smaller end. The analysis consists of a static structural system (for pre-stress) and an eigenvalue buckling system (for linear buckling).

Workbench Component System

  • First, we need to solve System A. We open the setup cell A5 (ANSYS Mechanical) and once all definitions are completed, highlight the Solution (A6) state in the tree on the left, then go to Tools < Write Input File...

Mechanical GUI Input File

  • You will be prompted to a "Save as" window. Choose the appropriate file name and directory. For this example, we name it: input_batch.dat

Rescale job submission

  • Go onto the Rescale platform, start and name a new job, and upload the input file that you generated from Workbench. For this example, configure the software settings by selecting Ansys Mechanical version 18.0. For more information on launching a basic job, please refer to the tutorial here.

  • Under the command window, you will need to specify the input file name under the angle bracket <input-file>. In this tutorial, the command will be as shown below.

Job Submission sofware setting

  • Specify your license option, and move onto hardware settings. This example will be run on 4 Onyx cores. There is no post-processing options here.

  • Submit your job, and feel free to monitor the status of your job and get information about your cluster in real-time. A guide on "Monitoring Status" on Rescale is found here.

Download and read results back into Workbench

Once the job is completed, it is highly recommended to use our Rescale Transfer Manager (available on Windows OS only) to download output files. It is much faster than downloading through the browser. To install and learn to use the Rescale Transfer Manager, you can read here.

  • Go to the job results page, click "Download with Rescale Transfer Manager". If a warning message pops up, click on "Open Rescale.TransferClient.UI"

  • A "Browse for folder" window will open, select a destination where you want to save the job results and click ok. It will download and wait until the status shows "Complete". The files will be saved into a folder named after the job.

RST Download Results

  • You can now go back to Workbench, hightlight the Solution (A6) state on the tree on the left, then go to Tools <Read Result Files...

Mechanical GUI Read Results

  • An "open" window will display. Find the directory you specified earlier. This example is a Rescale Basic job and the output files will be under the "run1" folder. Select the "file.rst" file and click open. Wait for the results to completely load into ANSYS Mechanical. One way to verify this is to look at the tree and the Solution (A6) state should appear "green check marked".

Mechanical GUI Open Results

Important: You must preserve the directory where the .rst and all other result files are located. Failure to do so may result in files not loading on Workbench.

  • At this point, you may now proceed to your post-processing activities as you would normally do after solving an Ansys Mechanical simulation in the Workbench GUI.

Special case: Multiple analysis in batch mode

Import Job Setup Get Job Results

In several cases, the analysis may consist of more than one system therefore an input file must be generated for each. In this example, system A is a base analysis. We are interested in finding the critical load of the beam under buckling. To continue, we need a second input file in System B plus the restart files from System A. Refer to ANSYS documentation for more information about multiframe restart and APDL.

  • Open ANSYS Mechanical on system B (B5 cell), and follow the same worflow again with the difference that we hightlight the Solution (B6) state instead to write a second input file

  • Start a new job and upload this new input file. For this Linear Perturbation example, we also have to upload the .Rnn, .rdb, and .ldhi restart files from the base analysis.

Multiple Analysis in Batch

  • The rest of the workflow is the same again. Make sure to hightlight the Solution (B6) state to read the new result file.

The simulation in this example calculated a load multiplier of 4.709. Since we applied 500 lbs of force, this means that the critical buckling load is 2355 lbs of force.

Mechanical GUI Buckling Profile