Causal Block Diagram (continuoustime)

General Information
The assignmentYou will implement the operational semantics of the Causal Block Diagram (CBD) formalism (i.e., a simulator) for continuoustime semantics. In particular, you will add support for Integrator and Derivative blocks to the discretetime CBD simulator you developed for the first CBD assignment. The semantics of these blocks will not be encoded directly in CBDsimulator.py. Rather, you will replace
A consequence of the discretization is that you will need a timeslice size (aka stepsize) delta_t which can be encoded in a CBD as a constant. Note that if multiple integrator and/or derivative blocks are approximated in a CBD model, they must all use the same stepsize! Provide models (add test cases to CBDtest.py, but also create files like ExampleCBD.py where simulation results are plotted) to test your discretetime approximation of
[20%] Build the "circle test" model (d^{2}x / dt^{2} = x with x(0) = 0 and dx/dt(0) = 1), known in physics as a "harmonic oscillator" using
[10%] The smaller delta_t, the more accurate the discretetime approximation of the continuoustime semantics of a model will be. This is nicely visible when x(t) is plotted versus dx/dt(t) for various values of delta_t. Demonstrate this for both the circle test model with integrators and with derivatives. [30%] You should also compare the accuracy of the integrator and derivative approaches for the circle test. This means you will plot the total error for the integrator and the derivative approaches as a function of delta_t. The total error is the sum of the squares of the differences between the analytical solution (for x(t)) and its numerical approximation. The sum is over time points, over a sufficiently large time period. [10%] for proper documentation/description/plots. 
Maintained by Hans Vangheluwe.  Last Modified: 2014/10/20 03:40:17. 