Didn't we pick x to be the length of the piece we cut off from the string with length L?
If so, then one side has length x/4, since indeed, a square...
Let's let $F$ be the fixed costs and $M$ be the marginal cost (the cost to machine one part), and $x$ be the number of parts machined. Then the total...