In 2015, the second-named author introduced the dot product graph associated to a commutative ring $A$. Let $A$ be a commutative ring with nonzero identity, $1 \leq n < \infty$ be an integer, and $R = A \times A \times \cdots \times A$ ($n$ times). We recall that the total dot product graph of $R$ is the (undirected) graph $TD(R)$ with vertices $R^* = R\setminus \{(0, 0, \dots, 0)\}$, and two distinct vertices $x$ and $y$ are adjacent if and only if $x\cdot y = 0 \in A$ (where $x\cdot y$ denotes the normal dot product of $x$ and $y$). Let $Z(R)$ denote the set of all zero-divisors of $R$. Then the zero-divisor dot product graph of $R$ is the induced subgraph $ZD(R)$ of $TD(R)$ with vertices $Z(R)^* = Z(R) \setminus \{(0, 0, \dots, 0)\}$. Let $U(R)$ denote the set of all units of $R$. Then the unit dot product graph of $R$ is the induced subgraph $UD(R)$ of $TD(R)$ with vertices $U(R)$. In this paper, we study the structure of $TD(R)$, $UD(R)$, and $ZD(R)$ when $A = Z_n$ or $A = GF(p^n)$, the finite field with $p^n$ elements, where $n \geq 2$ and $p$ is a prime positive integer.