You will be needing Integrator blocks(4 integrator blocks) for derivative, function blocks(to implement the RHS of the equation) , sum blocks and a scope block for simulating the above equation in SIMULINK.
To compare the SIMULINK result with the analytical solution you can plot the analytical solution in MATLAB
function y = analytical_solution(x, c1, c2, c3, c4)
y = c1 + c2*exp(-x) + c3*x.*exp(-x) + c4*exp(x) + 2*x - x.^2 - 0.5*(sin(x) + cos(x));
c1 = 1; c2 = 1; c3 = 1; c4 = 1;
x = linspace(0, 10, 1000);
y = analytical_solution(x, c1, c2, c3, c4);
title('Analytical Solution');
To compare the SIMULINK simulation results with the analytical solution, you would run the Simulink model over the same (x) range and then overlay the plots or directly compare the numerical results.
Hope it Helps!
Soumnath