found bug in initial conditions...using X from state space model for r input!