Detailed Explanation
A first-order differential equation \( \frac{dy}{dx} = F(x, y) \) is called homogeneous if \( F(x, y) \) can be written purely as a function of \( \frac{y}{x} \). Equivalently, if we replace \( x \) by \( \lambda x \) and \( y \) by \( \lambda y \), the ratio stays unchanged. To solve such equations we use the substitution \( y = vx \), which gives \( \frac{dy}{dx} = v + x\frac{dv}{dx} \). This turns the equation into a variables-separable form in \( v \) and \( x \), which we then integrate. Here the presence of \( \cos\left(\frac{y}{x}\right) \) and \( \sin\left(\frac{y}{x}\right) \) already suggests the equation is homogeneous of degree zero in the ratio.
Formula Used
Substitution for a homogeneous equation: \( y = vx \) so that \( \frac{dy}{dx} = v + x\frac{dv}{dx} \). Useful integral: \( \int \tan v \, dv = -\ln|\cos v| + C \).
Solution
- Step 1: Write the equation in the form \( \frac{dy}{dx} = F(x,y) \). From the given equation \[ \left\{ x\cos\left(\frac{y}{x}\right) + y\sin\left(\frac{y}{x}\right) \right\} y \, dx = \left\{ y\sin\left(\frac{y}{x}\right) - x\cos\left(\frac{y}{x}\right) \right\} x \, dy \] we get \[ \frac{dy}{dx} = \frac{\left\{ x\cos\left(\frac{y}{x}\right) + y\sin\left(\frac{y}{x}\right) \right\} y}{\left\{ y\sin\left(\frac{y}{x}\right) - x\cos\left(\frac{y}{x}\right) \right\} x}. \]
- Step 2: Show it is homogeneous. Divide numerator and denominator inside the brackets by \( x \). Writing \( \frac{y}{x} \) throughout, \[ \frac{dy}{dx} = \frac{\left( \cos\left(\frac{y}{x}\right) + \frac{y}{x}\sin\left(\frac{y}{x}\right) \right)\frac{y}{x}}{\left( \frac{y}{x}\sin\left(\frac{y}{x}\right) - \cos\left(\frac{y}{x}\right) \right)}. \] The right side depends only on \( \frac{y}{x} \), so the equation is homogeneous.
- Step 3: Substitute \( y = vx \), so \( \frac{y}{x} = v \) and \( \frac{dy}{dx} = v + x\frac{dv}{dx} \). The equation becomes \[ v + x\frac{dv}{dx} = \frac{(\cos v + v\sin v)\,v}{v\sin v - \cos v}. \]
- Step 4: Isolate \( x\frac{dv}{dx} \) by subtracting \( v \). \[ x\frac{dv}{dx} = \frac{v(\cos v + v\sin v)}{v\sin v - \cos v} - v = \frac{v(\cos v + v\sin v) - v(v\sin v - \cos v)}{v\sin v - \cos v}. \] Simplify the numerator: \[ v\cos v + v^2\sin v - v^2\sin v + v\cos v = 2v\cos v. \] Therefore \[ x\frac{dv}{dx} = \frac{2v\cos v}{v\sin v - \cos v}. \]
- Step 5: Separate the variables. \[ \frac{v\sin v - \cos v}{v\cos v}\, dv = \frac{2}{x}\, dx. \] Split the left side: \[ \left( \frac{\sin v}{\cos v} - \frac{1}{v} \right) dv = \frac{2}{x}\, dx, \] that is \[ \left( \tan v - \frac{1}{v} \right) dv = \frac{2}{x}\, dx. \]
- Step 6: Integrate both sides. \[ \int \tan v \, dv - \int \frac{1}{v}\, dv = 2\int \frac{1}{x}\, dx. \] This gives \[ -\ln|\cos v| - \ln|v| = 2\ln|x| + \ln C_1, \] where \( \ln C_1 \) is the constant of integration.
- Step 7: Combine the logarithms. \[ -\ln|v\cos v| = \ln|x^2| + \ln C_1 \] so \[ \ln\left| \frac{1}{v\cos v} \right| = \ln|C_1 x^2|. \] Hence \[ \frac{1}{v\cos v} = C_1 x^2, \] which we rewrite as \[ v\cos v \cdot x^2 = C \] where \( C = \frac{1}{C_1} \) is a new constant.
- Step 8: Return to the original variables using \( v = \frac{y}{x} \). Then \( v\cos v = \frac{y}{x}\cos\left(\frac{y}{x}\right) \), so \[ \frac{y}{x}\cos\left(\frac{y}{x}\right)\cdot x^2 = C. \] Simplifying gives \[ xy\cos\left(\frac{y}{x}\right) = C. \]
Final Answer
The general solution is \[ xy\cos\left(\frac{y}{x}\right) = C, \] where \( C \) is an arbitrary constant.
Common Mistake
A frequent error is forgetting to subtract \( v \) after substituting \( \frac{dy}{dx} = v + x\frac{dv}{dx} \); students often equate \( x\frac{dv}{dx} \) directly to the right-hand side. Another common slip is mishandling the constant of integration when combining logarithms, which leads to an incorrect final relation.