= Solution
A length-zero <graph path> starts and ends at the same <vertex>. Therefore $P_0$ is the <Boolean> <identity matrix>. A <graph path> of length at most one is either such a stationary <graph path> or one original directed <edge>:
$$
\boxed{P_0[i,j]=(i=j),\qquad P_1[i,j]=(i=j)\lor E[i,j],\qquad P_1=I\lor E.}
$$
The logical disjunction is entrywise. Diagonal entries of $E$ may be false if there are no <self-loops>, but every diagonal entry of $P_1$ is true because the zero-length <graph path> is allowed.
Back to article page