Continue to Site

Eng-Tips is the largest engineering community on the Internet

Intelligent Work Forums for Engineering Professionals

  • Congratulations MintJulep on being selected by the Eng-Tips community for having the most helpful posts in the forums last week. Way to Go!

Parsing Abaqus .inp file with Matlab

Status
Not open for further replies.

BigwillyJohnson

Mechanical
Apr 21, 2010
6
Hello All,

I am trying to write data to specific locations in the .inp text file using matlab. My grand scheme' is to have matlab and abaqus work together to optimize a model.

I can write to specific places but the incumbent text gets pushed and moved around.

For example

if a line has the word "**PARTS"
and the next line has "**"
and i write "12345678" to the first line

the result will be:
"12345678*" on the first line and whatever was on the third line will be on the second line

the text gets moved and messed up

Any help would be appreciated
Rick
 
Replies continue below

Recommended for you

Thx for the reply.

I ended up using fgets and fprintf to rewrite the file.

It only takes a few seconds.
 
After thinking about this I have another question.

Can python do the brute force math that matlab can do?

If so then I would see were I should cut matlab out of the picture completely.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor