AI Assistant
Execute *scl file f...
 
Notifications
Clear all

Execute *scl file from Matlab

4 Posts
2 Users
0 Reactions
5,899 Views
tinh nguyen
Posts: 2
Topic starter
Translate
English
Spanish
French
German
Italian
Portuguese
Russian
Chinese
Japanese
Korean
Arabic
Hindi
Dutch
Polish
Turkish
Vietnamese
Thai
Swedish
Danish
Finnish
Norwegian
Czech
Hungarian
Romanian
Greek
Hebrew
Indonesian
Malay
Ukrainian
Bulgarian
Croatian
Slovak
Slovenian
Serbian
Lithuanian
Latvian
Estonian
(@tinh-nguyen)
Unpaid Intern
Joined: 7 years ago
[#49]

I get stuck to run a Scripting Command Language file from Matlab. I am trying to read Ls- dyna results (by using "SCL") and to process it in Matlab.

Please help me! Thanks in advance.


3 Replies




Negative Volume
Posts: 681
Admin
Translate
English
Spanish
French
German
Italian
Portuguese
Russian
Chinese
Japanese
Korean
Arabic
Hindi
Dutch
Polish
Turkish
Vietnamese
Thai
Swedish
Danish
Finnish
Norwegian
Czech
Hungarian
Romanian
Greek
Hebrew
Indonesian
Malay
Ukrainian
Bulgarian
Croatian
Slovak
Slovenian
Serbian
Lithuanian
Latvian
Estonian
(@negativevolume)
CEO
Joined: 8 years ago

Hi @tinh-nguyen

Have you tried using ls-prepost cfiles to script the export of ls-dyna results to something that Matlab can use like a .csv file? This is the way that I normally do it. Is this an option for you or do you want to know how to directly pull results from the results using Matlab only?


Reply
2 Replies
tinh nguyen
(@tinh-nguyen)
Joined: 7 years ago

Unpaid Intern
Posts: 2
Translate
English
Spanish
French
German
Italian
Portuguese
Russian
Chinese
Japanese
Korean
Arabic
Hindi
Dutch
Polish
Turkish
Vietnamese
Thai
Swedish
Danish
Finnish
Norwegian
Czech
Hungarian
Romanian
Greek
Hebrew
Indonesian
Malay
Ukrainian
Bulgarian
Croatian
Slovak
Slovenian
Serbian
Lithuanian
Latvian
Estonian

Hi @negativevolume

Thanks a lot for your suggestion.

In my research, I am trying to make a program in Matlab which calls Ls-dyna for analysis. After that, this program also imports Ls-dyna results to process it. I get stuck to write a code (Matlab) to import the result data of Ls-dyna into Matlab. I have never tried using ls-prepost cfiles before, is it possible to solve it with cfiles?

Kind regard,

Tinh


Reply
Negative Volume
Admin
(@negativevolume)
Joined: 8 years ago

CEO
Posts: 681
Negative Volume
Translate
English
Spanish
French
German
Italian
Portuguese
Russian
Chinese
Japanese
Korean
Arabic
Hindi
Dutch
Polish
Turkish
Vietnamese
Thai
Swedish
Danish
Finnish
Norwegian
Czech
Hungarian
Romanian
Greek
Hebrew
Indonesian
Malay
Ukrainian
Bulgarian
Croatian
Slovak
Slovenian
Serbian
Lithuanian
Latvian
Estonian

@tinh-nguyen

Very cool. I'm not sure if there is any way to directly import results from a .binout / .ascii files into Matlab, but do share if you figure it out. 

Cfiles are written as an echo whenever you are working in LS-PrePost, so every action that you do in PrePost has a script based command. What I have done traditionally is go through PrePost and plot / save the data that you want to post-process as a .csv, or whatever file format you'd like, and then copy and save the resulting .cfile in your file directory to retain the commands used to plot everything. You can open and modify these .cfiles as a .txt file, they are pretty simple. 

As a test, you can then test the cfile by opening PrePost and dragging the cfile into the window and clicking start. It should run through everything you did before. Now, the use of these really comes by removing the specific paths in the .cfile for opening .binouts and save locations because by default without paths, it will look for and save files in the location of the .cfile. So you can use Matlab to copy these .cfiles to specific folders and run them which will provide you with a file that you can then open in Matlab. 

Let me know if you need more clarification / help with this. It's an extremely useful tool when post-processing multiple simulations the same way. 


Reply







Share: