What steps were taken to get px-2x^2 to be p-4x??

I can't work out what happened to the 'x' after 'p'. I can see that 2x^2 equals 4x though.
Any help would be much appreciated :)
Thanks

px - 2x^2

= x(p-2x) , when factored

If y = px - 2x^2
then dy/dx = p - 4x , if p is a constant

I don't understand what you mean by
"I can see that 2x^2 equals 4x though. "
2x^2 is NOT equal to 4x

Sorry I should have added that I was working it out as a derivitive

To understand how the expression px - 2x^2 was simplified to p - 4x, let's break down the process step by step:

Step 1: Start with the original expression px - 2x^2.

Step 2: Notice that both terms have a common factor of 'x'. By factoring out 'x' from both terms, we get:
x(p - 2x).

Step 3: Now, let's focus on the expression (p - 2x) that remains after factoring out 'x'.

Step 4: It seems like you're wondering how the 'x' disappeared in the process. To clarify, when we factor out 'x' from the original expression, we're left with (p - 2x). In this step, we're just separating the common factor 'x' from the expression, but it doesn't disappear.

Step 5: Finally, we can rearrange the terms within the parentheses to get the simplified expression: p - 2x.

So, px - 2x^2 simplifies to p - 2x, not p - 4x as you mentioned. If there is any confusion or if you have further questions, please feel free to ask!