Please keep in mind that the screenshot with avgFreezerTemp = 7.31 is taken after the calculation. Therefore, n-1FreezerTemp should be substituted for currentFreezerTemp and n-2FreezerTemp for n-1FreezerTemp.
It would be helpful if you would replace those with Log actions that show the progressive value of sum. And, turn on Action Logging, so that the actual values can be seen in the logs, not just the rule display.
My original rule is working just fine and I'm not having any issues.
I put the delays in to just put a gap in between each variable change for my piece of mind. Just me I suppose.
The rule that is failing was at the request of the OP as he wanted me to try something as his rule does not work.
Maybe have a look at the original post to see if you can help with his issue.
Yeah, I tested with decimal also. Had three decimal Hub Variables, put values in two of them, summed those to the third, and then divided the third by 2. All work as expected.