Added simulation capability and plotting example.