1. Lösung der homogenen DGL
y' -  2*x*y = 0
y' =  2*x*y
dy/dx = 2*x*y
dy/y = 2*x*dx        | ∫
ln|y| +c1 = x2 + c2
ln|y| =  x2 + c2 - c1 = x2 + c
Die Differenz zweier Konstanten ist wiederum eine Konstante.
yH = ex2 + c = ec* ex2  = C* ex2
2. Variation der Konstanten
Ansatz: Die Konstante C in der homogenen Lösung häng von x ab -> C(x)
yP = C(x)*ex2  und
yP' = C'(x)*ex2 + 2x*C(x)*ex2
ergeben eingesetzt in die Ausgangsdifferentialgleichung
C'(x)*ex2 + 2x*C(x)*ex2 = 2*x*C(x)*ex2 + ex2*cos(x)
C'(x)*ex2 =  ex2*cos(x)
C'(x) =  cos(x)       | ∫
C(x) = sin(x) + c3
-> yP = (sin(x) + c3)*ex2
Gesamtlösung = Homogene Lösung + Partikuläre Lösung (y(x) =  yH + yP
-> y(x) = C* ex2 + (sin(x) + c3)*ex2
y(x) =  ex2*(C + (sin(x) + c3)
Die Summe zweier Konstanten ist wiederum 1 Konstante.
y(x) = ex2*(C + (sin(x))
Anfangsbedingung einsetzen:
y( x= π/2) = e(π/2)2*(C + (sin(π/2)) = 0
-> e(π/2)2*(C + 1)= 0
-> C = -1
=> y(x) = ex2*(-1 + (sin(x)) = ex2*((sin(x) - 1)