×
INTELLIGENT WORK FORUMS
FOR ENGINEERING PROFESSIONALS

Log In

Come Join Us!

Are you an
Engineering professional?
Join Eng-Tips Forums!
  • Talk With Other Members
  • Be Notified Of Responses
    To Your Posts
  • Keyword Search
  • One-Click Access To Your
    Favorite Forums
  • Automated Signatures
    On Your Posts
  • Best Of All, It's Free!
  • Students Click Here

*Eng-Tips's functionality depends on members receiving e-mail. By joining you are opting in to receive e-mail.

Posting Guidelines

Promoting, selling, recruiting, coursework and thesis posting is forbidden.

Students Click Here

Jobs

parametrical simulation

parametrical simulation

parametrical simulation

(OP)
I would like to perform one simulation which has a few steps:
- one load is changing and after each step result from one node i stored in file
How to do this using loops?
thx

RE: parametrical simulation

1. Define vector with length number of steps.

*dim,result,array,steps

2. Start a do loop:

*do,i,1,steps

3. Solve and get the nodal result

/solu
solve
/post1
*get,result(i),node,....

4. End do loop

*enddo

5. Write vector to file

*mwrite,result(1),result,dat
(1F20.6)

RE: parametrical simulation

(OP)
I would like to store Z displacement of node 30
each time in results2.dat only FINISH line is stored (amount correspond to steps value)

---------

steps=2
*dim,result,array,steps       - two steps
*dim,volts,array,3       - array with different load values

volts(1)=10
volts(2)=100
volts(3)=1000

*do,i,1,steps

/PREP7
   NSEL,S,LOC,Z,dif+h
   D,ALL,VOLT,volts(2)
   NSEL,ALL

/SOLU
   ANTYPE,STATIC
   SOLVE

/POST1
   *get,result(i),node,30,u,z

*enddo

*mwrite,result,result2,dat

------------------

Red Flag This Post

Please let us know here why this post is inappropriate. Reasons such as off-topic, duplicates, flames, illegal, vulgar, or students posting their homework.

Red Flag Submitted

Thank you for helping keep Eng-Tips Forums free from inappropriate posts.
The Eng-Tips staff will check this out and take appropriate action.

Reply To This Thread

Posting in the Eng-Tips forums is a member-only feature.

Click Here to join Eng-Tips and talk with other members!


Resources