In the solution of this problem(121), dW = (kmgcosΦ + mgsinΦ) ds, where ds is the differential element along the curve. Now they have done kmg dscosΦ + mg ds(sinΦ) = kmgdx +mgdy. Makes sense intuitively, but I want to know how this is rigorous. What I'm thinking is, the curve is broken into N elements of the same length along the curve over which a Riemann sum gives a line integral. But here cosΦ is varying, so wouldn't all the Δx's and Δy's not be of the same length? And if your explanation is that as Δx tends to zero the two become the same, then why can't we simply treat all differential elements as the same since they all tend to zero after all? Sorry for the rambling at the end. But can someone just show me why such an operation is rigorous?