3.4. Coupling and Constraint Routines
3.4.1. cpinqr Function (Getting Information About a Coupled Set)
*deck,cpinqr
function cpinqr (nce,key)
c *** primary function: get information about a coupled set
c *** secondary functions: none
c
c *** Notice - This file contains ANSYS Confidential information ***
c
c typ=int,dp,log,chr,dcp siz=sc,ar(n),func intent=in,out,inout
c
c input arguments:
c variable (typ,siz,intent) description
c nce (int,sc,in) - coupled set number
c key (int,sc,in) - inquiry key:
c should be zero for key=11, DB_NUMDEFINED,
c DB_NUMSELECTED, DB_MAXDEFINED, and
c DB_MAXRECLENG
c = DB_SELECTED - return select status
c cpinqr = 1 - coupled set is selected
c = 0 - coupled set in undefined
c =-1 - coupled set in unseleted
c = DB_NUMDEFINED - return number of defined coupled sets
c = DB_NUMSELECTED - return number of selected coupled sets
c = DB_MAXDEFINED - return the number of the highest numbered
c coupled set
c = DB_MAXRECLENG - return length of largest coupled set record
c (max record length)
c = 2 - return length (data units)
c = 3 - return layer number
c = 4 - return address of first data word
c = 11 - return void percent (integer)
c = 16 - return location of next record
c = -1 - return master node for this eqn (this is
c currently only used by solution DB object)
c
c output arguments:
c cpinqr (int,func,out) - the returned value of cpinqr is based on
c setting of key
c
3.4.2. cpget Function (Getting a Coupled Set)
*deck,cpget
function cpget (ncp,ieqn)
c *** primary function: get a coupled set
c *** Notice - This file contains ANSYS Confidential information ***
c input arguments:
c ncp (int,sc,in) - coupled set number
c
c output arguments:
c cpget (int,func,out) - number of nodes in list
c ieqn (int,ar(cpget+2),out) - coupled set info:
c ieqn(1:cpget) - list of coupled nodes
c ieqn(cpget+1) - set degree of freedom
c ieqn(cpget+2) - number of nodes in list
c (copy of return value)
3.4.3. cpput Subroutine (Storing a Coupled Set)
*deck,cpput
subroutine cpput (ncp,n,ieqn)
c *** primary function: store a coupling set
c *** Notice - This file contains ANSYS Confidential information ***
c input arguments:
c ncp (int,sc,in) - coupled set number
c n (int,sc,in) - number of nodes in coupled set
c ieqn (int,ar(n+2),in) - info for storage
c ieqn(1:n) - list of coupled nodes
c ieqn(n+1) - degree of freedom label for set
c (ieqn(n+2) is inout) ieqn(n+2) - number of nodes in coupled set
c (copy of n)
c output arguments:
c ieqn(n+2) (int,sc,inout) - number of nodes in coupled set
c (another copy of n)
3.4.4. cpsel Subroutine (Selecting or Deleting a Coupled Set)
*deck,cpsel
subroutine cpsel (ncpi,ksel)
c *** primary function: select or delete a coupled set
c *** secondary functions: none
c
c *** Notice - This file contains ANSYS Confidential information ***
c
c typ=int,dp,log,chr,dcp siz=sc,ar(n),func intent=in,out,inout
c
c input arguments:
c variable (typ,siz,intent) description
c ncpi (int,sc,in) - coupled set number
c ksel (int,sc,in) - select/delete flag
c = 0 - delete coupled set
c = 1 - select coupled set
c output arguments:
c none
c
3.4.5. ceinqr Function (Getting Information About a Constraint Equation Set)
*deck,ceinqr
function ceinqr (nce,key)
c *** primary function: get information about a constraint equation set
c *** Notice - This file contains ANSYS Confidential information ***
c input arguments:
c nce (int,sc,in) - constraint equation number
c key (int,sc,in) - inquiry key:
c should be zero for key=11, DB_NUMDEFINED,
c DB_NUMSELECTED, DB_MAXDEFINED, and
c DB_MAXRECLENG
c = DB_SELECTED - return select status
c ceinqr = 1 - equation is selected
c = 0 - equation is undefined
c =-1 - equation is unselected
c = DB_NUMDEFINED - return number of defined contraint equations
c = DB_NUMSELECTED - return number of selected contraint equations
c = DB_MAXDEFINED - return number of highest numbered constraint
c equation defined
c = DB_MAXRECLENG - return length of longest contraint equation set
c (max record length)
c = 2 - return length (data units)
c = 3 - return layer number
c = 4 - address of first data word
c = 11 - return void percent (integer)
c = 16 - return location of next record
c = CE_NONLINEAR - return 1 if CE is nonlinear
c output arguments:
c ceinqr (int,func,out) - the returned value of ceinqr is based on
c setting of key
3.4.6. ceget Function (Getting a Constraint Equation)
*deck,ceget
function ceget (nce,ieqn,deqn)
c *** primary function: get a constraint equation
c *** Notice - This file contains ANSYS Confidential information ***
c arguments:
integer,intent(in) :: nce ! constraint equation set number
integer,intent(out) :: ieqn(2,*) ! ieqn(1:2,1:n) - node, dof
! ieqn(2,n+1) - number of dof in set
! negative means internal CE
double precision,intent(out) :: deqn(*) ! deqn(1:n) - coefficients of
! each dof in set
! deqn(n+1) - constant term
3.4.7. ceput Subroutine (Storing a Constraint Equation)
*deck,ceput
subroutine ceput (nce,n,ieqn,deqn)
c *** primary function: store a constraint equation
c *** Notice - This file contains ANSYS Confidential information ***
c arguments:
integer,intent(in) :: ncei ! constraint equation number
integer,intent(in) :: ksel ! select/delete flag
! = 0 - delete equation
external fAnsMemAlloc, fAnsMemFree
external vmsel, ceinqr, cexsub, vmgetx, inquireAnsCe,
x activateAnsCe, erhandler, checkForDupTerms
integer vmgetx, ceinqr, inquireAnsCe, activateAnsCe
PTRFTN fAnsMemAlloc
3.4.8. cesel Subroutine (Deleting or Selecting a Constraint Equation)
*deck,cesel
subroutine cesel (ncei,ksel)
c *** primary function: select or delete a constraint equation
c *** Notice - This file contains ANSYS Confidential information ***
c arguments:
integer,intent(in) :: ncei ! constraint equation number
integer,intent(in) :: ksel ! select/delete flag
! = 0 - delete equation