← Back to team overview

yade-users team mailing list archive

Re: [Question #696759]: How can polyhedron use CpmMat 、Ip2_CpmMat_CpmMat_CpmPhys()and Law2_ScGeom_CpmPhys_Cpm() ?

 

Question #696759 on Yade changed:
https://answers.launchpad.net/yade/+question/696759

    Status: Open => Answered

Jan Stránský proposed the following answer:
CpmState() is "fresh" e.g. with zero mass (after O.step, pos is NaN because of zero mass and therefore "disappeared"), you have to "clone" the state:
###
oldState = poly1.state
poly1.state = CpmState()
poly1.state.mass = oldState.mass
# same for inertia, ori, ...
###

cheers
Jan

-- 
You received this question notification because your team yade-users is
an answer contact for Yade.