On Apr 1, 2010, at 8:22 AM, Helleringer, Nicolas wrote:
> I did put a comment on the jira issue pointing to the code I wrote inside
> Chris Male perspective.
> He answered on the JIRA topic as well.
Yep, saw that. If you wish for that code to be in Lucene, you need to post it
as a patch to Lucene and grant provenance to the ASF.
Here's another question:
Given the same latitude and same distance, shouldn't there be the same number
of box ids no matter the longitude? Yet the following code says otherwise:
public void testCartesianPolyFilterBuilder() throws Exception {
CartesianPolyFilterBuilder cpfb = new
CartesianPolyFilterBuilder(CartesianTierPlotter.DEFALT_FIELD_PREFIX, 2, 15);
//try out some shapes
final double miles = 20.0;
// Hawaii
// 2300 miles to Marshall Island Airfield
//Hawaii to Midway is 911 miles
lat = 0;
lng = -179.9;
Shape shape;
shape = cpfb.getBoxShape(lat, lng, miles);
System.out.println("Tier: " + shape.getTierLevel());
System.out.println("area: " + shape.getArea().size());
lat = 30;
lng = -100;
shape = cpfb.getBoxShape(lat, lng, miles);
System.out.println("Tier: " + shape.getTierLevel());
System.out.println("area: " + shape.getArea().size());
lat = 30;
lng = 100;
shape = cpfb.getBoxShape(lat, lng, miles);
System.out.println("Tier: " + shape.getTierLevel());
System.out.println("area: " + shape.getArea().size());
}
-Grant