Canvas example using math