diff --git a/src/route/fib-entry.cpp b/src/route/fib-entry.cpp
index a7eb68f..07346f0 100644
--- a/src/route/fib-entry.cpp
+++ b/src/route/fib-entry.cpp
@@ -31,30 +31,6 @@
 
 using namespace std;
 
-bool
-FibEntry::isEqualNextHops(NexthopList& nhlOther)
-{
-  if (m_nexthopList.getSize() != nhlOther.getSize()) {
-    return false;
-  }
-  else {
-    uint32_t nhCount = 0;
-    std::list<NextHop>::iterator it1, it2;
-    for (it1 = m_nexthopList.getNextHops().begin(),
-         it2 = nhlOther.getNextHops().begin() ;
-         it1 != m_nexthopList.getNextHops().end() ; it1++, it2++) {
-      if (it1->getConnectingFaceUri() == it2->getConnectingFaceUri()) {
-        it1->setRouteCost(it2->getRouteCost());
-        nhCount++;
-      }
-      else {
-        break;
-      }
-    }
-    return nhCount == m_nexthopList.getSize();
-  }
-}
-
 void
 FibEntry::writeLog()
 {
diff --git a/src/route/fib-entry.hpp b/src/route/fib-entry.hpp
index 7f39fdd..2c98002 100644
--- a/src/route/fib-entry.hpp
+++ b/src/route/fib-entry.hpp
@@ -102,9 +102,6 @@
     return m_seqNo;
   }
 
-  bool
-  isEqualNextHops(NexthopList& nhlOther);
-
   void
   writeLog();
 
diff --git a/src/route/fib.cpp b/src/route/fib.cpp
index de9d365..1e8b9ed 100644
--- a/src/route/fib.cpp
+++ b/src/route/fib.cpp
@@ -112,7 +112,7 @@
     if (isPrefixUpdatable(name)) {
       // Add nexthop to NDN-FIB
       registerPrefix(name, hopIt->getConnectingFaceUri(),
-                     std::ceil(hopIt->getRouteCost()),
+                     hopIt->getRouteCostAsAdjustedInteger(),
                      ndn::time::seconds(m_refreshTime + GRACE_PERIOD),
                      ndn::nfd::ROUTE_FLAG_CAPTURE, 0);
     }
diff --git a/src/route/nexthop-list.cpp b/src/route/nexthop-list.cpp
index 0822d38..9ef6fd3 100644
--- a/src/route/nexthop-list.cpp
+++ b/src/route/nexthop-list.cpp
@@ -41,7 +41,7 @@
 nexthopRemoveCompare(NextHop& nh1, NextHop& nh2)
 {
   return (nh1.getConnectingFaceUri() == nh2.getConnectingFaceUri() &&
-          nh1.getRouteCost() == nh2.getRouteCost()) ;
+          nh1.getRouteCostAsAdjustedInteger() == nh2.getRouteCostAsAdjustedInteger()) ;
 }
 
 static bool
diff --git a/src/route/nexthop.hpp b/src/route/nexthop.hpp
index a354752..a4feec2 100644
--- a/src/route/nexthop.hpp
+++ b/src/route/nexthop.hpp
@@ -56,10 +56,15 @@
   }
 
   uint64_t
+  getRouteCostAsAdjustedInteger() const
+  {
+    return static_cast<uint64_t>(m_routeCost*HYPERBOLIC_COST_ADJUSTMENT_FACTOR);
+  }
+
+  double
   getRouteCost() const
   {
-    uint64_t routeCost = static_cast<uint64_t>(ceil(m_routeCost));
-    return routeCost;
+    return m_routeCost;
   }
 
   void
@@ -71,6 +76,7 @@
 private:
   std::string m_connectingFaceUri;
   double m_routeCost;
+  static const uint64_t HYPERBOLIC_COST_ADJUSTMENT_FACTOR = 100;
 };
 
 }//namespace nlsr
