The vectors P and Q are as follows. Vector P is on the x-z plane (note that the y-value for vector P is `0`) , while Q is 'behind' the y-z plane.

example 3D vectors

Using the formula

`theta=arccos((P*Q)/(|P||Q|))`

we have:

P `*` Q

= (4 i + 0 j + 7 j) `*` (−2 i + j + 3 k )

= (4 × −2) + (0 × 1) + (7 × 3)

= 13

And now for the denominator:

`|P||Q|= sqrt (4^2+ (0)^2+ 7^2)` `xxsqrt((-2)^2+1^2+3^2) `

`= sqrt (65)sqrt(14)`

`=30.166\ "units"`

So

θ = arccos(13 ÷ 30.166)

Therefore the angle between the vectors P and Q is

θ = 64.47°