Polygon Buffering

11231
20
Jump to solution
03-27-2015 02:36 AM
AmazingMapMan
New Contributor III

Hello,

i have a polygon-featureclass that represents all communitys of germany.

Now I want to add a buffer to all "border" communities.

The buffer should only extend to the "outside" of germany so that the area of all "border" communities is extended with "foreign" territory.

I made a freehand-drawing to better illustrate my intention.

See attatchment.

What would be the best way to achieve this?

I have an ArcGIS Standard License.

Or can you imagine an sql-based approach (mssql) to the problem?

Any help is appreciated!

greetings

Stefan

0 Kudos
1 Solution

Accepted Solutions
RichardFairhurst
MVP Honored Contributor

I agree that the user can use the Project tool to convert from a Geographic Coordinate System to a Projected Coordinate System before using my tool.  However, I am not familiar with the best projection choice for Germany, so I was not prepared to do that with this particular data.  Anyway, using a Projected Coordinate System would be a requirement of the line network buffer tool I am building at this stage and that requirement will be specified in the help and error messages for the tool by the time I release it.

Thanks for the feedback on the buffers.  I spent about 6 hours tweaking the results.  Essentially anywhere the cut between two communities bends, I drew that.   Bending cuts are not precisely measured to split between communities exactly 50/50 and is only eye ball accurate in those cases.  But since these cuts are within waters (rivers and coastal areas) obviously controlled by Germany and not another country, I was not too concerned about getting better precision.

For straight line cuts, the methods involved used a mixture of tools, some of which would require an Advanced license.  I had to use the Polygon to Line tool to extract the full community buffer outline and each communities outline as a line.  I had to delete all community boundaries that touched another community (easy to do if topology is perfect).  The Feature Vertices to Points tool was used to extract points from the ends of each community line for LR processing.  I also used the Features to Polygon tool to combine a set of lines at a normal angle to the buffer outline with the buffer to cut it into separate polygons.   The Feature Vertices to Points tool was used to extract points from the mid point of each community line and the Spatial Join tool (Basic license) was used to transfer attributes from the mid points to the cut up polygon output of the Features to Polygon tool.

The cut lines that were at a normal angle to the buffer outline were created with LR tools and techniques, which work with a Basic license.  With these tools I had to categorize the country outlines into groups that would build continuous non-branching, non-looping portions of the country outline into routes and then used the Create Route tool to build simple routes.  I used the Locate Features Along Route tool to create an event table of the community outside end points on the routes.  I used the Make Route Event layer to create offset points at 2 km from the Germany outline.  I used the Points to Line tool to create a line segment between the point on the line and the LR offset point.

The straight cut lines were all examined and where the normal angle to the line was not the best fit to the buffer I moved the offset end to a location that I liked manually.  I would estimate I did this for about 15-20% of the cut lines.  Moving the ends took longer than using the tools to get the 80% of correct cut lines, but was necessary.

Anyway, I hope your client is happy with the result.

View solution in original post

0 Kudos
20 Replies
DanPatterson_Retired
MVP Emeritus

if is far easier to buffer as usual, then clip the resultant with the outline of Germany since you already have a file with its boundary

AmazingMapMan
New Contributor III

You mean, buffer each coummunity polygon and then cut of everything within germany?

But then the buffers for each border community would be overlapping.

What I need is one not-intersecting buffer polygon for each coummunity.

It is important, that every "buffer-area" outside of germany can be attributed distictly to one community.

0 Kudos
DanPatterson_Retired
MVP Emeritus

What you want to do...buffer to a barrier, is not possible to do without severe coding.  It would be easier to develop a model in modelbuilder, buffering each site individually, then clip those that extend beyond the border, keeping those inside intact.  A combination of modelbuilder and data driven pages will permit you to develop the series of maps you want.

0 Kudos
PeterJones
Occasional Contributor

I would assume the only problem with this is that with a basic license you can only have rounded ends, so Amazing MapMan​ will not get their nice splits (they'll be rounded instead of flat/butted/mitered).

Depending on the amount of work required (i.e. number of communities) could you not just buffer the communities and then cut the polygon buffer at each corner of two communities?

If you don't need to do this process regularly, i.e. it is one off exercise, and there are not too many communities in Germany you may be best doing it manually.

0 Kudos
AmazingMapMan
New Contributor III

Well, there are 730+ communities that share a part of the international border.

I certainly could cut all buffers manually, but: There are few things that I hate more than repeating one stupid task over and over again.(But I will check if our interns have some spare time 😉 ) Also the customer wont be willing to pay for the time needed...

If it cant be scripted, I think the customer will decide to omit the feature that needs this buffer.

0 Kudos
RichardFairhurst
MVP Honored Contributor

A Basic or Standard license just makes this process nearly impossible to automate or model.  I've programmed this in Python with the use of Advanced license tools.  See this discussion on the problem of just buffering a coastline, which is the identical problem you face (buffer coastline only is just another name for buffer external boundary only).  There is a python code file that shows the Advanced tools that you would need and snap shots of the problem areas I found in the results shown in post number 8.  However, post number 9 shows a snap shot of the more typical good results I got.

I have recently created an ArcObjects add-in that does left and right hand buffers of lines without overlap and that would work with a Basic license.  That tool came about as a result of this discussion and I have resolved most of the technical problems since my last post to that thread.  At this point, the took works but I have yet created a universal user interface so it is user friendly enough to publish the tool. You would still need a way to extract just the outer boundary of Germany as lines.  That can easily be done with Advanced license tools, but not with a Basic license.   At a minimum, I would have to write ArcObjects code to replicate the Features to Line tool functionality to make it work with a Basic license.  Since that would take several days to do, I would only offer to have you send me your polygons and I would just run the Advanced license tool to get you those boundaries in under 5 minutes.

Unfortunately, really wiggly lines will cause severe problems with the buffering methods I used in the Add-in, but there are alternative buffering options that can avoid most of those problems.

At the same time, your illustration is for all practical purposes impossible to program, since you are using a normal angle to your boundary lines that considers the overall line trend and avoids inlet pockets.  You drew lines that are not straight to cut the separations between the German subareas, which is illogical other than to avoid inlet pocket obstacles or to follow another country's boundary.  Nothing can really do what you drew other than the human brain or a monster program.  For practical and performance reasons geometry can only consider a limited set of points and line segment angles to come up with a normal angle to the wiggly boundaries of Germany.

Also, do you care about the boundaries of the adjoining countries?  The buffer you drew could cut in and out of multiple adjoining countries across the lines separating each of your subareas.

Anyway, this need comes up all the time and I am having some real success at tackling it for several scenarios.  But I do not believe you can come up with anything using Python and/or ModelBuilder that will do what you want under a Basic or Standard license only.  If you really want to do this level of work, a Basic or Standard license is just not adequate and you either need to buy an Advanced licence or partner with someone who has an Advanced license.

AmazingMapMan
New Contributor III

Hello Richard,

thanks for the Answer.

First of all: Dont take the buffer-lines in the attached image to serious. I drew them in MSPaint with the freehand mode. I only wanted to roughly display what i had in mind.

The images that you provided in the other discussion look very promising!

To get the outer boundary as lines is not a problem. I can do that in Postgis very easy.

I have an ArcMap Standard license (not Basic) so your tool would work for me. Is it opensource?

Or do you sell it?

0 Kudos
VinceAngelo
Esri Esteemed Contributor

If you have the data in PostGIS you should be doing the buffer there.

- V

0 Kudos
AmazingMapMan
New Contributor III

I could do that, but the basic question remains: How?

I experimented with ST_OffsetCurve and other functions, but the results were never quite right.

Can you suggest an approach?

0 Kudos