Why, exactly, does the derived category localisation factor through the "homotopy category" of cochain complexes? $\newcommand{\A}{\mathcal{A}}\newcommand{\C}{\mathsf{C}}\newcommand{\D}{\mathfrak{D}}\newcommand{\ho}{\mathsf{Ho}}\newcommand{\K}{\mathcal{K}}\newcommand{\kom}{\mathrm{Kom}}\newcommand{\H}{\mathsf{H}}$Let me set up the notation first. If you are familiar with the kind of notation used by Wikipedia and Emily Riehl, please skip this section.

We fix an Abelian category $\A$ and consider the category of cochain complexes $\kom(\A)$:

The objects of $\kom(\A)$ are represented as letters $X$ which encode a $\Bbb Z$-indexed diagram in $\A$ of the form: $$\cdots\to X_{n-1}\overset{\partial_X^{n-1}}{\longrightarrow}X_n\overset{\partial_X^n}{\longrightarrow}X_{n+1}\to\cdots$$Satisfying $\partial_X^n\partial_X^{n-1}=0$ for all $n\in\Bbb Z$. Morphisms $f:X\to Y$ in $\kom(\A)$ are 'natural' families of arrows $f_n:X_n\to Y_n$ satisfying: $$\partial_Y^nf_n=f_{n+1}\partial_X^n$$For all $n$. The composition and identities are in the obvious way.

We make $\kom(\A)$ a homotopical category by giving it the class of weak equivalences consisting of all quasi-isomorphisms: these are morphisms $f:X\to Y$ such that every induced $\H_n(f):\H_n(X)\cong\H_n(Y)$ is an isomorphism, with $\H_n$ the usual $n$th cohomology. This class satisfies the $2$-of-$6$ property and obviously contains all identities. We can then construct the homotopy category (in this sense) $\ho(\kom(\A))$, which is more commonly denoted as $\D(\A)$ and called the derived category of $\A$, with localisation $Q:\kom(\A)\to\D(\A)$.
Riehl constructs the homotopy category (in this sense) of a homotopical category $\C$ explicitly (more or less: I flesh out some formalisms) as follows:

The objects of $\ho\C$ are the objects of $\C$. Define an edge-class $[x,y]$, for every $x,y\in\C$, by having $[x,y]$ contain $\C(x,y)$ and also contain all weak equivalences in $\C(y,x)$. Let a 'path' $a\to b$ be a finite formal composition of edges in edge classes $[a=x_0,x_1],[x_1,x_2],\cdots,[x_k,x_{k+1}:=b]$. The arrow-class $\varsigma\to\varsigma'$ in $\ho\C$ is the quotient of the class of all paths $\varsigma\to\varsigma'$ in $\C$ by the two relations:

*

*If $w\in\C(x,y)$ is a weak equivalence, then the path $w\circ w:x\to y\to x$ is identified with the identity edge $x\to x$

*If $w\in\C(x,y)$ is a weak equivalence, then the path $w\circ w:y\to x\to y$ is also identified with the identity edge

The identity element of $\ho\C(\varsigma,\varsigma)$ is the equivalence class of the identity edge. The composition of elements in $a\in\ho\C(\varsigma,\varsigma')$ and $b\in\ho\C(\varsigma',\varsigma'')$ is the equivalence class of the formal composition $b'\circ a'$ where $a',b'$ are any representatives for $a,b$ (which is well-defined). With this, $\ho\C$ is a category, with a canonical identity-on-objects quotient functor $\C\to\ho\C$ called localisation.

However, we confusingly use the "homotopy category of cochain complexes" to mean a different category to $\ho\kom(\A)=\D(\A)$. By this we mean the category $\K(\A)$, which has the same objects as $\kom(\A)$ and its morphisms are the equivalence classes of morphisms in $\kom(\A)$ via the relation: $f\sim g$ whenever there exists a chain homotopy $f\to g$, which is an equivalence relation. There is a canonical quotient functor $\kom(\A)\twoheadrightarrow\K(\A)$.

Wikipedia claims the following (paraphrased):

Since any isomorphism in $\K(\A)$ corresponds to a quasi-isomorphism in $\kom(\A)$, the localisation $Q:\kom(\A)\to\D(\A)$ factors through $\kom(\A)\twoheadrightarrow\K(\A)$, and $\D(\A)$ can also be seen as the localisation of $\K(\A)$.

There are two things I'd like to ask about this statement. To say $\D(\A)$ is a localisation of $\K(\A)$ is to first assume a homotopical structure on $\K(\A)$. I presume we take this to be the same; a weak equivalence is an equivalence class of a quasi-isomorphism. This is well-defined since quasi-isomorphism is invariant under homotopy. Is that right?
The second, more important question:

*

*Why do we get this factorisation? That's equivalent to claiming $Q(f)=Q(g)$ if $f,g$ are chain homotopic morphisms. While $Q$ maps any homotopy equivalence (a morphism $f$ with some morphism $g$ in the opposite direction that $fg,gf$ are chain homotopic to the identities) to an isomorphism, because homotopy equivalences are quasi-isomorphisms as Wikipedia points out, I don't think this is strong enough to assert $Q(f)=Q(g)$. For that, we'd need to write $f$ in terms of $g$ followed by a zigzag of quasi-isomorphisms (see the edgewise construction of $\ho\kom(\A)=\D(\A)$ in the notation section).

How can we fill in this detail?
Please note: I know nothing about derived categories other than the relevant paragraphs of the Wikipedia page. This stood out to me as an important yet nontrivial detail, however it may well be obvious to those in the know. If this is indeed trivial, please explain why it is trivial in an explicit manner: I am not yet in a position to understand homological-algebraic 'abstract nonsense'. Many thanks.
 A: $\newcommand{\A}{\mathcal{A}}\newcommand{\C}{\mathsf{C}}\newcommand{\D}{\mathfrak{D}}\newcommand{\ho}{\mathsf{Ho}}\newcommand{\K}{\mathcal{K}}\newcommand{\kom}{\mathrm{Kom}}\newcommand{\H}{\mathsf{H}}\newcommand{\cyl}{\operatorname{Cyl}}$Detailed self-answer for the purpose of giving a clear account for my own paper notes later, and to hopefully save any other confused new student from the same frustration.
With topological spaces, continuous $f,g:X\to Y$, a homotopy $h:f\simeq g$ is exactly a continuous $h:X\times I\to Y$ where $h\iota_0=f,h\iota_1=g$ for the labelled endpoint inclusions $\iota_{0,1}:X\hookrightarrow X\times I$. It is easy to show that if $\pi:X\times I\to X$ is the first projection, then $\pi,\iota_{0,1}$ are homotopy inverses. If we take equivalence classes of continuous functions via the equivalence generated by inverting all homotopy equivalences, then: $$[f][\pi]=[h\iota_0]=[h][\iota_0][\pi]=[h]=[h][\iota_1][\pi]=[h\iota_1][\pi]=[g][\pi]\implies [f]=[g]$$So the relation generated in this way is exactly the relation: $[f]=[g]$ iff. $f$ is homotopic to $g$.
With (co)chain complexes, as Zhen Lin comments and as they answer, $\kom(\A)$ has a similar 'cylinder object' analogous to $X\times I$. I dualise and categorify the definition here (hopefully correctly...).
Since $\A$ is Abelian, it comes equipped with biproducts and the matrix calculus. Given a cochain complex $X$, we can define the cochain complex $\cyl(X)$ categorically via: $$\cyl(X)_n:=X_n\oplus X_{n+1}\oplus X_n$$And: $$\partial_{\cyl(X)}^n\simeq\begin{pmatrix}\partial_X^n&1& 0\\0&-\partial_X^{n+1}&0\\0&-1&\partial_X^n\end{pmatrix}:X_n\oplus X_{n+1}\oplus X_n\to X_{n+1}\oplus X_{n+2}\oplus X_{n+1}$$For all $n\in\Bbb Z$. This is a valid cochain complex since: $$\begin{align}\partial^n_{\cyl(X)}\partial^{n-1}_{\cyl(X)}&\simeq\begin{pmatrix}\partial_X^n&1& 0\\0&-\partial_X^{n+1}&0\\0&-1&\partial_X^n\end{pmatrix}\begin{pmatrix}\partial_X^{n-1}&1& 0\\0&-\partial_X^n&0\\0&-1&\partial_X^{n-1}\end{pmatrix}\\&=\begin{pmatrix}\partial_X^n\partial_X^{n-1}&\partial_X^n-\partial_X^n&0\\0&(-\partial_X^{n+1})(-\partial_X^n)&0\\0&-(-\partial_X^n)-\partial^n_X&\partial_X^n\partial_X^{n-1}\end{pmatrix}\\&\simeq0\end{align}$$
Though I do not know what the motivation is to consider such a construction as a candidate cylinder - On reflection, it is the only easy construction that is guaranteed to encode chain homotopies.
Anyway, we have maps $\iota_0,\iota_1:X\to\cyl(X)$ which are the inclusions into the leftmost and rightmost component. The matrix calculus reveals these are natural, so are suitable morphisms in $\kom(\A)$. There is a morphism $\pi:\cyl(X)\to X$ given by the representation: $$\pi\simeq\begin{pmatrix}1&0&1\end{pmatrix}$$So that $\pi\circ\iota_{0,1}=\mathrm{id}_X$, which is similarly checked to be natural.
We have that: $$\begin{align}(\mathrm{id}_{\cyl(X)}-\iota_0\circ\pi)_n&\simeq\begin{pmatrix}1&0&0\\0&1&0\\0&0&1\end{pmatrix}-\begin{pmatrix}1&0&1\\0&0&0\\0&0&0\end{pmatrix}\\&=\begin{pmatrix}0&0&-1\\0&1&0\\0&0&1\end{pmatrix}\end{align}$$And if $h_n:\cyl(X)_n\to\cyl(X)_{n-1}$ is defined by: $$h_n\simeq\begin{pmatrix}0&0&0\\0&0&-1\\0&0&0\end{pmatrix}$$Then: $$\begin{align}\partial_{\cyl(X)}^{n-1}h_n+h_{n+1}\partial_{\cyl(X)}^n&\simeq\begin{pmatrix}\partial_X^{n-1}&1& 0\\0&-\partial_X^n&0\\0&-1&\partial_X^{n-1}\end{pmatrix}\begin{pmatrix}0&0&0\\0&0&-1\\0&0&0\end{pmatrix}\\&+\begin{pmatrix}0&0&0\\0&0&-1\\0&0&0\end{pmatrix}\begin{pmatrix}\partial_X^n&1& 0\\0&-\partial_X^{n+1}&0\\0&-1&\partial_X^n\end{pmatrix}\\&=\begin{pmatrix}0&0&-1\\0&0&\partial^n_X\\0&0&1\end{pmatrix}+\begin{pmatrix}0&0&0\\0&1&-\partial^n_X\\0&0&0\end{pmatrix}\\&=\begin{pmatrix}0&0&-1\\0&1&0\\0&0&1\end{pmatrix}\end{align}$$So we obtain: $$(\mathrm{id}_{\cyl(X)}-\iota_0\circ\pi)_n=\partial_{\cyl(X)}^{n-1}h_n+h_{n+1}\partial_{\cyl(X)}^n$$For all $n$. Similarly, if we define a family of morphism $h'_n:\cyl(X)_n\to\cyl(X)_{n-1}$ via: $$h'_n\simeq\begin{pmatrix}0&0&0\\1&0&0\\0&0&0\end{pmatrix}$$We get: $$(\mathrm{id}_{\cyl(X)}-\iota_1\circ\pi)_n=\partial_{\cyl(X)}^{n-1}h'_n+h'_{n+1}\partial_{\cyl(X)}^n$$For all $n\in\Bbb Z$. Thus, $\pi,\iota_{0,1}$ are mutually inverse chain homotopy equivalences.
Now fix two morphisms $f,g:X\to Y$ which are chain homotopic via $h$. To mimic the topological proof, we need to encode this as a map: $\alpha:\cyl(X)\to Y$, with $\alpha\iota_0=f,\alpha\iota_1=g$. Because then we'd obtain: $$Q(f)Q(\pi)=Q(\alpha)Q(\iota_0\pi)=Q(\alpha)=Q(\alpha)Q(\iota_1\pi)=Q(g)Q(\pi)\\\therefore Q(f)=Q(g)$$Which would address my original problem. We get $Q(\iota_0\pi)=1=Q(\iota_1\pi)$ since $\pi$ is a quasi-isomorphism, so it has some inverse in $\D(\A)$, but then $1=Q(\pi)Q(\iota_0)=Q(\pi)Q(\iota_1)$ gives $Q(\iota_0)=Q(\iota_1)$ with common inverse $Q(\pi)$.
I think the appropriate $\alpha:\cyl(X)\to Y$ is the map represented by the following matrix: $$\alpha_n\simeq\begin{pmatrix}f_n&h_n&g_n\end{pmatrix}$$We have that $\alpha$ is a morphism of chain complexes iff. $h$ is a homotopy $f\simeq g$. This completes the proof. An alternative construction is given here but I only found this post several hours too late...
