×
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!

*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

Read an txt.file from ABAQUS

Read an txt.file from ABAQUS

Read an txt.file from ABAQUS

(OP)
Dear all.


I would like to know how can I take the information out of ABQUS in a txt. file ( temperature node vs time) and then use it in matlab as this.The solution from ABAQUS is like this
                           temperature(ºC)
                node 123            node 456     node 778
x(time)
0                0                    0            0
1                0                    0            0
2                1                    0            0
3                1                    1            0
4                1                    1            1

 
When I open in matlab ,I make some mathematical operations  and then I extract the minimal value from the temperature and its position and node , the answer is always the same  first position , because Matlab asumes that the minimal value is in the first node  since the first node is 123 .
 
Well , I appreciated if you could help me  with this!!!!!
 
Thanks in advanced

kind regars,

paulis
 
Replies continue below

Recommended for you

RE: Read an txt.file from ABAQUS

Hi pauli,

I don't understand the problem.
Is it reading the file or sorting the data?
To read in the file try something like this:

--
clear all; clc;

file='abaqus.txt';
fid=fopen(file);
data=textscan(fid,'%f %f %f %f','HeaderLines',3,'Delimiter',' ','MultipleDelimsAsOne',1);
fclose(fid);
data % cell
[data{:}] % matrix
--

all the best
nschlange

RE: Read an txt.file from ABAQUS

(OP)
Dear nschlange,

Thank you so much! I am working with this kind of file , because I want to discover the slowest heating point from a piece of food with some  outside thermal load. I can extract an txt .file from abaqus like temperature node vs time. So I have to know which is the slowest  heating point= which is the slowest heating node and its temperature.

kind regards,

Paulis happy shades

RE: Read an txt.file from ABAQUS

Dear Paulis,

I'm still missing the point.
Is my work done or do you need further advice?
If so, what is the slowest heating node in this example?

all the best
nschlange

RE: Read an txt.file from ABAQUS

Hi Paulis,

Can you tell me how you extract a text file from ABAQUS? The need just came up and I was trying to use Fortran to read the results but if they can be written to a text file which can be read by Matlab then that will make life so much easier!! Please let me know!

Thanks :)

RE: Read an txt.file from ABAQUS

(OP)
Dear RM 447 , what I did is to read the inp.file from abaqus in matlab.  i give an example to read the inp file

fdat=fopen('gsinvrt.inp','r');
fout=fopen('cut3.inp','w');

%aca
nod=96373;
tline = fgetl(fdat);
pos=strfind(tline,'*Node');
while length(pos)==0
    tline = fgetl(fdat);
    pos=strfind(tline,'*Node');
end
nodos=fscanf(fdat,'%d, %f, %f, %f',[4 nod]);
k=nodos(1,:);x=nodos(2,:);y=nodos(3,:);z=nodos(4,:);
clear nodos;


well , good luck!!!!!!

kisses

Paula

   

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! Already a Member? Login



News


Close Box

Join Eng-Tips® Today!

Join your peers on the Internet's largest technical engineering professional community.
It's easy to join and it's free.

Here's Why Members Love Eng-Tips Forums:

Register now while it's still free!

Already a member? Close this window and log in.

Join Us             Close