marscosta
Mechanical
- Oct 2, 2013
- 3
So I'm building a UEL subroutine and I'm having a basic problem: the coordinates of the nodes of my custom element are not being read correctly.
In my inp file I have a simple model (two solid elements and one cohesive zero-thickness element):
and my UEL for file starts with the typical structure:
where debug_matriz is a custom function to write the contents of the matrix to a file. According to the documentation, coords should be an array containing the original coordinates of the nodes, so I would expect a result similar to the node positions I defined in my .inp file. But the result is that coords actually has the following:
where each column corresponds to one node and each line is the coordinate for that node. Basically it's telling me that the coordinates for node 3 (inp file) is (0,0), and remaining nodes are (0,1.875).
I'm a bit lost as to why this is happening and was hoping someone could shed some light.
Thank you very much!
In my inp file I have a simple model (two solid elements and one cohesive zero-thickness element):
Code:
*Node
1, 0.,0.,
2, 1.,0.,
3, 0.,1.,
4, 1.,1.,
5, 0.,1.,
6, 1.,1.,
7, 0.,2.,
8, 1.,2.,
*Element, type=CPE4
1, 1,2,4,3,
2, 5,6,8,7
*USER ELEMENT,TYPE=U1,NODES=4
1,2
*ELEMENT,TYPE=U1
3,3,4,5,6
*ELSET,ELSET=INTER
3
*UEL PROPERTY,ELSET=INTER
7.2, 4.6
and my UEL for file starts with the typical structure:
Code:
subroutine uel(rhs,amatrx,svars,energy,
1 ndofel,nrhs,nsvars,props,nprops,coords,
2 mcrd,nnode,u,du,v,a,jtype,time,dtime,
3 kstep,kinc,jelem,params,ndload,jdltyp,
4 adlmag,predef,npredf,lflags,mlvarx,
5 ddlmag,mdload,pnewdt,jprops,njprop,
6 period)
include 'ABA_PARAM.INC'
dimension rhs(mlvarx,*),
1 amatrx(ndofel,ndofel),
2 svars(nsvars),energy(8),props(*),
3 coords(mcrd,nnode),u(ndofel),
4 du(mlvarx,*),v(ndofel),a(ndofel),
5 time(2),params(3),jdltyp(mdload,*),
6 adlmag(mdload,*),ddlmag(mdload,*),
7 predef(2,npredf,nnode),lflags(*),
8 jprops(*)
parameter ( ngauss=2, debug=1 )
call debug_matriz(U,1,ndofel,'D:\test1.txt','U')
call debug_matriz(coords,mcrd,nnode,'D:\test1.txt','coords')
where debug_matriz is a custom function to write the contents of the matrix to a file. According to the documentation, coords should be an array containing the original coordinates of the nodes, so I would expect a result similar to the node positions I defined in my .inp file. But the result is that coords actually has the following:
Code:
-coords--------------------------
0.00000 0.00000 0.00000 0.00000
0.00000 1.87500 1.87500 1.87500
-/coords--------------------------
I'm a bit lost as to why this is happening and was hoping someone could shed some light.
Thank you very much!