19x+rx=−37x+w
Here's the first step, although I don't really get your question.
56x=w-rx
or
x(56-r)=w