Using the Usermat UPF to Define Custom ANSYS Mechanical Materials on Windows, Part 1

Categories:

A longstanding capability in Ansys Mechanical is the ability to add your own user-defined material with the Usermat function. The Usermat.f routine is one of many user-programmable features (UPFs) in Mechanical APDL, the solver behind Ansys Mechanical and the original Ansys program from which the company takes its name.

In order to keep computational performance the same as with any material model that comes with Ansys Mechanical, the Usermat.f routine is an actual Fortran subroutine that the user modifies, compiles, and links to the solver. Don’t panic, you don’t have to be someone who watched the Apollo landings live on a black and white TV in order to use this capability. PADT’s Alex Grishin has laid out the whole process for using the Usermat function with Ansys Mechanical on Microsoft Windows.

We created a post on Usermat.f back and 2012, and some things have not changed. But others have, including the compiler you will use. Alex has created a great update that also takes the example to something a bit more useful, showing how to do custom plasticity with the Usermat.f UPF.

Note: Alex added a second part to this series, Customizing the Usermat.f Algorithm: Creating A Combined Isotropic/Kinematic Hardening Model

Don’t Be Scared of FORTRAN, You Can do a Custom Material with Usermat.f

Graph showing plasticity curve use in Usermat.f example.

Alex has laid out a pretty great example that should help you get started on your own custom material. If you need some assistance or want to just have someone else get a custom material or any other custom feature in Ansys Mechanical up and running, please reach out to PADT. Alex, or one of his co-workers, are ready to help.

Get Your Ansys Products & Support from the Engineers who Contribute to this Blog.

Technical Expertise to Enable your Additive Manufacturing Success.

Share this post:

Upcoming Events

Sep 14
- Sep 19
, 2026
IMTS 2026
Sep 15
, 2026
Simulation for Data Center Cooling Infrastructure - Webinar
Sep 16
, 2026
Ansys Simulation Solutions for Electrical Machines - Webinar
Sep 16
, 2026
Entry-Level Structural, Thermal and Flow Simulation - Webinar
Sep 23
, 2026
AZTC September After 5
Sep 30
, 2026
The Role of the Digital Twin in Modern Design and Engineering - Webinar
Oct 07
, 2026
2026 AZBio Awards
Oct 08
, 2026
White Hat Life Science Investor Conference
Oct 13
- Oct 14
, 2026
Ansys Transportation Summit & International LS-DYNA User Conference
Oct 21
, 2026
2026 Southern Arizona Tech + Business Expo
Oct 22
, 2026
Tucson Ansys Optics User Group Meeting
Oct 28
, 2026
Nerdtoberfest 2026
Nov 15
- Nov 18
, 2026
2026 ANS Winter Conference & Expo
Nov 18
, 2026
2026 Governor’s Celebration of Innovation

Contact Us

Most of our customers receive their support over the phone or via email. Customers who are close by can also set up a face-to-face appointment with one of our engineers.

For most locations, simply contact us: