C DPFUNC SOURCE AM 12/02/27 23:39:37 7289 FUNCTION DPfunc(sigma,alpha) c Drucker Prager function to describe the compressive part of a concrete material. c sigmaeq = dsqrt (3 J2) + alpha I1 with J2 : 2nd invariant of the deviatoric stress c and I1 : 1st invariant of the stress IMPLICIT REAL*8 (A-B,D-H,O-Z) implicit integer (I-K,M,N) implicit logical (L) implicit character*10 (C) dimension sigma(6) sigmaxx = sigma(1) sigmayy = sigma(2) sigmazz = sigma(3) sigmaxy = sigma(4) sigmaxz = sigma(5) sigmayz = sigma(6) rloc = (sigmaxx-sigmayy)**2 + (sigmayy-sigmazz)**2 + . (sigmazz-sigmaxx)**2 rloc2 = ((1d0)/(6d0))*rloc rj2 = rloc2 + sigmaxy**2 + sigmayz**2 + sigmaxz**2 ri1 = sigmaxx + sigmayy + sigmazz DPfunc = dsqrt (3d0*rj2) + alpha*ri1 return end