Skip to content

Voronoi Diagram; Area weighted Thiessen polygon interpolation method

Notifications You must be signed in to change notification settings

kenash0625/Thiessen-polygon-interpolation

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

29 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

fantastic-guacamole

In order to achieve accurate estimation of the spatial distribution of rainfall, it is necessary to use interpolation methods,this is the area weighted Thiessen polygon method. input:point layer and polygon layer output:thiessen polygon and weight

dependencies gdal2.3.2 geos3.6.3

Edited geos-3.6.3\src\triangulate\quadedge\QuadEdgeSubdivision.cpp line 588 ,added the following :

	cellPoly->setUserData(reinterpret_cast<void*>(geomFact.createPoint(c)));
	return cellPoly;

Edited geos-3.6.3\src\triangulate\VoronoiDiagramBuilder.cpp line 136 ,moved one line:

	else if(clipEnv.intersects(g->getEnvelopeInternal()))
	{
		result.reset( clipPoly->intersection(g) );
	}
	
	if(result.get() && !result->isEmpty() )
	{result->setUserData(((Geometry*)g)->getUserData()); // moved
		clipped->push_back(result.release());
	}

Usage:(edit paths) D:\MyFirstProject\fantastic-guacamole.git\trunk\Debug\ConsoleApplication2.exe D:\MyFirstProject\fantastic-guacamole.git\trunk\Debug\test\jczd.shp D:\MyFirstProject\fantastic-guacamole.git\trunk\Debug\test\wata.shp

About

Voronoi Diagram; Area weighted Thiessen polygon interpolation method

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages