## 48.16 Upper shriek functors

In this section, we construct the functors $f^!$ for morphisms between schemes which are of finite type and separated over a fixed Noetherian base using compactifications. As is customary in coherent duality, there are a number of diagrams that have to be shown to be commutative. We suggest the reader, after reading the construction, skips the verification of the lemmas and continues to the next section where we discuss properties of the upper shriek functors.

Situation 48.16.1. Here $S$ is a Noetherian scheme and $\textit{FTS}_ S$ is the category whose

1. objects are schemes $X$ over $S$ such that the structure morphism $X \to S$ is both separated and of finite type, and

2. morphisms $f : X \to Y$ between objects are morphisms of schemes over $S$.

In Situation 48.16.1 given a morphism $f : X \to Y$ in $\textit{FTS}_ S$, we will define an exact functor

$f^! : D_\mathit{QCoh}^+(\mathcal{O}_ Y) \to D_\mathit{QCoh}^+(\mathcal{O}_ X)$

of triangulated categories. Namely, we choose a compactification $X \to \overline{X}$ over $Y$ which is possible by More on Flatness, Theorem 38.33.8 and Lemma 38.32.2. Denote $\overline{f} : \overline{X} \to Y$ the structure morphism. Let $\overline{a} : D_\mathit{QCoh}(\mathcal{O}_ Y) \to D_\mathit{QCoh}(\mathcal{O}_{\overline{X}})$ be the right adjoint of $R\overline{f}_*$ constructed in Lemma 48.3.1. Then we set

$f^!K = \overline{a}(K)|_ X$

for $K \in D_\mathit{QCoh}^+(\mathcal{O}_ Y)$. The result is an object of $D_\mathit{QCoh}^+(\mathcal{O}_ X)$ by Lemma 48.3.5.

Lemma 48.16.2. In Situation 48.16.1 let $f : X \to Y$ be a morphism of $\textit{FTS}_ S$. The functor $f^!$ is, up to canonical isomorphism, independent of the choice of the compactification.

Proof. The category of compactifications of $X$ over $Y$ is defined in More on Flatness, Section 38.32. By More on Flatness, Theorem 38.33.8 and Lemma 38.32.2 it is nonempty. To every choice of a compactification

$j : X \to \overline{X},\quad \overline{f} : \overline{X} \to Y$

the construction above associates the functor $j^* \circ \overline{a} : D_\mathit{QCoh}^+(\mathcal{O}_ Y) \to D_\mathit{QCoh}^+(\mathcal{O}_ X)$ where $\overline{a}$ is the right adjoint of $R\overline{f}_*$ constructed in Lemma 48.3.1.

Suppose given a morphism $g : \overline{X}_1 \to \overline{X}_2$ between compactifications $j_ i : X \to \overline{X}_ i$ over $Y$ such that $g^{-1}(j_2(X)) = j_1(X)$1. Let $\overline{c}$ be the right adjoint of Lemma 48.3.1 for $g$. Then $\overline{c} \circ \overline{a}_2 = \overline{a}_1$ because these functors are adjoint to $R\overline{f}_{2, *} \circ Rg_* = R(\overline{f}_2 \circ g)_*$. By (48.4.1.1) we have a canonical transformation

$j_1^* \circ \overline{c} \longrightarrow j_2^*$

of functors $D^+_\mathit{QCoh}(\mathcal{O}_{\overline{X}_2}) \to D^+_\mathit{QCoh}(\mathcal{O}_ X)$ which is an isomorphism by Lemma 48.4.4. The composition

$j_1^* \circ \overline{a}_1 \longrightarrow j_1^* \circ \overline{c} \circ \overline{a}_2 \longrightarrow j_2^* \circ \overline{a}_2$

is an isomorphism of functors which we will denote by $\alpha _ g$.

Consider two compactifications $j_ i : X \to \overline{X}_ i$, $i = 1, 2$ of $X$ over $Y$. By More on Flatness, Lemma 38.32.1 part (b) we can find a compactification $j : X \to \overline{X}$ with dense image and morphisms $g_ i : \overline{X} \to \overline{X}_ i$ of compactififcatins. By More on Flatness, Lemma 38.32.1 part (c) we have $g_ i^{-1}(j_ i(X)) = j(X)$. Hence we get isomorpisms

$\alpha _{g_ i} : j^* \circ \overline{a} \longrightarrow j_ i^* \circ \overline{a}_ i$

by the previous paragraph. We obtain an isomorphism

$\alpha _{g_2} \circ \alpha _{g_1}^{-1} : j_1^* \circ \overline{a}_1 \to j_2^* \circ \overline{a}_2$

To finish the proof we have to show that these isomorphisms are well defined. We claim it suffices to show the composition of isomorphisms constructed in the previous paragraph is another (for a precise statement see the next paragraph). We suggest the reader check this is true on a napkin, but we will also completely spell it out in the rest of this paragraph. Namely, consider a second choice of a compactification $j' : X \to \overline{X}'$ with dense image and morphisms of compactifications $g'_ i : \overline{X}' \to \overline{X}_ i$. By More on Flatness, Lemma 38.32.1 we can find a compactification $j'' : X \to \overline{X}''$ with dense image and morphisms of compactifications $h : \overline{X}'' \to \overline{X}$ and $h' : \overline{X}'' \to \overline{X}'$. We may even assume $g_1 \circ h = g'_1 \circ h'$ and $g_2 \circ h = g'_2 \circ h'$. The result of the next paragraph gives

$\alpha _{g_ i} \circ \alpha _ h = \alpha _{g_ i \circ h} = \alpha _{g'_ i \circ h'} = \alpha _{g'_ i} \circ \alpha _{h'}$

for $i = 1, 2$. Since these are all isomorphisms of functors we conclude that $\alpha _{g_2} \circ \alpha _{g_1}^{-1} = \alpha _{g'_2} \circ \alpha _{g'_1}^{-1}$ as desired.

Suppose given compactifications $j_ i : X \to \overline{X}_ i$ for $i = 1, 2, 3$. Suppose given morphisms $g : \overline{X}_1 \to \overline{X}_2$ and $h : \overline{X}_2 \to \overline{X}_3$ of compactifications such that $g^{-1}(j_2(X)) = j_1(X)$ and $h^{-1}(j_2(X)) = j_3(X)$. Let $\overline{a}_ i$ be as above. The claim above means that

$\alpha _ g \circ \alpha _ h = \alpha _{g \circ h} : j_1^* \circ \overline{a}_1 \to j_3^* \circ \overline{a}_3$

Let $\overline{c}$, resp. $\overline{d}$ be the right adjoint of Lemma 48.3.1 for $g$, resp. $h$. Then $\overline{c} \circ \overline{a}_2 = \overline{a}_1$ and $\overline{d} \circ \overline{a}_3 = \overline{a}_2$ and there are canonical transformations

$j_1^* \circ \overline{c} \longrightarrow j_2^* \quad \text{and}\quad j_2^* \circ \overline{d} \longrightarrow j_3^*$

of functors $D^+_\mathit{QCoh}(\mathcal{O}_{\overline{X}_2}) \to D^+_\mathit{QCoh}(\mathcal{O}_ X)$ and $D^+_\mathit{QCoh}(\mathcal{O}_{\overline{X}_3}) \to D^+_\mathit{QCoh}(\mathcal{O}_ X)$ for the same reasons as above. Denote $\overline{e}$ the right adjoint of Lemma 48.3.1 for $h \circ g$. There is a canonical transformation

$j_1^* \circ \overline{e} \longrightarrow j_3^*$

of functors $D^+_\mathit{QCoh}(\mathcal{O}_{\overline{X}_3}) \to D^+_\mathit{QCoh}(\mathcal{O}_ X)$ given by (48.4.1.1). Spelling things out we have to show that the composition

$\alpha _ h \circ \alpha _ g : j_1^* \circ \overline{a}_1 \to j_1^* \circ \overline{c} \circ \overline{a}_2 \to j_2^* \circ \overline{a}_2 \to j_2^* \circ \overline{d} \circ \overline{a}_3 \to j_3^* \circ \overline{a}_3$

is the same as the composition

$\alpha _{h \circ g} : j_1^* \circ \overline{a}_1 \to j_1^* \circ \overline{e} \circ \overline{a}_3 \to j_3^* \circ \overline{a}_3$

We split this into two parts. The first is to show that the diagram

$\xymatrix{ \overline{a}_1 \ar[r] \ar[d] & \overline{c} \circ \overline{a}_2 \ar[d] \\ \overline{e} \circ \overline{a}_3 \ar[r] & \overline{c} \circ \overline{d} \circ \overline{a}_3 }$

commutes where the lower horizontal arrow comes from the identification $\overline{e} = \overline{c} \circ \overline{d}$. This is true because the corresponding diagram of total direct image functors

$\xymatrix{ R\overline{f}_{1, *} \ar[r] \ar[d] & Rg_* \circ R\overline{f}_{2, *} \ar[d] \\ R(h \circ g)_* \circ R\overline{f}_{3, *} \ar[r] & Rg_* \circ Rh_* \circ R\overline{f}_{3, *} }$

is commutative (insert future reference here). The second part is to show that the composition

$j_1^* \circ \overline{c} \circ \overline{d} \to j_2^* \circ \overline{d} \to j_3^*$

is equal to the map

$j_1^* \circ \overline{e} \to j_3^*$

via the identification $\overline{e} = \overline{c} \circ \overline{d}$. This was proven in Lemma 48.5.1 (note that in the current case the morphisms $f', g'$ of that lemma are equal to $\text{id}_ X$). $\square$

Lemma 48.16.3. In Situation 48.16.1 let $f : X \to Y$ and $g : Y \to Z$ be composable morphisms of $\textit{FTS}_ S$. Then there is a canonical isomorphism $(g \circ f)^! \to f^! \circ g^!$.

Proof. Choose a compactification $i : Y \to \overline{Y}$ of $Y$ over $Z$. Choose a compactification $X \to \overline{X}$ of $X$ over $\overline{Y}$. This uses More on Flatness, Theorem 38.33.8 and Lemma 38.32.2 twice. Let $\overline{a}$ be the right adjoint of Lemma 48.3.1 for $\overline{X} \to \overline{Y}$ and let $\overline{b}$ be the right adjoint of Lemma 48.3.1 for $\overline{Y} \to Z$. Then $\overline{a} \circ \overline{b}$ is the right adjoint of Lemma 48.3.1 for the composition $\overline{X} \to Z$. Hence $g^! = i^* \circ \overline{b}$ and $(g \circ f)^! = (X \to \overline{X})^* \circ \overline{a} \circ \overline{b}$. Let $U$ be the inverse image of $Y$ in $\overline{X}$ so that we get the commutative diagram

$\xymatrix{ X \ar[r]_ j \ar[d] & U \ar[dl] \ar[r]_{j'} & \overline{X} \ar[dl] \\ Y \ar[r]_ i \ar[d] & \overline{Y} \ar[dl] \\ Z }$

Let $\overline{a}'$ be the right adjoint of Lemma 48.3.1 for $U \to Y$. Then $f^! = j^* \circ \overline{a}'$. We obtain

$\gamma : (j')^* \circ \overline{a} \to \overline{a}' \circ i^*$

by (48.4.1.1) and we can use it to define

$(g \circ f)^! = (j' \circ j)^* \circ \overline{a} \circ \overline{b} = j^* \circ (j')^* \circ \overline{a} \circ \overline{b} \to j^* \circ \overline{a}' \circ i^* \circ \overline{b} = f^! \circ g^!$

which is an isomorphism on objects of $D_\mathit{QCoh}^+(\mathcal{O}_ Z)$ by Lemma 48.4.4. To finish the proof we show that this isomorphism is independent of choices made.

Suppose we have two diagrams

$\vcenter { \xymatrix{ X \ar[r]_{j_1} \ar[d] & U_1 \ar[dl] \ar[r]_{j'_1} & \overline{X}_1 \ar[dl] \\ Y \ar[r]_{i_1} \ar[d] & \overline{Y}_1 \ar[dl] \\ Z } } \quad \text{and}\quad \vcenter { \xymatrix{ X \ar[r]_{j_2} \ar[d] & U_2 \ar[dl] \ar[r]_{j'_2} & \overline{X}_2 \ar[dl] \\ Y \ar[r]_{i_2} \ar[d] & \overline{Y}_2 \ar[dl] \\ Z } }$

We can first choose a compactification $i : Y \to \overline{Y}$ with dense image of $Y$ over $Z$ which dominates both $\overline{Y}_1$ and $\overline{Y}_2$, see More on Flatness, Lemma 38.32.1. By More on Flatness, Lemma 38.32.3 and Categories, Lemmas 4.27.13 and 4.27.14 we can choose a compactification $X \to \overline{X}$ with dense image of $X$ over $\overline{Y}$ with morphisms $\overline{X} \to \overline{X}_1$ and $\overline{X} \to \overline{X}_2$ and such that the composition $\overline{X} \to \overline{Y} \to \overline{Y}_1$ is equal to the composition $\overline{X} \to \overline{X}_1 \to \overline{Y}_1$ and such that the composition $\overline{X} \to \overline{Y} \to \overline{Y}_2$ is equal to the composition $\overline{X} \to \overline{X}_2 \to \overline{Y}_2$. Thus we see that it suffices to compare the maps determined by our diagrams when we have a commutative diagram as follows

$\xymatrix{ X \ar[rr]_{j_1} \ar@{=}[d] & & U_1 \ar[d] \ar[ddll] \ar[rr]_{j'_1} & & \overline{X}_1 \ar[d] \ar[ddll] \\ X \ar '[r][rr]^-{j_2} \ar[d] & & U_2 \ar '[dl][ddll] \ar '[r][rr]^-{j'_2} & & \overline{X}_2 \ar[ddll] \\ Y \ar[rr]^{i_1} \ar@{=}[d] & & \overline{Y}_1 \ar[d] \\ Y \ar[rr]^{i_2} \ar[d] & & \overline{Y}_2 \ar[dll] \\ Z }$

and moreover the compactifications $X \to \overline{X}_1$ and $Y \to \overline{Y}_2$ have dense image. We use $\overline{a}_ i$, $\overline{a}'_ i$, $\overline{c}$, and $\overline{c}'$ for the right adjoint of Lemma 48.3.1 for $\overline{X}_ i \to \overline{Y}_ i$, $U_ i \to Y$, $\overline{X}_1 \to \overline{X}_2$, and $U_1 \to U_2$. Each of the squares

$\xymatrix{ X \ar[r] \ar[d] \ar@{}[dr]|A & U_1 \ar[d] \\ X \ar[r] & U_2 } \quad \xymatrix{ U_2 \ar[r] \ar[d] \ar@{}[dr]|B & \overline{X}_2 \ar[d] \\ Y \ar[r] & \overline{Y}_2 } \quad \xymatrix{ U_1 \ar[r] \ar[d] \ar@{}[dr]|C & \overline{X}_1 \ar[d] \\ Y \ar[r] & \overline{Y}_1 } \quad \xymatrix{ Y \ar[r] \ar[d] \ar@{}[dr]|D & \overline{Y}_1 \ar[d] \\ Y \ar[r] & \overline{Y}_2 } \quad \xymatrix{ X \ar[r] \ar[d] \ar@{}[dr]|E & \overline{X}_1 \ar[d] \\ X \ar[r] & \overline{X}_2 }$

is cartesian (see More on Flatness, Lemma 38.32.1 part (c) for A, D, E and recall that $U_ i$ is the inverse image of $Y$ by $\overline{X}_ i \to \overline{Y}_ i$ for B, C) and hence gives rise to a base change map (48.4.1.1) as follows

$\begin{matrix} \gamma _ A : j_1^* \circ \overline{c}' \to j_2^* & \gamma _ B : (j_2')^* \circ \overline{a}_2 \to \overline{a}'_2 \circ i_2^* & \gamma _ C : (j_1')^* \circ \overline{a}_1 \to \overline{a}'_1 \circ i_1^* \\ \gamma _ D : i_1^* \circ \overline{d} \to i_2^* & \gamma _ E : (j'_1 \circ j_1)^* \circ \overline{c} \to (j'_2 \circ j_2)^* \end{matrix}$

Denote $f_1^! = j_1^* \circ \overline{a}'_1$, $f_2^! = j_2^* \circ \overline{a}'_2$, $g_1^! = i_1^* \circ \overline{b}_1$, $g_2^! = i_2^* \circ \overline{b}_2$, $(g \circ f)_1^! = (j_1' \circ j_1)^* \circ \overline{a}_1 \circ \overline{b}_1$, and $(g \circ f)^!_2 = (j_2' \circ j_2)^* \circ \overline{a}_2 \circ \overline{b}_2$. The construction given in the first paragraph of the proof and in Lemma 48.16.2 uses

1. $\gamma _ C$ for the map $(g \circ f)^!_1 \to f_1^! \circ g_1^!$,

2. $\gamma _ B$ for the map $(g \circ f)^!_2 \to f_2^! \circ g_2^!$,

3. $\gamma _ A$ for the map $f_1^! \to f_2^!$,

4. $\gamma _ D$ for the map $g_1^! \to g_2^!$, and

5. $\gamma _ E$ for the map $(g \circ f)^!_1 \to (g \circ f)^!_2$.

We have to show that the diagram

$\xymatrix{ (g \circ f)^!_1 \ar[r]_{\gamma _ E} \ar[d]_{\gamma _ C} & (g \circ f)^!_2 \ar[d]_{\gamma _ B} \\ f_1^! \circ g_1^! \ar[r]^{\gamma _ A \circ \gamma _ D} & f_2^! \circ g_2^! }$

is commutative. We will use Lemmas 48.5.1 and 48.5.2 and with (abuse of) notation as in Remark 48.5.3 (in particular dropping $\star$ products with identity transformations from the notation). We can write $\gamma _ E = \gamma _ A \circ \gamma _ F$ where

$\xymatrix{ U_1 \ar[r] \ar[d] \ar@{}[rd]|F & \overline{X}_1 \ar[d] \\ U_2 \ar[r] & \overline{X}_2 }$

Thus we see that

$\gamma _ B \circ \gamma _ E = \gamma _ B \circ \gamma _ A \circ \gamma _ F = \gamma _ A \circ \gamma _ B \circ \gamma _ F$

the last equality because the two squares $A$ and $B$ only intersect in one point (similar to the last argument in Remark 48.5.3). Thus it suffices to prove that $\gamma _ D \circ \gamma _ C = \gamma _ B \circ \gamma _ F$. Since both of these are equal to the map (48.4.1.1) for the square

$\xymatrix{ U_1 \ar[r] \ar[d] & \overline{X}_1 \ar[d] \\ Y \ar[r] & \overline{Y}_2 }$

we conclude. $\square$

Lemma 48.16.4. In Situation 48.16.1 the constructions of Lemmas 48.16.2 and 48.16.3 define a pseudo functor from the category $\textit{FTS}_ S$ into the $2$-category of categories (see Categories, Definition 4.29.5).

Proof. To show this we have to prove given morphisms $f : X \to Y$, $g : Y \to Z$, $h : Z \to T$ that

$\xymatrix{ (h \circ g \circ f)^! \ar[r]_{\gamma _{A + B}} \ar[d]_{\gamma _{B + C}} & f^! \circ (h \circ g)^! \ar[d]^{\gamma _ C} \\ (g \circ f)^! \circ h^! \ar[r]^{\gamma _ A} & f^! \circ g^! \circ h^! }$

is commutative (for the meaning of the $\gamma$'s, see below). To do this we choose a compactification $\overline{Z}$ of $Z$ over $T$, then a compactification $\overline{Y}$ of $Y$ over $\overline{Z}$, and then a compactification $\overline{X}$ of $X$ over $\overline{Y}$. This uses More on Flatness, Theorem 38.33.8 and Lemma 38.32.2. Let $W \subset \overline{Y}$ be the inverse image of $Z$ under $\overline{Y} \to \overline{Z}$ and let $U \subset V \subset \overline{X}$ be the inverse images of $Y \subset W$ under $\overline{X} \to \overline{Y}$. This produces the following diagram

$\xymatrix{ X \ar[d]_ f \ar[r] & U \ar[r] \ar[d] \ar@{}[dr]|A & V \ar[d] \ar[r] \ar@{}[rd]|B & \overline{X} \ar[d] \\ Y \ar[d]_ g \ar[r] & Y \ar[r] \ar[d] & W \ar[r] \ar[d] \ar@{}[rd]|C & \overline{Y} \ar[d] \\ Z \ar[d]_ h \ar[r] & Z \ar[d] \ar[r] & Z \ar[d] \ar[r] & \overline{Z} \ar[d] \\ T \ar[r] & T \ar[r] & T \ar[r] & T }$

Without introducing tons of notation but arguing exactly as in the proof of Lemma 48.16.3 we see that the maps in the first displayed diagram use the maps (48.4.1.1) for the rectangles $A + B$, $B + C$, $A$, and $C$ as indicated. Since by Lemmas 48.5.1 and 48.5.2 we have $\gamma _{A + B} = \gamma _ A \circ \gamma _ B$ and $\gamma _{B + C} = \gamma _ C \circ \gamma _ B$ we conclude that the desired equality holds provided $\gamma _ A \circ \gamma _ C = \gamma _ C \circ \gamma _ A$. This is true because the two squares $A$ and $C$ only intersect in one point (similar to the last argument in Remark 48.5.3). $\square$

Lemma 48.16.5. In Situation 48.16.1 let $f : X \to Y$ be a morphism of $\textit{FTS}_ S$. There are canonical maps

$\mu _{f, K} : Lf^*K \otimes _{\mathcal{O}_ X}^\mathbf {L} f^!\mathcal{O}_ Y \longrightarrow f^!K$

functorial in $K$ in $D^+_\mathit{QCoh}(\mathcal{O}_ Y)$. If $g : Y \to Z$ is another morphism of $\textit{FTS}_ S$, then the diagram

$\xymatrix{ Lf^*(Lg^*K \otimes _{\mathcal{O}_ Y}^\mathbf {L} g^!\mathcal{O}_ Z) \otimes _{\mathcal{O}_ X}^\mathbf {L} f^!\mathcal{O}_ Y \ar@{=}[d] \ar[r]_-{\mu _ f} & f^!(Lg^*K \otimes _{\mathcal{O}_ Y}^\mathbf {L} g^!\mathcal{O}_ Z) \ar[r]_-{f^!\mu _ g} & f^!g^!K \ar@{=}[d] \\ Lf^*Lg^*K \otimes _{\mathcal{O}_ X}^\mathbf {L} Lf^* g^!\mathcal{O}_ Z \otimes _{\mathcal{O}_ X}^\mathbf {L} f^!\mathcal{O}_ Y \ar[r]^-{\mu _ f} & Lf^*Lg^*K \otimes _{\mathcal{O}_ X}^\mathbf {L} f^!g^!\mathcal{O}_ Z \ar[r]^-{\mu _{g \circ f}} & f^!g^!K }$

commutes for all $K \in D^+_\mathit{QCoh}(\mathcal{O}_ Z)$.

Proof. If $f$ is proper, then $f^! = a$ and we can use (48.8.0.1) and if $g$ is also proper, then Lemma 48.8.4 proves the commutativity of the diagram (in greater generality).

Let us define the map $\mu _{f, K}$. Choose a compactification $j : X \to \overline{X}$ of $X$ over $Y$. Since $f^!$ is defined as $j^* \circ \overline{a}$ we obtain $\mu _{f, K}$ as the restriction of the map (48.8.0.1)

$L\overline{f}^*K \otimes _{\mathcal{O}_{\overline{X}}}^\mathbf {L} \overline{a}(\mathcal{O}_ Y) \longrightarrow \overline{a}(K)$

to $X$. To see this is independent of the choice of the compactification we argue as in the proof of Lemma 48.16.2. We urge the reader to read the proof of that lemma first.

Assume given a morphism $g : \overline{X}_1 \to \overline{X}_2$ between compactifications $j_ i : X \to \overline{X}_ i$ over $Y$ such that $g^{-1}(j_2(X)) = j_1(X)$. Denote $\overline{c}$ the right adjoint for pushforward of Lemma 48.3.1 for the morphism $g$. The maps

$L\overline{f}_1^*K \otimes _{\mathcal{O}_{\overline{X}}}^\mathbf {L} \overline{a}_1(\mathcal{O}_ Y) \longrightarrow \overline{a}_1(K) \quad \text{and}\quad L\overline{f}_2^*K \otimes _{\mathcal{O}_{\overline{X}}}^\mathbf {L} \overline{a}_2(\mathcal{O}_ Y) \longrightarrow \overline{a}_2(K)$

fit into the commutative diagram

$\xymatrix{ Lg^*(L\overline{f}_2^*K \otimes ^\mathbf {L} \overline{a}_2(\mathcal{O}_ Y)) \otimes ^\mathbf {L} \overline{c}(\mathcal{O}_{\overline{X}_2}) \ar@{=}[d] \ar[r]_-\sigma & \overline{c}(L\overline{f}_2^*K \otimes ^\mathbf {L} \overline{a}_2(\mathcal{O}_ Y)) \ar[r] & \overline{c}(\overline{a}_2(K)) \ar@{=}[d] \\ L\overline{f}_1^*K \otimes ^\mathbf {L} Lg^*\overline{a}_2(\mathcal{O}_ Y) \otimes ^\mathbf {L} \overline{c}(\mathcal{O}_{\overline{X}_2}) \ar[r]^-{1 \otimes \tau } & L\overline{f}_1^*K \otimes ^\mathbf {L} \overline{a}_1(\mathcal{O}_ Y) \ar[r] & \overline{a}_1(K) }$

by Lemma 48.8.4. By Lemma 48.8.3 the maps $\sigma$ and $\tau$ restrict to an isomorphism over $X$. In fact, we can say more. Recall that in the proof of Lemma 48.16.2 we used the map (48.4.1.1) $\gamma : j_1^* \circ \overline{c} \to j_2^*$ to construct our isomorphism $\alpha _ g : j_1^* \circ \overline{a}_1 \to j_2^* \circ \overline{a}_2$. Pulling back to map $\sigma$ by $j_1$ we obtain the identity map on $j_2^*\left(L\overline{f}_2^*K \otimes ^\mathbf {L} \overline{a}_2(\mathcal{O}_ Y)\right)$ if we identify $j_1^*\overline{c}(\mathcal{O}_{\overline{X}_2})$ with $\mathcal{O}_ X$ via $j_1^* \circ \overline{c} \to j_2^*$, see Lemma 48.8.2. Similarly, the map $\tau : Lg^*\overline{a}_2(\mathcal{O}_ Y) \otimes ^\mathbf {L} \overline{c}(\mathcal{O}_{\overline{X}_2}) \to \overline{a}_1(\mathcal{O}_ Y) = \overline{c}(\overline{a}_2(\mathcal{O}_ Y))$ pulls back to the identity map on $j_2^*\overline{a}_2(\mathcal{O}_ Y)$. We conclude that pulling back by $j_1$ and applying $\gamma$ wherever we can we obtain a commutative diagram

$\xymatrix{ j_2^*\left(L\overline{f}_2^*K \otimes ^\mathbf {L} \overline{a}_2(\mathcal{O}_ Y)\right) \ar[r] \ar[d] & j_2^*\overline{a}_2(K) \\ j_1^*L\overline{f}_1^*K \otimes ^\mathbf {L} j_2^*\overline{a}_2(\mathcal{O}_ Y) & j_1^*(L\overline{f}_1^*K \otimes ^\mathbf {L} \overline{a}_1(\mathcal{O}_ Y)) \ar[r] \ar[l]_{1 \otimes \alpha _ g} & j_1^* \overline{a}_1(K) \ar[lu]_{\alpha _ g} }$

The commutativity of this diagram exactly tells us that the map $\mu _{f, K}$ constructed using the compactification $\overline{X}_1$ is the same as the map $\mu _{f, K}$ constructed using the compactification $\overline{X}_2$ via the identification $\alpha _ g$ used in the proof of Lemma 48.16.2. Some categorical arguments exactly as in the proof of Lemma 48.16.2 now show that $\mu _{f, K}$ is well defined (small detail omitted).

Having said this, the commutativity of the diagram in the statement of our lemma follows from the construction of the isomorphism $(g \circ f)^! \to f^! \circ g^!$ (first part of the proof of Lemma 48.16.3 using $\overline{X} \to \overline{Y} \to Z$) and the result of Lemma 48.8.4 for $\overline{X} \to \overline{Y} \to Z$. $\square$

[1] This may fail with our definition of compactification. See More on Flatness, Section 38.32.

In your comment you can use Markdown and LaTeX style mathematics (enclose it like $\pi$). A preview option is available if you wish to see how it works out (just click on the eye in the toolbar).