| Thread Closed |
ANSYS command problem re element death/element table postprocessing |
Share Thread | Thread Tools |
| Oct19-08, 05:05 PM | #1 |
|
|
ANSYS command problem re element death/element table postprocessing
I am a new to ANSYS command-language mode. I am having trouble animating the procedure described below. The procedure is meant to model melting over time through element death (based on example from U. Alberta at http://www.mece.ualberta.ca/tutorial...irthDeath.html).
My problem is that I can't get the elements that exceed 600 C (my melting criterion) to disappear SEQUENTIALLY from the animation. Instead, I can only get those elements that exceed 600 C in EITHER the first or last step to disappear. The temperature contours evolve during the animation, but the melted/disappeared elements stay the same. I have tried writing a loop to make a new element table for each substep in which melted elements disappear, but this has not worked. I would very much appreciate help with this...The postprocessing part of the code should appear in bold blue italics. finish /clear /title, Transient melting by element death (conduction) /prep7 ! Enter the preprocessor ! define geometry BLC4,0,0,20,15 ! Create rectangle BLC4,0,0,10,4 ! Create smaller rectangle (magma) ASBA,1,2 ! Boolean Subtraction (subtracts area 2 (small) from area 1 (big)) ET,1,Plane55 ! Element type MP,Dens,1,2262e9 ! Define density mp,c,1,0.001604 ! Define specific heat mp,kxx,1,0.001 ! Define heat transfer coefficient ! Mesh size SMRT,6 CM,_Y,AREA ASEL, , , , 3 CM,_Y1,AREA CHKMSH,'AREA' CMSEL,S,_Y AMESH,_Y1 ! Mesh area ! Refine mesh CMDEL,_Y CMDEL,_Y1 CMDEL,_Y2 FLST,5,6,2,ORDE,4 FITEM,5,6 FITEM,5,22 FITEM,5,-25 FITEM,5,44 CM,_Y,ELEM ESEL, , , ,P51X CM,_Y1,ELEM CMSEL,S,_Y CMDEL,_Y EREF,_Y1, , ,3,0,1,1 CMDEL,_Y1 finish /solu ! Enter solution phase antype,4 ! Transient analysis nropt,full ! Newton Raphson - full SOLCONTROL,ON,0 TUNIF,200, TREF,200, OUTPR,ALL,ALL, OUTRES,ALL,ALL time,3.1536e13 ! Time at end of analysis AUTOTS,0 DELTIM,315360e6, , ,1 ! Time step AUTOTS,0 KBC,1 TSRES,ERASE TIME,31536000000000 AUTOTS,0 NSUBST,100, , ,1 ! Number of substeps,100 KBC,1 lumpm,0 ! Lumped mass off neqit,100 ! Max no. of iterations autots,off ! Auto time search off lnsrch,on ! Line search on kbc,1 ! Load applied in steps, not ramped IC,all,temp,200 ! Initial conditions, temp = 200 PRED,-1 FLST,2,628,1,ORDE,2 FITEM,2,1 FITEM,2,-628 IC,P51X,TEMP,200, FLST,2,2,4,ORDE,2 FITEM,2,6 FITEM,2,-7 /GO DL,P51X, ,TEMP,1200,1 ! BC FLST,2,2,4,ORDE,2 FITEM,2,2 FITEM,2,-3 /GO DL,P51X, ,TEMP,200,1 SAVE SAVE SAVE /STAT,SOLU SOLVE TIME,31536000000000 AUTOTS,-1 DELTIM,315360000000, , ,1 KBC,1 TSRES,ERASE TIME,31536000000000 AUTOTS,-1 NSUBST,100, , ,1 KBC,1 TSRES,ERASE /STAT,SOLU solve finish /post1 set, first etable,melty,temp, ! Create an element table esel,s,etab,melty,600 ! Select all elements from table ! above 600 finish /solu ! Re-enter solution phase antype,,rest ! Restart analysis ekill,all ! Kill all selected elements esel,all ! Re-select all elements finish /post1 ! Re-enter postprocessor set,first ! Read in last subset of data esel,s,live ! Select all live elements plnsol,temp ! Plot the temp contour of the live elements !/CONT,1,10,200,100,1200 !PLNS,TEMP, !/REPLOT *DO, i,1,10,1 set,i etable,delete etable,melty,temp, ! Create an element table esel,s,etab,melty,600 ! Select all elements from table ! above 600 finish /solu ! Re-enter solution phase antype,,rest ! Restart analysis ekill,all ! Kill all selected elements esel,all ! Re-select all elements finish /post1 ! Re-enter postprocessor set,i ! Read in last subset of data esel,s,live ! Select all live elements plnsol,temp /CONT,1,10,200,100,1200 PLNS,TEMP, /replot *ENDDO ANTIME,100,0.5, ,0,2,0,0.31536E+14 |
| Oct20-08, 06:50 PM | #2 |
|
|
I'm a new user and realized my initial post wasn't very clear...I worked on the problem some more by incorporating some advice and think I'm on the right track, but still have a couple of problems. I would really appreciate any help. The code (below) now includes a loop for checking whether elements meet the melting/death criterion at each substep.
Although I have a SOLUTION, I still can't ANIMATE the element death/melting. Also, when I change parameters like the initial T or BC T, I get error messages saying that no elements have been selected. I also get errors when I try to change the time range of the calculation (I want total time to be ~1e13 for example). Here's the code: /title, Convection Example /prep7 ! Enter the preprocessor ! define geometry k,1,0,0 ! Define keypoints k,2,0.03,0 k,3,0.03,0.03 k,4,0,0.03 a,1,2,3,4 ! Connect the keypoints to form area ! mesh 2D areas ET,1,Plane55 ! Element type MP,Dens,1,2262e9 ! Define density mp,c,1,0.001604 ! Define specific heat mp,kxx,1,1.8 ! Define heat transfer coefficient esize,0.0025 ! Mesh size amesh,all ! Mesh area finish /solu ! Enter solution phase antype,4 ! Transient analysis tot_time = 1e6 t_steps = 10 time_inc = tot_time/t_steps time,1e6 ! Time at end of analysis nropt,full ! Newton Raphson - full lumpm,0 ! Lumped mass off nsubst,10 ! Number of substeps, 20 neqit,10 ! Max no. of iterations autots,off ! Auto time search off lnsrch,on ! Line search on TUNIF,200, IC,all,temp,200 ! Initial conditions, temp = 200 *do, i,1 ,10, 1 /solu time=i*time_inc nsub, 1 outres,all,all ! Output data for all substeps !... any stuff about boundary conditions ... ! fixed temp BC's nsel,s,ext ! Node select all exterior nodes sf,all,conv,10,1200 NSEL,ALL ! Reselect all nodes kbc,1 ! Load applied in steps, not ramped /gst,off ! Turn off graphical convergence monitor solve finish /post1 set, last etable,melty,temp, ! Create an element table esel,s,etab,melty,200 ! Select all elements from table above 200 finish /solu ! Re-enter solution phase antype,,rest ! Restart analysis ekill,all ! Kill all selected elements esel,all !*enddo /post1 ! Re-enter postprocessor set,last ! Read in last subset of data esel,s,live ! Select all live elements plnsol,temp ! Plot the temp contour of the live elements /seg,delete /seg,multi,anm1,.1 /CONT,1,10,200,100,1200 !PLNS,TEMP, /REPLOT *enddo /post1 /seg,off ANTIME,20,0.5, ,0,2,200,1200 |
| Thread Closed |
| Thread Tools | |
Similar Threads for: ANSYS command problem re element death/element table postprocessing
|
||||
| Thread | Forum | Replies | ||
| Proper ANSYS Element? | General Engineering | 12 | ||
| beam element vs. Finite element? | Mechanical Engineering | 3 | ||
| differences between natural element and built element? | Biology, Chemistry & Other Homework | 4 | ||
| zero element/unit element | Calculus & Beyond Homework | 2 | ||
| Help with this vector element problem | Introductory Physics Homework | 3 | ||