# Derivative with respect to which variable?

#### sweatingbear

##### Member
We have the following trapezoid:

The question is to find the length of the fourth side when the area of trapezoid is maximized.

I realize we will not be able to find a numerical value for the fourth side due to the given information (rather, lack thereof). So we are essentially going have to find, through calculus, an algebraic relationship between the fourth side and the given side, $$\displaystyle a$$.

First and foremost, we need to write an equation for the area. The problem however is that we will not be able to express the function in simply one variable. This is where I am stuck: Since the function will depend on several variables, how can we tell which variable we ought to be taking the derivative with respect to? This is normally, from what I have experienced, the most difficult task i.e. to realize which variable one should take the derivative of.

Here's a spontaneous thought: Since we are looking for the relationship between the fourth side and the side $$\displaystyle a$$, it would be wise to express the function in terms of the mentioned sides. Thus, when we take the derivative and equate it to zero, we ought to be able to find some kind of relationship between the aforementioned sides.

What do you think forum? Share your insights!

#### MarkFL

Staff member
I would attack the problem by drawing the following diagram first:

The area may then be written:

$$\displaystyle A(h,x)=\frac{h}{2}((a+2x)+a)=h(a+x)$$

subject to the constraint:

$$\displaystyle x^2+h^2=a^2$$

You may then express the area as a function of one variable, or use Lagrange multipliers.

#### sweatingbear

##### Member
I would attack the problem by drawing the following diagram first:

View attachment 1203

The area may then be written:

$$\displaystyle A(h,x)=\frac{h}{2}((a+2x)+a)=h(a+x)$$

subject to the constraint:

$$\displaystyle x^2+h^2=a^2$$

You may then express the area as a function of one variable, or use Lagrange multipliers.
Yes that's great but I am afraid it does not answer the main question: In the case where we have several variables, how can one tell which variable one should optimize with respect to?

#### M R

##### Active member
Yes that's great but I am afraid it does not answer the main question: In the case where we have several variables, how can one tell which variable one should optimize with respect to?
Instead of considering MarkFL's $$\displaystyle x$$ you might consider the leftmost angle. If we call this $$\displaystyle \theta$$ then we get $$\displaystyle A(\theta)=a^2(\cos\theta \sin\theta +\sin\theta)$$.

This is quite easy to differentiate and the resulting equation is easy to solve.

Just another possibility.

#### MarkFL

Staff member
Yes that's great but I am afraid it does not answer the main question: In the case where we have several variables, how can one tell which variable one should optimize with respect to?
$a$ is a given constant, as it remains fixed. Therefore, you have the choice of using the constraint to get the area as a function of one variable (either $x$ or $h$), or using a multi-variable method, such as Lagrange multipliers (which is much easier in this case).

Thanks!