The overall matrix can be built from the knowledge of the matrices representing each element of the circuit (in your example, the Toffoli and single-qubit gates) by simple matrix multiplication.
To obtain the matrix representation of a Toffoli gate acting between three qubits, a good way to start is by first writing down its bra-ket representation. This amounts to writing down how the gate operates on the various elements of the computational basis.
In this case, this would amount to
- List all the elements of the computational basis of five qubits, that is, all bit-strings of length $5$: $|00000\rangle,|00001\rangle,|00010\rangle$ etc.
- Determine how the gate under consideration acts on each one of these states. For example, the first Toffoli in the circuit sends $|00000\rangle$ to $|00000\rangle$, but $|11000\rangle$ to $|11100\rangle$.
- Write down the operation as a sum of operators of the form $|q_p\rangle\!\langle p|$, where $|p\rangle$ ranges over all computational basis elements, and $q_p$ is the element obtained by acting with the gate over $|p\rangle$.
To obtain the matrix representation, you now build the matrix whose $p$-th column has a single $1$ at the position $q_p$ (note that the bra-ket representation of the gate is not actually necessary here, it's just a way to write down the action of the gate in a systematic way, but can be skipped once you are familiar with the process).
For example, the action of the first Toffoli gate in your circuit can be written as
$$
|11100\rangle\!\langle 11000| + |11000\rangle\!\langle 11100| + (\text{identity over all other elements}).
$$
The matrix representation is then the matrix which only differs from the diagonal by its acting off-diagonally in the positions corresponding to $|11000\rangle$ and $|11100\rangle$. Note that which positions correspond to these states partly depends on the notation you are using. A standard notation is to list computational basis states as if you were counting in binary, so $|00000\rangle\to 0$, $|00001\rangle\to 1,...,|11000\rangle\to 2^4 + 2^3=24$, etc.
This trick will work to find the matrix representation of any gate which acts as a permutation over computational basis elements.