Calculate dot product (#608)

Calculate dot product (#608)

Use a⋅b=axbx+ayby+azbz\mathbf{a} \cdot \mathbf{b} = a_x b_x + a_y b_y + a_z b_z.