How is getKineticEnergy defined in Edempy?

Santiago Garrido
Santiago Garrido Altair Community Member
edited August 2022 in Community Q&A

Hi,

I'm wondering if the aforementioned function in Edempy includes both rotational and translational kinetic energies (or just one of these two). 

I tried looking at the documentation but there the description simply reads: 

"Returns numpy.ndarray of kinetic energy for all particles of current type in the current timestep."

And I couldn't find a way to access the function to see how it is defined. 

 

Could you please clarify this for me? Thanks in advance.

Tagged:

Best Answer

  • Renan
    Renan
    Altair Employee
    edited August 2022 Answer ✓

    Hi Santiago,

     

    The getKineticEnergy function in EDEMpy just takes the particle mass and linear velocity as inputs. If you are interested in the rotational kinetic energy you'd need to use the getRawInertia and getAngularVelocities functions 

    Best regards,

    Renan

Answers

  • Renan
    Renan
    Altair Employee
    edited August 2022 Answer ✓

    Hi Santiago,

     

    The getKineticEnergy function in EDEMpy just takes the particle mass and linear velocity as inputs. If you are interested in the rotational kinetic energy you'd need to use the getRawInertia and getAngularVelocities functions 

    Best regards,

    Renan

  • Santiago Garrido
    Santiago Garrido Altair Community Member
    edited August 2022

    Hi Santiago,

     

    The getKineticEnergy function in EDEMpy just takes the particle mass and linear velocity as inputs. If you are interested in the rotational kinetic energy you'd need to use the getRawInertia and getAngularVelocities functions 

    Best regards,

    Renan

    Hi Renan,

     

    Thanks for the answer! So just to be clear, the getKineticEnergy function only performs the classic m*v^2/2. Correct? 

     

    Also thanks for indicating those extra functions, with that I know how to calculate the rotational one. 

     

    Best regards.

  • Renan
    Renan
    Altair Employee
    edited August 2022

    Hi Renan,

     

    Thanks for the answer! So just to be clear, the getKineticEnergy function only performs the classic m*v^2/2. Correct? 

     

    Also thanks for indicating those extra functions, with that I know how to calculate the rotational one. 

     

    Best regards.

    Hi Santiago,

    That's correct. The getKineticEnergy function only calculates the quantity m*v^2/2 for all particles in your simulation

     

    Best regards,

    Renan