1
$\begingroup$

As an extension problem which my math teacher gave me, I was asked to solve for the maximum area of triangle, with each of its vertices on a circle of radius 3,4,5 respectively. I got the answer alright (20.495) but the solution is very awkward and the calculus approach I used is definitely not the most convenient one (the solution is sketched in this Desmos file: https://www.desmos.com/calculator/fydjs4wfbm). I am not that interested in this specific problem now and my Current question is how can one solve the problem when it's generalized to an N-sided polygon, with each of its vertex on a different circle, having N concentric circles in total whose radii can be any number as long as they have different values.

I have some code here that uses the method provided by Empy2 (thetaj=arccos(min(1,k/(rjrj+1))) )) (if you have your own idea then ignore it). It looks like a good estimate so I added the code here. But problem still exists when n<6, because k has to be negative for these ns and arccos(x) is undefined when x<-1, so there will be math error when the program does arccos(min(1,k/r1r2)), when k/r1r2 <-1.

import numpy as np
import matplotlib.pyplot as plt

fig, ax = plt.subplots(1, 1, figsize=(8, 8))

ax.axis('equal')

theta = np.linspace(0, 2 * np.pi, 1500)

# number of circles
#works for n>5
n = 3

radius = [i for i in range(1, n+1)]


def asum(k):
    Sum = 0

    for i in range(1, n):
        if i == n - 1:
            a = np.arccos(min(1, k/(radius[i]*(radius[i]+1))))
            if a != 0:
                Sum += a

        else:
            a = np.arccos(min(1, k/(radius[i]*radius[i+1])))

            if a != 0:
                Sum += a
    return Sum

#works for n>5
def findbest(s, e, n):

    real = 2*np.pi
    for i in range(50):
        mid = (s+e)/2
        midV = asum(mid)
        if midV < real:
            e = mid
        if midV > real:
            s = mid
    return (s+e)/2


#k=findbest(startvalue,endvalue,n)  add sensible start and END value                                           -70
s = 0
e = 100000000
k = findbest(s,e, n)

print("aprox k:", k)


angles = [0]
A = []

# update angles

for i in range(1, n):
    if i == n - 1:
        a = np.arccos(min(1, k/(radius[i]*(radius[i]+1))))
        angles.append(a+angles[len(angles)-1])

        if a != 0:
            A.append(a)

    else:
        a = np.arccos(min(1, k/(radius[i]*radius[i+1])))


        angles.append(a+angles[len(angles)-1])
        if a != 0:
            A.append(a)


X = []
Y = []
for i in range(len(angles)):
    X.append(radius[i] * np.cos(angles[i]))
    Y.append(radius[i] * np.sin(angles[i]))


area = 0.5*abs((X[len(X)-1]*Y[0] - Y[len(Y)-1] * X[0]))

for i in range(0, len(X)-1):
    area += 0.5*(X[i] * Y[i+1] - X[i+1] * Y[i])

print("Area:", area)

#####
# plot circle
xs = []
ys = []

for i in range(0, len(radius)):
    xs.append(radius[i] * np.cos(theta))
    ys.append(radius[i] * np.sin(theta))

for i in range(len(xs)):
    ax.plot(xs[i], ys[i], linewidth=0.4, c='black')
######


plt.plot(X, Y, linewidth=1.75, color='b')
plt.plot([radius[0], radius[len(radius)-1]*np.cos(sum(A))],
         [0, radius[len(radius)-1]*np.sin(sum(A))], color='b', linewidth=1.75)

print("Sum of angles:", "R:", sum(A), "D:", sum(A)*180/np.pi)
print(" 2pi - sum of angles:", "R:", sum(A)-2 *
      np.pi, "D:", 180/np.pi * (sum(A)-2*np.pi))

plt.show()
$\endgroup$
4
  • $\begingroup$ Your mention of the "original problem" lacks critical details, as does the new problem. While it is certainly true that by constraining the vertices of an $n$-gon to lie on certain circles, a maximum area of the $n$-gon is determined, many Readers will be dissuaded from responding because you did not digest this problem statement even to the extent of creating the notion to express it formally. $\endgroup$
    – hardmath
    Commented Dec 22, 2021 at 23:15
  • $\begingroup$ Are the circles concentric? Are $N$ and $n$ supposed to be the same? $\endgroup$ Commented Dec 25, 2021 at 14:38
  • $\begingroup$ Yes, they are concentric and like I said the radii are in an N elements list and each vertex will be on a different circle $\endgroup$
    – Simon
    Commented Dec 26, 2021 at 4:58
  • $\begingroup$ It might be a whole new interesting problem when 2, 3 or n (<N) circles are allowed to have the same radius but just to clarify again the problem is asking for the case when the radii of the concentric circles are distinct $\endgroup$
    – Simon
    Commented Dec 26, 2021 at 5:06

1 Answer 1

1
$\begingroup$

Here is my guess for raddi $(1,2,...,n)$. I think it gives an area $\pi n^2-O(n^{4/3})$.
Let $\phi_j$ be the angle of the $j$th point.
Give them radii in the order $ 1,3,5,...,n-3,n-1,n,n-2,n-4,...,2$. That maximises the sum of the product of adjacent radii.
Let $\phi_j=0$ for $j\lt n/2-n^{1/3}$. Let $\phi_j=2\pi$ for $j\gt n/2+n^{1/3}$.
Let the bulk of the $2\pi$ rotation be within a small set of vertices where the radii are largest.
The straight line between two adjacent vertices comes in a distance $O(n^{1/3})$ from the circumference of a circle of radius $n$ because the angle between verrices is $O(n^{-1/3})$. The radii of the vertices also come in a distance $O(n^{1/3})$ because there are $O(n^{1/3})$ of them. So there is a balance.
I haven't worked out more details.

The following figure is for 100 points, only nine of which are not on the line $\theta = 0$.
enter image description here

$\endgroup$
7
  • $\begingroup$ I think the cosine of the angle in each segment should be inversely proportional to the product of the radii of that segment. There is just one constant of proportionality for which the sum of those angles is exactly 2pi. (That is, $theta_j = arccos(min(1,k/(r_jr_{j+1})))$) $\endgroup$
    – Empy2
    Commented Dec 26, 2021 at 23:49
  • $\begingroup$ thank you for the response, which k value did you use for the generation of that picture in your answer? $\endgroup$
    – Simon
    Commented Dec 27, 2021 at 13:39
  • $\begingroup$ I got something close to 7595 for this example $\endgroup$
    – Simon
    Commented Dec 27, 2021 at 14:07
  • $\begingroup$ The picture was with all angkes $2\pi/10$ $\endgroup$
    – Empy2
    Commented Dec 27, 2021 at 14:52
  • $\begingroup$ The principle of dropping vertices at angle 0 make sense when you have a polygon with lots of vertices. But it just doesn't give correct picture for triangles and I don't think there is any choice of k that would make sum of angles near 2pi. Can you suggest how this might be resolved? $\endgroup$
    – Simon
    Commented Dec 28, 2021 at 2:39

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .