Distance Equation Coefficients for ibeacon Receiver

Hello I have some Anchors around my office, I’m developing an RTLS Zone location system.

I’m using the next code to calculate a estimation of the distance
(I Know this distance is only an approximation and it’s very sensitive to variation due to external factors,
I’m aware of it)

public double getDistance(int measuredPower, double rssi) {
if (rssi >= 0) {
return -1.0;
if (measuredPower == 0) {
return -1.0;
double ratio = rssi * 1.0 / measuredPower;
if (ratio < 1.0) {
return Math.pow(ratio, 10);
} else {
double distance= (0.42093) * Math.pow(ratio, 6.9476) + 0.54992;
return distance;

for this example we have three coefficients

This code is an extraction of a SDK used to get an estimation between an iBeacon an a cellPhone
and these coefficients are for some specific Cellphone Model (Samsung, iPhone etc.)

so well, my question is, using that equation to get distance from RSSI and measured power, what are
the recommended coefficients for the iBeacon Receiver device Coeff1, Coeff2 and Coeff3?

Sorry. We have no more experience about the coefficients.