Hi,
I'm writing a very simple subroutine using USDFLD. It should work as an element deletion replacement in Abaqus/Standard. Basically It checks for value of S11 and if it's lower than a single certain value defined by me in the code, it uses FIELD(1)=1 (which is E=1 , Poisson=0), otherwise FILED(1)=0 (which is E=100E9 , Poisson=0.3) is chosen. There must be something silly wrong with it because I've spent so much time on it and the answer everytime is "Problem during compilation". (My other Subroutines work fine)
Here is the code main body, I really appreciate it if someone can help me out, It's really frustrating...
C INITIALIZE FAILURE FLAGS FROM STATEV.
C
DAMAGE = STATEV(1)
C
GET STRESSES FROM PREVIOUS INCREMENT
C
CALL GETVRM('S',ARRAY,JARRAY,FLGRAY,JRCD,JMAC,JMATYP, 1 MATLAYO,LACCFLA)
S11 = ARRAY(1)
C
C DAMAGE INDEX: IF SMALLER THAN -10 MPa, ACTIVATE
C
IF (DAMAGE .LT. 1D.0) THEN
IF (S11 .LT. -10.D6) THEN
DAMAGE = 1.D0
ENDIF
STATEV(1) = DAMAGE
ENDIF
C
UPDATE FIELD VARIABLES
C
FIELD(1) = 0.D0
IF (DAMAGE .GT. 1.D0) THEN
FIELD(1) = 1.D0
ENDIF
C
RETURN
END