suppose r(x)=x^2/(x^2+1) represents revenue, and c(x)= (x-1)^3 + 1/3 represents cost with X measured and thousands of units. Is there a production level that maximizes profit? If so, what is it

profit = revenue - cost

= x^2/(x^2 + 1) - (x-1)^3 + 1/3
d profit/dx = ( (x^2 + 1)(2x) - x^2(2x) )/(x^2 + 1)^2 - 3(x-1)^2
= 0 for a max/min of profit

2x(x^2 + 1 - x^2)/(x^2 + 1)^2 = 3(x-1)^2
2x/(x^2 + 1)^2 = 3(x-1)^2
nasty to solve, perhaps use Wolfram to get x = 1.338
so for a max profit we need 1338 units