﻿id	summary	reporter	owner	description	type	status	priority	milestone	component	version	resolution	keywords	cc
17614	Some polygon intersections are ignored	GerdP	team	"==== What steps will reproduce the problem?
1. Run validator on the attached osm file

==== What is the expected result?
Validator should report ""Overlapping Identical Natural Areas"" for the two rectangles in the upper left area like for those on the right.
==== What happens instead?
The rather large overlap in the upper left area is ignored, we also allow to create a multipolygon 
and if you verify that mp the overlap is detected because a different test is used.
==== Please provide any additional information below. Attach a screenshot if possible.
I think there are two reasons:
- First is that `Geometry.polygonIntersection(Area a1, Area a2, double eps)` use Rectangle instead of Rectangle2D
- Second is that the default value 1 for eps is far too high, no matter if the area is in EastNorth or LatLon. My understanding is that the eps value should be chosen so that we ignore really small overlaps which could disappear after rounding to OSM precision, so maybe 1e-7 for LatLon areas. 
I am still trying to find out the proper value for EastNorth.
{{{
URL:https://josm.openstreetmap.de/svn/trunk
Repository:UUID: 0c6e7542-c601-0410-84e7-c038aed88b3b
Last:Changed Date: 2019-03-31 21:17:00 +0200 (Sun, 31 Mar 2019)
Build-Date:2019-03-31 20:25:18
Revision:14945
Relative:URL: ^/trunk

Identification: JOSM/1.5 (14945 de) Windows 10 64-Bit
OS Build number: Windows 10 Home 1803 (17134)
Memory Usage: 370 MB / 1820 MB (160 MB allocated, but free)
Java version: 1.8.0_201-b09, Oracle Corporation, Java HotSpot(TM) 64-Bit Server VM
Screen: \Display0 1920x1080
Maximum Screen Size: 1920x1080
VM arguments: [-XX:StartFlightRecording=name=MyRecording2,settings=d:\dbg\gerd.jfc, -XX:FlightRecorderOptions=defaultrecording=true,dumponexit=true,dumponexitpath=e:\ld\perf_20190416_100731.jfr]
Dataset consistency test: No problems found

Last errors/warnings:
- W: No configuration settings found.  Using hardcoded default values for all pools.
}}}
"	defect	closed	normal	19.04	Core		fixed	template_report	Don-vip Klumbumbus
