Distance Measurament B/w Beacon And Gateway

Hello Estimote Team,
I am not getting accurate distance between Beacon and gateway.
i am using following Formula
RSSI = -20 * logd + TxPower (where d = distance) from this link Determine accurate distance of signal

My RSSI value is : -80 and TxPower is : -90
As per formula i am getting distance : 0.31622776601684 metes
But actual distance is : 5 meters

Can you please tell me what is wrong distance calculation.