# Drawing planes and vectors

What would be the best way to create diagrams similar to those attached? I have briefly looked over the tikz-3dplot package but it doesn't seem very convenient for my purposes. When I'm dealing with one plane, a parallelogram using tikz or tkz-euclid does the job but I don't think it would be the best choice here. Thanks in advance.

Edit (to make things more concise): How can I replicate the diagram. I'm not sure about how to draw the two intersecting planes.

• Welcom to TeX SX . Can you show us what you tried, please?
– anis
Commented Jul 8, 2023 at 8:42
• Please edit the question to limit it to a specific problem with enough detail to identify an adequate answer.
– Community Bot
Commented Jul 8, 2023 at 8:45

This is an option using the TikZ libraries:

• 3d for the options canvas is ... that allow you to draw in a plane parallel to the coordinate planes. Also you can rotate around any axis those planes.
• perspective for choosing the 3d view.

I made a couple of styles too, one for each plane and other for the vectors.

For example:

\documentclass[tikz,border=1.618mm]{standalone}
\usetikzlibrary{3d,perspective}

\pgfmathsetmacro\anglelp{-5}  % rotation of light plane
\pgfmathsetmacro\angledp{-50} % rotation of dark  plane
\tikzset
{
light plane/.style={rotate around x=\anglelp, canvas is xz plane at y=0,draw=cyan,fill=cyan!5},
dark plane/.style={rotate around x=\angledp,canvas is xy plane at z=0,draw=cyan,fill=cyan!25},
vector/.style={rotate around x=#1, canvas is yz plane at x=0,-latex,thick,draw=blue}
}

\begin{document}
\begin{tikzpicture}[3d view={120}{20},line join=round]
% planes
\draw[dark plane]  (-2,-2) rectangle (2,0);
\draw[light plane] (-2,-2) rectangle (2,4);
\draw[dark plane]  (-2, 0) rectangle (2,4);
% vectors
\draw[vector=\anglelp] (0,1) coordinate (o1) --++ (4,0) coordinate (n1) node[below] {$n_1$};
\draw[vector=\angledp] (1,0) coordinate (o2) --++ (0,4) coordinate (n2) node[above] {$n_2$};
\coordinate (i) at (intersection of o1--n1 and o2--n2); % intersection of both vectors
% angles
\draw[dashed] (o1) -- (0,0,0) -- (o2);
\draw[canvas is yz plane at x=0] (90+\anglelp:0.5)        arc (90+\anglelp:\angledp:0.5)      node[midway,right] {$\theta$};
\draw[canvas is yz plane at x=0] (i) ++ (90+\angledp:0.5) arc (90+\angledp:\anglelp:0.5)      node[midway,right] {$\alpha$};
\draw[canvas is yz plane at x=2] (270+\anglelp:0.5)       arc (270+\anglelp:360+\angledp:0.5) node[midway,below] {$\alpha$};
\end{tikzpicture}
\end{document}