How can I calculate the area reachable by the tip of an articulated arm? In the image below, I have an articulated arm. There's a joint 1 at its origin, and a joint 2 in the middle.
Each joint can rotate around 150 degrees.
My intuition tells me that if the tip is to be able to cover the greatest area, then the centre of rotation of joint 2 should be at 90 degrees to to the blue arm. Is this intuition correct?
Is there a general solution to the question: what is the area coverable by the tip, given:


*

*the length of the blue and red arms

*a limit to the possible rotation of each joint

*the orientation of the centre of rotation of each joint?


Ultimately, I want to maximise the rectangular area reachable by the tip, by adjusting those conditions.

 A: I've been able to answer my question partly.
I wrote a short script in Python (listed below) that uses the turtle module to visualise the results. In the images below, the grey arcs represent the area coverable by the tip.
One thing that is clearly obvious in some of these configurations is that some rectangular areas within the grey area will be largest when at an angle; I've measured this with the not very scientific method of holding a business card up against the screen to see whether it fits.
However, I did judge that an angle of 90 degrees as the centre of movement between the two arms, and arms of equal lengths, produces reasonable results, with a decent rectangularish area covered. Small changes in the values of angles and the difference in arm sizes might make a small improvement, but large changes make the area narrower.
Being able to draw these plots does help make one's intuitions more accurate.
The results
Arms: 180 long each, arcs: 160 degrees, arc of tip: 90 degrees relative to inner arm

Inner arm: 160 long, outer arm: 180 long, arcs: 160 degrees, arc of tip: 90 degrees relative to inner arm

Arms: 180 long each, arcs: 90 degrees, arc of tip: 100 degrees relative to inner arm

Arms: 180 long each, arcs: 90 degrees, arc of tip: 80 degrees relative to inner arm

The script
# run with python3 turtle_draw.py

from turtle import *
import math

# set up the environment

Screen().setup(width=800, height=800)
mode("logo")


# describe the arm and its joints

inner_radius = 180    # the blue (inner) arm
outer_radius = 180    # the red (outer) arm
extent = 160          # the arc covered by each of the two joints
joint_angle = 90      # the centre of the outer arm relative to the blue arm
steps = 5             # number of degrees to step between drawing arcs
draw_arms_every = 45  # the number of degrees between drawing the arms


class T(Turtle):

    def draw_inner_arm(self, angle):

        t.up()
        t.home()
        t.width(1)

        # only draw the inner arm every draw_arms_every degrees
        if (angle/draw_arms_every).is_integer() or angle==extent:
            t.down()
            t.color("blue")
            t.left(angle)
            t.fd(inner_radius)
            t.dot(5, "black")

        else:
            t.left(angle)
            t.fd(inner_radius)

    def draw_outer_arm(self):

        t.rt(joint_angle)
        t.color("red")
        # go back to the start of the arm before drawing the arc
        t.fd(outer_radius)
        t.fd(-outer_radius)

    def draw_arc(self):

        # get the turtle into the correct position for drawing the arc
        t.up()
        t.rt(180)
        t.fd(outer_radius)
        t.rt(-90)

        # cover the undrawn part of the arc first
        t.circle(outer_radius, (360-extent)/2)

        # and then the part we want to draw
        t.color("gray")
        t.down()
        t.width(2)
        t.circle(outer_radius, extent)


t = T()
t.speed(0)
t.hideturtle()


for angle in range (0, extent+1, steps):
    t.draw_inner_arm(angle)
    t.draw_outer_arm()
    t.draw_arc()


mainloop()

