forked from stacks/stacks-project
-
Notifications
You must be signed in to change notification settings - Fork 0
/
quot.tex
5783 lines (5301 loc) · 220 KB
/
quot.tex
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
\input{preamble}
% OK, start here.
%
\begin{document}
\title{Quot and Hilbert Spaces}
\maketitle
\phantomsection
\label{section-phantom}
\tableofcontents
\section{Introduction}
\label{section-introduction}
\noindent
As initially conceived, the purpose of this chapter was to write about
Quot and Hilbert functors and to prove that these are algebraic spaces
provided certain technical conditions are satisfied. This material, in
the setting of schemes, is
covered in Grothendieck's lectures in the s\'eminair Bourbaki, see
\cite{Gr-I},
\cite{Gr-II},
\cite{Gr-III},
\cite{Gr-IV},
\cite{Gr-V}, and
\cite{Gr-VI}. For projective schemes the Quot and Hilbert schemes
live inside Grassmannians of spaces of sections of suitable very
ample invertible sheaves, and this provides a method of construction
for these schemes. Our approach is different: we use Artin's axioms to
prove Quot and Hilb are algebraic spaces.
\medskip\noindent
Upon further consideration, it turned out to be more convenient for
the development of theory in the Stacks project, to start the
discussion with the stack $\Cohstack_{X/B}$
of coherent sheaves (with proper support over the base)
as introduced in \cite{lieblich_remarks}. For us $f : X \to B$
is a morphism of algebraic spaces satisfying suitable
technical conditions, although this can be generalized (see below).
Given modules $\mathcal{F}$ and $\mathcal{G}$
on $X$, under suitably hypotheses, the functor
$T/B \mapsto \Hom_{X_T}(\mathcal{F}_T, \mathcal{G}_T)$
is an algebraic space $\mathit{Hom}(\mathcal{F}, \mathcal{G})$
over $B$. See Section \ref{section-hom}. The subfunctor
$\mathit{Isom}(\mathcal{F}, \mathcal{G})$ of isomorphisms is
shown to be an algebraic space in Section \ref{section-isom}.
This is used in the next sections to show the diagonal of
the stack $\Cohstack_{X/B}$ is representable. We prove
$\Cohstack_{X/B}$ is an algebraic stack in
Section \ref{section-stack-coherent-sheaves} when $X \to B$ is flat
and in Section \ref{section-not-flat} in general.
Please see the introduction of this section for pointers
to the literature.
\medskip\noindent
Having proved this, it is rather straightforward to prove that
$\Quotfunctor_{\mathcal{F}/X/B}$, $\Hilbfunctor_{X/B}$, and
$\Picardfunctor_{X/B}$ are algebraic spaces and that
$\Picardstack_{X/B}$ is an algebraic stack. See
Sections \ref{section-quot}, \ref{section-hilb},
\ref{section-picard-functor}, and \ref{section-picard-stack}.
\medskip\noindent
In the usual manner we deduce that the functor $\mathit{Mor}_B(Z, X)$
of relative morphisms is an algebraic space (under suitable
hypotheses) in Section \ref{section-relative-morphisms}.
\medskip\noindent
In Section \ref{section-stack-of-spaces} we prove that the stack in
groupoids
$$
\Spacesstack'_{fp, flat, proper}
$$
parametrizing flat families of proper algebraic spaces satisfies all
of Artin's axioms (including openness of versality) except for
formal effectiveness. We've chosen the very awkward notation for
this stack intentionally, because the reader should be carefull
in using its properties.
\medskip\noindent
In Section \ref{section-polarized} we prove that the stack
$\Polarizedstack$
parametrizing flat families of polarized proper algebraic spaces
is an algebraic stack. Because of our work on flat families of proper
algebraic spaces, this comes down to proving
formal effectiveness for polarized schemes which is often known
as Grothendieck's algebraization theorem.
\medskip\noindent
In Section \ref{section-curves} we prove that the stack
$\Curvesstack$ parametrizing families of curves is algebraic.
\medskip\noindent
In Section \ref{section-moduli-complexes}
we study moduli of complexes on a proper morphism
and we obtain an algebraic stack $\Complexesstack_{X/B}$.
The idea of the statement and the proof are taken from
\cite{lieblich-complexes}.
\medskip\noindent
What is not in this chapter? There is almost no discussion of
the properties the resulting moduli spaces and moduli stacks
possess (beyond their algebraicity); to read about this we
refer to Moduli Stacks, Section \ref{moduli-section-introduction}.
In most of the results discussed, we can generalize the constructions
by considering a morphism $\mathcal{X} \to \mathcal{B}$ of algebraic
stacks instead of a morphism $X \to B$ of algebraic space.
We will discuss this (insert future reference here).
In the case of Hilbert spaces there is a more general notion of
``Hilbert stacks'' which we will discuss in a separate chapter, see
(insert future reference here).
\section{Conventions}
\label{section-conventions}
\noindent
We have intentionally placed this chapter, as well as the chapters
``Examples of Stacks'', ``Sheaves on Algebraic Stacks'',
``Criteria for Representability'', and ``Artin's Axioms'' before the
general development of the theory of algebraic stacks. The reason
for this is that starting with the next chapter (see
Properties of Stacks, Section \ref{stacks-properties-section-conventions})
we will no longer distinguish between a scheme and the algebraic stack
it gives rise to. Thus our language will become more flexible and
easier for a human to parse, but also less precise. These first few
chapters, including the initial chapter ``Algebraic Stacks'', lay the
groundwork that later allow us to ignore some of the very technical
distinctions between different ways of thinking about algebraic stacks.
But especially in the chapters ``Artin's Axioms'' and
``Criteria of Representability'' we need
to be very precise about what objects exactly we are working with, as
we are trying to show that certain constructions produce algebraic stacks or
algebraic spaces.
\medskip\noindent
Unfortunately, this means that some of the notation, conventions and
terminology is awkward and may seem backwards to the more experienced
reader. We hope the reader will forgive us!
\medskip\noindent
The standing assumption is that all schemes are contained in
a big fppf site $\Sch_{fppf}$. And all rings $A$ considered
have the property that $\Spec(A)$ is (isomorphic) to an
object of this big site.
\medskip\noindent
Let $S$ be a scheme and let $X$ be an algebraic space over $S$.
In this chapter and the following we will write $X \times_S X$
for the product of $X$ with itself (in the category of algebraic
spaces over $S$), instead of $X \times X$.
\section{The Hom functor}
\label{section-hom}
\noindent
In this section we study the functor of homomorphisms defined below.
\begin{situation}
\label{situation-hom}
Let $S$ be a scheme. Let $f : X \to B$ be a morphism of algebraic spaces
over $S$. Let $\mathcal{F}$, $\mathcal{G}$ be quasi-coherent
$\mathcal{O}_X$-modules. For any scheme $T$ over $B$ we will denote
$\mathcal{F}_T$ and $\mathcal{G}_T$ the base changes of
$\mathcal{F}$ and $\mathcal{G}$ to $T$, in other words, the pullbacks
via the projection morphism $X_T = X \times_B T \to X$.
We consider the functor
\begin{equation}
\label{equation-hom}
\mathit{Hom}(\mathcal{F}, \mathcal{G}) :
(\Sch/B)^{opp}
\longrightarrow
\textit{Sets},\quad
T
\longrightarrow
\Hom_{\mathcal{O}_{X_T}}(\mathcal{F}_T, \mathcal{G}_T)
\end{equation}
\end{situation}
\noindent
In Situation \ref{situation-hom} we sometimes think of
$\mathit{Hom}(\mathcal{F}, \mathcal{G})$ as a functor
$(\Sch/S)^{opp} \to \textit{Sets}$
endowed with a morphism
$\mathit{Hom}(\mathcal{F}, \mathcal{G}) \to B$.
Namely, if $T$ is a scheme over $S$, then an element of
$\mathit{Hom}(\mathcal{F}, \mathcal{G})(T)$ consists of a pair
$(h, u)$, where $h$ is a morphism $h : T \to B$ and
$u : \mathcal{F}_T \to \mathcal{G}_T$ is an $\mathcal{O}_{X_T}$-module
map where $X_T = T \times_{h, B} X$ and $\mathcal{F}_T$ and $\mathcal{G}_T$
are the pullbacks to $X_T$. In particular, when we say
that $\mathit{Hom}(\mathcal{F}, \mathcal{G})$ is an algebraic space,
we mean that the corresponding functor
$(\Sch/S)^{opp} \to \textit{Sets}$ is an algebraic space.
\begin{lemma}
\label{lemma-hom-sheaf}
In Situation \ref{situation-hom} the functor
$\mathit{Hom}(\mathcal{F}, \mathcal{G})$
satisfies the sheaf property for the fpqc topology.
\end{lemma}
\begin{proof}
Let $\{T_i \to T\}_{i \in I}$ be an fpqc covering of schemes over $B$.
Set $X_i = X_{T_i} = X \times_S T_i$ and $\mathcal{F}_i = u_{T_i}$
and $\mathcal{G}_i = \mathcal{G}_{T_i}$.
Note that $\{X_i \to X_T\}_{i \in I}$ is an fpqc covering of $X_T$, see
Topologies on Spaces, Lemma \ref{spaces-topologies-lemma-fpqc}.
Thus a family of maps $u_i : \mathcal{F}_i \to \mathcal{G}_i$
such that $u_i$ and $u_j$ restrict to the same map on
$X_{T_i \times_T T_j}$ comes from a unique map
$u : \mathcal{F}_T \to \mathcal{G}_T$ by descent
(Descent on Spaces, Proposition
\ref{spaces-descent-proposition-fpqc-descent-quasi-coherent}).
\end{proof}
\noindent
Sanity check: $\mathit{Hom}$ sheaf plays the same role among algebraic spaces
over $S$.
\begin{lemma}
\label{lemma-extend-hom-to-spaces}
In Situation \ref{situation-hom}. Let $T$ be an algebraic space over $S$.
We have
$$
\Mor_{\Sh((\Sch/S)_{fppf})}(T, \mathit{Hom}(\mathcal{F}, \mathcal{G})) =
\{(h, u) \mid h : T \to B, u : \mathcal{F}_T \to \mathcal{G}_T\}
$$
where $\mathcal{F}_T, \mathcal{G}_T$ denote the pullbacks of $\mathcal{F}$
and $\mathcal{G}$ to the algebraic space $X \times_{B, h} T$.
\end{lemma}
\begin{proof}
Choose a scheme $U$ and a surjective \'etale morphism $p : U \to T$.
Let $R = U \times_T U$ with projections $t, s : R \to U$.
\medskip\noindent
Let $v : T \to \mathit{Hom}(\mathcal{F}, \mathcal{G})$
be a natural transformation. Then $v(p)$ corresponds to a pair
$(h_U, u_U)$ over $U$. As $v$ is a transformation of functors we see
that the pullbacks of $(h_U, u_U)$ by $s$ and $t$ agree.
Since $T = U/R$ (Spaces, Lemma \ref{spaces-lemma-space-presentation}),
we obtain a morphism $h : T \to B$ such that
$h_U = h \circ p$. Then $\mathcal{F}_U$ is the pullback of
$\mathcal{F}_T$ to $X_U$ and similarly for $\mathcal{G}_U$.
Hence $u_U$ descends to a $\mathcal{O}_{X_T}$-module map
$u : \mathcal{F}_T \to \mathcal{G}_T$ by
Descent on Spaces, Proposition
\ref{spaces-descent-proposition-fpqc-descent-quasi-coherent}.
\medskip\noindent
Conversely, let $(h, u)$ be a pair over $T$. Then we get a natural
transformation $v : T \to \mathit{Hom}(\mathcal{F}, \mathcal{G})$
by sending a morphism $a : T' \to T$ where $T'$ is a scheme
to $(h \circ a, a^*u)$. We omit the verification that the construction
of this and the previous paragraph are mutually inverse.
\end{proof}
\begin{remark}
\label{remark-hom-base-change}
In Situation \ref{situation-hom} let $B' \to B$ be a morphism of
algebraic spaces over $S$. Set $X' = X \times_B B'$ and denote
$\mathcal{F}'$, $\mathcal{G}'$ the pullback of
$\mathcal{F}$, $\mathcal{G}$ to $X'$. Then we obtain a functor
$\mathit{Hom}(\mathcal{F}', \mathcal{G}') : (\Sch/B')^{opp} \to \textit{Sets}$
associated to the base change $f' : X' \to B'$. For a scheme $T$ over $B'$
it is clear that we have
$$
\mathit{Hom}(\mathcal{F}', \mathcal{G}')(T) =
\mathit{Hom}(\mathcal{F}, \mathcal{G})(T)
$$
where on the right hand side we think of $T$ as a scheme over $B$
via the composition $T \to B' \to B$. This trivial remark
will occasionally be useful to change the base algebraic space.
\end{remark}
\begin{lemma}
\label{lemma-hom-sheaf-in-X}
In Situation \ref{situation-hom} let $\{X_i \to X\}_{i \in I}$ be an fppf
covering and for each $i, j \in I$ let $\{X_{ijk} \to X_i \times_X X_j\}$
be an fppf covering. Denote $\mathcal{F}_i$, resp.\ $\mathcal{F}_{ijk}$
the pullback of $\mathcal{F}$ to $X_i$, resp.\ $X_{ijk}$. Similarly
define $\mathcal{G}_i$ and $\mathcal{G}_{ijk}$. For every scheme
$T$ over $B$ the diagram
$$
\xymatrix{
\mathit{Hom}(\mathcal{F}, \mathcal{G})(T) \ar[r] &
\prod\nolimits_i
\mathit{Hom}(\mathcal{F}_i, \mathcal{G}_i)(T)
\ar@<1ex>[r]^-{\text{pr}_0^*} \ar@<-1ex>[r]_-{\text{pr}_1^*}
&
\prod\nolimits_{i, j, k}
\mathit{Hom}(\mathcal{F}_{ijk}, \mathcal{G}_{ijk})(T)
}
$$
presents the first arrow as the equalizer of the other two.
\end{lemma}
\begin{proof}
Let $u_i : \mathcal{F}_{i, T} \to \mathcal{G}_{i, T}$ be an element in the
equalizer of $\text{pr}_0^*$ and $\text{pr}_1^*$. Since the base change
of an fppf covering is an fppf covering
(Topologies on Spaces, Lemma \ref{spaces-topologies-lemma-fppf})
we see that $\{X_{i, T} \to X_T\}_{i \in I}$ and
$\{X_{ijk, T} \to X_{i, T} \times_{X_T} X_{j, T}\}$ are fppf coverings.
Applying Descent on Spaces, Proposition
\ref{spaces-descent-proposition-fpqc-descent-quasi-coherent}
we first conclude that $u_i$ and $u_j$ restrict to the same morphism
over $X_{i, T} \times_{X_T} X_{j, T}$, whereupon a second application
shows that there is a unique morphism $u : \mathcal{F}_T \to \mathcal{G}_T$
restricting to $u_i$ for each $i$. This finishes the proof.
\end{proof}
\begin{lemma}
\label{lemma-hom-limits}
In Situation \ref{situation-hom}. If $\mathcal{F}$ is of finite presentation
and $f$ is quasi-compact and quasi-separated, then
$\mathit{Hom}(\mathcal{F}, \mathcal{G})$ is limit preserving.
\end{lemma}
\begin{proof}
Let $T = \lim_{i \in I} T_i$ be a directed limit of affine $B$-schemes.
We have to show that
$$
\mathit{Hom}(\mathcal{F}, \mathcal{G})(T) =
\colim \mathit{Hom}(\mathcal{F}, \mathcal{G})(T_i)
$$
Pick $0 \in I$. We may replace $B$ by $T_0$, $X$ by $X_{T_0}$,
$\mathcal{F}$ by $\mathcal{F}_{T_0}$, $\mathcal{G}$ by
$\mathcal{G}_{T_0}$, and $I$ by $\{i \in I \mid i \geq 0\}$.
See Remark \ref{remark-hom-base-change}.
Thus we may assume $B = \Spec(R)$ is affine.
\medskip\noindent
When $B$ is affine, then $X$ is quasi-compact and quasi-separated.
Choose a surjective \'etale morphism $U \to X$ where $U$ is an
affine scheme (Properties of Spaces, Lemma
\ref{spaces-properties-lemma-quasi-compact-affine-cover}).
Since $X$ is quasi-separated, the scheme $U \times_X U$ is quasi-compact
and we may choose a surjective \'etale morphism $V \to U \times_X U$
where $V$ is an affine scheme. Applying Lemma \ref{lemma-hom-sheaf-in-X}
we see that $\mathit{Hom}(\mathcal{F}, \mathcal{G})$ is the
equalizer of two maps between
$$
\mathit{Hom}(\mathcal{F}|_U, \mathcal{G}|_U)
\quad\text{and}\quad
\mathit{Hom}(\mathcal{F}|_V, \mathcal{G}|_V)
$$
This reduces us to the case that $X$ is affine.
\medskip\noindent
In the affine case the statement of the lemma reduces to
the following problem: Given a ring map $R \to A$, two $A$-modules
$M$, $N$ and a directed system of $R$-algebras $C = \colim C_i$.
When is it true that the map
$$
\colim \Hom_{A \otimes_R C_i}(M \otimes_R C_i, N \otimes_R C_i)
\longrightarrow
\Hom_{A \otimes_R C}(M \otimes_R C, N \otimes_R C)
$$
is bijective? By
Algebra, Lemma \ref{algebra-lemma-module-map-property-in-colimit}
this holds if $M \otimes_R C$ is of finite presentation over
$A \otimes_R C$, i.e., when $M$ is of finite presentation over $A$.
\end{proof}
\begin{lemma}
\label{lemma-hom-closed}
Let $S$ be a scheme. Let $B$ be an algebraic space over $S$.
Let $i : X' \to X$ be a closed immersion of algebraic spaces
over $B$. Let $\mathcal{F}$ be a quasi-coherent $\mathcal{O}_X$-module
and let $\mathcal{G}'$ be a quasi-coherent $\mathcal{O}_{X'}$-module.
Then
$$
\mathit{Hom}(\mathcal{F}, i_*\mathcal{G}') =
\mathit{Hom}(i^*\mathcal{F}, \mathcal{G}')
$$
as functors on $(\Sch/B)$.
\end{lemma}
\begin{proof}
Let $g : T \to B$ be a morphism where $T$ is a scheme.
Denote $i_T : X'_T \to X_T$ the base change of $i$.
Denote $h : X_T \to X$ and $h' : X'_T \to X'$ the projections.
Observe that $(h')^*i^*\mathcal{F} = i_T^*h^*\mathcal{F}$.
As a closed immersion is affine
(Morphisms of Spaces, Lemma
\ref{spaces-morphisms-lemma-closed-immersion-affine})
we have $h^*i_*\mathcal{G} = i_{T, *}(h')^*\mathcal{G}$ by
Cohomology of Spaces, Lemma \ref{spaces-cohomology-lemma-affine-base-change}.
Thus we have
\begin{align*}
\mathit{Hom}(\mathcal{F}, i_*\mathcal{G}')(T)
& =
\Hom_{\mathcal{O}_{X_T}}(h^*\mathcal{F}, h^*i_*\mathcal{G}') \\
& =
\Hom_{\mathcal{O}_{X_T}}(h^*\mathcal{F}, i_{T, *}(h')^*\mathcal{G}) \\
& =
\Hom_{\mathcal{O}_{X'_T}}(i_T^*h^*\mathcal{F}, (h')^*\mathcal{G}) \\
& =
\Hom_{\mathcal{O}_{X'_T}}((h')^*i^*\mathcal{F}, (h')^*\mathcal{G}) \\
& =
\mathit{Hom}(i^*\mathcal{F}, \mathcal{G}')(T)
\end{align*}
as desired. The middle equality follows from the adjointness of the functors
$i_{T, *}$ and $i_T^*$.
\end{proof}
\begin{lemma}
\label{lemma-cohomology-perfect-complex}
Let $S$ be a scheme. Let $B$ be an algebraic space over $S$.
Let $K$ be a pseudo-coherent object of $D(\mathcal{O}_B)$.
\begin{enumerate}
\item If for all $g : T \to B$ in $(\Sch/B)$ the cohomology sheaf
$H^{-1}(Lg^*K)$ is zero, then the functor
$$
(\Sch/B)^{opp} \longrightarrow \textit{Sets},\quad
(g : T \to B) \longmapsto H^0(T, H^0(Lg^*K))
$$
is an algebraic space affine and of finite presentation over $B$.
\item If for all $g : T \to B$ in $(\Sch/B)$ the cohomology sheaves
$H^i(Lg^*K)$ are zero for $i < 0$, then $K$ is perfect,
$K$ locally has tor amplitude in $[0, b]$, and the functor
$$
(\Sch/B)^{opp} \longrightarrow \textit{Sets},\quad
(g : T \to B) \longmapsto H^0(T, Lg^*K)
$$
is an algebraic space affine and of finite presentation over $B$.
\end{enumerate}
\end{lemma}
\begin{proof}
Under the assumptions of (2) we have $H^0(T, Lg^*K) = H^0(T, H^0(Lg^*K))$.
Let us prove that the rule $T \mapsto H^0(T, H^0(Lg^*K))$ satisfies the
sheaf property for the fppf topology. To do this assume we have an
fppf covering $\{h_i : T_i \to T\}$ of a scheme $g : T \to B$ over $B$.
Set $g_i = g \circ h_i$. Note that since $h_i$ is flat, we have
$Lh_i^* = h_i^*$ and $h_i^*$ commutes with taking cohomology. Hence
$$
H^0(T_i, H^0(Lg_i^*K)) =
H^0(T_i, H^0(h_i^*Lg^*K)) =
H^0(T, h_i^*H^0(Lg^*K))
$$
Similarly for the pullback to $T_i \times_T T_j$.
Since $Lg^*K$ is a pseudo-coherent complex on $T$
(Cohomology on Sites, Lemma
\ref{sites-cohomology-lemma-pseudo-coherent-pullback})
the cohomology sheaf $\mathcal{F} = H^0(Lg^*K)$ is quasi-coherent
(Derived Categories of Spaces, Lemma
\ref{spaces-perfect-lemma-pseudo-coherent}).
Hence by Descent on Spaces, Proposition
\ref{spaces-descent-proposition-fpqc-descent-quasi-coherent}
we see that
$$
H^0(T, \mathcal{F}) = \Ker(
\prod H^0(T_i, h_i^*\mathcal{F}) \to
\prod H^0(T_i \times_T T_j, (T_i \times_T T_j \to T)^*\mathcal{F}))
$$
In this way we see that the rules in (1) and (2) satisfy
the sheaf property for fppf coverings. This means we may apply
Bootstrap, Lemma \ref{bootstrap-lemma-locally-algebraic-space-finite-type}
to see it suffices to prove the representability \'etale locally on $B$.
Moreover, we may check whether the end result is affine and
of finite presentation \'etale locally on $B$, see
Morphisms of Spaces, Lemmas \ref{spaces-morphisms-lemma-affine-local} and
\ref{spaces-morphisms-lemma-finite-presentation-local}.
Hence we may assume that $B$ is an affine scheme.
\medskip\noindent
Assume $B = \Spec(A)$ is an affine scheme. By the results of
Derived Categories of Spaces, Lemmas
\ref{spaces-perfect-lemma-pseudo-coherent},
\ref{spaces-perfect-lemma-derived-quasi-coherent-small-etale-site}, and
\ref{spaces-perfect-lemma-descend-pseudo-coherent}
we deduce that in the rest of the proof we may think of $K$ as a perfect
object of the derived category of complexes of modules on $B$
in the Zariski topology. By
Derived Categories of Schemes, Lemmas
\ref{perfect-lemma-pseudo-coherent},
\ref{perfect-lemma-affine-compare-bounded}, and
\ref{perfect-lemma-pseudo-coherent-affine} we can find a pseudo-coherent
complex $M^\bullet$ of $A$-modules such that $K$ is the corresponding
object of $D(\mathcal{O}_B)$. Our assumption on pullbacks implies
that $M^\bullet \otimes^\mathbf{L}_A \kappa(\mathfrak p)$
has vanishing $H^{-1}$ for all primes $\mathfrak p \subset A$.
By More on Algebra, Lemma \ref{more-algebra-lemma-cut-complex-in-two}
we can write
$$
M^\bullet =
\tau_{\geq 0}M^\bullet \oplus \tau_{\leq - 1}M^\bullet
$$
with $\tau_{\geq 0}M^\bullet$ perfect with Tor amplitude in $[0, b]$
for some $b \geq 0$ (here we also have used
More on Algebra, Lemmas \ref{more-algebra-lemma-glue-perfect} and
\ref{more-algebra-lemma-glue-tor-amplitude}).
Note that in case (2) we also see that $\tau_{\leq - 1}M^\bullet = 0$
in $D(A)$ whence $M^\bullet$ and $K$ are perfect with
tor amplitude in $[0, b]$. For any $B$-scheme $g : T \to B$ we have
$$
H^0(T, H^0(Lg^*K)) = H^0(T, H^0(Lg^*\tau_{\geq 0}K))
$$
(by the dual of Derived Categories, Lemma
\ref{derived-lemma-negative-vanishing})
hence we may replace $K$ by $\tau_{\geq 0}K$ and correspondingly
$M^\bullet$ by $\tau_{\geq 0}M^\bullet$. In other words, we may
assume $M^\bullet$ has tor amplitude in $[0, b]$.
\medskip\noindent
Assume $M^\bullet$ has tor amplitude in $[0, b]$.
We may assume $M^\bullet$ is a bounded above complex of finite free
$A$-modules (by our definition of pseudo-coherent complexes, see
More on Algebra, Definition \ref{more-algebra-definition-pseudo-coherent}
and the discussion following the definition).
By More on Algebra, Lemma \ref{more-algebra-lemma-last-one-flat}
we see that $M = \Coker(M^{- 1} \to M^0)$ is flat. By
Algebra, Lemma \ref{algebra-lemma-finite-projective} we see that $M$
is finite locally free. Hence $M^\bullet$ is quasi-isomorphic to
$$
M \to M^1 \to M^2 \to \ldots \to M^d \to 0 \ldots
$$
Note that this is a K-flat complex
(Cohomology, Lemma \ref{cohomology-lemma-bounded-flat-K-flat}),
hence derived pullback of $K$ via a morphism $T \to B$ is computed
by the complex
$$
g^*\widetilde{M} \to g^*\widetilde{M^1} \to \ldots
$$
Thus it suffices to show that the functor
$$
(g : T \to B) \longmapsto
\Ker(
\Gamma(T,g^*\widetilde{M})
\to
\Gamma(T, g^*(\widetilde{M^1})
)
$$
is representable by an affine scheme of finite presentation over $B$.
\medskip\noindent
We may still replace $B$ by the members of an affine open covering
in order to prove this last statement. Hence we may assume that $M$
is finite free (recall that $M^1$ is finite free to begin with).
Write $M = A^{\oplus n}$ and $M^1 = A^{\oplus m}$. Let the map
$M \to M^1$ be given by the $m \times n$ matrix $(a_{ij})$ with
coefficients in $A$. Then $\widetilde{M} = \mathcal{O}_B^{\oplus n}$
and $\widetilde{M^1} = \mathcal{O}_B^{\oplus m}$. Thus the functor
above is equal to the functor
$$
(g : T \to B) \longmapsto
\{(f_1, \ldots, f_n) \in \Gamma(T, \mathcal{O}_T) \mid
\sum g^\sharp(a_{ij})f_i = 0,\ j = 1, \ldots, m\}
$$
Clearly this is representable by the affine scheme
$$
\Spec\left(A[x_1, \ldots, x_n]/(\sum a_{ij}x_i; j = 1, \ldots, m)\right)
$$
and the lemma has been proved.
\end{proof}
\noindent
The functor $\mathit{Hom}(\mathcal{F}, \mathcal{G})$ is representable in a
number of situations. All of our results will be based on the following
basic case. The proof of this lemma as given below is in some sense the
natural generalization to the proof of \cite[III, Cor 7.7.8]{EGA}.
\begin{lemma}
\label{lemma-noetherian-hom}
In Situation \ref{situation-hom} assume that
\begin{enumerate}
\item $B$ is a Noetherian algebraic space,
\item $f$ is locally of finite type and quasi-separated,
\item $\mathcal{F}$ is a finite type $\mathcal{O}_X$-module, and
\item $\mathcal{G}$ is a finite type $\mathcal{O}_X$-module, flat over $B$,
with support proper over $B$.
\end{enumerate}
Then the functor $\mathit{Hom}(\mathcal{F}, \mathcal{G})$ is
an algebraic space affine and of finite presentation over $B$.
\end{lemma}
\begin{proof}
We may replace $X$ by a quasi-compact open neighbourhood of
the support of $\mathcal{G}$, hence we may assume $X$ is Noetherian.
In this case $X$ and $f$ are quasi-compact and quasi-separated.
Choose an approximation $P \to \mathcal{F}$ by a perfect complex $P$ of
the triple $(X, \mathcal{F}, -1)$, see
Derived Categories of Spaces, Definition
\ref{spaces-perfect-definition-approximation-holds} and
Theorem \ref{spaces-perfect-theorem-approximation}).
Then the induced map
$$
\Hom_{\mathcal{O}_X}(\mathcal{F}, \mathcal{G})
\longrightarrow
\Hom_{D(\mathcal{O}_X)}(P, \mathcal{G})
$$
is an isomorphism because $P \to \mathcal{F}$ induces an isomorphism
$H^0(P) \to \mathcal{F}$ and $H^i(P) = 0$ for $i > 0$.
Moreover, for any morphism $g : T \to B$
denote $h : X_T = T \times_B X \to X$ the projection and set
$P_T = Lh^*P$. Then it is equally true that
$$
\Hom_{\mathcal{O}_{X_T}}(\mathcal{F}_T, \mathcal{G}_T)
\longrightarrow
\Hom_{D(\mathcal{O}_{X_T})}(P_T, \mathcal{G}_T)
$$
is an isomorphism, as $P_T = Lh^*P \to Lh^*\mathcal{F} \to \mathcal{F}_T$
induces an isomorphism $H^0(P_T) \to \mathcal{F}_T$ (because $h^*$ is
right exact and $H^i(P) = 0$ for $i > 0$). Thus it suffices to prove the
result for the functor
$$
T \longmapsto \Hom_{D(\mathcal{O}_{X_T})}(P_T, \mathcal{G}_T).
$$
By the Leray spectral sequence (see Cohomology on Sites, Remark
\ref{sites-cohomology-remark-before-Leray}) we have
$$
\Hom_{D(\mathcal{O}_{X_T})}(P_T, \mathcal{G}_T) =
H^0(X_T, R\SheafHom(P_T, \mathcal{G}_T)) =
H^0(T, Rf_{T, *}R\SheafHom(P_T, \mathcal{G}_T))
$$
where $f_T : X_T \to T$ is the base change of $f$. By
Derived Categories of Spaces, Lemma
\ref{spaces-perfect-lemma-base-change-RHom}
we have
$$
Rf_{T, *}R\SheafHom(P_T, \mathcal{G}_T) = Lg^*Rf_*R\SheafHom(P, \mathcal{G}).
$$
By
Derived Categories of Spaces, Lemma
\ref{spaces-perfect-lemma-ext-perfect}
the object $K = Rf_*R\SheafHom(P, \mathcal{G})$ of $D(\mathcal{O}_B)$
is perfect. This means we can apply
Lemma \ref{lemma-cohomology-perfect-complex}
as long as we can prove that the cohomology sheaf
$H^i(Lg^*K)$ is $0$ for all $i < 0$ and $g : T \to B$ as above.
This is clear from the last displayed formula as
the cohomology sheaves of
$Rf_{T, *}R\SheafHom(P_T, \mathcal{G}_T)$
are zero in negative degrees
due to the fact that $R\SheafHom(P_T, \mathcal{G}_T)$ has vanishing
cohomology sheaves in negative degrees as $P_T$ is perfect with
vanishing cohomology sheaves in positive degrees.
\end{proof}
\noindent
Here is a cheap consequence of Lemma \ref{lemma-noetherian-hom}.
\begin{proposition}
\label{proposition-hom}
In Situation \ref{situation-hom} assume that
\begin{enumerate}
\item $f$ is of finite presentation, and
\item $\mathcal{G}$ is a finitely presented $\mathcal{O}_X$-module,
flat over $B$, with support proper over $B$.
\end{enumerate}
Then the functor $\mathit{Hom}(\mathcal{F}, \mathcal{G})$ is
an algebraic space affine over $B$. If $\mathcal{F}$
is of finite presentation, then $\mathit{Hom}(\mathcal{F}, \mathcal{G})$
is of finite presentation over $B$.
\end{proposition}
\begin{proof}
By Lemma \ref{lemma-hom-sheaf} the functor
$\mathit{Hom}(\mathcal{F}, \mathcal{G})$ satisfies
the sheaf property for fppf coverings. This mean we may\footnote{We omit
the verification of the set theoretical condition (3) of the referenced
lemma.} apply
Bootstrap, Lemma \ref{bootstrap-lemma-locally-algebraic-space}
to check the representability \'etale locally on $B$. Moreover,
we may check whether the end result is affine or
of finite presentation \'etale locally on $B$, see
Morphisms of Spaces, Lemmas \ref{spaces-morphisms-lemma-affine-local} and
\ref{spaces-morphisms-lemma-finite-presentation-local}.
Hence we may assume that $B$ is an affine scheme.
\medskip\noindent
Assume $B$ is an affine scheme. As $f$ is of finite presentation, it follows
$X$ is quasi-compact and quasi-separated. Thus we can write
$\mathcal{F} = \colim \mathcal{F}_i$ as a filtered colimit of
$\mathcal{O}_X$-modules of finite presentation
(Limits of Spaces, Lemma \ref{spaces-limits-lemma-colimit-finitely-presented}).
It is clear that
$$
\mathit{Hom}(\mathcal{F}, \mathcal{G}) =
\lim \mathit{Hom}(\mathcal{F}_i, \mathcal{G})
$$
Hence if we can show that each $\mathit{Hom}(\mathcal{F}_i, \mathcal{G})$
is representable by an affine scheme, then we see that the same thing
holds for $\mathit{Hom}(\mathcal{F}, \mathcal{G})$. Use the material in
Limits, Section \ref{limits-section-limits} and
Limits of Spaces, Section \ref{spaces-limits-section-limits}.
Thus we may assume that $\mathcal{F}$ is of finite presentation.
\medskip\noindent
Say $B = \Spec(R)$. Write $R = \colim R_i$ with each $R_i$ a finite
type $\mathbf{Z}$-algebra. Set $B_i = \Spec(R_i)$. By the results of
Limits of Spaces, Lemmas
\ref{spaces-limits-lemma-descend-finite-presentation} and
\ref{spaces-limits-lemma-descend-modules-finite-presentation}
we can find an $i$, a morphism of algebraic spaces $X_i \to B_i$,
and finitely presented $\mathcal{O}_{X_i}$-modules $\mathcal{F}_i$ and
$\mathcal{G}_i$ such that the base change of
$(X_i, \mathcal{F}_i, \mathcal{G}_i)$ to $B$ recovers
$(X, \mathcal{F}, \mathcal{G})$. By
Limits of Spaces, Lemma \ref{spaces-limits-lemma-descend-flat}
we may, after increasing $i$, assume that $\mathcal{G}_i$
is flat over $B_i$. By
Limits of Spaces, Lemma \ref{spaces-limits-lemma-eventually-proper-support}
we may similarly assume the scheme theoretic support of $\mathcal{G}_i$
is proper over $B_i$. At this point we can apply
Lemma \ref{lemma-noetherian-hom}
to see that $H_i = \mathit{Hom}(\mathcal{F}_i, \mathcal{G}_i)$ is
an algebraic space affine of finite presentation over $B_i$.
Pulling back to $B$ (using Remark \ref{remark-hom-base-change})
we see that $H_i \times_{B_i} B = \mathit{Hom}(\mathcal{F}, \mathcal{G})$
and we win.
\end{proof}
\section{The Isom functor}
\label{section-isom}
\noindent
In Situation \ref{situation-hom} we can consider the subfunctor
$$
\mathit{Isom}(\mathcal{F}, \mathcal{G}) \subset
\mathit{Hom}(\mathcal{F}, \mathcal{G})
$$
whose value on a scheme $T$ over $B$ is the set of {\it invertible}
$\mathcal{O}_{X_T}$-homomorphisms $u : \mathcal{F}_T \to \mathcal{G}_T$.
\medskip\noindent
We sometimes think of
$\mathit{Isom}(\mathcal{F}, \mathcal{G})$ as a functor
$(\Sch/S)^{opp} \to \textit{Sets}$
endowed with a morphism
$\mathit{Isom}(\mathcal{F}, \mathcal{G}) \to B$.
Namely, if $T$ is a scheme over $S$, then an element of
$\mathit{Isom}(\mathcal{F}, \mathcal{G})(T)$ consists of a pair
$(h, u)$, where $h$ is a morphism $h : T \to B$ and
$u : \mathcal{F}_T \to \mathcal{G}_T$ is an $\mathcal{O}_{X_T}$-module
isomorphism
where $X_T = T \times_{h, B} X$ and $\mathcal{F}_T$ and $\mathcal{G}_T$
are the pullbacks to $X_T$. In particular, when we say
that $\mathit{Isom}(\mathcal{F}, \mathcal{G})$ is an algebraic space,
we mean that the corresponding functor
$(\Sch/S)^{opp} \to \textit{Sets}$ is an algebraic space.
\begin{lemma}
\label{lemma-isom-sheaf}
In Situation \ref{situation-hom} the functor
$\mathit{Isom}(\mathcal{F}, \mathcal{G})$
satisfies the sheaf property for the fpqc topology.
\end{lemma}
\begin{proof}
We have already seen that $\mathit{Hom}(\mathcal{F}, \mathcal{G})$
satisfies the sheaf property. Hence it remains to show the following:
Given an fpqc covering $\{T_i \to T\}_{i \in I}$ of schemes over $B$
and an $\mathcal{O}_{X_T}$-linear map
$u : \mathcal{F}_T \to \mathcal{G}_T$ such that
$u_{T_i}$ is an isomorphism for all $i$, then $u$ is an isomorphism.
Since $\{X_i \to X_T\}_{i \in I}$ is an fpqc covering of $X_T$, see
Topologies on Spaces, Lemma \ref{spaces-topologies-lemma-fpqc},
this follows from
Descent on Spaces, Proposition
\ref{spaces-descent-proposition-fpqc-descent-quasi-coherent}.
\end{proof}
\noindent
Sanity check: $\mathit{Isom}$ sheaf plays the same role among algebraic spaces
over $S$.
\begin{lemma}
\label{lemma-extend-isom-to-spaces}
In Situation \ref{situation-hom}. Let $T$ be an algebraic space over $S$.
We have
$$
\Mor_{\Sh((\Sch/S)_{fppf})}(T, \mathit{Isom}(\mathcal{F}, \mathcal{G})) =
\{(h, u) \mid
h : T \to B, u : \mathcal{F}_T \to \mathcal{G}_T\text{ isomorphism}\}
$$
where $\mathcal{F}_T, \mathcal{G}_T$ denote the pullbacks of $\mathcal{F}$
and $\mathcal{G}$ to the algebraic space $X \times_{B, h} T$.
\end{lemma}
\begin{proof}
Observe that the left and right hand side of the equality are
subsets of the left and right hand side of the equality in
Lemma \ref{lemma-extend-hom-to-spaces}.
We omit the verification that these subsets correspond under
the identification given in the proof of that lemma.
\end{proof}
\begin{proposition}
\label{proposition-isom}
In Situation \ref{situation-hom} assume that
\begin{enumerate}
\item $f$ is of finite presentation, and
\item $\mathcal{F}$ and $\mathcal{G}$ are finitely presented
$\mathcal{O}_X$-modules, flat over $B$, with support proper over $B$.
\end{enumerate}
Then the functor $\mathit{Isom}(\mathcal{F}, \mathcal{G})$ is
an algebraic space affine of finite presentation over $B$.
\end{proposition}
\begin{proof}
We will use the abbreviations
$H = \mathit{Hom}(\mathcal{F}, \mathcal{G})$,
$I = \mathit{Hom}(\mathcal{F}, \mathcal{F})$,
$H' = \mathit{Hom}(\mathcal{G}, \mathcal{F})$, and
$I' = \mathit{Hom}(\mathcal{G}, \mathcal{G})$.
By Proposition \ref{proposition-hom} the functors
$H$, $I$, $H'$, $I'$ are algebraic spaces and the morphisms
$H \to B$, $I \to B$, $H' \to B$, and $I' \to B$
are affine and of finite presentation.
The composition of maps gives a morphism
$$
c : H' \times_B H \longrightarrow I \times_B I',\quad
(u', u) \longmapsto (u \circ u', u' \circ u)
$$
of algebraic spaces over $B$. Since $I \times_B I' \to B$ is separated,
the section $\sigma : B \to I \times_B I'$ corresponding to
$(\text{id}_\mathcal{F}, \text{id}_\mathcal{G})$
is a closed immersion
(Morphisms of Spaces, Lemma \ref{spaces-morphisms-lemma-section-immersion}).
Moreover, $\sigma$ is of finite presentation
(Morphisms of Spaces, Lemma
\ref{spaces-morphisms-lemma-finite-presentation-permanence}).
Hence
$$
\mathit{Isom}(\mathcal{F}, \mathcal{G}) =
(H' \times_B H) \times_{c, I \times_B I', \sigma} B
$$
is an algebraic space affine of finite presentation over $B$ as well.
Some details omitted.
\end{proof}
\section{The stack of coherent sheaves}
\label{section-stack-coherent-sheaves}
\noindent
In this section we prove that the stack of coherent sheaves
on $X/B$ is algebraic under suitable hypotheses. This is a
special case of \cite[Theorem 2.1.1]{lieblich_remarks}
which treats the case of the stack of coherent sheaves on an
Artin stack over a base.
\begin{situation}
\label{situation-coherent}
Let $S$ be a scheme. Let $f : X \to B$ be a morphism of algebraic spaces
over $S$. Assume that $f$ is of finite presentation.
We denote $\Cohstack_{X/B}$ the category whose objects are
triples $(T, g, \mathcal{F})$ where
\begin{enumerate}
\item $T$ is a scheme over $S$,
\item $g : T \to B$ is a morphism over $S$, and setting
$X_T = T \times_{g, B} X$
\item $\mathcal{F}$ is a quasi-coherent $\mathcal{O}_{X_T}$-module
of finite presentation, flat over $T$, with support proper over $T$.
\end{enumerate}
A morphism $(T, g, \mathcal{F}) \to (T', g', \mathcal{F}')$
is given by a pair $(h, \varphi)$ where
\begin{enumerate}
\item $h : T \to T'$ is a morphism of schemes over $B$
(i.e., $g' \circ h = g$), and
\item $\varphi : (h')^*\mathcal{F}' \to \mathcal{F}$ is an
isomorphism of $\mathcal{O}_{X_T}$-modules where $h' : X_T \to X_{T'}$
is the base change of $h$.
\end{enumerate}
\end{situation}
\noindent
Thus $\Cohstack_{X/B}$ is a category and the rule
$$
p : \Cohstack_{X/B} \longrightarrow (\Sch/S)_{fppf},
\quad
(T, g, \mathcal{F}) \longmapsto T
$$
is a functor. For a scheme $T$ over $S$ we denote $\Cohstack_{X/B, T}$
the fibre category of $p$ over $T$. These fibre categories are groupoids.
\begin{lemma}
\label{lemma-coherent-fibred-in-groupoids}
In Situation \ref{situation-coherent} the functor
$p : \Cohstack_{X/B} \longrightarrow (\Sch/S)_{fppf}$
is fibred in groupoids.
\end{lemma}
\begin{proof}
We show that $p$ is fibred in groupoids by checking conditions
(1) and (2) of Categories, Definition
\ref{categories-definition-fibred-groupoids}.
Given an object $(T', g', \mathcal{F}')$
of $\Cohstack_{X/B}$ and a morphism $h : T \to T'$ of
schemes over $S$ we can set $g = h \circ g'$ and
$\mathcal{F} = (h')^*\mathcal{F}'$ where $h' : X_T \to X_{T'}$
is the base change of $h$. Then it is clear that we obtain
a morphism $(T, g, \mathcal{F}) \to (T', g', \mathcal{F}')$
of $\Cohstack_{X/B}$ lying over $h$. This proves (1).
For (2) suppose we are given morphisms
$$
(h_1, \varphi_1) : (T_1, g_1, \mathcal{F}_1) \to (T, g, \mathcal{F})
\quad\text{and}\quad
(h_2, \varphi_2) : (T_2, g_2, \mathcal{F}_2) \to (T, g, \mathcal{F})
$$
of $\Cohstack_{X/B}$ and a morphism $h : T_1 \to T_2$ such that
$h_2 \circ h = h_1$. Then we can let $\varphi$ be the composition
$$
(h')^*\mathcal{F}_2
\xrightarrow{(h')^*\varphi_2^{-1}}
(h')^*(h_2)^*\mathcal{F} = (h_1)^*\mathcal{F}
\xrightarrow{\varphi_1}
\mathcal{F}_1
$$
to obtain the morphism
$(h, \varphi) : (T_1, g_1, \mathcal{F}_1) \to (T_2, g_2, \mathcal{F}_2)$
that witnesses the truth of condition (2).
\end{proof}
\begin{lemma}
\label{lemma-coherent-diagonal}
In Situation \ref{situation-coherent}. Denote
$\mathcal{X} = \Cohstack_{X/B}$. Then
$\Delta : \mathcal{X} \to \mathcal{X} \times \mathcal{X}$ is
representable by algebraic spaces.
\end{lemma}
\begin{proof}
Consider two objects $x = (T, g, \mathcal{F})$ and $y = (T, h, \mathcal{G})$
of $\mathcal{X}$ over a scheme $T$. We have to show that
$\mathit{Isom}_\mathcal{X}(x, y)$ is an algebraic space over $T$, see
Algebraic Stacks, Lemma \ref{algebraic-lemma-representable-diagonal}.
If for $a : T' \to T$ the restrictions $x|_{T'}$ and $y|_{T'}$ are isomorphic
in the fibre category $\mathcal{X}_{T'}$, then $g \circ a = h \circ a$.
Hence there is a transformation of presheaves
$$
\mathit{Isom}_\mathcal{X}(x, y) \longrightarrow \text{Equalizer}(g, h)
$$
Since the diagonal of $B$ is representable (by schemes) this equalizer is
a scheme. Thus we may replace $T$ by this equalizer and the sheaves
$\mathcal{F}$ and $\mathcal{G}$ by their pullbacks. Thus we may assume
$g = h$. In this case we have
$\mathit{Isom}_\mathcal{X}(x, y) = \mathit{Isom}(\mathcal{F}, \mathcal{G})$
and the result follows from Proposition \ref{proposition-isom}.
\end{proof}
\begin{lemma}
\label{lemma-coherent-stack}
In Situation \ref{situation-coherent} the functor
$p : \Cohstack_{X/B} \longrightarrow (\Sch/S)_{fppf}$
is a stack in groupoids.
\end{lemma}
\begin{proof}
To prove that $\Cohstack_{X/B}$ is a stack in groupoids, we have to show
that the presheaves $\mathit{Isom}$ are sheaves and that descent data are
effective. The statement on $\mathit{Isom}$ follows from
Lemma \ref{lemma-coherent-diagonal}, see
Algebraic Stacks, Lemma \ref{algebraic-lemma-representable-diagonal}.
Let us prove the statement on descent data.
Suppose that $\{a_i : T_i \to T\}$ is an fppf covering of schemes over $S$.
Let $(\xi_i, \varphi_{ij})$ be a descent datum for $\{T_i \to T\}$
with values in $\Cohstack_{X/B}$.
For each $i$ we can write $\xi_i = (T_i, g_i, \mathcal{F}_i)$.
Denote $\text{pr}_0 : T_i \times_T T_j \to T_i$ and
$\text{pr}_1 : T_i \times_T T_j \to T_j$ the projections.
The condition that $\xi_i|_{T_i \times_T T_j} = \xi_j|_{T_i \times_T T_j}$
implies in particular that $g_i \circ \text{pr}_0 = g_j \circ \text{pr}_1$.
Thus there exists a unique morphism $g : T \to B$ such that