Webinar Info: Writing and Compiling a Custom Material Property in ANSYS Mechanical APDL

Categories:
image 358

During our webinar held at noon on 9/27/2012 we promised to provide a link to the recording, a PDF of the PowerPoint, and some answers to a few questions.  Here is that information:

Files

Presentation PDF is here:

Zip file with the sample USERMAT.f and input file:

State Variables

I was a bit confusing on state variables. The problem is with my use of them, not with the variables.  The test model only had one integration point.  My code is still not working right, the default USERMAT is overwriting my flag somewhere and I don’t have time to figure it out. It’s killing me but I have to do some real work.

But anyhow, my assertion that the state variables are per integration point is correct.

Debugging

I am not aware of any way to use a debugger with ANSYS.  There is nothing in the documentation, and to be honest, I’ve not used a real debugger in years.  So there may be a way to do so, and see your routine in the debugger since you have the source code, but I have no idea on how to do that.  Perhaps someone with more debugging experience can comment below.

Other UPF’s

Someone asked about other routines that are available and we ran out of time before I could go over them.  Here is a list.

  
ELEMENTS 
UserElem.fUser Defined Element that use newer API
UEL100.f – UEL105.f
UEC100.f – UEC105.f
UEX100.f – UEX105.f
UEP100.f-UEP105.f
USERTR.f
USERAC.f
User elements defined that access the program database directly
USEROU.fStores user-provided element output
USERAN.fModify orientation of material properties
USERRC.fCOMBIN37 (control/thermostat/spring/damper/resistor) user routine.
UEIMatx.fAccess to an elements matrix or load vector
UTHICK.fSets thickness at integration points
UsrFictiveSets “fictive” temperature (I have no idea what that is)
UFLEX.fCalculates pipe flexibility for PIPE288/289
UsrShift.fAllows user to specify time shift
Materials 
UserMat.fUser material models
UserHyper.fUser defined hyperelasticity models
UserCreep.fUser defined creep model
user_tbelastic.fAllows definition of elastic stiffness at a given integration point based on user model.  TB,ELASTIC,,,,USER
USERFC.fUser defined failure criteria
USERSWTRAIN.fUser defined swelling, for TB, SWELL,,,,USER
USERCK.fHelper routine that passes material properties for a user material in
USERFRIC.fUser defined friction calculation.  Not just friction but all values calculated in contact calculations with friction turned on.
LOADS 
USERFL.fChanges scalar field values (temp, fluence, heat generation, moisture content, magnetic virtual displacement), by element.
USERPR.fCalculates element pressure, by element
USERCV.fCalculates element face convection.
USERFX.fCalculates element face heat flux
USERCH.fCalculates element face charge density surface values
USERFD.fComputes complex load vectors for frequency domain logic
USERPE.fCalculate the rotation of an elbow pipe element caused by internal pressure
USRSURF116.f
USER116Cond.f
USER116Hf.f
Modifies the conduction, film coefficient, bulk temp for SURF151/152
userPartVelAcc.fOcean wave particle acceleration calculation for PIPE288/289
userPanelHydFor.fCalcs hydrodynamic loading on SURF164 from ocean loading
USER Commands 
USER01.f-USER10.fCreate your own ANSYS commands that are accessed through /UCMD,cmd,num where num refers to the subroutine number and cmd is the command name you want to assign it. Put this in your startxx.ans file to give regular access.

Join PADT and the global Ansys user community for this year’s online conference.

Multiple Tracks | Every Physics & Every Industry

Hear from Ansys Leadership | Presentations from Customers on How They Use Ansys

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

Jun 19
, 2025
Digital Engineering for ePowertrain Development for Automotive - Webinar
May 21
, 2025
Optics Updates in Ansys 2025 R1 - Webinar
May 29
, 2025
Applying Digital Engineering across Space Mission Analysis and Design: Payload - Webinar
Jun 03
, 2025
Experience Stratasys Truck Tour - Denver Colorado
Jun 03
, 2025
Accelerate Electronics Thermal Workflows with Ansys Discovery and Ansys Icepak - Webinar
Jun 03
, 2025
Smart Manufacturing and Operations Enabled by Simulation - Webinar
Jun 04
, 2025
Composites & Structural Optimization Updates in Ansys 2025 R1 - Webinar
Jun 05
, 2025
Using Digital Engineering for a Structural, Thermal, and Optical Performance Workflow - Webinar
Jun 09
- Jun 11
, 2025
TechConnect World 2025
Jun 12
, 2025
Design and Test: Critical Links for Mission Success - Webinar
Jun 17
, 2025
Ansys Virtual Workshop - Fatigue & Durability Workflows with Ansys Mechanical & nCode
Jun 18
, 2025
Fluent CPU - UI & UX Updates in Ansys 2025 R1 - Webinar
Jun 16
- Jun 20
, 2025
Turbo Expo
Jun 24
, 2025
Cardiovascular Digital Twins: From Bench to Bedside - Webinar
Jun 25
, 2025
E-Mobility and Clean Energy Summit
Jul 02
, 2025
Electric Machine & Consumer Electronics Updates in Ansys 2025 R1 - Webinar
Jul 11
, 2025
2025 Aerospace, Aviation, Defense and Manufacturing Conference
Jul 16
, 2025
HFSS Updates in Ansys 2025 R1 - Webinar
Jul 16
- Jul 17
, 2025
Ansys Simulation World 2025
Aug 10
- Aug 13
, 2025
SmallSat 2025

Search the PADT Site

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: