MongoDB:如何在没有索引的情况下计算两个坐标内的距离

我需要在一个聚合框架中获得两个坐标之间的距离,但是只有pipe道的第一个匹配(我使用$ text)才能使用索引,并且我不能在同一个匹配查询中使用$ geoNear或$ text 。 我解决了使用下列方法返回半径坐标的问题:

{$geoWithin: {$centerSphere: [[lon, lat], (distance*1000)/6731]}} 

但我不知道如何计算没有使用索引的距离。

这是pipe道的前两个阶段

 [ { '$match': { '$text': { $search: "some text" } } }, { '$match': { coordinate: {$geoWithin: {$centerSphere: [[lon, lat], (distance*1000)/6731]}}, type: 0 } } ] 

有可能通过在这个pipe道中增加一个$项目来返回[x,y]和[lon,lat]之间的距离?