Skip to content

Instantly share code, notes, and snippets.

@costerwi
Last active December 14, 2021 17:42
Show Gist options
  • Save costerwi/fa950295b779a3837d987407ba641d0f to your computer and use it in GitHub Desktop.
Save costerwi/fa950295b779a3837d987407ba641d0f to your computer and use it in GitHub Desktop.
Prerequisites for Abaqus user subroutines on Windows

Abaqus requires additional software to be installed on Windows in order to make use of custom User Subroutines. You will need both a C++ compiler and Fortran compiler. Only specific versions of these compilers are officially supported by Simulia for use with each version of Abaqus.

Abaqus 2021

C++ compiler

Microsoft Visual Studio 2017 (Visual C++) is a Qualified Platform.

Fortran compiler

Intel® Fortran Version 19.0.5 is a Qualified Platform. Versions higher than 19.0.5 are Compatible.

Intel Fortran Compiler 2021.3 has passed verification.

Microsoft MPI SDK

The MPI Software Development Kit (SDK) is normally required only for building user subroutines that utilize MPI based communication. If the SDK is needed but missing you may see compiler errors such as "Cannot open include file 'mpif.h'"

Accordng to MS-MPI upgrade issues with older releases Abaqus 2017 and later only install the Microsoft MPI runtime software. The SDK must be downloaded and installed separately.

These system environment variables should be available after installation:

MSMPI_INC=C:\Program Files (x86)\Microsoft SDKs\MPI\Include\
MSMPI_LIB32=C:\Program Files (x86)\Microsoft SDKs\MPI\Lib\x86\
MSMPI_LIB64=C:\Program Files (x86)\Microsoft SDKs\MPI\Lib\x64\

Abaqus 2019

C++ compiler

Microsoft Visual Studio 2015 Update 3 (also known as version 14.3)

You may download old versions of Visual Studio through a subscription from Microsoft.

Fortran compiler

Intel® Visual Fortran 16 Update 1 (also known as Parallel Studio XE 2016 Update 1)

Intel has instructions for how to download an older version of Fortran.

Setting environment variables

The Fortran compiler comes with a batch file, ifortvars.bat, which sets up shell environment variables in a particular command window so that Abaqus (or other programs) can locate and properly execute the compilers. You may open a command window from the Fortran program group which will already have the proper settings or modify the Abaqus Command shortcut to also call ifortvars.bat. To modify the Abaqus Command shortcut:

  1. Navigate to the Abaqus Command shortcut in the Start Menu, right-click on the shortcut and choose Properties. In Windows 10, right-click, select More->Open File Location. Then right-click on Abaqus Command and choose Properties.
  2. Append the full path to the ifortvars.bat file to the Target field on the Shortcut tab so it looks like:
C:\WINDOWS\system32\cmd.exe /k "C:\Program Files (x86)\Intel\Composer XE 2011 SP1\bin\ifortvars.bat" intel64

Abaqus 2016

C++ compiler

Microsoft Visual Studio 2012 Update 4 (also known as version 11.4)

You may download old versions of Visual Studio through a subscription from Microsoft.

Fortran compiler

Intel® Fortran Composer XE 2011 Update 6 (also known as version 12.1)

Intel has instructions for how to download an older version of Fortran.

Setting environment variables

The Fortran compiler comes with a batch file, ifortvars.bat, which sets up shell environment variables in a particular command window so that Abaqus (or other programs) can locate and properly execute the compilers. You may open a command window from the Fortran program group which will already have the proper settings or modify the Abaqus Command shortcut to also call ifortvars.bat. To modify the Abaqus Command shortcut:

  1. Navigate to the Abaqus Command shortcut in the Start Menu, right-click on the shortcut and choose Properties. In Windows 10, right-click, select More->Open File Location. Then right-click on Abaqus Command and choose Properties.
  2. Append the full path to the ifortvars.bat file to the Target field on the Shortcut tab so it looks like:
C:\WINDOWS\system32\cmd.exe /k "C:\Program Files (x86)\Intel\Composer XE 2011 SP1\bin\ifortvars.bat" intel64

Verification

Test that everything is working correctly with the command:

abaqus verify -user_std

To try a simple example problem you can type:

abaqus fetch job=c8
abaqus job=c8 user=c8

If that fails, it will be helpful to review the compiler section of the support.log file produced by the command:

abaqus info=support job=support

That file will be required by Simulia support to help diagnose what might be wrong.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment