OpenFAST / openfast

Main repository for the NREL-supported OpenFAST whole-turbine and FAST.Farm wind farm simulation codes.
http://openfast.readthedocs.io
Apache License 2.0
671 stars 453 forks source link

BeamDyn reports wrong inertia (missing cg-offsets and section inertia) in summary file #1337

Open ebranlard opened 1 year ago

ebranlard commented 1 year ago

Bug description The blade inertia reported in the summary file is missing several contributions (center of mass offsets and cross-section inertia, in particular the polar moment of inertia). The calculation is done here For a straight blade, the summary file will always return 0 inertia in the (3,3) term. As far as I can tell, this calculation is only done for the summary file output, so it should have a minor impact on the code.

To Reproduce Write a BeamDyn summary file with any beamdyn blade file. The blade inertia is wrong in the (3,3) element.

Expected behavior For a volume, V, the inertia is obtained over integration over all points of the volume $\boldsymbol{r}$:

  J = - \int_V \tilde{\boldsymbol{r}} \tilde{\boldsymbol{r}}  dm(\boldsymbol{r})
=     \int_V
    \begin{bmatrix}
        r_y^2+r_z^2 & -r_x r_y & -r_x r_z \\
        -r_y r_x & r_x^2 + r_z^2 & -r_y r_z \\
       - r_z r_x & -r_z r_y  & r_x^2+r_y^2
    \end{bmatrix} dm(\boldsymbol{r})

If for simplicity, the integral is performed along a line, $L$ (with the curvilinear coordinate $s$), the inertia is something like:

  J = - \int_L \tilde{\boldsymbol{r}}(s) \tilde{\boldsymbol{r}} (s)  m(s)  ds    +  \int_L \boldsymbol{j}(s) ds

where $m(s)$ is the mass per length at a given cross-section, and $\boldsymbol{j}$ is the moment of inertia density (i.e. per length and for each cross-section). If all the mass were concentrated at the center of mass, and if the line $L$ corresponds to the center of mass line, then the second part would be zero. The first part is what is being computed by BeamDyn (here). For a straight blade, the first term's contribution to $J_{zz}$ is always zero (because $r_x^2+r_y^2$). No matter if the blade is straight or not, we need to add the second term's contribution to end up with the correct inertia (accounting for center of mass offsets and section inertia).

I believe one solution would consist in

As an alternative (that's the method I was using when I found this bug), I believe we could obtain the rigid body mass matrix of the Blade by computing:

   \boldsymbol{M}_{66} =  \boldsymbol{S}^T  \boldsymbol{M}  \boldsymbol{S}

Where $\boldsymbol{S}$ is the matrix of rigid body modes in its 6 columns, and $\boldsymbol{M}$ is the mass matrix. Maybe the rigid body modes need to be scaled by the integration weights to improve the accuracy.

andrew-platt commented 1 year ago

Originally reported in #302. This is a better description, so closing #302.