Motionview flexbodies stress results

Pantelis_Myrio
Pantelis_Myrio Altair Community Member

Hello,
I’m using the Vehicle Tools in MotionView and have successfully imported a FlexBody into my model. After running the simulation, I was able to visualize the stress and strain contours in HyperView.

Now, I would like to extract the stress values (e.g., von Mises stress) for each node of the FlexBody into a readable file format, such as CSV or PLT.

Could you please guide me on how to export these stress values per node from the simulation results?

Best Answer

Answers

  • Vishvam
    Vishvam
    Altair Employee
    Answer ✓

    Hello @Pantelis_Myrio,

    This can be achieved from Hyperview "Plots Query" option, wherein you can select the desired node and the result type, and plot the curve. Which can be further exported to csv. But this would be time-consuming based on the size of your flexbody.

    Another approach can be using Altair Compose script, which can automate this whole process using it's inbuilt CAE Reader utility. This directly takes in the .h3d as input, and you can select the nodes and outputs required and write few code lines to export it into a csv file.
    The below links will be helpful.

    Compose Interacting with Altair Products eLearning v2022.3 - Module 2 CAE Readers Library
    Compose-3020: Read CAE Data in OML
    Altair Compose for Processing CAE/Test Data

    Also you can go through the compose FAQ page

    Hope this helps!

  • Pantelis_Myrio
    Pantelis_Myrio Altair Community Member

    Hello,
    I tried Compose and it did what I was hpoing to but now I have another problem. I want to run the compose script that I have created using matlab.


    I saw that this line works "C:\Program Files\Altair\2025\Compose2025\Compose_Console.bat" -e "filePath=C:/Users/pantm/OneDrive/Desktop/TEST_LCA_doublelane_0.h3d" -f "C:/Users/pantm/OneDrive/Desktop/get_stress.oml" when i run it in cmd.

    When i run this from matlab system("C:\Program Files\Altair\2025\Compose2025\Compose_Console.bat" -e "filePath=C:/Users/pantm/OneDrive/Desktop/TEST_LCA_doublelane_0.h3d" -f "C:/Users/pantm/OneDrive/Desktop/get_stress.oml") it doesnt, giving these errors Syntax error at line number 1 near character position 1
    Error: 'filePath' is not defined at line number 17 in file get_stress.oml
    .

    Any idea why ?

    The script is a function and is currently looking like this:

    function get_stress(filePath)

    % Display the received file path for debugging

    disp('Received File Path:');

    disp(filePath);

    % Read the CAE data using the provided filePath

    data = readcae(filePath, 'Transient', 'Stress (Flexbody/10602)', {}, {'vonMises (Z1)'}, {}, 1); % Get the maximum stress value out = max(data(:));

    % Display the maximum stress value

    disp('Max Stress:');

    disp(out);

    end

    get_stress(filePath)



    Thanks in advance!

  • Vishvam
    Vishvam
    Altair Employee

    Hi @Pantelis_Myrio

    I am not 100% sure what might be the issue in matlab. As Matlab documentation would be helpful in understanding the correct syntax here. But you can try this one thing which might work:

    system('"C:\Program Files\Altair\2025\Compose2025\Compose_Console.bat" -e "filePath=C:/Users/pantm/OneDrive/Desktop/TEST_LCA_doublelane_0.h3d" -f "C:/Users/pantm/OneDrive/Desktop/get_stress.oml"')

    You need to use double quotes inside double quotes (or use single quotes on the outside) so that the string passed to the OS is well-formed.

  • Pantelis_Myrio
    Pantelis_Myrio Altair Community Member

    Thank you for your response, it doesnt seem to work but I will check matlab's documentation!

  • Pantelis_Myrio
    Pantelis_Myrio Altair Community Member

    Hello Vishvam,

    I checked the solutions you proposed and I chose to use compose.

    I also noticed that the plots query in the 2024.1 version doesn't include stresses.

    I am able to plot all the other results apart from that. Contour to visualize stressed works just fine.