We want to know what value of width will maximize the area of the pigs. This is, we want to find a maximum of the function:
[tex]a(x)=144x-2x^2[/tex]
For doing so, we will find its critical points, by the first derivative criteria. Then we find the first derivative:
[tex]a^{\prime}(x)=144-4x[/tex]
We equal to zero and solve for x:
[tex]\begin{gathered} 144-4x=0 \\ 144=4x \\ \frac{144}{4}=x \\ 36=x \end{gathered}[/tex]
This means that x=36 is a critical point. Now, we will check if it is a maximum or a minimum using the second derivative test:
[tex]a^{\doubleprime}(x)=-4[/tex]
As the second derivative is negative for all x, this means that x=36 is a maximum of the funtion a(x).
On other words, the farmer should use a width of 36 feet to have the maximum area for his pigs.