Forum: Answers and discussion

Monitor Forum | Start New Thread Start New Thread
Displaying NASTRAN stress output [ Reply ]
By: Balmes on 2009-07-16 09:48
[forum:20]

The initial bulk file had a problem : YOU SHOULD NOT USE FORM=FORMATTED for OP2 files

ASSIGN OUTPUT2 = '2Dplane.op2', UNIT = 12$, FORM = FORMATTED

% Sample display of stresses read from NASTRAN

cf=feplot;
nasread('2Dplane.op2');
cf.Stack % display the entries that were read
cf.def=cf.Stack{'OUG(1)'};  %display deformation

r1=cf.Stack{'OES1X1(1)'} % the stresses with PARAM,POST,-1
%r1=cf.Stack{'OES1(1)'}; % the stresses with PARAM,POST,-2
i1=16; % Von mises on top fiber;
fecom('colordataelt',struct('EltId',r1.X{1},'data',r1.Y(:,i1))); % display color

% To write a model
naswrite('test.bdf',cf.mdl);