09-30-2019, 10:01 AM

I have to admit that I do not have a feel for the acceleration of the tree doing a swaying motion, so I don't have an estimate of how bad it is. But the inclination is calculated from all axes of the acceleration. Let me give an example:

Let's assume that the y axis is pointing upwards along the tree (that's probably the most natural way to mount a phone, but any other orientation would lead to the same) and that the wind is blowing along the z direction (perpendicular to the screen). Then the tree would sway around the x axis.

When the tree is perfectly upright, phyphox should see an acceleration of 9.81m/s² along y and nothing along x or z. If the tree is bent to an angle of 10°, we will recognize this because earth's acceleration is no longer pointing perfectly along y, but there is also a small component along z as well. The ratio of the contribution along y over the contribution along z the tangent of the angle, so phyphox will calculate atan(y/z) to get that angle. That is 1.7m/s² along z and 9.66m/s² along y to get atan(y/z) = 10°.

Now, if the tree is not simply bent that way, but actually swaying (and the phone is swaying with it), there is an acceleration at the reversal points of the swaying motion, which also contributes to the measured acceleration along z. So, if there is an acceleration of only 0.5m/s² (again, I don't have a feel for the numbers here, so I am not sure if this is an appropriate estimate), phyphox will see 2.2m/s² along z instead and will get atan(y/z) = 13°.

How bad this error gets, depends on how much acceleration you get from the swaying motion. You can get a good estimate if you assume a harmonic oscillation and put in the swaying period and the distance over which the tree sways and if it is significant, this info can also be used for a correction. Alternatively, it might be a good idea, to simply try it. Capture the swaying on camera while measuring it in the wind and then bent the tree to the same orientation while holding it there to measure again without swaying (well, of course it depends on the kind of tree if this is possible - I'm obviously thinking of small ones here).

Let's assume that the y axis is pointing upwards along the tree (that's probably the most natural way to mount a phone, but any other orientation would lead to the same) and that the wind is blowing along the z direction (perpendicular to the screen). Then the tree would sway around the x axis.

When the tree is perfectly upright, phyphox should see an acceleration of 9.81m/s² along y and nothing along x or z. If the tree is bent to an angle of 10°, we will recognize this because earth's acceleration is no longer pointing perfectly along y, but there is also a small component along z as well. The ratio of the contribution along y over the contribution along z the tangent of the angle, so phyphox will calculate atan(y/z) to get that angle. That is 1.7m/s² along z and 9.66m/s² along y to get atan(y/z) = 10°.

Now, if the tree is not simply bent that way, but actually swaying (and the phone is swaying with it), there is an acceleration at the reversal points of the swaying motion, which also contributes to the measured acceleration along z. So, if there is an acceleration of only 0.5m/s² (again, I don't have a feel for the numbers here, so I am not sure if this is an appropriate estimate), phyphox will see 2.2m/s² along z instead and will get atan(y/z) = 13°.

How bad this error gets, depends on how much acceleration you get from the swaying motion. You can get a good estimate if you assume a harmonic oscillation and put in the swaying period and the distance over which the tree sways and if it is significant, this info can also be used for a correction. Alternatively, it might be a good idea, to simply try it. Capture the swaying on camera while measuring it in the wind and then bent the tree to the same orientation while holding it there to measure again without swaying (well, of course it depends on the kind of tree if this is possible - I'm obviously thinking of small ones here).