Gianni,

I am a bit confused.  Assuming you are talking about the function 
chrono::utils::AddBoxContainer<https://github.com/projectchrono/chrono/blob/e3eb07ec07abcd4adcfc24054335547e462eae98/src/chrono/utils/ChUtilsCreators.h#L250>,
 note that this functions does *not* create a body but rather just attaches 
collision (and optionally visualization) geometry to an existing body.  As 
such, what is relevant here is the rotation of the body (which you must have 
created prior to invoking AddBoxContainer).  If you have specified a 
non-identity frame (transform) for the box container relative to the parent 
body, you will then need to concatenate the two rotations.

I cannot help with your question about the “disassembled” container, since I 
have no idea how/what you save to that CSV file, nor do I know how you try to 
reconstruct the container from data read from that file.

Finally, the dimensions passed to AddBoxContainer represent the *interior* size 
of the container.  That is clearly indicated in the 
documentation<https://api.projectchrono.org/group__chrono__utils.html#ga6f8dc768acdf64a53c94baffb53fc3dc>
 (also, you can always look at the 
implementation<https://github.com/projectchrono/chrono/blob/e3eb07ec07abcd4adcfc24054335547e462eae98/src/chrono/utils/ChUtilsCreators.cpp#L557>).

--Radu

From: [email protected] <[email protected]> On Behalf 
Of Gianni Curti
Sent: Sunday, August 4, 2024 11:07 PM
To: ProjectChrono <[email protected]>
Subject: [chrono] Retrieving the rotation of a box container in Multicore

Hi,
I have an object in Chrono::Multicore created with the command 
"AddBoxContainer", and I need to obtain the quaternion describing its rotation 
at each timestep. I tried with "GetRot" but all I obtain is a 1x4 vector full 
of "-nan(ind)" and I cannot understand why since from the graphical interface I 
can clearly see that the body is rotating.
I have also tried to add a marker to the body but I did not get any result. Can 
you please help me?

Another question regards saving the box container in a csv file to be read by 
another simulation. When I start the second simulation, the box appears to be 
like "disassembled" with all the walls far from each other. Am I missing 
something?

The last doubt is about how the box containers are created. Do the three 
dimesions describe the inner or the outer envelope of the box?

Thank you for your kindness.

Gianni
--
You received this message because you are subscribed to the Google Groups 
"ProjectChrono" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to 
[email protected]<mailto:[email protected]>.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/projectchrono/7e241951-99b3-4995-8cbc-cf42f432bca0n%40googlegroups.com<https://urldefense.com/v3/__https:/groups.google.com/d/msgid/projectchrono/7e241951-99b3-4995-8cbc-cf42f432bca0n*40googlegroups.com?utm_medium=email&utm_source=footer__;JQ!!Mak6IKo!KI3VdWEXMvD0ljRPIpAwZFrW44305yQdKYu6Af4oGdmB34PXwy5oybIBM2bXVRwqNhOiVftbdq9_MppA61Td$>.

-- 
You received this message because you are subscribed to the Google Groups 
"ProjectChrono" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/projectchrono/CH3PPF46CDC2185EB471087C67C4EECD98FA7BE2%40CH3PPF46CDC2185.namprd06.prod.outlook.com.

Reply via email to