Checking whether lines and/or planes in space are perpendicular

### 26.11.4 Checking whether lines and/or planes in space are perpendicular

See Section 25.15.12 for checking for perpendicularity in two-dimensional geometry.

The is_perpendicular command determines if two objects are perpendicular.

- is_perpendicular takes two arguments: L,P, each one either a line or a plane.
- is_perpendicular(L,P) returns 1 if L and P are perpendicular and returns 0 otherwise.

Note that two lines must be coplanar to be perpendicular.

#### Examples

is_perpendicular(line([2,3,-2],[-1,-1,-1]),line([1,0,0],[1,2,8]))

0 |  |  |  |  |  |  |  |  |  |

P1:=plane([0,0,0],[1,2,-3],[1,1,-2]); P2:=plane([-1,-1,-1],1,2,-3],[0,0,0]); is_perpendicular(P1,P2)

1 |  |  |  |  |  |  |  |  |  |

L:=plane([2,3,-2],[-1,-1,-1]); is_perpendicular(L,P1)

0 |  |  |  |  |  |  |  |  |  |