8

I want to create buffer polygon(with curved edges) from points like this using ArcGIS for Desktop.

distance toward North from a point 5, toward South 1.5, toward west 1, toward East 2.

all this distance is attached as attribute in point in different fields.

enter image description here

0

1 Answer 1

14

Here's a solution for the trigonometry in Python (credit to my wife, who pointed out the problem was an ellipse, not a circle):

# FunkyEllipse.py

import math

n_dist=5000
e_dist=2000
s_dist=1500
w_dist=1000

distV=[n_dist,e_dist,s_dist,w_dist,n_dist]
radix=0

nverts=120              #!! Must be evenly divisible by 4!
quad=nverts / 4

step=(math.pi * 2) / nverts
stepSin = math.sin(step);
stepCos = math.cos(step);

acc1   = 1.0            # Cos(90)
acc2   = 0.0            # Sin(90)
coords = []
for i in range(0,nverts):
    if ((radix % 2) == 0):
        x = acc2 * distV[(radix+1)%4]
        y = acc1 * distV[radix%4]
    else:
        x = acc2 * distV[radix%4]
        y = acc1 * distV[(radix+1)%4]

    coords.append((x, y))

    if ((i % quad) == (quad - 1)):
        radix += 1

    temp = (acc1 * stepCos) - (acc2 * stepSin)
    acc2 = (acc2 * stepCos) + (acc1 * stepSin)
    acc1 = temp

coords.append(coords[0])
print(coords)

Which generates a shape which looks like: enter image description here

Incorporating the math in an arcpy script to copy a point featureclass to polygon is left as an exercise.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.