! ----------------------------------------

! Apply boundary conditions

! ----------------------------------------

! Ground nodes at Z = 0
NSEL, S, LOC, Z, 0
CP, 1, VOLT, ALL
D, ALL, VOLT, 0

! Apply pole_volt at nodes at top of cube
NSEL, S, LOC, Z, Lz
CP, 2, VOLT, ALL
D, ALL, VOLT, pole_volt

*GET, charge_node, CP, 2, TERM, 1, NODE

! Select nodes at X, Y, Z = 0 and constrain DOF by symmetry
NSEL, S, LOC, X, 0
DSYM, SYMM, X
NSEL, S, LOC, Y, 0
DSYM, SYMM, Y
NSEL, S, LOC, Z, 0
DSYM, SYMM, Z

! Select nodes on exterior X, Y, Z faces and couple displacements
NSEL, S, LOC, X, Lx
CP, 3, UX, ALL
NSEL, S, LOC, Y, Ly
CP, 4, UY, ALL
NSEL, S, LOC, Z, Lz
CP, 5, UZ, ALL

ALLSEL, ALL		! Select all entities
EQSLV, SPARSE, 1E-6



/SOLU
SOLVE

/POST1
PRNSOL,U,COMP   
SET,LAST
!*  


