How to Using Matlab Calling LS-PrePost to Generate Text Files

11 Ansichten (letzte 30 Tage)
Mercedes
Mercedes am 8 Dez. 2012
Beantwortet: Jiguang Wu am 22 Sep. 2016
Hi,
LS-DYNA simulation results are in d3plot files, which can be opened by LS-PrePost. I wonder how to use Matlab operating LS-PrePost to save the coordinates/displacements of SPH particles (only final state needed) into text files or whatever files that can be read by Matlab. Not sure what codes should I put in Matlab or if there's any other way to do this.
Mercedes

Antworten (1)

Jiguang Wu
Jiguang Wu am 22 Sep. 2016
Hi, Mercedes The d3plot files contain animation of whole structure. What I'm most interested in is acsii file, such as nodout, rcforc and spcforc. The nodout file has information of nodal coordinates, displacement, velocity and acceleration. To display the result, you can use ls_prepost script named nodout.cfile, the file is
ascii nodout open "nodout" 0
ascii nodout plot 1 4821
xyplot 1 savefile xypair "nodout_4821_1" 1 all
xyplot 1 donemenu
exit
the nodout.cfile export the x-displacement of node 4821 to a text file named nodout_4821_1. you can modify the cfile to obtain the result you want.
the commnand in matlab call ls_prepost to run is
dos('ls_prespost nodout.cfile')

Kategorien

Mehr zu Scripts finden Sie in Help Center und File Exchange

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by