Reference no: EM131871689
Question -
1. a) For planning, you are to create a 3th order spline system (a "cubic spline"). The general 3th order spline equation is: x(t) = c0 + c1t + c2t2 + c3t3
Assume the movement duration is τ, and the movement starts at t=0. Assume that at start the movement is at x0, and it is supposed to reach xf at time t = τ. Determine all the constants c0 to c3 as a function of x0, xf, and their derivatives, and τ. At start and end velocities are x·(0) = x·0 , x·(τ ) = x·f.
b) Using matlab, implement a planning system that creates a trajectory of 2 seconds duration, starting at position x = 0 and going to a target at x = 2, with zero velocity boundary conditions.
Use a time step of 0.01s to compute the movement plan. Provide a print-out of your matlab code, and plots of position, velocity, and acceleration for the entire trajectory.
c) A useful way to implement the cubic spline planning system is by creating a function that takes as input variables the current state x(t), x·(t), the remaining time to go τtogo, and the target state xf, x·f. The output of the function would be x(t + Δt), x·(t + Δt), i.e., the planned state one time increment ahead. This function can be used to plan the next desired state given the current desired state, which is useful in a control loop of a robot. Note that the time-to-go τtogo needs to be decreased at every iteration of the control loop by Δt. Implement this function in matlab, and create the results of b) using this incremental planning system. Compare the results of b) and c) and comment on the differences and similarities.
2. Consider the dynamical system:
x·1 = bx1 + kx2 + x3
x·2 = x1 (2)
x·3 = α(u - x2) - βx3
a) Show a physical system that corresponds to the equations in (2) and explain what the parameters mean.
b) Transform the system into the frequency domain and give the individual transfer functions and the transfer function of the complete system. Provide a block diagram that shows how the individual transfer functions are connected.
c) Assume b=-1, k=-1, α = 1, β = 10. Use Simulink to build a PD controller for the system, assuming that the system should track a sinusoidal desired trajectory with 1Hz frequency. Use the "Transfer Function" building block in Simulink for this implementation.