how to go from /SOLU to /PREP7 then to return in /SOLU for thenextstep
how to go from /SOLU to /PREP7 then to return in /SOLU for thenextstep
(OP)
Hi !! help please!!!!
how to go in /PREP7 starting from the /SOLU then to return in /SOLU??
/PREP7
……..
……..
FINISH
/SOLU
ANTYPE,STATIC
......
loads
*DO,i,1,n
*IF,k,EQ,0,THEN
/PREP7
.....
/SOLU
*ENDIF
......
SOLVE
.....
*ENDDO
.....
Somebody suggested me making:
*DO,i,1,n
*IF,k,EQ,0,THEN
/PREP7
......
PARSAV,ALL,myfile,ext
/SOLU
ANTYPE,,REST,,,CONTINUE
PARRES,NEW,myfile,ext
*ENDIF
......
SOLVE
.....
*ENDDO
But it does not work!!!
Thank’s in advance!!!
Barha
how to go in /PREP7 starting from the /SOLU then to return in /SOLU??
/PREP7
……..
……..
FINISH
/SOLU
ANTYPE,STATIC
......
loads
*DO,i,1,n
*IF,k,EQ,0,THEN
/PREP7
.....
/SOLU
*ENDIF
......
SOLVE
.....
*ENDDO
.....
Somebody suggested me making:
*DO,i,1,n
*IF,k,EQ,0,THEN
/PREP7
......
PARSAV,ALL,myfile,ext
/SOLU
ANTYPE,,REST,,,CONTINUE
PARRES,NEW,myfile,ext
*ENDIF
......
SOLVE
.....
*ENDDO
But it does not work!!!
Thank’s in advance!!!
Barha





RE: how to go from /SOLU to /PREP7 then to return in /SOLU for thenextstep
Alex
RE: how to go from /SOLU to /PREP7 then to return in /SOLU for thenextstep
if, from one step to another in /SOLU, I change the number of material of some elements by using MPCHG, Ansys carries out the change (I can check that with ELIST), but does not hold any account of it at the time of calculation (it calculates with the values of properties of the material witch I declare at the beginning of the analysis)
*DO,i,1,n
/PREP7
ALLS,ALL,ELEM
MPCHG,2,some_elements
/SOLU
………
SOLVE
……..
*ENDDO
And i receive this error message:
“Cumulative iteration 1 may have been solved using different model or boundary condition data than currently stored. POST1 results may be erroneous unless you RESUME from a jobname.DB file for this substep”.
The change occur at step 1.
barha
RE: how to go from /SOLU to /PREP7 then to return in /SOLU for thenextstep
"Nonstandard procedures or techniques ... have not been or cannot be fully tested by ANSYS."
"Following is a partial list of nonstandard ANSYS features and uses:
...
High-risk capabilities such as the following:
Changing element real constants during the solution phase in between load steps. Depending on the element type being used, the element may not properly use the updated real constant value."
I don't know if changing the material number has the same risk or not. But it is possible. On the other hand, I think you should provide some more detailed code, if possible.
Regards,
Alex
RE: how to go from /SOLU to /PREP7 then to return in /SOLU for thenextstep
regards
Barha
RE: how to go from /SOLU to /PREP7 then to return in /SOLU for thenextstep
Restarting a analysis from previous time step (is necessary if you are doing a transient analysis for example antype,transient,resume).
Saving (save) is good if you are doing several different analysis with different model geometry. You can chage the job name (/filname) for each solve routine and the save (save,all,,db). You can define different job names by
CODE
By the way, if you tried to restart the analysis after changing the materials, then it's possible that ansys uses the old model data. But if you change the material number and start a new analyses, it MUST work! See next example:
CODE
...
! define materials
! Material 1
...
! Material n
...
! Mesh modell with Material 1
...
*do,i,1,n
! define a jobname
fini
/filname,strcat('jobname',chrval(i))
! change material
/prep7
mpchg,i,some_elements
! solve
/solu
antype,,new
solve
! save
/post1
save,all,,db
*enddo
Hope it helps!
Alex
RE: how to go from /SOLU to /PREP7 then to return in /SOLU for thenextstep
my programe is like this:
/PREP7
!Structural model
…….
FINISH
/SOLU
ANTYPE,static
SOLCONTROL,On
AUTOTS,on
NSEL,S,NODE,,1,5,2
D,ALL,UY,0
NSEL,S,NODE,,1
D,ALL,UX,0
TIME,0.0001
ALLS
SOLVE
*DO,i,1,n
tim=i*dt
*DO,k,1,ne ! ne: number of element
*IF,g(i,k),EQ,0,THEN
MPCHG,2,k
g(i,k)=1
*ENDIF
*ENDDO
!loads
………….
………….
TIME,tim
DELTIM,dt/5
OUTRES,ALL,LAST
SOLVE
*ENDDO
RE: how to go from /SOLU to /PREP7 then to return in /SOLU for thenextstep
CODE
/PREP7
!Structural model
…….
FINISH
/filname,iteration_0 !!! Jobname
/SOLU
ANTYPE,static,new
SOLCONTROL,On
!!! AUTOTS,on
NSEL,S,NODE,,1,5,2
D,ALL,UY,0
NSEL,S,NODE,,1
D,ALL,UX,0
!!! TIME,0.0001
ALLS
SOLVE
save,all,,db !!! Save
*DO,i,1,n
tim=i*dt
*DO,k,1,ne ! ne: number of element
*IF,g(i,k),EQ,0,THEN
MPCHG,2,k
g(i,k)=1
*ENDIF
*ENDDO
finish
/filname,strcat('iteration_',chrval(i)) !!! change jobname
/solu
antype,static,new !!! statical solve!?
!loads
………….
………….
!!! TIME,tim !!! not necesary!?
!!! DELTIM,dt/5
!!! OUTRES,ALL,LAST
SOLVE
save,all,,db !!! Save
*ENDDO
RE: how to go from /SOLU to /PREP7 then to return in /SOLU for thenextstep
1) I know that in static analysis i don't need time but in my work i need it because my loads are temperaturs witch i obtened befor in thermal analysis. so, in structural analysis i use LDREAD,TEMP,,,time,1,my_jobname,rth.
if i want to not use time i have to put:
LDREAD,TEMP,LAST,,,1,my_jobname,rth.
2) Other thing: i need to go in /PREP7 to use MPCHG, then to return to /SOLU.i see that you use this command in /SOLU. LIKE YOU DO ANSYS WILL NOT TAKE IN ACCOUNT THIS CHANGE WHEN IT CALCULATE THE STRESSES FOR EXAMPLE.
3) When i run the programme like you show me, at the and i see that i have juste one step!!!