verners
Subscriber

I have faced similar issues - no mesh change if using rmshky=0 and 'An unexpected error ( SIG$SEGV )' if using rmshky=1 (the code is pasted below for reference - the ANSYS Mechanical APDL version I use is 2021 R1).

FINISH
/CLEAR
 
! /UNITS (p. 1937),Label,LENFACT,MASSFACT,TIMEFACT,TEMPFACT,TOFFSET,CHARGEFACT,FORCEFACT,HEATFACT ! used for convenience only
! MPA (mm, N, MPa, Mg=t)
/UNITS,MPA
/FILNAME, test, 1
 
! general parameters
! 0 - pre-processing test, 1 - electrostatic calculation
*SET, scalc, 1
! 0 - no morphing
*SET, morph, 1
 
! geometry parameters
*SET, L, 20
*SET, lmesh, 1
*SET, lmeshair, lmesh/1
 
! material parameters
! mechanical properties
*SET, dens,0.965*1e-9 ! g/cm3 to t/mm3 ! http://polymerdatabase.com/polymers/Polydimethylsiloxane.html
*SET, E0, 6.4
*SET, nu0, 0.48
 
! electric properties
! PDMS [10.1109/JMEMS.2010.2076786]
! assume alpha_inf=1
*SET, PER,2.4 ! DOI: 10.1039/c3py01522j
*SET, LSST,0 ! DOI: 10.1039/c3py01522j
*SET, RSV,4e13*1e3 ! Ohm*mm ! https://www.mit.edu/~6.777/matprops/pdms.htm
! air
*SET, PERair,1.0006
*SET, LSSTair,0
*SET, RSVair,1e12*1e3 ! Ohm*mm
 
/PREP7  
! Includes large-deflection effects in a static or full transient analysis ! default = off
*AFUN,DEG   
! MPTEMP,SLOC,T1,T2,T3,T4,T5,T6 ! SLOC - Starting location in table for entering temperatures
! Defines a temperature table for material properties
MPTEMP, 1,0  
! LESIZE,NL1,SIZE,ANGSIZ,NDIV,SPACE,KFORC,LAYER1,LAYER2,KYNDIV
! AESIZE,ANUM,SIZE
! MSHKEY,KEY
! Specifies whether free meshing or mapped meshing should be used to mesh a model.
! 0 Use free meshing (the default).
! 1 Use mapped meshing.
! 2 Use mapped meshing if possible; otherwise, use free meshing. If you specify MSHKEY,2, SmartSizing will be inactive even while free meshing non-map-meshable areas.
MSHKEY, 2    
 
! materials and elements
! mechanical properties
! TB,Lab,MATID,NTEMP,NPTS,TBOPT,--,FuncName
TB, ELASTIC,1,,,ISOT ! EX, NUXY
MP, DENS,1,dens
! TBDATA,STLOC,C1,C2,C3,C4,C5,C6 ! Defines data for the table specified via the most recent TB command
TBDATA,,E0,nu0
 
! electric properties
! MP,Lab,MAT,C0,C1,C2,C3,C4
MP, PERX,1,PER
MP, PERY,1,PER
MP, LSST,1,LSST
MP, RSVX,1,RSV
MP, RSVY,1,RSV
MP, PERX,2,PERair
MP, PERY,2,PERair
MP, LSST,2,LSSTair
MP, RSVX,2,RSVair
MP, RSVY,2,RSVair
 
! geometry
! BLC4,XCORNER,YCORNER,WIDTH,HEIGHT,DEPTH
! active material layers
BLC4, 0,-3./4*L,L,L
 
! generate mesh
! ET,ITYPE,Ename,KOP1,KOP2,KOP3,KOP4,KOP5,KOP6,INOPR
!ET, 1,PLANE182,,,2 ! Plane strain
ET, 1,PLANE183,0,,2 ! 8-node quadrilateral, Plane strain
REAL, 1
TYPE, 1
! active materials
! MAT,MAT
MAT, 1
AESIZE, ALL, lmesh
AMESH, ALL
 
!BLC4, 0,L/4.,L,L/2.
!ET, 1,PLANE121,,,0,0,0,0 ! Element behavior: Plane (3); Element coordinate system defined: Element coordinate system is parallel to the global coordinate system (4); Extra element output: Basic element printout; Electric charge reaction sign: Positive (6)
!MAT, 2
!AESIZE, ALL, lmesh
!AMESH, 2
 
/AUTO,1
EPLOT
 
/SOLU
NSUB, 1
ANTYPE,STATIC,NEW
! boundary conditions
NSEL, S,LOC,Y,-3./4*L
CM, ntest1,NODE
! D,Node,Lab,VALUE,VALUE2,NEND,NINC,Lab2,Lab3,Lab4,Lab5,Lab6,MESHFLAG
D, ALL,ALL,0
 
! loads
NSEL, S,LOC,Y,1./4*L
CM, ntest2,NODE
D, ALL,UY,0.1*L 
 
*IF, scalc,EQ,1,THEN
    ALLSEL
    CHECK
    SOLVE
    
    /POST1
    SET,FIRST
    /EFACET,1
    PLDISP,0
    
    *IF, morph,EQ,1,THEN
        FINISH
        /PREP7
        ! air region
        BLC4, 0,L/4.,L,L/2.
        ET, 1,PLANE121,,,0,0,0,0 ! Element behavior: Plane (3); Element coordinate system defined: Element coordinate system is parallel to the global coordinate system (4); Extra element output: Basic element printout (5); Electric charge reaction sign: Positive (6)
        MAT, 2
        AESIZE, ALL, lmesh
        AMESH, 2
!       NSEL, S,LOC,Y,1./4*L
!       CM, ntest3,NODE
!       CP, NEXT,ALL,ALL
        NSEL, ALL
    !   DDELE, ALL, ALL
        ! morph mesh
        ! Coupled degree of freedom must first be removed before morphing or remeshing (CPDELE). 
        ! DAMORPH,AREA,XLINE,RMSHKY
        ! rmshky=0: no effect on non-structural nodes
        ! rmshky=1: An unexpected error ( SIG$SEGV ) has occurred...  ANSYS internal data has been corrupted.  ANSYS is unable to recover and will terminate. Previously saved files are unaffected.  Please send the data leading to this operation to your technical support provider, as this will allow ANSYS, Inc to improve the program. 
        DAMORPH, 2,,1
!       MORPH, ON
!       NSEL, S,LOC,Y,3./4*L
!       CM, ntest4,NODE
!       D, ALL,UY,0
!       NSEL, ALL
        NPLOT
    *ENDIF    
*ENDIF