Different results with custom 6dof solver in pitch with newmark scheme
Hi,
I am trying to write my own custom 6dof (only in pitch) solver under the solidBodyMotionFunction class, using the newmark scheme. Reason is that my body undergoes large pitching rotation and if I use the org sixDoFRigidBodyMotion, the mesh deformation will be severe. However, if I run it under the solidBodyMotionFunction class, the whole body will pitch as a whole with no deformation. I start off with modifing the rotatingmotion code since that's the nearest to what I want. So instead of prescribed rotation, the angle will be determined by the 6dof solver. I followed the newmark scheme as given in the newmmark.C under the sixDoFRigidBodyMotion: Code:
//newmark scheme I then compared my case with the wingMotion2D from the tutorial. I modified a bit to make it just simple pitch rotation in 1dof . The results I obtained are similar for t = 0.1 and 0.2 but then the results start to diverge and for my case, the pitch angle keeps increasing. However, for the org tutorial, the pitch angle starts to reverse after ~ t = 0.4. I wonder why. Is there anything which I missed out? Is using a custom 6dof solver under the solidBodyMotionFunction class sufficient to get the correct ans? Hope someone can help or give some suggestions. Thanks. |
Anyone can help?
I'm still struggling with the error. After t ~ 0.2s, the difference between my result and OF's gets bigger and bigger. My understanding of 6dof, simplified for my problem is as follows: For simple pitch only 1dof z axis mz = external pitch force izz = moment of inertia in z axis center of rotation = center of mass angular acceleration acc = mz/izz v = u + acc*t, where v, u and t = new velocity, old velocity, delta time new final displacement theta = theta_old + u*t + 0.5*acc*t^2 That's the simplest way. However, for better accuracy and stability, we can use the newmark scheme whereby: acc = accelerationRelaxation_*(mz/izz); v = u + accelerationDamping_*t*(gamma_*acc + (1. - gamma_)*acc_old); theta = theta_old + u*t + accelerationDamping_*t^2*(beta_*acc + (0.5 - beta_)*acc_old); Is there anything wrong with the above formulas? |
All times are GMT -4. The time now is 09:59. |