MODAL output from Abaqus to Matlab (Record key 1980)
In this example a simple Abaqus model is analysed and results are retrieved by postprocessing the results *.fil file generated by Abaqus using Matlab. For more information please see the Documentation of Abaqus2Matlab toolbox.
Contents
Run Abaqus model
Change current directory to Abaqus working directory
a = strfind(S,'\');
cd(S(1:a(end)-1))
Copy the input file to be run by Abaqus into the Abaqus working directory
copyfile([S,'\AbaqusInputFiles\1980.inp'],[S(1:a(end)-1),'\1980.inp'],'f')
Run the input file 1980.inp with Abaqus
!abaqus job=1980
Pause Matlab execution to give Abaqus enough time to create the lck file
pause(10)
If the lck file exists then halt Matlab execution
while exist('1980.lck','file')==2 pause(0.1) end
Postprocess Abaqus results file with Matlab
Assign all lines of the fil file in an one-row string (after Abaqus analysis terminates)
Rec = Fil2str('1980.fil');
Obtain the desired output data
out = Rec1980(Rec)
out = 1.0e+06 * Columns 1 through 3 0.000001000000000 0 0.000002759043609 0.000002000000000 0 0.000002479694534 0.000003000000000 0.000000000000000 0.000002131232517 0.000004000000000 0.000000000000000 0.000001376338419 0.000005000000000 0.000000000000000 0.000001487922843 0.000006000000000 0.000000000000000 0.000001711232302 0.000007000000000 0.000001416397939 0.000002530684255 0.000008000000000 0.000013151093433 0.000002766384232 0.000009000000000 0.000014646234081 0.000003101353588 0.000010000000000 0.000043251206716 0.000003891928495 Columns 4 through 6 0 0.000000000000000 0.000000000000000 0 -0.000000000000000 -0.000000000000000 0 0.000000000000000 -0.000000000000000 0 -0.000000000000000 -0.000000000000000 0 0.000000000000000 0.000000000000000 0 -0.000000000000000 -0.000000000000000 0 0.000000000000000 0.000001105052207 0 0.000001155672518 0.000000000000000 0 0.000000000000000 0.000000532285136 0 -0.000000000000000 -0.000000033616920 Columns 7 through 9 -0.000000014027347 -0.000248357375262 0.000012901200166 0.000000065024434 0.000100905678922 -0.000085113139961 0.000001339884146 0.000247482024720 -0.000361716135031 0.000001249903542 0.000197186441009 -0.000680052913959 -0.000000026388587 0.000032504265299 -0.000372757276793 0.000000082191355 0.000067298740090 0.000301415849656 0 0 0 0 0 0 0 0 0 0 0 0 Columns 10 through 12 0.000000000000000 0.000000000000000 0.000000000000000 -0.000000000000003 0.000000000000000 0.000000000000000 -0.000000000000003 0.000000000000000 0.000000000000000 -0.000000000000000 0.000000000000000 0.000000000000000 0.000000000000003 0.000000000000000 0.000000000000000 -0.000000000000004 0.000000000000000 0.000000000000000 0.000747409244904 0.000000000000000 0.000003090320734 -0.000208021053185 0.000003694724597 0.000000000000000 0.000044968031440 0.000000000000000 0.000000878698654 -0.000028481189428 0.000000000000000 0.000000004398258 Columns 13 through 15 0.000000000542887 0.170181633418716 0.000459217882742 0.000000010484587 0.025248140736398 0.017963518683581 0.000003826179411 0.130532349357449 0.278847398544362 0.000002150196897 0.053515468281103 0.636517934245476 0.000000001036126 0.001572031048744 0.206743884501058 0.000000011560091 0.007750377157180 0.155468046144639 0 0 0 0 0 0 0 0 0 0 0 0 Column 16 0.000000000000000 0.000000000000000 0.000000000000000 0.000000000000000 0.000000000000000 0.000000000000000 1.413692304991781 0.119709076958187 0.006271321061851 0.003157047360961
Verify output
Check number of attributes
nAttr=size(out,2)
nAttr = 16
Check the number of entries
nEntr=size(out,1)
nEntr = 10
Check class of output
cOut=class(out)
cOut = double
____________________________________________________ Copyright (c) 2016 by George Papazafeiropoulos Captain, Infrastructure Engineer, Hellenic Air Force Civil Engineer, M.Sc., Ph.D. candidate, NTUA Email: gpapazafeiropoulos@yahoo.gr Website: http://users.ntua.gr/gpapazaf/