Claude Code transcript - page 1/1

Read instr.md and let me know if you have any questions

I'll read that file.

Read
{
  "file_path": "~/twisted_arrow/instr.md"
}
1	This folder has several files:
2	
3	decomp.tex / decomp.bib (don't need to read bib probably) : an overview paper I wrote about decomposition spaces / 2-Segal spaces. Includes décalage / edgewise subdivision criteria for 2-Segality, which is what you should be interested in.
4	
5	from_hsd.tex : about d-Segal spaces, from a paper on higher Segal spaces and partial groups
6	
7	from_coskel.tex / higher.bib : excerpt from a recent preprint I wrote, with slightly different conventions to the above
8	
9	higher_segal_spheres.tex / spheres.tex : a calculation of a couple examples, written around the same time as the coskeletality paper
10	
11	Look over these and familiarize yourself with them. Feel free to ask me any questions.
12	
13	The thing I'd like you to investigate: 
14	Is there a version of the edgewise subdivision criterion that is true for d-Segal spaces for d > 2? 
15	
16	My instinct is that if anything like this were to be true it would be for 2k-Segal spaces, since edgewise subdivision contains in a sense both upper and lower décalage, and the path space criterion already relates upper or lower 2k-Segality to lower (2k-1)-Segality of these décalages.
17	
18	(But it also may just be false for d > 2, who knows!)
Thinking
$ Bash
ls -la && wc -l *.tex *.bib
total 352
drwxr-xr-x  11 user  staff    352 Jul 31 16:07 .
drwx------@ 95 user  staff   3040 Jul 31 16:07 ..
drwxr-xr-x@ 14 user  staff    448 Jul 31 16:07 .git
-rw-r--r--@  1 user  staff  27810 Mar 29  2025 decomp.bib
-rw-r--r--@  1 user  staff  67208 Jun  6  2025 decomp.tex
-rw-r--r--   1 user  staff  21351 Jul 31 16:00 from_coskel.tex
-rw-r--r--   1 user  staff  20106 Jul 31 15:54 from_hsd.tex
-rw-r--r--@  1 user  staff   2760 Jul 27 05:10 higher_segal_spheres.tex
-rw-r--r--@  1 user  staff   9019 Jul 27 09:35 higher.bib
-rw-r--r--   1 user  staff   1194 Jul 31 16:06 instr.md
-rw-r--r--   1 user  staff  13031 Jul 27 05:16 spheres.tex
    1126 decomp.tex
     337 from_coskel.tex
     278 from_hsd.tex
      67 higher_segal_spheres.tex
     183 spheres.tex
     834 decomp.bib
     268 higher.bib
    3093 total
Read
{
  "file_path": "~/twisted_arrow/from_coskel.tex"
}
1	\documentclass{amsart}
2	\usepackage{amssymb}
3	\usepackage{mathtools}
4	\usepackage[only,llbracket,rrbracket]{stmaryrd}
5	\usepackage[svgnames]{xcolor}
6	\usepackage[unicode,
7	  colorlinks=true,
8	  linktocpage=true,
9	  citecolor=OliveDrab,
10	  linkcolor=DarkMagenta,
11	  urlcolor=DarkMagenta,
12	  pdftitle={Coskeletality and the higher Segal conditions},
13	  pdfauthor={Philip Hackney}
14	  ]{hyperref}
15	\usepackage[capitalise,noabbrev]{cleveref}
16	\usepackage{tikz-cd}
17	\usepackage{microtype}
18	\frenchspacing
19	\usepackage[T1]{fontenc}
20	\usepackage{enumitem}
21	
22	\setlist[enumerate,1]{left=0pt, label={\arabic*.}, ref=\arabic*}
23	
24	\usepackage{comment}
25	
26	\newcommand{\cube}[1]{\llbracket #1 \rrbracket}
27	
28	\newcommand{\lowev}{\mathsf{le}}
29	\newcommand{\lowod}{\mathsf{lo}}
30	\newcommand{\uppev}{\mathsf{ue}}
31	\newcommand{\uppod}{\mathsf{uo}}
32	
33	\newcommand{\ps}{\mathcal{P}}
34	\newcommand{\op}{\textup{op}}
35	
36	\newcommand{\sset}{\mathsf{sSet}}
37	
38	\newcommand{\bim}{{\bar \imath}}
39	\newcommand{\bjm}{{\bar \jmath}}
40	
41	\newcommand{\decbot}{\operatorname{dec}_\bot}
42	\newcommand{\dectop}{\operatorname{dec}_\top}
43	
44	% Only for a small example
45	\DeclareMathOperator{\cosk}{cosk}
46	\DeclareMathOperator{\sk}{sk}
47	\DeclareMathOperator{\map}{map}
48	
49	\newtheorem{theorem}{Theorem}
50	\newtheorem{proposition}[theorem]{Proposition}
51	\newtheorem{corollary}[theorem]{Corollary}
52	\newtheorem{lemma}[theorem]{Lemma}
53	
54	\theoremstyle{definition}
55	\newtheorem{definition}[theorem]{Definition}
56	
57	\theoremstyle{remark}
58	\newtheorem{remark}[theorem]{Remark}
59	
60	\begin{document}
61	
62	\title{Coskeletality and the higher Segal conditions}
63	
64	\author{Philip Hackney}
65	\address{Department of Mathematics, University of Louisiana at Lafayette}
66	\email{philip@phck.net} 
67	\urladdr{http://phck.net}
68	
69	\thanks{
70	This work was supported by a grant from the Simons Foundation (\#850849, PH). 
71	The author was partially supported by the Louisiana Board of Regents through the Board of Regents Support fund LEQSF(2024-27)-RD-A-31.
72	}
73	
74	\date{\today}
75	
76	\begin{abstract}
77	A simplicial set is $d$-Segal if and only if it is $(d{+}1)$-coskeletal and satisfies the $d$-Segal condition in the two lowest relevant simplicial dimensions.
78	\end{abstract}
79	
80	\maketitle
81	
82	A simplicial set $X$ is $n$-coskeletal if it is determined by its simplices of dimension at most $n$, together with unique fillers for higher-dimensional simplex boundaries.\footnote{Precisely, $X$ is right Kan extended along $\Delta_{\leq n} \hookrightarrow \Delta$ from its restriction to $\Delta_{\leq n}$.} 
83	It is well-known that a simplicial set is the nerve of a category if and only if it is 2-coskeletal\footnote{In the reverse direction, one may actually assume that the simplicial set is 3-coskeletal rather than 2-coskeletal.} and has unique fillers for inner horns in simplicial dimension 2 and 3.\footnote{\cite{nlab:simplicial_skeleton}, \cite[Lemma 5.2]{Riehl:SSCAQC}}
84	There is a similar result for 2-Segal sets \cite{DyckerhoffKapranov:HSS} (also known as discrete decomposition spaces \cite{GKT1}):
85	a simplicial set is 2-Segal if and only if it is 3-coskeletal and satisfies the 2-Segal condition for the square and the pentagon (that is, it satisfies the 2-Segal conditions in simplicial dimensions 3 and 4).\footnote{\cite[Corollary 1.7]{BOORS:2SSetsWC}, \cite[\S4.1]{Stern:P2SC} -- the latter source observes that one may replace 3-coskeletal by 4-coskeletal in the reverse direction.}
86	In this paper, we prove an analogous result for $d$-Segal sets, resolving a question of Walker Stern: a simplicial set is upper (resp.\ lower) $d$-Segal if and only if it is $(d{+}1)$-coskeletal and satisfies the upper (resp.\ lower) $d$-Segal conditions in simplicial dimensions $d+1$ and $d+2$ (the lowest two non-vacuous dimensions).
87	See \cref{thm main theorem} for a slightly stronger statement.
88	The corresponding statement for simplicial spaces is false (\cref{rmk simplicial anima}).
89	
90	The higher Segal conditions were introduced by Dyckerhoff and Kapranov \cite{Dyckerhoff:CPOC,DyckerhoffKapranov:HSS} as exactness conditions arising from triangulations of cyclic polytopes, generalizing the classical Segal conditions underlying models for $(\infty,1)$-categories.
91	The case $d=2$ has proven especially fruitful, with applications to Hall algebras, incidence coalgebras, and other constructions in representation theory, algebraic combinatorics, and algebraic K-theory \cite{Dyckerhoff:HCAHA,GKT:DSC}. 
92	The situation for general $d$ is considerably less developed: besides \cite{Dyckerhoff:CPOC,Poguntke:HSSAKT}, see \cite{DyckerhoffJassoWalde:SSHART,HackneyLynd:HSSPG,Walde:HSSHE} for some of the first steps in this direction.
93	
94	Our criterion allows for an effective, finite check of $d$-Segality for simplicial sets with finitely many nondegenerate simplices (for $d$ suitably large).
95	This rests on \cite[Theorem 3.19]{KRRZ:LTSS}, which states that $n$-skeletal simplicial sets (with $n > 1$) are automatically $(2n{-}1)$-coskeletal.
96	This was used to compute that $\Delta^n/\partial \Delta^n$ is $2n$-Segal but not lower $(2n{-}1)$-Segal for $2 \leq n \leq 7$; we proceeded to prove this for general $n \geq 1$ \cite{Hackney:SdSS}. 
97	Thus the strictness of the hierarchy of higher Segal conditions is visible in rather simple and familiar examples.
98	
99	\section{Simplicial conventions}
100	In this paper $\Delta$ will refer to the category whose objects are nonempty finite sets of integers and whose morphisms are order-preserving maps.
101	The usual simplicial indexing category is the skeletal subcategory of $\Delta$ whose objects are the intervals $[n] = [0,n] = \{0, 1, \dots, n\}$ for $n\geq 0$.
102	We'll write $X(S)$ for $X$ evaluated at $S\in \Delta$; we occasionally abbreviate $X([n])$ to $X_n$.
103	
104	The opposite $X^\op$ of a simplicial object $X$ is given by $X^\op(S) = X(-S)$, and sends $f\colon S \to T$ to
105	\[
106		X(f^-) \colon X(-T) \to X(-S),
107	\]
108	where $f^- \colon (-S) \to (-T)$ is given by $x\mapsto -f(-x)$ for $x\in -S$.
109	
110	If $S\in \Delta$ is a finite ordered set with more than one element and $i\in S$, we'll write $S_i = S\setminus \{i\}$. 
111	If $X$ is a simplicial set, we'll write $e_i \colon X(S) \to X(S_i)$ for the restriction.
112	This is essentially the face map $d_i \colon X_n \to X_{n-1}$ (where $n+1 = |S|$), but has the more convenient interchange property $e_i e_j = e_j e_i$ for $i\neq j$ in $S$.
113	
114	\subsection{D\'ecalage} 
115	The \emph{upper d\'ecalage} of $X$, denoted $\dectop X$, is obtained by shifting simplicial dimension by one (i.e.\ $(\dectop X)_n = X_{n+1}$ for $n\geq 0$) and forgetting about the top face and degeneracy maps \cite[VI.1]{Illusie:CCD2}.
116	More concretely in our setting: $(\dectop X)(S)$ is defined to be $X(S^\triangleright)$ where $S^\triangleright = S \cup \{ \max(S) + 1 \}$, and, if $f\colon S \to T$ is in $\Delta$, then $(\dectop X) (f) \colon (\dectop X)(T) \to (\dectop X)(S)$ is defined to be $X(f^\triangleright)$ where $f^\triangleright \colon S^\triangleright \to T^\triangleright$ is the extension of $f$ which preserves maximal elements.
117	Similarly the \emph{lower d\'ecalage} $\decbot X$ is given by $(\decbot X)(S) = X(S^\triangleleft)$ and $(\decbot X)(f) = X(f^\triangleleft)$, where $S^\triangleleft = \{\min(S) - 1\} \cup S$, and $f^\triangleleft$ is the extension which  preserves minimal elements.
118	Since $(f^\triangleright)^- = (f^-)^\triangleleft$, 
119	the simplicial objects $\dectop (X^\op)$ and $(\decbot X)^\op$ are equal. 
120	
121	\subsection{Coskeletality}
122	
123	If $S \in \Delta$ and a simplicial set $X$ are fixed in a discussion, a symbol like $f_i$ will generally be used for an element of $X(S_i)$.
124	
125	\begin{definition}
126	Let $X$ be a simplicial set, $U \subset S$, and $f_i \in X(S_i)$ a collection of elements (for $i\in U$).
127	\begin{itemize}
128	\item If $e_i f_j = e_j f_i \in X(S_{i,j})$ for all $i\neq j \in U$, we say $\{f_i\}_{i\in U}$ is \emph{compatible}.
129	\item Suppose additionally that $t \in S \setminus U$ and $f_t \in X(S_t)$. If $e_i f_t = e_t f_i$ for all $i\in U$, then we say $f_t$ is \emph{compatible with} the collection $\{f_i\}_{i\in U}$.
130	\end{itemize}
131	\end{definition}
132	
133	We'll use the following simple compatibility lemma repeatedly.
134	
135	\begin{lemma}\label{triv lemma}
136	Let $f_i \in X(S_i)$ for each $i$ in a three element subset $\{p,q,t\} \subset S$. 
137	If $e_qf_t = e_tf_q$ and $e_qf_p = e_p f_q$, then $e_q e_p f_t = e_q e_t f_p$.
138	\end{lemma}
139	\begin{proof} $e_q e_p f_t = e_p e_q f_t = e_p e_t f_q = e_t e_p f_q = e_t e_q f_p = e_q e_t f_p$.
140	\end{proof}
141	
142	A compatible collection where $U=S=[m]$ is called an \emph{$m$-sphere in $X$} in \cite[Definition 3.2]{KRRZ:LTSS}.
143	Coskeletality is about unique filling of $m$-spheres: 
144	
145	\begin{definition}\label{def n-coskel}
146	A simplicial set $X\in \sset$ is \emph{$n$-coskeletal} if, whenever $S = [m]$ for $m > n$ and $\{ f_i \}_{i\in S}$ is a compatible collection, there exists a unique $F \in X_m$ such that $e_i F = f_i$ for all $0\leq i \leq m$.
147	\end{definition}
148	
149	There are multiple equivalent formulations of $n$-coskeletality. 
150	For instance we could ask that $X$ is orthogonal to the boundary inclusions $\partial \Delta^m \to \Delta^m$ for all $m > n$, or we could ask that it is in the image of the right Kan extension from $n$-truncated simplicial sets (presheaves on $\Delta_{\leq n}$).
151	See also \cite[\href{https://kerodon.net/tag/051Z}{Tag 051Z}]{kerodon}.
152	
153	
154	\section{Background: Higher Segal Conditions}
155	
156	We closely follow the presentation of the higher Segal conditions from \cite{HackneyLynd:HSSPG}, which is based on Walde's theorem \cite{Walde:HSSHE}.
157	See \cite{Dyckerhoff:CPOC} for a recent survey on higher Segal spaces.
158	
159	A \emph{gapped subset} $I$ of a finite totally ordered set $S$ is a proper subset which does not contain a pair of adjacent elements of $S$.
160	We will often abbreviate `gapped set of cardinality $k+1$' by `gapped set' when the number $k$ is fixed in the discussion.
161	
162	Given a gapped set $I\subset S$ of cardinality $k+1$, there is a cube
163	\[
164		\cube{I} = \cube{I\subset S} \colon \ps(I) \to \Delta^\op
165	\]
166	sending $U \subset I$ to $S\setminus U$.
167	If $X \colon \Delta^\op \to \mathcal{C}$ is a simplicial object in a category or $\infty$-category $\mathcal{C}$, we write $X\cube{I} \colon \ps(I) \to \mathcal{C}$ for the corresponding composite cube.
168	
169	\begin{definition}[Higher Segal conditions]\label{def higher Segal}
170	Let $k$ be a nonnegative integer and $X$ a simplicial object in $\mathcal{C}$.
171	Consider the collection of gapped subsets $I \subset [n]$ of cardinality $k+1$ as $n$ varies and the associated collection of cubes $X\cube{I} \colon \ps(I) \to \mathcal{C}$.
172	We say that $X$ is
173	\begin{enumerate}
174	\item \emph{lower $(2k{-}1)$-Segal} if $X\cube{I}$ is cartesian for all such $I$,
175	\item \emph{lower $2k$-Segal} if $X\cube{I}$ is cartesian whenever $0 \notin I$,
176	\item \emph{upper $2k$-Segal} if $X\cube{I}$ is cartesian whenever $n \notin I$, and
177	\item \emph{upper $(2k{+}1)$-Segal} if $X\cube{I}$ is cartesian whenever $0 \notin I$ and $n \notin I$.
178	\end{enumerate}
179	\end{definition}
180	
181	We say $X$ is $d$-Segal if it is both upper and lower $d$-Segal.
182	The lower 1-Segal condition is equivalent to the usual Segal condition.
183	When $k=0$, all four cases coincide, and amount to $X$ being a constant simplicial object (\cite[Example~3.9]{Dyckerhoff:CPOC}, \cite[Remark~3.11]{HackneyLynd:HSSPG}).
184	Poguntke showed that if $X$ is upper or lower $d$-Segal, then it is also both upper and lower $(d{+}1)$-Segal (\cite[Theorem~5.1]{Dyckerhoff:CPOC}, \cite[Proposition~3.14]{HackneyLynd:HSSPG}, \cite[Proposition~2.10]{Poguntke:HSSAKT}).
185	
186	\begin{remark}
187	As mentioned in \cite[Remark 3.8]{HackneyLynd:HSSPG}, if $X$ is a simplicial set, then $X$ is lower $(2k{-}1)$-Segal if and only if for each gapped set $I\subset S$ of cardinality $k+1$ and each compatible collection $\{f_i\}_{i\in I}$, there exists a unique $F\in X(S)$ with $e_i F = f_i$ for all $i\in I$.
188	A similar statement holds for the other higher Segal conditions above, and for definitions \ref{def segal properties} and \ref{def d critical} below.
189	This is the form we most often use these properties later.
190	\end{remark}
191	
192	We separate the conditions from \cref{def higher Segal} by simplicial dimension.
193	
194	\begin{definition}\label{def segal properties}
195	Let $k,n$ be nonnegative integers and $X$ a simplicial object.
196	Consider the collection of gapped subsets $I \subset [n]$ of cardinality $k+1$ and the associated collection of cubes $X\cube{I} \colon \ps(I) \to \mathcal{C}$.
197	We say that $X$ has property
198	\begin{enumerate}
199	\item $\lowod^k_n$ if $X\cube{I}$ is cartesian for all $I \subset [n]$,
200	\item $\lowev^k_n$ if $X\cube{I}$ is cartesian whenever $0 \notin I \subset [n]$,
201	\item $\uppev^k_n$ if $X\cube{I}$ is cartesian whenever $n \notin I \subset [n]$, and
202	\item $\uppod^k_n$ if $X\cube{I}$ is cartesian whenever $0,n \notin I \subset [n]$.
203	\end{enumerate}
204	\end{definition}
205	
206	Notice that $X$ satisfies $\lowod^k_n$ or $\uppod^k_n$ if and only if $X^\op$ does so, and $X$ satisfies $\lowev^k_n$ if and only if $X^\op$ satisfies $\uppev^k_n$.
207	This allows us to infer some theorems by \emph{duality}.
208	If $k$ is positive,\footnote{Condition $\lowod^0_0$ is vacuous since gapped sets are proper, while $\lowev_1^0$, $\uppev_1^0$, and $\uppod_2^0$ are non-vacuous.} the first non-vacuous conditions are $\lowod^k_{2k}$, $\lowev^k_{2k+1}$, $\uppev^k_{2k+1}$, and $\uppod^k_{2k+2}$.
209	It will be important to isolate the first \emph{two} simplicial dimensions where there is something to check; see also \cref{rmk d crit}.
210	
211	\begin{definition}\label{def d critical}
212	We say that a simplicial set is \emph{upper (resp.\ lower) $d$-critical} if it satisfies the upper (resp.\ lower) $d$-Segal conditions in the lowest two non-vacuous simplicial dimensions ($d+1$ and $d+2$).
213	This means that our simplicial set is
214	\begin{enumerate}
215	\item lower $(2k{-}1)$-critical if it satisfies $\lowod^k_{2k}$ and $\lowod^k_{2k+1}$,
216	\item lower $2k$-critical if it satisfies $\lowev^k_{2k+1}$ and $\lowev^k_{2k+2}$,
217	\item upper $2k$-critical if it satisfies $\uppev^k_{2k+1}$ and $\uppev^k_{2k+2}$, and 
218	\item upper $(2k{+}1)$-critical if it satisfies $\uppod^k_{2k+2}$ and $\uppod^k_{2k+3}$.
219	\end{enumerate}
220	\end{definition}
221	
222	We next have Poguntke's \emph{path space criterion} \cite[Proposition 2.7]{Poguntke:HSSAKT}.\footnote{See also \cite[Theorem 6.3.2]{DyckerhoffKapranov:HSS} and \cite[Theorem 4.10]{GKT1}}
223	The similar statement replacing `$d$-Segal' with `$d$-critical' holds by \cref{easy psc} below.
224	
225	\begin{theorem}[Path Space Criterion]\label{path space criterion}
226	Let $X$ be a simplicial object and $k\geq 1$.
227	The simplicial object 
228	$X$ is lower (resp.\ upper) $2k$-Segal if and only if $\decbot X$ (resp.\ $\dectop X$) is lower $(2k{-}1)$-Segal.
229	The simplicial object $X$ is upper $(2k{+}1)$-Segal if and only if $\decbot X$ is upper $2k$-Segal if and only if $\dectop X$ is lower $2k$-Segal if and only if $\dectop \decbot X = \decbot \dectop X$ is lower $(2k{-}1)$-Segal. \qed
230	\end{theorem}
231	
232	\begin{proposition}\label{easy psc}
233	Let $X$ be a simplicial object and $k\geq 1$.
234	\begin{enumerate}
235			\item $X$ satisfies $\lowev^k_n$ if and only if $\decbot X$ satisfies $\lowod^k_{n-1}$.\label{PSC ldec}
236			\item $X$ satisfies $\uppev^k_n$ if and only if $\dectop X$ satisfies $\lowod^k_{n-1}$.\label{PSC udec}
237			\item The following are equivalent:
238			\begin{enumerate}[label={\alph*.}, ref=\alph*]
239			\item $X$ satisfies $\uppod^k_n$.
240			\item $\decbot X$ satisfies $\uppev^k_{n-1}$.
241			\item $\dectop X$ satisfies $\lowev^k_{n-1}$.
242			\item $\decbot \dectop X = \dectop \decbot X$ satisfies $\lowod^k_{n-2}$.
243			\end{enumerate}
244	\end{enumerate}
245	\end{proposition}
246	\begin{proof}
247	As in the proof of Proposition 3.13 of \cite{HackneyLynd:HSSPG}.
248	\end{proof}
249	
250	
251	
252	\begin{remark}\label{rmk d crit}
253	In formulating upper or lower $d$-critical in \cref{def d critical}, one could instead use (for simplicial dimension $n=d+1,d+2$) the geometric conditions in \cite[Definition 3.7]{Dyckerhoff:CPOC} (or \cite[Definition 2.2]{Poguntke:HSSAKT}) expressed in terms of triangulations of cyclic polytopes.
254	This yields an equivalent definition -- it's not so arduous to prove this directly, but one can also see it by a careful reading of Walde's proof of the equivalence of the $(2k{-}1)$-Segal conditions (especially the proof of Theorem 7.2.1 of \cite{Walde:HSSHE}; see \cite[Remark 3.6]{HackneyLynd:HSSPG}) and Poguntke's account of the path space criterion \cite[Proposition 2.7]{Poguntke:HSSAKT}.
255	Thus, for example, $2$-critical simplicial objects can be described as those local with respect to triangulations of squares and pentagons.
256	\end{remark}
257	
258	We end this section with the Wiggle Lemma, whose strategy of proof informs the argument in \cref{prop lower odd implies coskel}.
259	Immediate consequences of the Wiggle Lemma are \cite[Lemma 3.9]{HackneyLynd:HSSPG} (on which its proof is based) and \cite[Lemma 3.6]{GKT1}.
260	
261	\begin{lemma}[Wiggling]\label{wiggling}
262	If $X$ has property $\lowod^k_{n-1}$ and there is a gapped set $I \subset [n]$ of size $k+1$ such that $X\cube{I}$ is cartesian, then $X$ has property $\lowod^k_n$.
263	Similarly, if $X$ has property $\lowev_{n-1}^k$ (resp.\ $\uppev_{n-1}^k$, resp.\ $\uppod_{n-1}^k$) and there is a gapped set %(of size $k+1$) 
264	$I\subset [n]$ avoiding $0$ (resp.\ avoiding $n$, resp.\ avoiding $0$ and $n$) such that $X\cube{I}$ is cartesian, then $X$ has property $\lowev_n^k$ (resp.\ $\uppev_n^k$, resp.\ $\uppod_n^k$).
265	\end{lemma}
266	\begin{proof}
267	If $n < 2k$ then $\lowod^k_n$ is a vacuous condition, while if $n=2k$ then there is exactly one gapped set in $[n]$, so the condition is satisfied by hypothesis. Assume $n > 2k$.
268	
269	Suppose we have two gapped sets $I, J \subset [n] = S$ which differ in only one position.
270	In other words, $I\setminus J = \{ \bim \}$ and $J\setminus I = \{ \bjm \}$ such that the successor (resp.\ predecessor) of $\bim$ in $I \cup \{-1, n+1\}$ coincides with the successor (resp.\ predecessor) of $\bjm$ in $J \cup \{-1, n+1\}$.
271	Notice that $J\subset S_\bim$ and $I \subset S_\bjm$ are also gapped sets.
272	The following square of maps of cubes commutes.
273	\[ \begin{tikzcd}[row sep=0.25cm]
274	& 
275	X\cube{I_\bim \subset S_\bim} \rar[equals] &[-0.6cm] 
276	X\cube{J_\bjm \subset S_\bim}
277		\drar[bend left=15,"X\cube{J\subset S_\bim}"]
278	\\
279	X\cube{I_\bim \subset S} \dar[equals] 
280		\urar[bend left=15,"X\cube{I\subset S}"]
281	& 
282	&
283	&
284	X\cube{J_\bjm \subset S_{\bim,\bjm}} \dar[equals]
285	\\%[-0.4cm]
286	X\cube{J_\bjm \subset S}
287		\drar[bend right=15,"X\cube{J\subset S}"']
288	& 
289	&
290	&
291	X\cube{I_\bim \subset S_{\bim,\bjm}}
292	\\
293	& 
294	X\cube{J_\bjm \subset S_\bjm} \rar[equals] &[-0.6cm] 
295	X\cube{I_\bim \subset S_\bjm}
296		\urar[bend right=15,"X\cube{I\subset S_\bjm}"']
297	\end{tikzcd} \]
298	The cubes $X\cube{J\subset S_\bim}$ and $X\cube{I\subset S_\bjm}$ are cartesian by $\lowod^k_{n-1}$, so $X\cube{I\subset S}$ is cartesian if and only if $X\cube{J\subset S}$ is cartesian by \cite[Lemma 3.3]{HackneyLynd:HSSPG}.
299	Iterating this process, we see that $X$ is cartesian for a gapped set $I \subset [n]$ if and only if it is cartesian for $\{0 < 2 < \dots < 2k \}$, and the result follows.
300	The statements in the second sentence follow from the first via \cref{easy psc}.
301	\end{proof}
302	
303	
304	
305	==============
306	
307	
308	
309	
310	
311	\begin{theorem}\label{thm main theorem}
312	Let $X$ be a simplicial set and $d \geq 0$.
313	If $X$ is $(d{+}2)$-coskeletal and is upper (resp.\ lower) $d$-critical, then it is upper (resp.\ lower) $d$-Segal.
314	Conversely, if $X$ is upper or lower $d$-Segal, then it is $(d{+}1)$-coskeletal.
315	\end{theorem}
316	\begin{proof}
317	The second statement is \cref{hsc implies coskel}, while the first combines \cref{lem k=0 case}, \cref{thm lowod case coskel to segal}, and \cref{thm other cases coskel to segal}.
318	\end{proof}
319	
320	\begin{remark}\label{rmk simplicial anima}
321	The corresponding statement for simplicial spaces is false.
322	Let $M$ be a nonempty space, and $X$ the associated constant simplicial space, which is automatically $0$-Segal (hence $d$-Segal for all $d$).
323	The $p$-coskeleton of $X$ (see \cite[\href{https://kerodon.net/tag/05GU}{Tag 05GU}]{kerodon}) is given in dimension $n$ by 
324	\[
325		(\cosk_p X)_n \simeq \lim_{(\Delta_{/[n]} \times_\Delta \Delta_{\leq p})^\op} M \simeq \map(|\Delta_{/[n]} \times_\Delta \Delta_{\leq p}|, M),
326	\]
327	the second equivalence because $X$ is constant, 
328	where $\Delta_{\leq p} \subset \Delta$ is the full subcategory on $[q]$ for $q \leq p$.
329	Since $|\Delta_{/[n]} \times_\Delta \Delta_{\leq p}| \simeq |\sk_p \Delta^n|$, taking $n=p+1$ gives $|\partial \Delta^{p+1}| \simeq S^p$, and the unit map $X_{p+1} \to (\cosk_p X)_{p+1}$ is identified with restriction along $\sk_p \Delta^{p+1} \subset \Delta^{p+1}$, i.e.\ with the inclusion of constant maps $M \to M^{S^p}$.
330	This is a section of evaluation at a basepoint, whose fibers are $\Omega^p M$, hence is an equivalence if and only if $\Omega^p M$ is contractible.
331	
332	Now suppose $M$ has infinitely many nontrivial homotopy groups (e.g.\ $M=S^2$).
333	Then $X$ immediately gives a counterexample to the second statement, as $\Omega^p M$ is not contractible for any $p$, but $X$ is $d$-Segal for all $d\geq 0$.
334	
335	For the first statement, set $Y \coloneq \cosk_{d+2} X$, which is $(d{+}2)$-coskeletal. 
336	As the unit $X \to Y$ is an equivalence in simplicial dimensions up to $d+2$, we have that $Y$ is $d$-critical since $X$ is so.
337	But naturality implies that $Y$ cannot satisfy the $d$-Segal condition in simplicial dimension $d+3$, since $X$ is known to, and $M \simeq X_{d+3} \to Y_{d+3} \simeq M^{S^{d+2}}$ is not an equivalence.
338	\end{remark}
Thinking
$ Bash
grep -n "edgewise\|subdivision\|sd\b\|twisted" decomp.tex | head -80
55:\DeclareMathOperator{\sd}{sd}
100:Key results include the path space criterion, which characterizes decomposition spaces in terms of their upper and lower décalages, and the edgewise subdivision criterion. 
126:The next three sections (\S\ref{sec segal spaces}, \S\ref{sec path space}, \S\ref{sec edgewise}) are all about relationships between decomposition spaces and Segal spaces.
130:Finally, in \cref{sec edgewise} we prove the closely related edgewise subdivision criterion, which says that $X$ is a decomposition space if and only if $\sd X$ is a Segal space.
783:\section{The edgewise subdivision criterion}\label{sec edgewise}
787:This proof relies on the path space criterion (\cref{cor path space}), which is appropriate as there is a close connection between the edgewise subdivision and the upper/lower d\'ecalage pair.\phnote{Additionally, this theorem can be interpreted in terms of the double-categorical perspective from \cite{BOORS:2SSWC}.}
788:\begin{theorem}\label{thm edgewise}
789:A simplicial space $X$ is a decomposition space if and only if its edgewise subdivision $\sd X$ is Segal.
792:As with the d\'ecalage functors, the edgewise subdivision is the result of precomposition with an endofunctor of $\Delta$, namely the one that sends $[n]$ to $[n]^\op \star [n] \cong [2n+1]$.
808:If $X$ is a simplicial space, then the simplicial space $Z = \sd X$ has $Z_n = X_{2n+1}$ and
813:One can check that $\sd X = \sd (X^\op)$. %May 30 note.
814:If $X$ is the nerve of a category $C$, then $\sd X$ is (isomorphic to) the nerve of the \emph{twisted arrow category} of $C$, whose objects are the morphisms of $C$, and where a morphism $f \to g$ is given by a factorization of $g$ as below:
822:One manifestation of the connection between d\'eclage and edgewise subdivision is that iterated bottom and top degeneracies yield simplicial maps
824:\ldec X \rar & \sd X & (\udec X)^\op. \lar
829:\begin{equation}\label{eq ldec to sd}
830:  \ldec X_n = X_{n+1} \xrightarrow{s_\bot^n} X_{2n+1} = \sd X_n.
834:  \sd X_n = X_{2n+1} \xleftarrow{s_\top^n} X_{n+1} = (\udec X)^\op_n,
838:\begin{lemma}\label{lem decomp implies sd Segal}
839:If $X$ is a decomposition space, then $\sd X$ is Segal.
842:Let $Z = \sd X$.
858:Let $X$ be a simplicial space and write $Y = \ldec X$, $Z = \sd X$. For each $n \geq 1$, the square below left is a retract of the square below right:
867:Consequently, if $\sd X$ is Segal, so is $\ldec X$.
871:The map from left to right is given by the simplicial map $Y \to Z$ from \eqref{eq ldec to sd}.
917:If $\sd X$ is Segal, so is the upper d\'ecalage $\udec X$.
920:We have $\sd X = \sd (X^\op)$ for any simplicial space $X$. 
924:\begin{proof}[Proof of \cref{thm edgewise}]
925:The forward direction is \cref{lem decomp implies sd Segal}.
926:If $\sd X$ is Segal, then the preceding two lemmas show that $\ldec X$ and $\udec X$ are Segal as well, so the path space criterion implies that $X$ is a decomposition space.
929:% We have already observed that the edgewise subdivision and d\'ecalage constructions are closely related, which is corroborated by the following, already prefigured in \cite{BOORS:2SSWC}.
931:\begin{remark}\label{rmk sd vs dec}
932:If $X$ is a discrete decomposition space, then the three simplicial sets $\sd X$, $\ldec X$, and $\udec X$ are (nerves of) categories.
933:We have inclusions of simplicial sets $\ldec X \hookrightarrow \sd X$ and $(\udec X)^\op \hookrightarrow \sd X$.
934:Identifying each of these subcategories with its image, the category $\sd X$ admits two (strict) factorization systems $(\ldec X, (\udec X)^\op)$ and $((\udec X)^\op, \ldec X)$; see \cite{Hackney:OC2SS} for one explanation.% (including for simplicial spaces).
937:There is also an interesting story about culf maps (\cref{def culf}) and edgewise subdivision, which gives the following theorem from \cite{KockSpivak:DSST} (see \cite{HackneyKock:CMES} for a generalization). 
940:If $X$ is a discrete decomposition space, then there is an equivalence of categories between the category of culf maps over $X$ and the category of presheaves on $\sd X$.
Read
{
  "file_path": "~/twisted_arrow/decomp.tex",
  "offset": 640,
  "limit": 300
}
640	\end{proof}
641	
642	\begin{exercise}\label{exc 2-Segal defs}
643	Recall that one characterization of 2-Segal spaces given in \cite{Stern:BIRS} is that $X$ sends the pushout diagram of finite ordered sets
644	\begin{equation}
645	\label{diag ij}
646	\begin{tikzcd}
647	\{ i,j\} \rar[-act] \dar[tail] & \{i,i+1, \dots, j \} \dar[tail] \\
648	\{0,1,\dots, i,j,j+1, \dots, n\} \rar[-act] & {[n]}
649	\end{tikzcd} \end{equation}
650	to a pullback for each $0 \leq i < j \leq n$.
651	Prove this condition is equivalent to the definition of 2-Segal space from \cref{def 2-segal}.
652	\end{exercise}
653	
654	The squares \eqref{diag ij} correspond to those squares appearing in \eqref{diag ai pushout} of \cref{lem ai pushout} where $n=1$ and $\alpha$ is injective.
655	As in \cite[Proposition 2.3.2]{DyckerhoffKapranov:HSS}, one only needs to require these squares be sent to pullbacks when $i=0$ or $j=n$.
656	
657	\section{Segal spaces are decomposition spaces}\label{sec segal spaces}
658	
659	In \cite{Stern:BIRS}, we saw that the nerve of a category is a 2-Segal set, under the characterization from \cref{exc 2-Segal defs}, a fact that is true more generally: Segal spaces \cite{Rezk:MHTHT,Segal:CCT} are always decomposition spaces.
660	In this brief section we use the pasting law to establish this fact, and to characterize the Segal spaces among decomposition spaces.
661	
662	\begin{definition}\label{def Segal}
663	A simplicial space $X$ is a \emph{Segal space} if the following equivalent conditions hold.
664	\begin{enumerate}
665	\item \label{item pullback Segal} For each $n\geq 1$, the following square is a pullback. 
666	\[ \begin{tikzcd}
667	X_{n+1} \ar[dr, phantom, "\lrcorner" very near start] \rar{d_\bot} \dar[swap]{d_\top} & X_n \dar{d_\top} \\
668	X_n \rar[swap]{d_\bot} & X_{n-1}
669	\end{tikzcd} \]
670	\item For each $n\geq 2$, the map
671	\[
672	\begin{tikzcd}[column sep=2.2cm]
673	X_n \rar["(d_\top^{n-i} d_\bot^{i-1})_{i=1}^n" swap, "\simeq"] & X_1 \times_{X_0} X_1 \times_{X_0} \dots  \times_{X_0} X_1
674	\end{tikzcd} 
675	\]
676	is an equivalence. \label{item usual Segal}
677	\end{enumerate}
678	\end{definition}
679	
680	\begin{exercise}
681	Prove that \eqref{item pullback Segal} and \eqref{item usual Segal} in \cref{def Segal} are equivalent. (For a hint or solution, see \cite[Lemma 2.10]{GKT1}.)
682	\end{exercise}
683	
684	\begin{proposition}\label{segal implies decomposition}
685	Every Segal space is a decomposition space.
686	\end{proposition}
687	\begin{proof}
688	We show that every Segal space is upper 2-Segal.
689	Since the opposite of a Segal space is a Segal space, and the opposite of an upper 2-Segal space is a lower 2-Segal space, this argument suffices.
690	By \cref{prop fewer squares}, we need only show that the left square in diagram 
691	\[ \begin{tikzcd}
692	X_{n+1} \rar{d_n} \dar[swap]{d_\bot} &
693	X_n \rar{d_\top} \dar[swap]{d_\bot} \ar[dr, phantom, "\lrcorner" very near start] & X_{n-1} \dar{d_\bot}
694	\\
695	X_n \rar[swap]{d_{n-1}} & 
696	X_{n-1} \rar[swap]{d_\top} & X_{n-2}
697	\end{tikzcd} \]
698	is a pullback.
699	The right square is a pullback since $X$ is Segal.
700	The outer rectangle is equal to the outer rectangle of the diagram
701	\[ \begin{tikzcd}
702	X_{n+1} \rar{d_\top} \dar[swap]{d_\bot} \ar[dr, phantom, "\lrcorner" very near start] &
703	X_n \rar{d_\top} \dar[swap]{d_\bot} \ar[dr, phantom, "\lrcorner" very near start] & X_{n-1} \dar{d_\bot}
704	\\
705	X_n \rar[swap]{d_\top} & 
706	X_{n-1} \rar[swap]{d_\top} & X_{n-2}.
707	\end{tikzcd} \]
708	Since both squares are pullbacks, so is the outer rectangle, which implies that the left square in first diagram is a pullback, as desired.
709	\end{proof}
710	
711	\begin{proposition}
712	A simplicial space $X$ is a Segal space if and only if it is a decomposition space and the following square is a pullback:
713	\[ \begin{tikzcd}
714	X_2 \rar{d_0} \dar[swap]{d_2} & X_1 \dar{d_1} \\
715	X_1 \rar[swap]{d_0} & X_0.
716	\end{tikzcd} \]
717	\end{proposition}
718	\begin{proof}
719	The forward direction is immediate from \cref{segal implies decomposition}.
720	For the reverse direction, one shows via induction that the squares in \cref{def Segal} \eqref{item pullback Segal} are pullbacks; the case $n=1$ is an assumption.
721	For the inductive step, use the two rectangles from the proof of \cref{segal implies decomposition} in a different way, assuming that both squares in the first rectangle and the right square in the second rectangle are pullbacks, in order to deduce that the left square in the second rectangle is a pullback.
722	\end{proof}
723	
724	\section{The path space criterion}\label{sec path space}
725	
726	We now turn to the path space criterion, which is originally due to Dyckerhoff and Kapranov \cite[Theorem 6.3.2]{DyckerhoffKapranov:HSS}.
727	Our presentation separates the lower and upper 2-Segal conditions, following Poguntke \cite{Poguntke:HSSAKT}, who also gave higher-dimensional versions.
728	A version for decomposition spaces appeared as \cite[Theorem 4.10]{GKT1}.
729	
730	\begin{theorem}\label{thm upper path}
731	A simplicial space $X$ is upper 2-Segal if and only if its upper d\'ecalage $\udec X$ is Segal.
732	\end{theorem}
733	
734	The upper d\'ecalage $\udec X$ is given by precomposition of $X \colon \Delta^\op \to \spaces$ with the endofunctor $\Delta \to \Delta$ that sends $[n]$ to $[n]\star [0] \cong [n+1]$.\footnote{
735	Here $\star$ denotes the \emph{join} of categories \cite[\href{https://kerodon.net/tag/0160}{Tag 0160}]{kerodon}, where the set of objects of $C \star D$ is the disjoint union of the sets of objects of $C$ and $D$, the categories $C$ and $D$ are full subcategories of $C\star D$, and, for $c\in C$ and $d\in D$, there are no morphisms $d\to c$ and exactly one morphism $c\to d$.}
736	This endofunctor takes $f\colon [n] \to [m]$ to $g\colon [n+1] \to [m+1]$ satisfying $g(n+1) = m+1$ and $g(k) = f(k)$ for $0\leq k \leq n$.
737	
738	More explicitly, we have $(\udec X)_n = X_{n+1}$ and the face and degeneracy operators are given for $0 \leq k \leq n$ by
739	\begin{align*} 
740	\big( d_k \colon (\udec X)_n \to (\udec X)_{n-1} \big) &= \big( d_k \colon X_{n+1} \to X_n \big)
741	\\
742	\big( s_k \colon (\udec X)_n \to (\udec X)_{n+1} \big) &= \big( s_k \colon X_{n+1} \to X_{n+2} \big).
743	\end{align*}
744	Notably, we have forgotten about the top face $d_\top = d_{n+1} \colon X_{n+1} \to X_n$ and top degeneracy $s_\top = s_n \colon X_n \to X_{n+1}$.
745	The upper d\'ecalage is also called the \emph{final path space} and denoted by $P^\triangleright X$.
746	
747	\begin{proof}[Proof of \cref{thm upper path}]
748	For $n\geq 2$, the following two squares are the same:
749	\[ \begin{tikzcd}
750	(\udec X)_n \rar{d_\top} \dar[swap]{d_\bot}  & (\udec X)_{n-1} \dar{d_\bot} 
751	&  
752	X_{n+1} \rar{d_n} \dar[swap]{d_\bot}  & X_n \dar{d_\bot}
753	\\
754	(\udec X)_{n-1} \rar[swap]{d_\top} & (\udec X)_{n-2}
755	&  
756	X_n \rar[swap]{d_{n-1}} & X_{n-1}.
757	\end{tikzcd} \]
758	\cref{prop fewer squares} says that the right square is a pullback for all $n\geq 2$ if and only if $X$ is upper 2-Segal.
759	\end{proof}
760	
761	Similarly, there is a lower d\'ecalage $\ldec X$ (or initial path space $P^\triangleleft X$) with $(\ldec X)_n = X_{n+1}$ obtained by forgetting the bottom face and degeneracy operators (and shifting indices by one).
762	It can be formally obtained using precomposition with the endofunctor $[n] \mapsto [0] \star [n]$ of $\Delta$, sending $f \colon [n] \to [m]$ to $g \colon [n+1] \to [m+1]$ satisfying $g(0) = 0$ and $g(k) = f(k-1) + 1$ for $1 \leq k \leq n+1$.
763	In other words, the face and degeneracy operators are as follows:
764	\begin{align*} 
765	\big( d_k \colon (\ldec X)_n \to (\ldec X)_{n-1} \big) &= \big( d_{k+1} \colon X_{n+1} \to X_n \big)
766	\\
767	\big( s_k \colon (\ldec X)_n \to (\ldec X)_{n+1} \big) &= \big( s_{k+1} \colon X_{n+1} \to X_{n+2} \big).
768	\end{align*}
769	One checks that $(\udec X)^\op = \ldec(X^\op)$, so that applying \cref{thm upper path} to $X^\op$ we obtain the following.
770	
771	\begin{corollary}
772	A simplicial space $X$ is lower 2-Segal if and only if its lower d\'ecalage $\ldec X$ is Segal. \qed
773	\end{corollary}
774	
775	Using \cref{thm unitality}, we conclude the original form of the path space criterion.
776	
777	\begin{corollary}\label{cor path space}
778	A simplicial space $X$ is a decomposition space if and only if both $\udec X$ and $\ldec X$ are Segal. \qed
779	\end{corollary}
780	
781	When $X$ is a decomposition space, it turns out that the maps $d_\top \colon \udec X \to X$ and $d_\bot \colon \ldec X \to X$ are culf (in the sense of \cref{def culf}); see \cite[Theorem~4.10]{GKT1}.
782	
783	\section{The edgewise subdivision criterion}\label{sec edgewise}
784	
785	In this section we explain the following theorem from \cite{BOORS:ESC}.
786	The proof presented here utilizes the exact same techniques that we have been using since \cref{sec 2-Segl decomp}.
787	This proof relies on the path space criterion (\cref{cor path space}), which is appropriate as there is a close connection between the edgewise subdivision and the upper/lower d\'ecalage pair.\phnote{Additionally, this theorem can be interpreted in terms of the double-categorical perspective from \cite{BOORS:2SSWC}.}
788	\begin{theorem}\label{thm edgewise}
789	A simplicial space $X$ is a decomposition space if and only if its edgewise subdivision $\sd X$ is Segal.
790	\end{theorem}
791	
792	As with the d\'ecalage functors, the edgewise subdivision is the result of precomposition with an endofunctor of $\Delta$, namely the one that sends $[n]$ to $[n]^\op \star [n] \cong [2n+1]$.
793	A map $f \colon [n] \to [m]$ is sent to $g \colon [2n+1] \to [2m+1]$ with
794	\[
795	g(t) = \begin{cases}
796	m - f(n-t) & t \leq n \\
797	m+1 + f(t-n-1) & n+1 \leq t.
798	\end{cases}
799	\]
800	If we write $[2n+1]$ in the following way
801	\[
802	\begin{tikzcd}[sep=small]
803	  0 \rar & 1 \rar & \cdots \rar & n \\
804	  0' \uar & 1' \lar & \cdots \lar & n' \lar,
805	\end{tikzcd}
806	\]
807	then $g$ can be interpreted as $t' \mapsto f(t)'$ and $t \mapsto f(t)$.
808	If $X$ is a simplicial space, then the simplicial space $Z = \sd X$ has $Z_n = X_{2n+1}$ and
809	\begin{align*}
810	  \big(d_i \colon Z_n \to Z_{n-1}\big) &= \big(d_{n-i} d_{n+i+1} \colon X_{2n+1} \to X_{2n-1}\big) \\
811	  \big(s_i \colon Z_n \to Z_{n+1}\big) &= \big(s_{n-i} s_{n+i+1} \colon X_{2n+1} \to X_{2n+3}\big).
812	\end{align*}
813	One can check that $\sd X = \sd (X^\op)$. %May 30 note.
814	If $X$ is the nerve of a category $C$, then $\sd X$ is (isomorphic to) the nerve of the \emph{twisted arrow category} of $C$, whose objects are the morphisms of $C$, and where a morphism $f \to g$ is given by a factorization of $g$ as below:
815	\[
816	\begin{tikzcd}  
817	  c' \rar{k} & d' \\
818	  c \uar{f} & d \lar{h} \uar[swap]{g}.
819	\end{tikzcd}
820	\]
821	
822	One manifestation of the connection between d\'eclage and edgewise subdivision is that iterated bottom and top degeneracies yield simplicial maps
823	\[ \begin{tikzcd}[sep=small]
824	\ldec X \rar & \sd X & (\udec X)^\op. \lar
825	\end{tikzcd} \]
826	For the map on the left, recall that $\ldec X$ is given by precomposition with the endofunctor $[n] \mapsto [0] \star [n]$. 
827	The maps $[n]^\op \star [n] \to [0] \star [n]$ collapsing the first component to a point gives a natural transformation of functors, and hence the indicated map.
828	It is specified by
829	\begin{equation}\label{eq ldec to sd}
830	  \ldec X_n = X_{n+1} \xrightarrow{s_\bot^n} X_{2n+1} = \sd X_n.
831	\end{equation}
832	Likewise, the leftward arrow is given by
833	\[
834	  \sd X_n = X_{2n+1} \xleftarrow{s_\top^n} X_{n+1} = (\udec X)^\op_n,
835	\]
836	which arises from the natural transformation $[n]^\op \star [n] \to [n]^\op \star [0]$.
837	
838	\begin{lemma}\label{lem decomp implies sd Segal}
839	If $X$ is a decomposition space, then $\sd X$ is Segal.
840	\end{lemma}
841	\begin{proof}
842	Let $Z = \sd X$.
843	For $n\geq 1$, the following two squares are the same:
844	\[ \begin{tikzcd}
845	Z_{n+1} \rar{d_{n+1}} \dar[swap]{d_0}  & Z_n \dar{d_0} 
846	&  
847	X_{2n+3} \rar{d_0d_{2n+3}} \dar[swap]{d_{n+1}d_{n+2}}  & X_{2n+1} \dar{d_n d_{n+1}}
848	\\
849	Z_n \rar[swap]{d_n} & Z_{n-1}
850	&  
851	X_{2n+1} \rar[swap]{d_0d_{2n+1}} & X_{2n-1}.
852	\end{tikzcd} \]
853	The result follows since the right-hand square is an active-inert pullback square.
854	\end{proof}
855	
856	
857	\begin{lemma}\label{lem ldec square as retract}
858	Let $X$ be a simplicial space and write $Y = \ldec X$, $Z = \sd X$. For each $n \geq 1$, the square below left is a retract of the square below right:
859	\[ \begin{tikzcd}
860	Y_{n+1} \rar{d_\bot} \dar[swap]{d_\top} & Y_n \dar{d_\top} 
861	& Z_{n+1} \rar{d_\bot} \dar[swap]{d_\top} & Z_n \dar{d_\top} 
862	\\
863	Y_n \rar[swap]{d_\bot} & Y_{n-1}
864	&
865	Z_n \rar[swap]{d_\bot} & Z_{n-1}.
866	\end{tikzcd} \]
867	Consequently, if $\sd X$ is Segal, so is $\ldec X$.
868	\end{lemma}
869	\begin{proof}
870	The conclusion follows since pullbacks are stable under retracts.
871	The map from left to right is given by the simplicial map $Y \to Z$ from \eqref{eq ldec to sd}.
872	We explicitly give the retraction from right to left (which does \emph{not} come from a simplicial map $Z \to Y$).
873	Utilizing the simplicial identities, all faces in the following cube commute:
874	\[ \begin{tikzcd}
875	X_{2n+3} \ar[rr,"d_0d_{2n+3}"] \ar[dd,"d_{n+1}d_{n+2}"'] \ar[dr,"d_0d_2^n" description] & & 
876	X_{2n+1} \ar[dd, "d_nd_{n+1}"' very near start] \ar[dr,"d_1^n"]  \\
877	& 
878	X_{n+2} \ar[rr,"d_{n+2}" near end, crossing over] & & 
879	X_{n+1} \ar[dd,"d_1"] \\
880	X_{2n+1} \ar[rr,"d_0d_{2n+1}" very near start] \ar[dr,"d_0d_2^{n-1}"'] & & X_{2n-1} \ar[dr,"d_1^{n-1}" description] \\
881	& X_{n+1} \ar[rr,"d_{n+1}"] \ar[from=uu, crossing over, "d_1" very near start] & & X_n.
882	\end{tikzcd} \]
883	In terms of the face maps of $Y$ and $Z$, the front and back faces of the cube are as follows:
884	\[ \begin{tikzcd}
885	Z_{n+1} \ar[rr,"d_{n+1}^Z"] \ar[dd,"d_0^Z"'] \ar[dr,"d_0d_2^n" description] & & 
886	Z_n \ar[dd, "d_0^Z"' very near start] \ar[dr,"d_1^n"]  \\
887	& 
888	Y_{n+1} \ar[rr,"d_{n+1}^Y" near end, crossing over] & & 
889	Y_n \ar[dd,"d_0^Y"] \\
890	Z_n \ar[rr,"d_n^Z" very near start] \ar[dr,"d_0d_2^{n-1}"'] & & Z_{n-1} \ar[dr,"d_1^{n-1}" description] \\
891	& Y_n \ar[rr,"d_n^Y"] \ar[from=uu, crossing over, "d_0^Y" very near start] & & Y_{n-1}.
892	\end{tikzcd} \]
893	% That is, we are using the maps of squares
894	% \[
895	% \setlength\arraycolsep{1pt}
896	% S = \,
897	% \begin{matrix}
898	% s_\bot^{n+1} & \vline & s_\bot^n \\
899	% \hline
900	% s_\bot^n & \vline & s_\bot^{n-1}
901	% \end{matrix}
902	% \qquad
903	% \text{and}
904	% \qquad
905	% D = 
906	% \, \begin{matrix}
907	% d_0d_2^n & \vline & d_1^n \\
908	% \hline
909	% d_0d_2^{n-1} & \vline & d_1^{n-1}
910	% \end{matrix}
911	% \]
912	% with $DS = \id$.
913	We thus see that the $Y$ square is indeed a retract of the $Z$ square since $d_1^n s_0^n = \id_{X_{n+1}} = d_0 d_2^{n-1} s_0^n$ for all $n\geq 1$.
914	\end{proof}
915	
916	\begin{lemma}
917	If $\sd X$ is Segal, so is the upper d\'ecalage $\udec X$.
918	\end{lemma}
919	\begin{proof}
920	We have $\sd X = \sd (X^\op)$ for any simplicial space $X$. 
921	By \cref{lem ldec square as retract} we conclude that $\ldec(X^\op) = (\udec X)^\op$ is Segal.
922	\end{proof}
923	
924	\begin{proof}[Proof of \cref{thm edgewise}]
925	The forward direction is \cref{lem decomp implies sd Segal}.
926	If $\sd X$ is Segal, then the preceding two lemmas show that $\ldec X$ and $\udec X$ are Segal as well, so the path space criterion implies that $X$ is a decomposition space.
927	\end{proof}
928	
929	% We have already observed that the edgewise subdivision and d\'ecalage constructions are closely related, which is corroborated by the following, already prefigured in \cite{BOORS:2SSWC}.
930	
931	\begin{remark}\label{rmk sd vs dec}
932	If $X$ is a discrete decomposition space, then the three simplicial sets $\sd X$, $\ldec X$, and $\udec X$ are (nerves of) categories.
933	We have inclusions of simplicial sets $\ldec X \hookrightarrow \sd X$ and $(\udec X)^\op \hookrightarrow \sd X$.
934	Identifying each of these subcategories with its image, the category $\sd X$ admits two (strict) factorization systems $(\ldec X, (\udec X)^\op)$ and $((\udec X)^\op, \ldec X)$; see \cite{Hackney:OC2SS} for one explanation.% (including for simplicial spaces).
935	\end{remark}
936	
937	There is also an interesting story about culf maps (\cref{def culf}) and edgewise subdivision, which gives the following theorem from \cite{KockSpivak:DSST} (see \cite{HackneyKock:CMES} for a generalization). 
938	
939	\begin{theorem}\label{thm kock spivak}
Thinking
Read
{
  "file_path": "~/twisted_arrow/from_hsd.tex"
}
1	\section{Higher Segal spaces}\label{sec higher Segal}
2	
3	At the beginning of this section, we provide background material on higher Segal spaces. 
4	Our approach highlights that the types of arguments used in the decomposition space literature can also be used for higher Segal spaces, by replacing pullback squares with cartesian cubes of larger dimension.
5	This relies on work of Walde, who recast the higher Segal conditions in terms of cartesian cubes. 
6	We'll begin with preliminaries on cartesian cubes before turning to the higher Segal conditions for simplicial objects in \cref{ss HSC Walde}.
7	Arguments in this section are in the spirit of those in \cite{Hackney:DSP}.
8	In \cref{ss SSO Segal} we discuss the case of symmetric simplicial objects, where a number of subtleties vanish.
9	
10	In this section, $\mathcal{C}$ will denote a fixed category (or $\infty$-category) with finite limits.
11	All subsequent sections of the paper will take $\mathcal{C}$ to be the category of sets, and the reader is welcome to make this replacement immediately.
12	
13	\subsection{Cubical diagrams}
14	We recall basics about cube-shaped diagrams in a category or $\infty$-category; references include \cite[\S3.3]{Walde:HSSHE} and \cite[\S6.1.1]{LurieHA}.
15	The \emph{generic cube} of dimension $n$ is the $n$-fold product $[1]^n \in \cat$ of the generic arrow $ \{ 0 \to 1 \} = [1] \in \ord \subset \cat$.
16	An \emph{$n$-dimensional cubical diagram} in $\mathcal{C}$, or briefly an \emph{$n$-cube}, is a functor $[1]^n \to \mathcal{C}$.
17	The functor category $\fun([1]^n, \mathcal{C})$ is the associated category of cubes.
18	If $S$ is a set of cardinality $n$, then we may also think of a functor $\ps(S) \to \mathcal{C}$ from the powerset of $S$ as an $n$-cube in $\mathcal{C}$ by choosing an isomorphism $\ps(S) \cong [1]^n$ (and similarly for $\ps(S)^\op$).
19	
20	A map between $n$-cubes may be regarded as an $(n{+}1)$-cube.
21	Namely, we have the following description of the arrow category of the category of cubes, for each choice of isomorphism $[1] \times [1]^n \cong [1]^{n+1}$:
22	\[
23		\fun([1], \fun([1]^n, \mathcal{C})) \cong \fun([1] \times [1]^n, \mathcal{C}) \cong \fun([1]^{n+1}, \mathcal{C}).
24	\]
25	
26	An $n$-cube $Q \colon [1]^n \cong \ps(S) \to \mathcal{C}$ is \emph{cartesian} if it is a limit diagram.
27	Another way to say this is that $Q$ is cartesian if and only if it is right Kan extended from its restriction to the punctured cube $[1]^n \setmin 0 \cong \ps(S) \setmin \{ \varnothing \}$ (i.e.\ $Q \simeq i_*i^*Q$ where $i$ is in the inclusion of the punctured cube, $i_*$ is right Kan extension, and $i^*$ restriction).
28	We now recount several basic lemmas about cartesian cubes that we will need below.
29	
30	\begin{lemma}\label{lem retract}
31	Retracts of cartesian $n$-cubes are cartesian.
32	\end{lemma}
33	\begin{proof}
34	This is an instance of a general fact about closure of limit diagrams under retracts; see e.g.\ \cite[\href{https://kerodon.net/tag/05E6}{Tag 05E6}]{kerodon}.
35	\end{proof}
36	
37	The following two well-known lemmas likely first appear in the Goodwillie calculus literature (with $\mathcal{C}$ the $\infty$-category of spaces). 
38	See Proposition~1.6 and Proposition~1.8 of \cite{Goodwillie:CalcII}.
39	In this generality, the next lemma is \cite[Lemma 3.3.8]{Walde:HSSHE}.
40	
41	
42	\begin{lemma}\label{cube lemma 2}
43	Let $P$ and $Q$ be $n$-cubes, and $R \colon P \to Q$ an $(n{+}1)$-cube. 
44	If $Q$ is cartesian, then $P$ is cartesian if and only if $R$ is cartesian.
45	\end{lemma}
46	
47	
48	\begin{lemma}\label{generalized pasting law}
49	Suppose $P$, $Q$, and $R$ are $(n{+}1)$-cubes, which satisfy $R = Q \circ P$ when regarded as maps of $n$-cubes.
50	If $Q$ is cartesian, then $P$ is cartesian if and only if $R$ is cartesian.
51	\end{lemma}
52	This lemma generalizes the usual pasting law for pullbacks when $n=1$.
53	For completeness, we provide a proof in \cref{cube appendix} in the generality of $\mathcal{C}$ an arbitrary $\infty$-category with finite limits.
54	
55	\begin{remark}
56	When $\mathcal{C}$ is a complete and cocomplete $\infty$-category, these lemmas also follow from corresponding results for derivators (Theorem~8.7 and Proposition~8.11 of \cite{GrothStovicek:TTSHS}) applied to the homotopy derivator of $\mathcal{C}$. 
57	When $\mathcal{C}$ is a stable $\infty$-category, stronger statements hold -- see Corollary~A.16 and Corollary~A.18 of \cite{DyckerhoffJassoWalde}.
58	\end{remark}
59	
60	\subsection{Higher Segal conditions after Walde}\label{ss HSC Walde}
61	
62	In Walde's perspective on the higher Segal conditions \cite{Walde:HSSHE}, a simplicial object is lower $(2k{-}1)$-Segal if and only if it maps each strongly bicartesian $(k{+}1)$-dimensional cube in $\ord$ to a cartesian cube.
63	Strongly bicartesian means that each $2$-dimensional face is bicartesian.
64	On the other hand, not all strongly bicartesian cubes need be checked, only the ones with injective edges.
65	This collection of cubes corresponds precisely to intersection cubes associated with gapped subsets, as we now explain. 
66	
67	Given an object $S \in \ordalt$ and proper subset $I \subset S$, the associated \emph{intersection cube} in $\ordalt$ is the functor 
68	\[
69	\intcu{I} = \intcube{I}{S} \colon \ps(I)^\op \to \ordalt
70	\]
71	that sends a subset $J \subseteq I$ to its complement $S\setmin J$ in $S$. 
72	We use the abbreviation $\intcu{I}$ when $S$ is understood. 
73	To illustrate the terminology, note that if we let $S_i = S\setmin i$ for $i\in I$,
74	then the vertices of the cube are the intersections $\intcu{I}_J = \bigcap_{j\in J} S_j$ of the $S_i$, and the edges are the inclusions.
75	The initial vertex of the cube is $\bigcap_{i\in I} S_i = S \setmin I$, and the terminal vertex is $S$.
76	For example, if $I = \{i_0,\dots,i_k\} \subset [n] = S$, then the intersection cubes for $k = 0$ and $1$ are 
77	$[n]$ and $[n] \leftarrow [n]\setmin \{i_0\}$, while the ones for $k = 2$ and $3$ look like
78	\[
79	\begin{tikzcd}
80	{[n]} & {[n]\setmin i_1} \lar\\
81	{[n]\setmin i_0} \uar & {[n]\setmin \{i_0,i_1\}} \uar \lar
82	\end{tikzcd}
83	\,\, \text{and} \quad
84	\begin{tikzcd}[column sep=0.8ex, row sep=0.8ex]
85	{[n]} \ar[from=rr] \ar[from=dd] \ar[from=dr] & & 
86	{[n]\setmin i_2} \ar[from=dd] \ar[from=dr]  \\
87	& {[n]\setmin i_1} \ar[from=rr, crossing over] & & {[n]\setmin\{i_1,i_2\}} \ar[from=dd] \\
88	{[n]\setmin i_0} \ar[from=rr] \ar[from=dr] & & {[n]\setmin\{i_0,i_2\}} \ar[from=dr] \\
89	& {[n]\setmin\{i_0,i_1\}} \ar[from=rr] \ar[uu, crossing over] & & {[n]\setmin\{i_0, i_1,i_2\}}.
90	\end{tikzcd}
91	\]
92	
93	\smallskip
94	If $X \colon \ordalt^\op \to \mathcal{C}$ is a simplicial object, then composing $\intcu{I}$ with $X$ yields a cube
95	\[
96	X\intcu{I} = X\intcube{I}{S} \colon \ps(I) \to \mathcal{C}
97	\]
98	in $\mathcal{C}$ whose initial vertex is $X_S$ and whose terminal vertex is $X_{S \setmin I}$. 
99	In the special case where $S = [n]$ and $I$ has cardinality $k+1$, these amount to $X_S = X_n$ and $X_{S \setmin I} = X_{n-k-1}$. 
100	
101	\smallskip
102	A subset $I \subseteq S$ is \emph{gapped} if for each pair of elements $i < i'$ in $I$, there is $j \in S$ such that $i < j < i'$. 
103	If $S = [n]$, this just means that each pair of distinct elements of $I$ are at distance at least two from one another. 
104	We use the notation $i \ll i'$ if there exists such a gap $j$ between $i$ and $i'$, so that a gapped subset can be written as a sequence
105	\[
106	i_0 \ll i_1 \ll i_2 \ll \cdots \ll i_k
107	\]
108	where $k+1$ is the cardinality of $I$.
109	As an example, if $I$ is the gapped subset $0 \ll i \ll n$ of $[n]$, then 
110	\[
111	  \begin{tikzcd}[row sep=small]
112	    X_n \ar[rr,"d_n"] \ar[dd,"d_0"'] \ar[dr,"d_i"'] & & 
113	    X_{n-1} \ar[dd, "d_0"' very near start] \ar[dr,"d_i"]  \\
114	    & X_{n-1} \ar[rr,"d_{n-1}" near end, crossing over] & & X_{n-2} \ar[dd,"d_0"] \\
115	    X_{n-1} \ar[rr,"d_{n-1}" near start] \ar[dr,"d_{i-1}"'] & & X_{n-2} \ar[dr,"d_{i-1}" near start] \\
116	    & X_{n-2} \ar[rr,"d_{n-2}"] \ar[from=uu, crossing over, "d_0" very near start] & & X_{n-3}.
117	  \end{tikzcd}
118	\]
119	is the corresponding 3-dimensional cube $X\cube{I}$.
120	\begin{definition}\label{def lower odd Segal}
121	Let $k$ be a positive integer.
122	A simplicial object $X$ is \emph{lower $(2k{-}1)$-Segal} if for every $n \in \mathbb{N}$ and every gapped set $I \subset [n]$ of cardinality $k+1$, the associated cube $X\cube{I}\colon \ps(I) \to \mathcal{C}$ is cartesian.
123	\end{definition}
124	
125	These conditions generalize the usual Segal condition. 
126	Indeed, the lower 1-Segal condition coincides with the Segal condition (see e.g.\ \cite[\S1]{Walde:HSSHE} or \cite[Ex.~3.9]{Dyckerhoff:CPOC}), and if $X$ is lower $(2k{-}1)$-Segal, it is also lower $(2k{+}1)$-Segal (\cref{prop hierarchy}).
127	
128	\begin{remark}\label{rmk walde lower segal}
129	\Cref{def lower odd Segal} is a distillation of the main theorem of \cite{Walde:HSSHE}. 
130	Specifically, it is a combination of Corollary 4.1.5, Theorem 6.1.1, and Theorem 7.2.2 of \cite{Walde:HSSHE}, along with an unraveling of a compatible (Definition 4.1.1) and primitive (Definition 4.3.1) claw whose constituent maps are injective.
131	\end{remark}
132	
133	Each lower $(2k{-}1)$-Segal condition is a one-parameter family of conditions on $X$ involving gapped subsets of $[n]$ for each $n \geq 0$.
134	Observe however, that there are no gapped subsets $I$ of $[n]$ of cardinality $k+1$ if $n < 2k$;
135	the first nonvacuous condition involves the gapped sequence $0 \ll 2 \ll \cdots \ll 2k$ in $[2k]$. 
136	
137	\begin{example}
138	If $X$ is the nerve of a category, then the first lower $1$-Segal condition ($k = 1$, $n = 2$) says that 
139	a $2$-simplex amounts to a pair $(f,g)$ of morphisms agreeing target to source, which is of course the case. 
140	The first of the lower $3$-Segal conditions ($k = 2$, $n = 4$) says a $4$-simplex amounts to a 
141	triple of $3$-simplices $[f|g|h]$, $[g|h|k]$, and $[f|h \circ g|k]$, again the case.
142	\end{example}
143	
144	\begin{remark}\label{exercise sset}
145	Using a cofinality argument, the lower $(2k{-}1)$-Segal condition for a simplicial set $X$ can be reformulated as follows:
146	for every gapped set $I \subset [n]$ of cardinality $k+1$ and every list of $(n{-}1)$ simplices $(x_i) \in \prod_I X_{n-1}$ satisfying $d_i x_j = d_{j-1} x_i$ for $i < j$ in $I$, there exists a unique $x\in X_n$ such that $d_i x = x_i$ for all $i\in I$.
147	\end{remark}
148	
149	The following is a variant on similar results for pullback squares, e.g. \cite[Lemma 3.10]{GKT1}. 
150	It reduces further the number of cubes one needs to check for lower $(2k{-}1)$-Segality. 
151	
152	\begin{lemma}\label{segality top bottom}
153	Let $k$ be a positive integer and $X$ a simplicial object.
154	Assume that for each $n \in \mathbb{N}$ and each gapped subset $I \subset [n]$ of cardinality $k+1$ containing both $0$ and $n$, the cube $X\cube{I}$ is cartesian.
155	Then $X$ is lower $(2k{-}1)$-Segal.
156	\end{lemma}
157	\begin{proof}
158	By the cowidth of a subset $I \subset S \in \ordalt$ we mean the cardinality of the set $\{s \in S \mid s < \min(I) \text{ or } s > \max(I)\}$, 
159	so for $S = [n]$ we are in the hypotheses of the lemma just when the cowidth is $0$. 
160	Assume that for each $S' \in \ordalt$ and each gapped subset $I' \subset S'$ of cardinality $k+1$ and cowidth $0$, the associated cube $X\cube{I'}$ is cartesian. 
161	Fix $S \in \ordalt$ and a gapped subset $I \subset S$ of cardinality $k+1$. 
162	We wish to prove that $X\cube{I}$ is cartesian, and this is by induction first on $|S|$, and then on the cowidth of $I$ in $S$.
163	In the case $|S| = 2k+1$, the unique gapped subset has cowidth $0$ and so the result holds by hypothesis. 
164	
165	Assume now $|S| > 2k+1$. 
166	We may assume that either $\min(S) \notin I$ or $\max(S) \notin I$, say the latter, so that $\max(I) < \max(S)$.
167	Write $m = \max(I)$ and $n = \max(S)$ for short. 
168	A subscript on $I$ or $S$ indicates that the corresponding elements have been removed. 
169	For example, $I_m = I \setmin m$ and $S_{m,n} = S \setmin \{m,n\}$. 
170	We also set $J = I \setmin m \cup n$, which is gapped in both $S_m$ and in $S$. 
171	Observe that since $m < n$ by assumption, $J$ has strictly smaller cowidth in $S$ than $I$ does.
172	
173	Regard $\intcube{I}{S}$ as a map of cubes from $\intcube{I_m}{S_m}$ to $\intcube{I_m}{S}$. 
174	This is the top arrow in the commutative diagram
175	\[
176	\begin{tikzcd}[column sep=large]
177	\intcube{I_m}{S_m} \rar{\intcube{I}{S}} & \intcube{I_m}{S}\\
178	\intcube{I_m}{S_{m,n}} \uar{\intcube{J}{S_m}} \rar{\intcube{I}{S_n}} & \intcube{I_m}{S_n} \uar[swap]{\intcube{J}{S}}.
179	\end{tikzcd}
180	\]
181	By induction, $X\intcube{I}{S_n}$ and $X\intcube{J}{S}$ are cartesian, hence so is their composite by \cref{generalized pasting law}. 
182	By induction, the cube $X\intcube{J}{S_m}$ is cartesian as well. 
183	So by \cref{generalized pasting law} again, $X\intcube{I}{S}$ is cartesian.
184	\end{proof} 
185	
186	We are now ready to introduce the other higher Segal conditions.
187	
188	\begin{definition}[Other higher Segal conditions]\label{def other higher Segal}
189	Let $k$ be a positive integer and $X$ a simplicial object.
190	Consider the collection of gapped subsets $I \subset [n]$ of cardinality $k+1$ and the associated collection of cubes $X\cube{I} \colon \ps(I) \to \mathcal{C}$.
191	We say that $X$ is
192	\begin{enumerate}
193	\item \emph{lower $2k$-Segal} if $X\cube{I}$ is cartesian whenever $0 \notin I$,
194	\item \emph{upper $2k$-Segal} if $X\cube{I}$ is cartesian whenever $n \notin I$, and
195	\item \emph{upper $(2k{+}1)$-Segal} if $X\cube{I}$ is cartesian whenever $0 \notin I$ and $n \notin I$.
196	\end{enumerate}
197	\end{definition}
198	
199	If the definition seems a bit ad hoc, the reason is that all of our definitions are in terms of cartesian cubes, rather than the original geometric definitions (see \cite{poguntke} and \cite[p.\ xv]{DyckerhoffKapranov}) in terms of upper and lower triangulations of cyclic polytopes.
200	Walde proved in \cite{Walde:HSSHE} (see \cref{rmk walde lower segal}) that \cref{def lower odd Segal} is equivalent to the geometric definition of lower $(2k{-}1)$-Segal.
201	Independently, Poguntke proved the characterization in \cref{prop path space criterion} below for the original geometric definitions \cite[Proposition 2.7]{poguntke}.
202	As \cref{prop path space criterion} holds for the conditions defined in \cref{def other higher Segal}, this means that they coincide with the geometric ones.
203	
204	\begin{remark}
205	One could also take $k=0$ in \cref{def lower odd Segal} and \cref{def other higher Segal} to arrive at notions of lower $(-1)$-Segal, lower and upper $0$-Segal, and upper $1$-Segal.
206	The latter three appear in \cite{poguntke}.
207	An adaptation of the proof of \cref{prop symmetric higher Segal} below shows that all four of these conditions coincide for a simplicial object $X \colon \ord^\op \to \mathcal{C}$, and just mean that $X$ is constant \cite[Ex.\ 3.9]{Dyckerhoff:CPOC}.
208	We will not consider this `degree zero' (\cref{def degree}) case any further in this paper, always taking $k > 0$ and not distinguishing between discrete and nondiscrete groupoids.
209	\end{remark}
210	
211	The following is immediate from \cref{def lower odd Segal} and \cref{def other higher Segal}.
212	
213	\begin{lemma}[Opposites]\label{lem opposites}
214	Let $X$ be a simplicial object and $d$ a positive integer.
215	If $d$ is odd, then $X$ is lower or upper $d$-Segal if and only if $X^\op$ is so.
216	If $d$ is even, then $X$ is lower $d$-Segal if and only if $X^\op$ is upper $d$-Segal. \qed
217	\end{lemma}
218	
219	To state the next proposition, we need the \emph{d\'ecalage} functors of Illusie \cite[VI.1]{Illusie:CCD2}
220	\[
221	\ldec, \udec \colon \fun(\ord^\op, \mathcal{C}) \to \fun(\ord^\op, \mathcal{C}),
222	\]
223	which we now define (see also \cite[\S6]{Hackney:DSP}). 
224	There is a functor $\ord \to \ord$ which sends $[n]$ to the ordinal sum $[0] \star [n] = [n+1]$. 
225	Restriction along this functor induces the lower d\'ecalage functor $\ldec \colon \fun(\ord^\op, \mathcal{C}) \to \fun(\ord^\op, \mathcal{C})$.
226	If $X$ is a simplicial object, then $\ldec X$ is obtained from $X$ by deleting $X_0$, setting $\ldec X_n = X_{n+1}$, and deleting the bottom face and degeneracy maps (and renumbering the remaining ones by 1):
227	\[ \begin{tikzcd}
228	X: &  X_0 \rar["s_0" description] & X_1 \lar[shift left=2, "d_0"] \lar[shift right=2, "d_1"']  \rar[shift left=1.5] \rar[shift right=1.5] & X_2 \lar[shift left=3,"d_0"] \lar[shift right=3,"d_2"'] \lar
229	\rar[shift left=3] \rar[shift right=3] \rar &
230	X_3 
231	\lar[shift left=1.5] \lar[shift left=4.5] \lar[shift right=1.5] \lar[shift right=4.5] \cdots \\[+0.25cm]
232	\ldec X: &   & X_1  \rar[shift left=1.5] \rar[shift right=1.5, dotted] & X_2 \lar[shift left=3, dotted, "\color{gray} d_0"] \lar[shift right=3,"d_2"'] \lar
233	\rar[shift left=3] \rar[shift right=3, dotted] \rar &
234	X_3 
235	\lar[shift left=1.5] \lar[shift left=4.5, dotted] \lar[shift right=1.5] \lar[shift right=4.5] \cdots 
236	\end{tikzcd} \]
237	That is, $d_k \colon \ldec X_n \to \ldec X_{n-1}$ is equal to $d_{k+1} \colon X_{n+1} \to X_n$ (and similarly for degeneracies).
238	(In \cite{DyckerhoffKapranov}, $\ldec X$ is called the initial path space $P^\triangleleft X$.)
239	Likewise, there is a functor $\ord \to \ord$ sending $[n]$ to $[n] \star [0] = [n+1]$ and restriction along it induces the upper d\'ecalage functor $\udec \colon \fun(\ord^\op, \mathcal{C}) \to \fun(\ord^\op, \mathcal{C})$.
240	We again have $\udec X_n = X_{n+1}$ for $n\geq 0$, and this time we delete the top face and degeneracy maps (no renumbering of the remaining faces/degeneracies is necessary).
241	
242	\begin{proposition}[Path space criterion \cite{poguntke}]\label{prop path space criterion}
243	Let $X$ be a simplicial object and $k$ a positive integer.
244	\begin{enumerate}
245			\item $X$ is lower $2k$-Segal if and only if $\ldec X$ is lower $(2k{-}1)$-Segal.\label{PSC ldec}
246			\item $X$ is upper $2k$-Segal if and only if $\udec X$ is lower $(2k{-}1)$-Segal.\label{PSC udec}
247	    \item $X$ is upper $(2k{+}1)$-Segal if and only if $\ldec \udec X = \udec \ldec X$ is lower $(2k{-}1)$-Segal.\label{PSC double}
248	\end{enumerate}
249	\end{proposition}
250	Combining the criteria, $X$ is upper $(2k{+}1)$-Segal if and only if $\ldec X$ is upper $2k$-Segal if and only if $\udec X$ is lower $2k$-Segal.
251	These separate conditions are how \eqref{PSC double} is presented in \cite{poguntke,Dyckerhoff:CPOC}.
252	\begin{proof}
253	We prove \eqref{PSC udec}.
254	The natural inclusion $\delta^{n+1} \colon [n] \to [n+1]$ gives a bijection between gapped sets $I\subset [n]$ of cardinality $k+1$ and gapped sets $I' \subset [n+1]$ of cardinality $k+1$ such that $n+1 \notin I'$.
255	Under this correspondence, the cube $(\udec X)\cube{I}$ is equal to the cube $X\cube{\delta^{n+1}I}$, as $(\udec X)_{[n] \setmin J} = X_{[n+1] \setmin J}$ for $J\subseteq I \subset [n]$.
256	This establishes \eqref{PSC udec}.
257	The other statements are proved similarly, replacing $\delta^{n+1}$ by $\delta^0 \colon [n] \to [n+1]$ and $\delta^0 \delta^{n+1} \colon [n] \to [n+2]$.
258	\end{proof}
259	
260	In a sense, the path space criterion tells us that \cref{def lower odd Segal} is the most essential of the higher Segal conditions. 
261	In \cref{prop symmetric higher Segal} we will see that this is even more pronounced for symmetric sets.
262	
263	These higher Segal conditions fit into a hierarchy, due to the following proposition which appears as \cite[Proposition 2.10]{poguntke}; the cases that are not immediate from the definitions are that upper $(2k{-}1)$-Segal implies $2k$-Segal, and that lower or upper $2k$-Segal implies lower $(2k{+}1)$-Segal.
264	
265	\begin{proposition}[Poguntke]\label{prop hierarchy}
266	If $X$ is lower or upper $d$-Segal, then $X$ is both lower $(d{+}1)$-Segal and upper $(d{+}1)$-Segal.
267	\end{proposition}
268	\begin{proof}
269	Throughout $k$ is a positive integer.
270	We first show that if $X$ is lower $2k$-Segal, then $X$ is lower $(2k{+}1)$-Segal.
271	Let $I \subseteq S = [n]$ be a gapped subset of cardinality $k+2$  with $0,n \in I$.
272	By \cref{segality top bottom} it is enough to show that $X\cube{I}$ is cartesian.
273	The set $I_0 = I \setmin 0$ is gapped in both $S_0 = S\setmin 0$ and $S$ and contains the minimal element of neither.
274	By lower $2k$-Segality, the cubes $X\intcube{I_0}{S_0}$ and $X\intcube{I_0}{S}$ are cartesian. 
275	Since $X\cube{I}$ is the map $d_0$ between them, $X\cube{I}$ is cartesian by \cref{cube lemma 2}. 
276	
277	If $X$ is upper $2k$-Segal, then it is lower $(2k{+}1)$-Segal by \cref{lem opposites} and the previous paragraph. 
278	If $X$ is upper $(2k{+}1)$-Segal, then $X$ is both lower and upper $(2k{+}2)$-Segal by the path space criterion and the previous paragraph. 
279	\end{proof}
Read
{
  "file_path": "~/twisted_arrow/spheres.tex"
}
1	%!TEX root = higher_segal_spheres.tex
2	
3	\section{Simplex modulo boundary}
4	In this section we consider, for $n\geq 1$, the simplicial model for the sphere $\Delta^n / \partial \Delta^n$.
5	For which $d$ is this upper and/or lower $d$-Segal?
6	When $n=1$, this circle is the nerve of the partial monoid $\{1,x\}$ (with $xx$ undefined), hence is 2-Segal \cite{BOORS:2SSetsWC}.  
7	It is evidently not lower 1-Segal, and is not constant so is not upper 1-Segal.
8	In general: 
9	
10	\begin{theorem}
11	Let $n > 1$ be an integer.
12	Then $\Delta^n / \partial \Delta^n$ is $2n$-Segal, but not lower $(2n{-}1)$-Segal. It is upper $(2n{-}1)$-Segal if and only if $n$ is odd.
13	\end{theorem}
14	
15	This follows from \cref{ex nice counterexample}, \cref{ex ugly counterexample}, \cref{thm sphere odd case}, and \cref{thm sphere even case}.
16	
17	When talking about simplices in $X=\Delta^n / \partial \Delta^n$ (at $S\in \Delta$), we just regard them as functions $S \to [n]$, though strictly speaking we're identifying all of the nonsurjective, or \emph{trivial}, functions $S \to [n]$ to a single basepoint $\ast \in X(S)$.
18	We'll write $f\simeq g \colon S \to [n]$ to indicate that either $f=g$ or that $f$ and $g$ are both nonsurjective.
19	We'll also call surjective functions \emph{nontrivial}.
20	Notice that if $e_i f_j = e_j f_i$ is surjective, then there exists a unique $F$ such that $e_i F = f_i$ and $e_j F = f_j$ since $\Delta^n$ is lower 1-Segal.
21	
22	\begin{example}\label{ex nice counterexample}
23	Let $F, G \colon [2n] \to [n]$ be given by the formulas $F(t) = \max(0,t-n)$ and $G(t) = \min(t,n)$.
24	The function $F$ restricts to a bijection $[n+1, 2n] \cong [1,n]$ (with other elements sent to 0), and $G$ restricts to the identity on $[0,n-1]$ (with other elements sent to $n$).
25	When $n$ is even let $I$ be the set of odd elements in $[2n]$, and when $n$ is odd let $I$ be the set of even elements in $[2n]$. 
26	% If $n$ is even, set $I = \{1,3,\dots, 2n-1\}$, and if $n$ is odd set $I= \{0,2,\dots, 2n\}$
27	In either case define $f_i \coloneq e_i F$ for $i<n$ and $f_i = e_i G$ for $i > n$ (noting that $n\notin I$).
28	Each $f_i$ is surjective, and this is a compatible collection of nontrivial elements in $X$.
29	Compatibility is clear for $I\cap [0,n]$ and for $I \cap [n,2n]$, and cross terms $e_i f_j$ are trivial when $i$ and $j$ are on opposite sides of $n$ (since $e_j F = \ast$ when $j > n$ and $e_i G = \ast$ when $i < n$).
30	Now if $H\in X_{2n}$ is any element with $e_i H = f_i$ for all $i$, then for each $i < n$ we have $H(n) = f_i(n) = F(n) = 0$, while for each $i > n$ we have $H(n) = f_i(n) = G(n) = n$, an impossibility.
31	This establishes that $\Delta^n / \partial \Delta^n$ is not upper $(2n{-}1)$-Segal when $n$ is even, and $\Delta^n / \partial \Delta^n$ is not lower $(2n{-}1)$-Segal when $n$ is odd.
32	\end{example}
33	
34	\begin{example}\label{ex ugly counterexample}
35	Suppose $n$ is even, and let $F, G \colon [2n] \to [n]$ be given by the formulas
36	\begin{align*}
37		F(t) &= \min(\max(0,t-n+1), n) \\
38		G(t) &= \max(t-n, \min(t,n-1)).
39	\end{align*}
40	Expanding, these functions act as follows:
41	% \[
42	% \begin{matrix}
43	% 0 & 1 & \cdots & n-1 & n  & n+1 & \cdots & 2n-2& 2n-1& 2n \\
44	% 0 & 0 & \cdots & 0   & 1  & 2   & \cdots & n-1 & n   & n  \\
45	% 0 & 1 & \cdots & n-1 & n-1 & n-1& \cdots & n-1 & n-1 & n
46	% \end{matrix}
47	% \]
48	\[
49	\begin{array}{l|cccccccccc}
50	  t & 0 & 1 & \cdots & n-1 & n  & n+1 & \cdots & 2n-2& 2n-1& 2n \\
51	\hline
52	F(t) & 0 & 0 & \cdots & 0   & 1  & 2   & \cdots & n-1 & n   & n  \\
53	G(t) & 0 & 1 & \cdots & n-1 & n-1 & n-1& \cdots & n-1 & n-1 & n
54	\end{array}
55	\]
56	Let $I \subset [2n]$ be the set of even elements, $I_F = I \cap [0,n-2] \cup \{2n\}$, and $I_G = I \cap [n,2n-2]$.
57	Set $f_i = e_i F$ for $i\in I_F$ and $f_i = e_i G$ for $i\in I_G$.
58	This is a compatible collection of elements -- we only need to check the cross terms, and these vanish since $e_i G = \ast$ for $i\in I_F$ and $e_i F = \ast$ for $i\in I_G$.
59	If $H \in X_{2n}$ is an element with $e_i H = f_i$ for all $i\in I$, then for $i\in I_F$ we have $H(1) = f_i(1) = F(1) = 0$ and for $i\in I_G$ we have $H(1) = f_i(1) = G(1) = 1$, an impossibility.
60	We conclude that $\Delta^n / \partial \Delta^n$ is not lower $(2n{-}1)$-Segal when $n$ is even.
61	\end{example}
62	
63	% Could consider making this a lemma if we expand.
64	
65	If $I \subset S$ is gapped with more than $\frac{n+2}{2}$ elements and $\{f_i\}_{i\in I}$ consists of trivial elements, then $\ast \in X(S)$ is the unique filler.
66	Indeed, suppose $F \colon S \to [n]$ is surjective. 
67	If $\{i\} = F^{-1}F(i)$ for all $i \in I$, we also need somewhere outside of $\{F(i) \mid i\in I \} \subseteq [n]$ to send elements \emph{between} the elements of $I$, implying $|I| + (|I|-1) \leq n+1$.
68	
69	\begin{theorem}\label{thm sphere odd case}
70	If $n > 1$ is odd, then $X = \Delta^n / \partial \Delta^n$ is upper $(2n{-}1)$-Segal.
71	\end{theorem}
72	\begin{proof}
73	Let $I$ be the set of odd elements in $[2n]$ and for a fixed $p\geq 2n$ declare $S = [p]$. 
74	Let $\{f_i\}_{i\in I}$ be a compatible collection of $(p-1)$-simplices in $X = \Delta^n / \partial \Delta^n$ (i.e.\ $f_i \in X(S_i)$ with $e_i f_j \simeq e_j f_i$ for $i\neq j$ in $I$).
75	
76	Define the following relation on $I$: we say $i\sim j$ if $e_i f_j$ is nontrivial, which implies $e_i f_j = e_j f_i$.
77	As $\Delta^n$ is a category (and hence lower 1-Segal), $i\sim j$ implies there exists a unique $F$ such that $e_i F = f_i$ and $e_j F = f_j$.
78	Let's check that $\sim$ is transitive, and to that end suppose also $j\sim k$ and let $G$ be the element with $e_j G = f_j$ and $e_k G = f_k$.
79	By compatibility we either have $e_i f_k = e_k f_i$ or we have $e_i f_k$ is trivial.
80	If $e_i f_k$ is trivial, then $f_k(i)$ is only hit once by $f_k$.
81	This means $f_k(i\pm 1) = f_k(i)\pm 1$ by surjectivity, and the fact that $i\pm 1 \notin I$, so in particular is different from $k$.
82	But $f_k(i\pm 1) = G(i\pm 1) = f_j(i\pm 1) = F(i\pm 1) = f_i(i\pm 1)$.
83	This implies that $f_k(i)$ is not in the image of $f_i$, contrary to our assumption that $f_i$ is nontrivial.
84	Now each equivalence class $E$ of $I$ having more than one element will have a unique $F$ such that $e_i F = f_i$ for all $i\in E$ (since $\Delta^n$ is lower 1-Segal, and hence lower $(|E|-1)$-Segal).
85	
86	
87	
88	Suppose $i\in I$ is such that $f_i$ is nontrivial. We'd like to know how large its equivalence class $E$ is.
89	Define the following sets:
90	\begin{align*}
91	J &= \{ j \in I \mid e_j f_i = \ast\} \\
92	K &= \{ k \in I \mid e_k f_i \text{ surjective}\},
93	\end{align*}
94	which satisfy $I = \{i\} \amalg J \amalg K$ and $E = K \amalg \{i\}$.
95	
96	Notice for $j\in J$ that $f_i(j-1) < f_i(j) < f_i(j+1)$, and hence $f_i(j+1) - f_i(j-1) = 2$. 
97	Now
98	\[
99		2|J| = \sum_{j\in J} f_i(j+1) - f_i(j-1) \leq \sum_{t \in I} f_i(t+1) - f_i(t-1) = f_i(2n) - f_i(0) \leq n.
100	\]
101	Thus $|J| \leq \frac{n}{2}$.
102	Since $n$ is odd and $E\amalg J = I$ has $n$ elements, $E$ has at least $(n+1)/2$ elements.
103	Since $E$ contains more than half of the elements of $I$, there cannot be any other equivalence class containing an $i$ with $f_i$ nontrivial.
104	By the preceding paragraph we know there is a unique $F$ such that $e_i F = f_i$ for all $i\in E$.
105	
106	It just remains to show that $e_j F$ is trivial for all $j\in J$ (since we know that $f_j$ is trivial), but this is about $e_j F(j\pm 1) = f_i(j\pm 1) = (e_j f_i)(j\pm 1)$ being two apart.
107	Thus we have established $\uppod_p^{n-1}$.
108	\end{proof}
109	
110	In particular, when $n$ is odd then $\Delta^n / \partial \Delta^n$ is $2n$-Segal.
111	
112	\begin{theorem}\label{thm sphere even case}
113	If $n > 1$ is even, then $X = \Delta^n / \partial \Delta^n$ is $2n$-Segal.
114	\end{theorem}
115	\begin{proof}
116	Since $X \cong X^\op$, it suffices to show that $X$ is lower $2n$-Segal.
117	Let $I \subset [2n+1]$ be the set of odd elements (an $n+1$ element set), considered as a gapped subset of $S = [p]$ for a fixed $p \geq 2n+1$.
118	Let $\{f_i \in X(S_i)\}_{i\in I}$ be a compatible collection of $(p-1)$-simplices.
119	
120	The argument proceeds as in the proof of \cref{thm sphere odd case}.
121	We again define a relation $\sim$ on $I$, which is again transitive.
122	The proof of this works even when $p = 2n+1$ if we assume $i < k$, which is fine since $e_if_k \simeq e_k f_i$.
123	
124	We define $J$ and $K$ in an identical way, and we wish to show that $|E| \geq \frac{n}{2} + 1$, i.e. that $E$ contains more than half of the elements of the $(n+1)$ element set $I$.
125	This implies that there can be at most one nontrivial equivalence class.
126	If $p > 2n+1$ we obtain the inequality
127	\[
128		2|J| = \sum_{j\in J} f_i(j+1) - f_i(j-1) \leq \sum_{t \in I} f_i(t+1) - f_i(t-1) = f_i(2n+2) - f_i(0) \leq n
129	\]
130	exactly as before, so $|J| \leq \frac{n}{2}$ and hence $|E| \geq \frac{n}{2} + 1$.
131	If $p=2n+1$ is not a member of $J$, then we have (instead summing over $I_p$ the set of odds less than $p$) 
132	\[
133		2|J| = \sum_{j\in J} f_i(j+1) - f_i(j-1) \leq \sum_{t \in I_p} f_i(t+1) - f_i(t-1) = f_i(2n) - f_i(0) \leq n,
134	\]
135	and may again conclude $|E| \geq \frac{n}{2} +1$.
136	Finally, if $p=2n+1$ is a member of $J$, then we compute
137	\[
138		2|J_p| = \sum_{j\in J_p} f_i(j+1) - f_i(j-1) \leq \sum_{t \in I_p} f_i(t+1) - f_i(t-1) = f_i(2n) - f_i(0) = n -1,
139	\]
140	implying $|J_p| \leq \frac{n-1}{2}$, and, since $n$ is even, $|J| \leq \frac{n}{2}$.
141	Thus we again have $|E| \geq \frac{n}{2} + 1$.
142	
143	Since $|E|-1 \geq \frac{n}{2} \geq 1$ and $\Delta^n$ is lower 1-Segal, there exists a unique $F$ such that $e_i F = f_i$ for all $i\in E$.
144	As in the proof of \cref{thm sphere odd case} we see that $e_j F$ is trivial for all $j\in J$, unless $p=2n+1$ and $j=p$.
145	In this last case, since we know $e_p f_i$ is trivial, we have $f_i(2n) = n-1$, but $F(2n) = f_i(2n)$, hence $e_pF$ does not have $n$ in its image, hence is trivial.
146	We conclude that $X$ is lower $2n$-Segal.
147	\end{proof}
148	
149	
150	
151	\section{Simplex boundaries}\label{sec simplex boundaries}
152	
153	\begin{proposition} If $n\geq 0$, then 
154	$\partial \Delta^{n+1}$ is $(n{+}1)$-coskeletal but not $n$-coskeletal.
155	\end{proposition}
156	\begin{proof}
157	It's clear that it's not $n$-coskeletal, as the identity $\partial \Delta^{n+1} \to \partial \Delta^{n+1}$ does not have a filler $\Delta^{n+1} \to \partial \Delta^{n+1}$.
158	% If $n=-1$ then $\partial \Delta^0 = \varnothing$ is trivially $0$-coskeletal. 
159	If $n=0$ then $\partial \Delta^{n+1} = \partial \Delta^1$ is discrete, hence 1-coskeletal. We now assume $n \geq 1$.
160	Suppose $m > n+1$, $S= [m]$, and $f_i \in X(S_i)$ is a compatible collection (ranging over all $i\in S$).
161	There is a unique $F \colon [m] \to [n+1]$ with $e_i F = f_i$ for all $i$, this is using that $\Delta^{n+1}$ is 2-coskeletal since it's a category, and $m > n+1 \geq 2$. If $F$ is surjective, then there exists a $k$ such that $F^{-1}(k)$ has more than one element; if $i \in F^{-1}(k)$, then $e_i F = f_i$ is surjective, contrary to assumption. Thus $F \in (\partial \Delta^{n+1})_m$.
162	\end{proof}
163	
164	% We immediately see for $n\geq 1$ that $\partial \Delta^{n+1}$ is not upper or lower $(n{-}1)$-Segal, as this would imply that it's $n$-coskeletal.
165	
166	\begin{proposition}
167	For $n \geq 1$, $\partial \Delta^{n+1}$ is $(n{+}1)$-Segal but not upper or lower $n$-Segal.
168	\end{proposition}
169	\begin{proof}
170	Suppose $X = \partial \Delta^{n+1}$ is not $(n{+}1)$-critical. 
171	Then for $S = [n+2]$ or $[n+3]$ we can find a compatible collection whose unique filler in $\Delta^{n+1}$ is surjective. 
172	We may assume that $I \subset [n+2]$ is either the set of even elements\footnote{If $n$ is even this set has size $(n/2 + 1) + 1$ and may contain both endpoints, while if $n$ is odd this set has size $(n+1)/2+1$ and misses $n+2$.} or the set of odd elements.\footnote{
173	If $n$ is even this set has size $n/2 +1$ and misses $0,n+2$, while if $n$ is odd this set has size $(n+1)/2+1$ elements and misses $0$ but not $n+2$.}
174	Consider $I$ as a gapped subset of $S$, and let $\{f_i\}_{i\in I}$ be a compatible collection whose unique filler in $\Delta^{n+1}(S)$ is a surjective function $F\colon S \to [n+1]$.
175	If $S = [n+2]$ then there is exactly one $k$ such that $F^{-1}(k)$ contains two elements; by parity, one must be in $I$, which then gives $e_i F = f_i$ surjective, contrary to assumption.
176	For $S = [n+3]$, there are two possibilities for the surjective function $F\colon [n+3] \to [n+1]$.
177	If there is a $k < n+1$ having $F^{-1}(k)$ having at least two elements, then $I \cap F^{-1}(k)$ will be nonempty, so we can argue by parity as before. 
178	If $F^{-1}(n+1)$ has size three, then it will contain the largest element of $I$, and we again do the same thing.
179	We've thus established that $\partial \Delta^{n+1}$ is $(n{+}1)$-critical -- since it's $(n{+}1)$-coskeletal, it is $(n{+}1)$-Segal by the main theorem of \cite{Hackney:CHSC}.
180	
181	To see that $\partial \Delta^{n+1}$ is not upper or lower $n$-Segal, let $F \colon [n+1] \to [n+1]$ be the identity and $I \subset [n+1]$ to be either the set of even elements or the set of odd elements. 
182	Then $\{e_i F\}_{i\in I}$ is an appropriate compatible collection of $n$-simplices in $\partial \Delta^{n+1}$, but its only filler is surjective.
183	(If $n=1$, the argument against upper 1-Segal is simply that $\partial \Delta^2$ is not constant.)
184	\end{proof}
Thinking
$ Bash
sed -n 400,640p decomp.tex
% (Without this assumption, one still obtains a semi-simplicial 2-Segal set.) 
\end{exercise}

\begin{remark}
Each partial monoid may be regarded as a monoid with a zero element, by adjoining a new absorbing element $0$ to $M$ and declaring that all undefined multiplications take $0$ as their value.
Likewise, for any monoid with a zero element different from $1$, we obtain a partial monoid by discarding $0$.
In a similar manner, the $\catpar$-enriched categories from the preceding exercise correspond to categories with (nonidentity) zero morphisms \cite[\S1.7]{Pareigis:CF}.
% (Also note that $\catpar$-enriched categories are a special case of the multivalued categories of \cite[\S3.3]{DyckerhoffKapranov:HSS}.)
\end{remark}

The examples of partial monoids and $\catpar$-enriched categories suggest a useful perspective: simplicial sets that are 2-Segal (or equivalently, discrete decomposition spaces) can be understood as encoding multivalued ``associative'' composition laws.
See \cite[\S3.3]{DyckerhoffKapranov:HSS} and \cite{Stern:BIRS} for precise statements.
The preceding examples cover the case of composition having at most one value, and the single-valued composition laws correspond to the Segal objects (\cref{sec segal spaces}).

We mention, in passing, a class of maps that plays an important role in the theory of decomposition spaces.
These maps do not make a significant appearance in this paper, but reappear elsewhere in this volume \cite{CooperYoung:BIRS,GKT:DSC}.
In particular, \cite{CooperYoung:BIRS} explains why a culf map between decomposition spaces induces a coalgebra homomorphism between the associated incidence coalgebras (originally from \cite[Lemma 8.2]{GKT1}).

\begin{definition}[Culf maps]\label{def culf}
A map $f \colon X \to Y$ between simplicial spaces is \emph{culf} if it is cartesian on active maps.
Concretely, we require that the following squares are pullbacks, for $0 < i < n$ and $0\leq j \leq n$:
\[ \begin{tikzcd}
X_n \rar{d_i} \dar[swap]{f} \ar[dr, phantom, "\lrcorner" very near start]  & X_{n-1} \dar{f} 
& &
X_n \rar{s_j} \dar[swap]{f} \ar[dr, phantom, "\lrcorner" very near start]  & X_{n+1} \dar{f} 
\\
Y_n  \rar[swap]{d_i} & Y_{n-1} 
& &
Y_n  \rar[swap]{s_j} & Y_{n+1}.
\end{tikzcd}
\]
\end{definition}

\section{2-Segal spaces are decomposition spaces}\label{sec 2-Segl decomp}

In this section we discuss the following fundamental result; as mentioned in the introduction, it was known early on that decomposition spaces were the same thing as unital 2-Segal spaces, and later on it was discovered that the unitality condition is automatic \cite{Feller_et_al:E2SSU}.

\begin{theorem}\label{thm unitality} 
A simplicial space $X$ is a decomposition space if and only if it is both upper and lower 2-Segal.
\end{theorem}

It is immediate that every decomposition space is 2-Segal, since the squares in \eqref{eq upper and lower 2-Segal} of \cref{def 2-segal} are active-inert pullback squares.
The converse is more interesting.
If $X$ is a decomposition space, then the following basic squares (for all $0 \leq i \leq n$) come from active-inert pushout squares in $\Delta$, so must be pullbacks:
\[ \begin{tikzcd}
X_{n+1} \rar{s_{i+1}} \dar[swap]{d_\bot} \ar[dr, phantom, "\lrcorner" very near start]  & X_{n+2} \dar{d_\bot} 
& &
X_{n+1} \rar{s_i} \dar[swap]{d_\top} \ar[dr, phantom, "\lrcorner" very near start]  & X_{n+2} \dar{d_\top} 
\\
X_n  \rar[swap]{s_i} & X_{n+1} 
& &
X_n  \rar[swap]{s_i} & X_{n+1}.
\end{tikzcd}
\]
However, the 2-Segal condition makes no mention of any squares involving degeneracies.
The main effort of the proof of \cref{thm unitality} is addressing this issue.
Most proofs in the rest of the paper rely on two basic tools.
Here is the first.

\begin{pastinglaw}
Suppose we have a diagram
\[ \begin{tikzcd}
\bullet \rar \dar & \bullet \rar \dar \ar[dr, phantom, "\lrcorner" very near start] & \bullet \dar \\
\bullet \rar & \bullet \rar & \bullet 
\end{tikzcd} \]
with right square a pullback.
Then the left square is a pullback if and only if the outer (composite) square is a pullback.
\end{pastinglaw}

For a 1-category $C$, such as that of sets, this law is traditionally left as an exercise, but see \cite[Proposition 2.5.9]{Borceux:HCA1} for a proof.
In an $(\infty,1)$-category $C$ (such as that of spaces), this law is sometimes called the \emph{prism lemma}, since the diagram above should be specified by a functor $\Delta^2 \times \Delta^1 \to C$ (see \cite[Lemma 4.4.2.1]{Lurie:HTT} or \cite[\href{https://kerodon.net/tag/03FZ}{Tag 03FZ}]{kerodon}).

As an illustration of the utility of the pasting law, we establish the following characterization of the (upper) 2-Segal condition from \cite[Lemma 3.6]{GKT1}.

\begin{proposition}\label{prop fewer squares}
The following are equivalent for a simplicial space $X$.
\begin{enumerate}
\item The simplicial space $X$ is upper 2-Segal.\label{item fewer upper}
\item For each $n\geq 2$, the left square of \eqref{eq upper and lower 2-Segal} is a pullback for some $0 < i < n$.\label{item fewer some}
\end{enumerate}
\end{proposition}
\begin{proof}
It is immediate that \eqref{item fewer upper} implies \eqref{item fewer some}.
To prove the converse, it is helpful to add a third equivalent condition:
\begin{enumerate}[start=3]
\item For each $n\geq 2$, the square below is a pullback.\label{item fewer composite}
\[ \begin{tikzcd}
X_{n+1} \rar{d_2^{n-1}} \dar[swap]{d_\bot} & X_2 \dar{d_\bot} \\
X_n \rar[swap]{d_1^{n-1}} & X_1
\end{tikzcd} \]
\end{enumerate}
The following diagram is used for the remaining implications:
\[ \begin{tikzcd}
X_{n+2} \rar{d_{i+1}} \dar[swap]{d_\bot} &
X_{n+1} \rar{d_2^{n-1}} \dar[swap]{d_\bot} \ar[dr, phantom, "\lrcorner" very near start] & X_2 \dar{d_\bot}
\\
X_{n+1} \rar[swap]{d_i} & 
X_n \rar[swap]{d_1^{n-1}} & X_1.
\end{tikzcd} \]
To prove that \eqref{item fewer some} implies \eqref{item fewer composite}, we assume inductively that the right square above is a pullback, and that for some $0 < i < n+1$ the left square is a pullback, which implies that the outer rectangle is also a pullback.
But $d_2^{n-1}d_{i+1} = d_2^n$ and $d_1^{n-1}d_i = d_1^n$, so this outer rectangle is the case of \eqref{item fewer composite} in the next level.
To show that \eqref{item fewer composite} implies \eqref{item fewer upper}, let $0 < i < n+1$ be arbitrary. 
Then the outer rectangle and the right square in the diagram are pullbacks, hence so is the left square.
Thus $X$ is upper 2-Segal.
\end{proof}

% A similar result holds for lower 2-Segal spaces using the square
% \[ \begin{tikzcd}
% X_{n+1} \rar{d_1^{n-1}} \dar[swap]{d_\top} & X_2 \dar{d_\top} \\
% X_n \rar[swap]{d_1^{n-1}} & X_1
% \end{tikzcd} \]
% instead. Formally, one can apply \cref{prop fewer squares} to $X^\op$.


\begin{lemma}\label{lem higher degen}
Suppose $X$ is an upper 2-Segal space.
If $n > 0$ and $0\leq i \leq n$, then the square
\[ \begin{tikzcd}
X_{n+1} \rar{s_{i+1}} \dar[swap]{d_\bot} \ar[dr, phantom, "\lrcorner" very near start]  & X_{n+2} \dar{d_\bot} \\
X_n  \rar[swap]{s_i} & X_{n+1}
\end{tikzcd} %\qquad
% \left(
% \text{resp.\ } 
% \begin{tikzcd}
% X_{n+1} \rar{s_i} \dar[swap]{d_\top} \ar[dr, phantom, "\lrcorner" very near start]  & X_{n+2} \dar{d_\top} \\
% X_n  \rar[swap]{s_i} & X_{n+1}
% \end{tikzcd}
% \right)
\]
is a pullback.
\end{lemma}
\begin{proof}
This proof is an application of the pasting law.
We can choose $j \in \{i,i+1 \}$ with $0 < j < n+1$, and then we have the following diagram:
\[
\begin{tikzcd}
X_{n+1} \ar[rr,bend left, "\id"'] \rar{s_{i+1}} \dar[swap]{d_\bot} & X_{n+2} \dar[swap]{d_\bot} \ar[dr, phantom, "\lrcorner" very near start] \rar{d_{j+1}} & X_{n+1} \dar{d_\bot} \\
X_n  \rar[swap]{s_i} \ar[rr, bend right, "\id"] & X_{n+1} \rar[swap]{d_j} & X_n.
\end{tikzcd}
\]
The right square is a pullback since $X$ is upper 2-Segal, and the outer square is a pullback.
Hence the left square is a pullback.
\end{proof}

Unfortunately, the proof of the lemma does not cover the $n=0$ case, for which we need our second basic tool.

\begin{retrstab}
Retracts of pullbacks are pullbacks.
\end{retrstab}
Being a pullback is a property of an object of $\fun(\Delta^1 \times \Delta^1, C)$, the category of commutative squares in $C$, and this property is stable under retracts.\phnote{May be confusing if not working in $\infty$-categories.}
See \cite[Appendix A]{Feller_et_al:E2SSU} for homotopy pullbacks in model categories; for quasi-categories use the duals of \cite[Lemma 5.1.6.3]{Lurie:HTT} or \cite[\href{https://kerodon.net/tag/05E6}{Tag 05E6}]{kerodon}.
The following is proved in \cite{Feller_et_al:E2SSU}.

\begin{lemma}\label{lem bot degen}
If $X$ is an upper 2-Segal space, then the square
\[ \begin{tikzcd}
X_1 \rar{s_1} \dar[swap]{d_0} \ar[dr, phantom, "\lrcorner" very near start]  & X_2 \dar{d_0} \\
X_0  \rar[swap]{s_0} & X_1
\end{tikzcd} 
\]
is a pullback.
\end{lemma}
\begin{proof}
The indicated square is a retract of 
\[
\begin{tikzcd}
X_2 \rar{s_2} \dar[swap]{d_\bot} \ar[dr, phantom, "\lrcorner" very near start]  & X_3 \dar{d_\bot} \\
X_1  \rar[swap]{s_1} & X_2
\end{tikzcd} 
\]
which is known to be a pullback by \cref{lem higher degen}.
This property is witnessed by the maps of squares
\[
\setlength\arraycolsep{1pt}
S = \,
\begin{matrix}
s_1 & \vline & s_1 \\
\hline
s_0 & \vline & s_0
\end{matrix}
\qquad
\text{and}
\qquad
D = 
\, \begin{matrix}
d_1 & \vline & d_1 \\
\hline
d_0 & \vline & d_0
\end{matrix}
\]
with $DS = \id$.
More explicitly, maps between squares are cubes, and the diagram
  \[
  \begin{tikzcd}[sep={30pt,between origins}]
      {X_1} \ar[rrr, "s_1"] \ar[dd, "d_0"] \ar[dr, "s_1"] & & & 
      {X_2} \ar[rrr, "d_1"] \ar[dd, "d_0"' very near start] \ar[dr, "s_2"] & & & 
      {X_1} \ar[dd, "d_0"' very near start] \ar[dr, "s_1"] & \\ &
      {X_2} \ar[rrr, pos=0.4, "s_1", crossing over]   & & & 
      {X_3} \ar[rrr, pos=0.4, "d_1", crossing over]   & & & 
      {X_2} \ar[dd,"d_0"] \\ 
      {X_0} \ar[rrr, pos=0.64, "s_0"] \ar[dr, "s_0"'] & & & 
      {X_1} \ar[rrr, pos=0.64, "d_0"] \ar[dr, "s_1"'] & & & 
      {X_0} \ar[dr, "s_0"] & \\ &
      {X_1} \ar[rrr, "s_0"] \ar[from=uu, crossing over, "d_0" very near start] & & &  
      {X_2} \ar[rrr, "d_0"] \ar[from=uu, crossing over, "d_0" very near start] & & &  
      {X_1}
  \end{tikzcd}
  \]
is commutative.
\end{proof}

Dually, if $X$ is a lower 2-Segal space then for $n\geq 0$ and $0\leq i \leq n$, the square 
\[
\begin{tikzcd}
X_{n+1} \rar{s_i} \dar[swap]{d_\top} \ar[dr, phantom, "\lrcorner" very near start]  & X_{n+2} \dar{d_\top} \\
X_n  \rar[swap]{s_i} & X_{n+1}
\end{tikzcd}
\]
is a pullback: apply \cref{lem higher degen} and \cref{lem bot degen} to $X^\op$.
To prove \cref{thm unitality}, one can now follow \cite[3.4]{GKT1}, or reason about the situation directly as follows.

\begin{proof}[Proof sketch for \cref{thm unitality}]
First consider active-inert pushout squares
\[ \begin{tikzcd}
{[n]} \rar[-act, "\alpha"] \dar[tail, "\delta^k"'] \ar[dr, phantom, "\ulcorner" very near end] & {[m]} \dar[tail, "\theta"] \\
{[n+1]} \rar[-act, "\phi"'] & {[m+1]}
\end{tikzcd} \]
where $k$ is either $0$ or $n+1$ (implying $\theta = \delta^\ell$ for $\ell$ either $0$ or $m+1$).
By factoring $\alpha$ into degeneracies and inner faces, we see that 
\begin{equation}\label{diag codim one inert}
\begin{tikzcd}
X_{m+1} \rar{\phi^*} \dar[swap]{d_\ell} 
\ar[dr, phantom, "\lrcorner" very near start]
& X_{n+1} \dar{d_k} 
\\
X_m \rar[swap]{\alpha^*} & X_n
\end{tikzcd}
\end{equation}
is a pullback using the pasting law and our known pullback squares.
Then, for an arbitrary active-inert pushout square as in \eqref{diag ai pushout} of \cref{lem ai pushout}, use induction on $k-n$ along with the squares \eqref{diag codim one inert} and the pasting law. 
\end{proof}
Thinking

I've read instr.md, decomp.tex (esp. §on décalage and §on edgewise subdivision), from_hsd.tex, from_coskel.tex, spheres.tex/higher_segal_spheres.tex. Here's where I've landed plus what I'd want to pin down before digging in.

What I take the target statement to be

Conjecture. For $k \geq 1$: $X$ is $2k$-Segal (upper and lower) $\iff$ $\operatorname{sd} X$ is lower $(2k{-}1)$-Segal. ($k=1$ recovers thm edgewise.)

Two things support your instinct here:

  1. Duality forces it. Since $\operatorname{sd} X = \operatorname{sd}(X^\op)$, any condition of the form "$\operatorname{sd}X$ satisfies $P$" is invariant under $X \mapsto X^\op$, so it can only ever characterize a self-dual condition on $X$. By lem opposites, the self-dual conditions are lower/upper $(2k{\pm}1)$-Segal and "upper and lower $2k$-Segal". So a one-sided $d$-Segal criterion via $\operatorname{sd}$ alone is impossible, and the even case is the natural candidate — exactly your reasoning about $\operatorname{sd}$ containing both décalages.

  2. A gappedness count that comes out right. With $Z = \operatorname{sd}X$, $Z_n = X_{2n+1}$ and $d_i^Z = d_{n-i}d_{n+i+1}$, a gapped $I \subset [n]$ of cardinality $k+1$ gives the "doubled" set $\tilde I = {n-i,\, n+i+1 : i \in I} \subset [2n+1]$, and $Z\llbracket I\rrbracket$ is the diagonal of $X\llbracket \tilde I \rrbracket$ — i.e. a composite of $(k{+}1)$-cubes indexed by the choices $\varepsilon_i \in {n-i, n+i+1}$. I checked: $\tilde I$ itself is not gapped when $0 \in I$ (the pair $n, n{+}1$ is adjacent), but every section ${\varepsilon_i}$ is gapped in $[2n+1]$ — the cross-distance is $i+j+1 \geq 2$ whenever $i \neq j$. Moreover such a section contains $0$ or $2n{+}1$ only when $n \in I$, and never both. So the generalized pasting law (generalized pasting law, from_hsd) should give the forward direction from upper + lower $2k$-Segality and nothing more — precisely mirroring how lem decomp implies sd Segal uses an active–inert square rather than a bare gapped one. The converse should be the cube version of lem ldec square as retract ($Y = \ldec X$ cube a retract of a $Z$ cube via $s_\bot^n$ / $d_0d_2^\bullet$), then prop path space criterion (PSC ldec) + the $X^\op$ trick.

So my working guess is that it's true and that both directions are adaptations rather than new ideas — with the real work in the forward direction being bookkeeping about which intermediate $S' \subsetneq [2n+1]$ the pasting steps live over (deleting elements can create adjacencies, though the ones I spot-checked are protected by gappedness of $I$).

Questions

  1. Setting. Simplicial objects in an $\infty$-category with finite limits (as in from_hsd.tex), or simplicial sets? I'd default to the general setting since the retract/pasting lemmas are already stated there.

  2. Conventions. from_coskel.tex ($X(S)$, $e_i$, $\llbracket I \subset S\rrbracket$ covariant on $\mathcal P(I)$) vs from_hsd.tex (intersection cubes on $\mathcal P(I)^\op$). Which do you want the writeup in? I lean from_coskel since it's the most recent.

  3. Odd case. Do you want me to also chase the other self-dual family — is there a $\operatorname{sd}$-criterion for upper $(2k{+}1)$-Segal? The obvious guess "$\operatorname{sd}X$ lower $2k$-Segal" is immediately suspect (not self-dual as a condition on $Z$... though it is when combined with upper), so maybe "$\operatorname{sd} X$ is $2k$-Segal". Worth a look or a distraction?

  4. Iterated subdivision. Any interest in $\operatorname{sd}_r$ ($[n] \mapsto$ $r$-fold analogue), which might shift $d$ by more than one step? Or strictly the classical $\operatorname{sd}$?

  5. Deliverable + method. Do you want (a) a short sketch/verdict first, (b) a full LaTeX note with proofs, or (c) me to try to break it computationally first (finite simplicial sets like $\Delta^n/\partial\Delta^n$, $\partial\Delta^{n+1}$, where your coskeletality theorem makes $d$-Segality a finite check)? I'd suggest a quick computational sanity check on $k=2$ against a known non-$4$-Segal example before writing anything up.

  6. Literature. Should I look up BOORS ESC and Poguntke directly (web), or do you want me working only from these files?

Setting is the general one, not just simplicial sets (though if there is a counterexample I'd be looking at simplicial sets). I thought the conventions in from_coskel and from_hsd were pretty much the same, so do whatever makes sense.

Odd case would be interesting -- for instance if something happened with upper 3-Segal even would be cool to know! I don't have any feel for this, haven't tried any examples.

I doubt iterated subdivision would tell us anything, since the Path Space Criterion doesn't really descend past "lower (2k-1)-Segal" (the most essential of the higher Segal conditions with k+1 dimensional cubes)

I don't want a full latex note with proofs to start. If you see a path forward on a proof, you could try to flesh that out to see if it works, or if you see a possible example to test computationally you could do that. (I am not sure what the subdivision of \partial \Delta^{n+1} or \Delta^n/\partial\Delta^n look like, but I guess we have formulas for them...)

For literature, I'd probably just work with what is given. I can also give you copies of the BOORS paper or the Poguntke paper, but I think that what's in decomp.tex is far simpler than the proof BOORS give, and I think the description of HSC in terms of cubes is simpler than what Poguntke does.

Feel free to take notes if you like, or write code, and you're welcome to add things to git that might be useful artifacts.

Thinking

Good — let me start with the computational side, since it can kill or support both conjectures fast, and the sphere examples give me known ground truth.

📝 Write segal.py
/tmp/scratchpad/segal.py
"""Higher Segal conditions for finite simplicial sets, and edgewise subdivision.

Conventions follow from_coskel.tex / from_hsd.tex:
  * gapped I subset [m]: proper subset, no two adjacent elements of [m].
  * for |I| = k+1, X is
      lower  (2k-1)-Segal : all gapped I
      lower  2k    -Segal : 0 notin I
      upper  2k    -Segal : m notin I
      upper  (2k+1)-Segal : 0, m notin I
  * cartesianness of X[[I]] for a simplicial SET: for every compatible family
    (f_i)_{i in I}, f_i in X_{m-1}, with  d_i f_j = d_{j-1} f_i  (i<j in I),
    there is a unique F in X_m with d_i F = f_i for all i in I.
"""

from itertools import product, combinations
from collections import defaultdict

STAR = "*"


class SimplicialSet:
    """Interface: elements(m) -> list, face(x, i, m) -> element of dim m-1."""

    def elements(self, m):
        raise NotImplementedError

    def face(self, x, i, m):
        raise NotImplementedError


class Sphere(SimplicialSet):
    """Delta^n / boundary Delta^n.  An m-simplex is a map [m] -> [n],
    all non-surjective ones identified to the basepoint STAR."""

    def __init__(self, n):
        self.n = n
        self._full = frozenset(range(n + 1))

    def _norm(self, t):
        return t if frozenset(t) == self._full else STAR

    def elements(self, m):
        out = [STAR]
        for t in product(range(self.n + 1), repeat=m + 1):
            if frozenset(t) == self._full:
                out.append(t)
        return out

    def face(self, x, i, m):
        if x is STAR:
            return STAR
        return self._norm(x[:i] + x[i + 1:])


class SimplexBoundary(SimplicialSet):
    """boundary Delta^N: m-simplices are NON-surjective maps [m] -> [N]."""

    def __init__(self, N):
        self.N = N
        self._full = frozenset(range(N + 1))

    def elements(self, m):
        return [t for t in product(range(self.N + 1), repeat=m + 1)
                if frozenset(t) != self._full]

    def face(self, x, i, m):
        return x[:i] + x[i + 1:]


class Edgewise(SimplicialSet):
    """sd X:  (sd X)_m = X_{2m+1},  d_i = d_{m-i} d_{m+i+1}."""

    def __init__(self, X):
        self.X = X

    def elements(self, m):
        return self.X.elements(2 * m + 1)

    def face(self, x, i, m):
        y = self.X.face(x, m + i + 1, 2 * m + 1)   # delete larger index first
        return self.X.face(y, m - i, 2 * m)


class Opposite(SimplicialSet):
    def __init__(self, X):
        self.X = X

    def elements(self, m):
        return self.X.elements(m)

    def face(self, x, i, m):
        return self.X.face(x, m - i, m)


def gapped_subsets(m, size):
    """gapped subsets of [m] of given cardinality (proper, no two adjacent)."""
    return [I for I in combinations(range(m + 1), size)
            if all(I[t + 1] - I[t] >= 2 for t in range(len(I) - 1))]


def is_cartesian(X, m, I):
    """Is X[[I]] cartesian, for I gapped in [m]?  Returns (ok, witness)."""
    I = sorted(I)
    lower = X.elements(m - 1)
    top = X.elements(m)

    # map each F in X_m to its family, check injectivity
    fam_of = {}
    for F in top:
        fam = tuple(X.face(F, i, m) for i in I)
        if fam in fam_of:
            return False, ("non-unique", fam, fam_of[fam], F)
        fam_of[fam] = F

    # index X_{m-1} by the value of each face map we will need
    index = {}
    for j_pos, j in enumerate(I):
        for i in I:
            if i < j:
                key = (j, i)          # want d_i f_j
                d = defaultdict(list)
                for f in lower:
                    d[X.face(f, i, m - 1)].append(f)
                index[key] = d

    # backtracking over I in order
    results = []

    def rec(pos, chosen):
        if pos == len(I):
            results.append(tuple(chosen))
            return True  # (we only need existence of a bad family; see below)
        j = I[pos]
        if pos == 0:
            cands = lower
        else:
            # constraints: for each earlier i, d_i f_j = d_{j-1} f_i
            cands = None
            for t in range(pos):
                i = I[t]
                want = X.face(chosen[t], j - 1, m - 1)
                c = index[(j, i)].get(want, [])
                if cands is None or len(c) < len(cands):
                    cands = c
            if cands is None:
                cands = lower
        for f in cands:
            ok = True
            for t in range(pos):
                i = I[t]
                if X.face(f, i, m - 1) != X.face(chosen[t], j - 1, m - 1):
                    ok = False
                    break
            if not ok:
                continue
            chosen.append(f)
            bad = rec(pos + 1, chosen)
            chosen.pop()
            if bad:
                return True
        return False

    # rewrite rec to *search for an unfilled family* rather than collect all
    def rec2(pos, chosen):
        if pos == len(I):
            fam = tuple(chosen)
            if fam not in fam_of:
                return fam
            return None
        j = I[pos]
        if pos == 0:
            cands = lower
        else:
            cands = None
            for t in range(pos):
                i = I[t]
                want = X.face(chosen[t], j - 1, m - 1)
                c = index[(j, i)].get(want, [])
                if cands is None or len(c) < len(cands):
                    cands = c
            if cands is None:
                cands = lower
        for f in cands:
            good = True
            for t in range(pos):
                i = I[t]
                if X.face(f, i, m - 1) != X.face(chosen[t], j - 1, m - 1):
                    good = False
                    break
            if not good:
                continue
            chosen.append(f)
            r = rec2(pos + 1, chosen)
            chosen.pop()
            if r is not None:
                return r
        return None

    bad = rec2(0, [])
    if bad is not None:
        return False, ("no-filler", bad)
    return True, None


CONDITIONS = {
    # name : predicate on (I, m)
    "lower_odd":  lambda I, m: True,                       # lower (2k-1)-Segal
    "lower_even": lambda I, m: 0 not in I,                 # lower 2k-Segal
    "upper_even": lambda I, m: m not in I,                 # upper 2k-Segal
    "upper_odd":  lambda I, m: 0 not in I and m not in I,  # upper (2k+1)-Segal
}


def check(X, k, cond, mrange, verbose=True, label=""):
    """Check condition `cond` with cube dimension k+1 in simplicial dims mrange."""
    allok = True
    for m in mrange:
        for I in gapped_subsets(m, k + 1):
            if not CONDITIONS[cond](I, m):
                continue
            ok, w = is_cartesian(X, m, I)
            if verbose:
                print(f"    {label} k={k} {cond} m={m} I={I}: "
                      f"{'OK' if ok else 'FAIL ' + str(w)[:120]}")
            if not ok:
                allok = False
    return allok
File created successfully at: /tmp/scratchpad/segal.py (file state is current in your context — no need to Read it back)
Thinking
$ Bash
cd /tmp/scratchpad && cat > t1.py <<'EOF'
from segal import *
# sanity: X = Delta^1/bdry = circle. Known: 2-Segal, not lower/upper 1-Segal.
X = Sphere(1)
print("circle lower_odd k=1 (Segal), expect FAIL:")
check(X,1,"lower_odd",[2,3],label="S1")
print("circle lower_even k=1 (lower 2-Segal), expect OK:")
check(X,1,"lower_even",[3,4],label="S1")
print("circle upper_even k=1, expect OK:")
check(X,1,"upper_even",[3,4],label="S1")
EOF
python3 t1.py
circle lower_odd k=1 (Segal), expect FAIL:
    S1 k=1 lower_odd m=2 I=(0, 2): FAIL ('no-filler', ((0, 1), (0, 1)))
    S1 k=1 lower_odd m=3 I=(0, 2): FAIL ('no-filler', ((0, 1, 0), (0, 1, 1)))
    S1 k=1 lower_odd m=3 I=(0, 3): FAIL ('no-filler', ((0, 0, 1), (0, 1, 1)))
    S1 k=1 lower_odd m=3 I=(1, 3): FAIL ('no-filler', ((0, 0, 1), (1, 0, 1)))
circle lower_even k=1 (lower 2-Segal), expect OK:
    S1 k=1 lower_even m=3 I=(1, 3): FAIL ('no-filler', ((0, 0, 1), (1, 0, 1)))
    S1 k=1 lower_even m=4 I=(1, 3): FAIL ('no-filler', ((0, 0, 1, 0), (1, 0, 1, 1)))
    S1 k=1 lower_even m=4 I=(1, 4): FAIL ('no-filler', ((0, 0, 0, 1), (1, 0, 1, 1)))
    S1 k=1 lower_even m=4 I=(2, 4): FAIL ('no-filler', ((0, 0, 0, 1), (1, 1, 0, 1)))
circle upper_even k=1, expect OK:
    S1 k=1 upper_even m=3 I=(0, 2): FAIL ('no-filler', ((0, 1, 0), (0, 1, 1)))
    S1 k=1 upper_even m=4 I=(0, 2): FAIL ('no-filler', ((0, 1, 0, 0), (0, 1, 1, 1)))
    S1 k=1 upper_even m=4 I=(0, 3): FAIL ('no-filler', ((0, 0, 1, 0), (0, 1, 1, 1)))
    S1 k=1 upper_even m=4 I=(1, 3): FAIL ('no-filler', ((0, 0, 1, 0), (1, 0, 1, 1)))
Shell cwd was reset to ~/twisted_arrow
Thinking

Bug in my model — simplices of $\Delta^n$ are order-preserving maps. Fixing:

$ Bash
cd /tmp/scratchpad && python3 - <<'EOF'
import re
s = open('segal.py').read()
s = s.replace('''    def elements(self, m):
        out = [STAR]
        for t in product(range(self.n + 1), repeat=m + 1):
            if frozenset(t) == self._full:
                out.append(t)
        return out''','''    def elements(self, m):
        out = [STAR]
        for t in monotone(m + 1, self.n):
            if frozenset(t) == self._full:
                out.append(t)
        return out''')
s = s.replace('''    def elements(self, m):
        return [t for t in product(range(self.N + 1), repeat=m + 1)
                if frozenset(t) != self._full]''','''    def elements(self, m):
        return [t for t in monotone(m + 1, self.N)
                if frozenset(t) != self._full]''')
s = s.replace('''STAR = "*"''','''STAR = "*"


def monotone(length, n):
    """all nondecreasing tuples of given length with values in [0,n]."""
    if length == 0:
        yield ()
        return
    def rec(prefix, lo):
        if len(prefix) == length:
            yield tuple(prefix)
            return
        for v in range(lo, n + 1):
            yield from rec(prefix + [v], v)
    yield from rec([], 0)''')
# drop the dead first `rec`
i = s.index('    # backtracking over I in order')
j = s.index('    # rewrite rec to *search for an unfilled family* rather than collect all')
s = s[:i] + s[j:]
s = s.replace('''    # rewrite rec to *search for an unfilled family* rather than collect all
    def rec2''','''    # search for a compatible family with no filler
    def rec2''')
open('segal.py','w').write(s)
EOF
cd /tmp/scratchpad && python3 t1.py
circle lower_odd k=1 (Segal), expect FAIL:
    S1 k=1 lower_odd m=2 I=(0, 2): FAIL ('no-filler', ((0, 1), (0, 1)))
    S1 k=1 lower_odd m=3 I=(0, 2): OK
    S1 k=1 lower_odd m=3 I=(0, 3): FAIL ('no-filler', ((0, 0, 1), (0, 1, 1)))
    S1 k=1 lower_odd m=3 I=(1, 3): OK
circle lower_even k=1 (lower 2-Segal), expect OK:
    S1 k=1 lower_even m=3 I=(1, 3): OK
    S1 k=1 lower_even m=4 I=(1, 3): OK
    S1 k=1 lower_even m=4 I=(1, 4): OK
    S1 k=1 lower_even m=4 I=(2, 4): OK
circle upper_even k=1, expect OK:
    S1 k=1 upper_even m=3 I=(0, 2): OK
    S1 k=1 upper_even m=4 I=(0, 2): OK
    S1 k=1 upper_even m=4 I=(0, 3): OK
    S1 k=1 upper_even m=4 I=(1, 3): OK
Shell cwd was reset to ~/twisted_arrow
Thinking

Sanity check passes now. Testing the $d=2$ case of the criterion, then $k=2$:

$ Bash
cd /tmp/scratchpad && cat > t2.py <<'EOF'
from segal import *
import time
# sd(circle) should be Segal (= lower 1-Segal, k=1)
Z = Edgewise(Sphere(1))
print("sd(S^1) lower_odd k=1 (Segal), expect OK:")
print(" ->", check(Z,1,"lower_odd",[2,3],label="sdS1"))

# X = Delta^2/bdry: 4-Segal, not lower 3-Segal, not upper 3-Segal, not 2-Segal.
X = Sphere(2)
print("\nX=S^2 model. sanity: not lower 2-Segal (k=1), expect a FAIL:")
print(" ->", check(X,1,"lower_even",[3,4],label="S2"))
EOF
timeout 900 python3 t2.py
Exit code 127
(eval):14: command not found: timeout
$ Bash
cd /tmp/scratchpad && python3 t2.py
sd(S^1) lower_odd k=1 (Segal), expect OK:
    sdS1 k=1 lower_odd m=2 I=(0, 2): OK
    sdS1 k=1 lower_odd m=3 I=(0, 2): OK
    sdS1 k=1 lower_odd m=3 I=(0, 3): OK
    sdS1 k=1 lower_odd m=3 I=(1, 3): OK
 -> True

X=S^2 model. sanity: not lower 2-Segal (k=1), expect a FAIL:
    S2 k=1 lower_even m=3 I=(1, 3): FAIL ('non-unique', ((0, 1, 2), '*'), (0, 0, 1, 2), (0, 1, 1, 2))
    S2 k=1 lower_even m=4 I=(1, 3): FAIL ('no-filler', ((0, 0, 1, 2), (0, 1, 2, 2)))
    S2 k=1 lower_even m=4 I=(1, 4): FAIL ('non-unique', ((0, 1, 1, 2), '*'), (0, 0, 1, 1, 2), (0, 1, 1, 1, 2))
    S2 k=1 lower_even m=4 I=(2, 4): FAIL ('non-unique', ((0, 0, 1, 2), '*'), (0, 0, 0, 1, 2), (0, 0, 1, 1, 2))
 -> False
Shell cwd was reset to ~/twisted_arrow
Thinking

Sizes are small (monotone maps!), so I can profile properly. Let me tabulate, for each sphere $\Delta^n/\partial\Delta^n$ and each $k$, which conditions $X$ and $\operatorname{sd}X$ satisfy:

$ Bash
cd /tmp/scratchpad && cat > profile.py <<'EOF'
from segal import *
import sys

def profile(X, k, mmax, label=""):
    """which of the 4 conditions (cube dim k+1) hold up to simplicial dim mmax"""
    res = {}
    for cond in ["lower_odd","lower_even","upper_even","upper_odd"]:
        ok = True
        for m in range(2*k, mmax+1):
            for I in gapped_subsets(m, k+1):
                if not CONDITIONS[cond](I, m): continue
                c, w = is_cartesian(X, m, I)
                if not c:
                    ok = False; break
            if not ok: break
        res[cond] = ok
    return res

def show(name, res, k):
    d = {"lower_odd":f"low{2*k-1}", "lower_even":f"low{2*k}",
         "upper_even":f"upp{2*k}", "upper_odd":f"upp{2*k+1}"}
    print(f"  {name:16s} " + "  ".join(
        f"{d[c]}:{'Y' if res[c] else 'n'}" for c in
        ["lower_odd","lower_even","upper_even","upper_odd"]))

for n in [1,2,3]:
    X = Sphere(n); Z = Edgewise(X)
    print(f"\n=== X = Delta^{n}/bdry ===")
    for k in [1,2,3]:
        mmax = 2*k+2
        print(f" k={k} (cubes of dim {k+1}), dims up to {mmax} for X; up to {mmax} for sd X")
        show(f"X", profile(X,k,mmax), k)
        sys.stdout.flush()
        show(f"sd X", profile(Z,k,mmax), k)
        sys.stdout.flush()
EOF
python3 profile.py
=== X = Delta^1/bdry ===
 k=1 (cubes of dim 2), dims up to 4 for X; up to 4 for sd X
  X                low1:n  low2:Y  upp2:Y  upp3:Y
  sd X             low1:Y  low2:Y  upp2:Y  upp3:Y
 k=2 (cubes of dim 3), dims up to 6 for X; up to 6 for sd X
  X                low3:Y  low4:Y  upp4:Y  upp5:Y
  sd X             low3:Y  low4:Y  upp4:Y  upp5:Y
 k=3 (cubes of dim 4), dims up to 8 for X; up to 8 for sd X
  X                low5:Y  low6:Y  upp6:Y  upp7:Y
  sd X             low5:Y  low6:Y  upp6:Y  upp7:Y

=== X = Delta^2/bdry ===
 k=1 (cubes of dim 2), dims up to 4 for X; up to 4 for sd X
  X                low1:n  low2:n  upp2:n  upp3:n
  sd X             low1:n  low2:n  upp2:n  upp3:n
 k=2 (cubes of dim 3), dims up to 6 for X; up to 6 for sd X
  X                low3:n  low4:Y  upp4:Y  upp5:Y
  sd X             low3:Y  low4:Y  upp4:Y  upp5:Y
 k=3 (cubes of dim 4), dims up to 8 for X; up to 8 for sd X
  X                low5:Y  low6:Y  upp6:Y  upp7:Y
  sd X             low5:Y  low6:Y  upp6:Y  upp7:Y

=== X = Delta^3/bdry ===
 k=1 (cubes of dim 2), dims up to 4 for X; up to 4 for sd X
  X                low1:n  low2:n  upp2:n  upp3:n
  sd X             low1:n  low2:n  upp2:n  upp3:n
 k=2 (cubes of dim 3), dims up to 6 for X; up to 6 for sd X
  X                low3:n  low4:n  upp4:n  upp5:Y
  sd X             low3:n  low4:n  upp4:Y  upp5:Y
 k=3 (cubes of dim 4), dims up to 8 for X; up to 8 for sd X
  X                low5:n  low6:Y  upp6:Y  upp7:Y
  sd X             low5:Y  low6:Y  upp6:Y  upp7:Y
Shell cwd was reset to ~/twisted_arrow
Thinking

Strong signal already. Let me widen the example pool — quotients $\Delta^N/A$ by subcomplexes, which are cheap and often not self-opposite — and search for counterexamples to both conjectures:

$ Bash
cd /tmp/scratchpad && cat >> segal.py <<'EOF'


class QuotientSimplex(SimplicialSet):
    """Delta^N / A, where A is the subcomplex generated by `collapsed`
    (a list of subsets of [N]).  An m-simplex is a monotone map [m] -> [N],
    identified to STAR when its image lies in one of the collapsed faces."""

    def __init__(self, N, collapsed):
        self.N = N
        self.collapsed = [frozenset(c) for c in collapsed]

    def _norm(self, t):
        im = frozenset(t)
        for c in self.collapsed:
            if im <= c:
                return STAR
        return t

    def elements(self, m):
        out = [STAR]
        for t in monotone(m + 1, self.N):
            if self._norm(t) is not STAR:
                out.append(t)
        return out

    def face(self, x, i, m):
        if x is STAR:
            return STAR
        return self._norm(x[:i] + x[i + 1:])
EOF
cat > search.py <<'EOF'
from segal import *
from itertools import combinations
import sys

def holds(X, k, cond, mmax):
    for m in range(2*k, mmax+1):
        for I in gapped_subsets(m, k+1):
            if not CONDITIONS[cond](I, m): continue
            if not is_cartesian(X, m, I)[0]:
                return False
    return True

def prof(X, k, mmax):
    return {c: holds(X,k,c,mmax) for c in
            ["lower_odd","lower_even","upper_even","upper_odd"]}

def subcomplex_gens(N):
    """antichains of proper subsets of [N] (generators of subcomplexes)"""
    subs = [frozenset(s) for r in range(1, N+1) for s in combinations(range(N+1), r)]
    out = []
    for r in range(0, 4):
        for gens in combinations(subs, r):
            if any(a < b for a in gens for b in gens): continue
            out.append(gens)
    return out

def run(examples, kmax=2):
    bad = []
    for name, X in examples:
        line = [f"{name:34s}"]
        for k in range(1, kmax+1):
            mmax = 2*k+2
            px = prof(X, k, mmax)
            pz = prof(Edgewise(X), k, mmax)
            # Conjecture A: X 2k-Segal  <=> sd X lower (2k-1)-Segal
            A = (px["lower_even"] and px["upper_even"]) == pz["lower_odd"]
            # Conjecture B: X upper (2k+1)-Segal <=> sd X upper 2k-Segal
            B = px["upper_odd"] == pz["upper_even"]
            # Conjecture C (guess): X lower?? <=> sd X lower 2k-Segal
            line.append(f"k={k} X[{''.join('Y' if px[c] else '.' for c in ['lower_odd','lower_even','upper_even','upper_odd'])}]"
                        f" sd[{''.join('Y' if pz[c] else '.' for c in ['lower_odd','lower_even','upper_even','upper_odd'])}]"
                        f" A:{'ok' if A else 'XX'} B:{'ok' if B else 'XX'}")
            if not A or not B:
                bad.append((name,k,px,pz,A,B))
        print("  ".join(line)); sys.stdout.flush()
    return bad

ex = []
for N in [2,3]:
    for gens in subcomplex_gens(N):
        X = QuotientSimplex(N, gens)
        if len(X.elements(1)) <= 1:   # too degenerate
            continue
        nm = f"D{N}/<{','.join(''.join(map(str,sorted(g))) for g in gens) or '-'}>"
        ex.append((nm, X))
print(f"{len(ex)} examples\n")
bad = run(ex, kmax=2)
print("\nCOUNTEREXAMPLES:", len(bad))
for b in bad: print(b)
EOF
python3 search.py 2>&1 | tail -60
D3/<012,123>                        k=1 X[...Y] sd[..YY] A:ok B:ok  k=2 X[.YYY] sd[YYYY] A:ok B:ok
D3/<013,023>                        k=1 X[....] sd[....] A:ok B:ok  k=2 X[YYYY] sd[YYYY] A:ok B:ok
D3/<013,123>                        k=1 X[....] sd[....] A:ok B:ok  k=2 X[.Y.Y] sd[..YY] A:ok B:ok
D3/<023,123>                        k=1 X[....] sd[....] A:ok B:ok  k=2 X[YYYY] sd[YYYY] A:ok B:ok
D3/<0,1,2>                          k=1 X[.YYY] sd[YYYY] A:ok B:ok  k=2 X[YYYY] sd[YYYY] A:ok B:ok
D3/<0,1,3>                          k=1 X[.YYY] sd[YYYY] A:ok B:ok  k=2 X[YYYY] sd[YYYY] A:ok B:ok
D3/<0,1,23>                         k=1 X[.Y.Y] sd[..YY] A:ok B:ok  k=2 X[YYYY] sd[YYYY] A:ok B:ok
D3/<0,2,3>                          k=1 X[.YYY] sd[YYYY] A:ok B:ok  k=2 X[YYYY] sd[YYYY] A:ok B:ok
D3/<0,2,13>                         k=1 X[....] sd[....] A:ok B:ok  k=2 X[YYYY] sd[YYYY] A:ok B:ok
D3/<0,3,12>                         k=1 X[...Y] sd[..YY] A:ok B:ok  k=2 X[.YYY] sd[YYYY] A:ok B:ok
D3/<0,12,13>                        k=1 X[....] sd[....] A:ok B:ok  k=2 X[.YYY] sd[YYYY] A:ok B:ok
D3/<0,12,23>                        k=1 X[...Y] sd[..YY] A:ok B:ok  k=2 X[.YYY] sd[YYYY] A:ok B:ok
D3/<0,13,23>                        k=1 X[....] sd[....] A:ok B:ok  k=2 X[YYYY] sd[YYYY] A:ok B:ok
D3/<1,2,3>                          k=1 X[.YYY] sd[YYYY] A:ok B:ok  k=2 X[YYYY] sd[YYYY] A:ok B:ok
D3/<1,2,03>                         k=1 X[....] sd[....] A:ok B:ok  k=2 X[YYYY] sd[YYYY] A:ok B:ok
D3/<1,3,02>                         k=1 X[....] sd[....] A:ok B:ok  k=2 X[YYYY] sd[YYYY] A:ok B:ok
D3/<1,02,03>                        k=1 X[....] sd[....] A:ok B:ok  k=2 X[YYYY] sd[YYYY] A:ok B:ok
D3/<1,02,23>                        k=1 X[....] sd[....] A:ok B:ok  k=2 X[.YYY] sd[YYYY] A:ok B:ok
D3/<1,03,23>                        k=1 X[....] sd[....] A:ok B:ok  k=2 X[YYYY] sd[YYYY] A:ok B:ok
D3/<2,3,01>                         k=1 X[..YY] sd[..YY] A:ok B:ok  k=2 X[YYYY] sd[YYYY] A:ok B:ok
D3/<2,01,03>                        k=1 X[....] sd[....] A:ok B:ok  k=2 X[YYYY] sd[YYYY] A:ok B:ok
D3/<2,01,13>                        k=1 X[....] sd[....] A:ok B:ok  k=2 X[.YYY] sd[YYYY] A:ok B:ok
D3/<2,03,13>                        k=1 X[....] sd[....] A:ok B:ok  k=2 X[YYYY] sd[YYYY] A:ok B:ok
D3/<3,01,02>                        k=1 X[....] sd[....] A:ok B:ok  k=2 X[YYYY] sd[YYYY] A:ok B:ok
D3/<3,01,12>                        k=1 X[...Y] sd[..YY] A:ok B:ok  k=2 X[.YYY] sd[YYYY] A:ok B:ok
D3/<3,02,12>                        k=1 X[....] sd[....] A:ok B:ok  k=2 X[.YYY] sd[YYYY] A:ok B:ok
D3/<01,02,03>                       k=1 X[....] sd[....] A:ok B:ok  k=2 X[YYYY] sd[YYYY] A:ok B:ok
D3/<01,02,12>                       k=1 X[....] sd[....] A:ok B:ok  k=2 X[.YYY] sd[YYYY] A:ok B:ok
D3/<01,02,13>                       k=1 X[....] sd[....] A:ok B:ok  k=2 X[.YYY] sd[YYYY] A:ok B:ok
D3/<01,02,23>                       k=1 X[....] sd[....] A:ok B:ok  k=2 X[.YYY] sd[YYYY] A:ok B:ok
D3/<01,02,123>                      k=1 X[....] sd[....] A:ok B:ok  k=2 X[.YYY] sd[YYYY] A:ok B:ok
D3/<01,03,12>                       k=1 X[....] sd[....] A:ok B:ok  k=2 X[.YYY] sd[YYYY] A:ok B:ok
D3/<01,03,13>                       k=1 X[....] sd[....] A:ok B:ok  k=2 X[.YYY] sd[YYYY] A:ok B:ok
D3/<01,03,23>                       k=1 X[....] sd[....] A:ok B:ok  k=2 X[YYYY] sd[YYYY] A:ok B:ok
D3/<01,03,123>                      k=1 X[....] sd[....] A:ok B:ok  k=2 X[.YYY] sd[YYYY] A:ok B:ok
D3/<01,12,13>                       k=1 X[....] sd[....] A:ok B:ok  k=2 X[.YYY] sd[YYYY] A:ok B:ok
D3/<01,12,23>                       k=1 X[...Y] sd[..YY] A:ok B:ok  k=2 X[.YYY] sd[YYYY] A:ok B:ok
D3/<01,12,023>                      k=1 X[....] sd[....] A:ok B:ok  k=2 X[.YYY] sd[YYYY] A:ok B:ok
D3/<01,13,23>                       k=1 X[....] sd[....] A:ok B:ok  k=2 X[.YYY] sd[YYYY] A:ok B:ok
D3/<01,13,023>                      k=1 X[....] sd[....] A:ok B:ok  k=2 X[.YYY] sd[YYYY] A:ok B:ok
D3/<02,03,12>                       k=1 X[....] sd[....] A:ok B:ok  k=2 X[.YYY] sd[YYYY] A:ok B:ok
D3/<02,03,13>                       k=1 X[....] sd[....] A:ok B:ok  k=2 X[YYYY] sd[YYYY] A:ok B:ok
D3/<02,03,23>                       k=1 X[....] sd[....] A:ok B:ok  k=2 X[.YYY] sd[YYYY] A:ok B:ok
D3/<02,03,123>                      k=1 X[....] sd[....] A:ok B:ok  k=2 X[.YYY] sd[YYYY] A:ok B:ok
D3/<02,12,13>                       k=1 X[....] sd[....] A:ok B:ok  k=2 X[.YYY] sd[YYYY] A:ok B:ok
D3/<02,12,23>                       k=1 X[....] sd[....] A:ok B:ok  k=2 X[.YYY] sd[YYYY] A:ok B:ok
D3/<02,12,013>                      k=1 X[....] sd[....] A:ok B:ok  k=2 X[.YYY] sd[YYYY] A:ok B:ok
D3/<02,13,23>                       k=1 X[....] sd[....] A:ok B:ok  k=2 X[.YYY] sd[YYYY] A:ok B:ok
D3/<02,23,013>                      k=1 X[....] sd[....] A:ok B:ok  k=2 X[.YYY] sd[YYYY] A:ok B:ok
D3/<03,12,13>                       k=1 X[....] sd[....] A:ok B:ok  k=2 X[.YYY] sd[YYYY] A:ok B:ok
D3/<03,12,23>                       k=1 X[....] sd[....] A:ok B:ok  k=2 X[.YYY] sd[YYYY] A:ok B:ok
D3/<03,13,23>                       k=1 X[....] sd[....] A:ok B:ok  k=2 X[YYYY] sd[YYYY] A:ok B:ok
D3/<03,13,012>                      k=1 X[....] sd[....] A:ok B:ok  k=2 X[.YYY] sd[YYYY] A:ok B:ok
D3/<03,23,012>                      k=1 X[....] sd[....] A:ok B:ok  k=2 X[.YYY] sd[YYYY] A:ok B:ok
D3/<12,13,23>                       k=1 X[....] sd[....] A:ok B:ok  k=2 X[.YYY] sd[YYYY] A:ok B:ok
D3/<12,13,023>                      k=1 X[....] sd[....] A:ok B:ok  k=2 X[.YYY] sd[YYYY] A:ok B:ok
D3/<12,23,013>                      k=1 X[....] sd[....] A:ok B:ok  k=2 X[.YYY] sd[YYYY] A:ok B:ok
D3/<13,23,012>                      k=1 X[....] sd[....] A:ok B:ok  k=2 X[.YYY] sd[YYYY] A:ok B:ok

COUNTEREXAMPLES: 0
Shell cwd was reset to ~/twisted_arrow
Thinking

Zero counterexamples over ~350 examples, for both conjectures. Before trusting that, let me validate the sd implementation against a known identity ($\operatorname{sd}X = \operatorname{sd}(X^{\mathrm{op}})$) and check whether $\operatorname{sd}X$ is self-opposite:

$ Bash
cd /tmp/scratchpad && cat > t3.py <<'EOF'
from segal import *
from search import prof   # note: search.py runs on import; use fresh copy instead
EOF
cat > t3.py <<'EOF'
from segal import *
def holds(X,k,cond,mmax):
    for m in range(2*k, mmax+1):
        for I in gapped_subsets(m,k+1):
            if not CONDITIONS[cond](I,m): continue
            if not is_cartesian(X,m,I)[0]: return False
    return True
def prof(X,k,mmax):
    return "".join('Y' if holds(X,k,c,mmax) else '.' for c in
                   ["lower_odd","lower_even","upper_even","upper_odd"])

tests = [("D3/<0,1,23>", QuotientSimplex(3,[[0],[1],[2,3]])),
         ("D3/<3,01,12>", QuotientSimplex(3,[[3],[0,1],[1,2]])),
         ("S^2", Sphere(2)), ("S^3", Sphere(3))]
for nm,X in tests:
    for k in [1,2]:
        mm=2*k+2
        print(f"{nm:14s} k={k}  X:{prof(X,k,mm)}  X^op:{prof(Opposite(X),k,mm)}  "
              f"sdX:{prof(Edgewise(X),k,mm)}  sd(X^op):{prof(Edgewise(Opposite(X)),k,mm)}  "
              f"(sdX)^op:{prof(Opposite(Edgewise(X)),k,mm)}")
EOF
python3 t3.py
D3/<0,1,23>    k=1  X:.Y.Y  X^op:..YY  sdX:..YY  sd(X^op):..YY  (sdX)^op:.Y.Y
D3/<0,1,23>    k=2  X:YYYY  X^op:YYYY  sdX:YYYY  sd(X^op):YYYY  (sdX)^op:YYYY
D3/<3,01,12>   k=1  X:...Y  X^op:...Y  sdX:..YY  sd(X^op):..YY  (sdX)^op:.Y.Y
D3/<3,01,12>   k=2  X:.YYY  X^op:.YYY  sdX:YYYY  sd(X^op):YYYY  (sdX)^op:YYYY
S^2            k=1  X:....  X^op:....  sdX:....  sd(X^op):....  (sdX)^op:....
S^2            k=2  X:.YYY  X^op:.YYY  sdX:YYYY  sd(X^op):YYYY  (sdX)^op:YYYY
S^3            k=1  X:....  X^op:....  sdX:....  sd(X^op):....  (sdX)^op:....
S^3            k=2  X:...Y  X^op:...Y  sdX:..YY  sd(X^op):..YY  (sdX)^op:.Y.Y
Shell cwd was reset to ~/twisted_arrow
Thinking

The sd X = sd(X^op) identity checks out numerically (and (sd X)^op genuinely differs — so sd X is not self-opposite, which matters). Let me stress-test at $k=3,4$ on the $n=4$ sphere:

$ Bash
cd /tmp/scratchpad && cat > t4.py <<'EOF'
from segal import *
import time, sys
def holds(X,k,cond,mmax):
    for m in range(2*k, mmax+1):
        for I in gapped_subsets(m,k+1):
            if not CONDITIONS[cond](I,m): continue
            if not is_cartesian(X,m,I)[0]: return False
    return True
def prof(X,k,mm):
    return "".join('Y' if holds(X,k,c,mm) else '.' for c in
                   ["lower_odd","lower_even","upper_even","upper_odd"])
for n in [4]:
    X=Sphere(n)
    for k in [2,3]:
        mm=2*k+2; t=time.time()
        px=prof(X,k,mm); pz=prof(Edgewise(X),k,mm)
        print(f"S^{n} k={k}: X:{px} sdX:{pz}   A:{'ok' if (px[1]=='Y' and px[2]=='Y')==(pz[0]=='Y') else 'XX'}"
              f" B:{'ok' if px[3]==pz[2] else 'XX'}  [{time.time()-t:.0f}s]"); sys.stdout.flush()
EOF
python3 t4.py
S^4 k=2: X:.... sdX:....   A:ok B:ok  [0s]
S^4 k=3: X:.... sdX:....   A:ok B:ok  [0s]
Shell cwd was reset to ~/twisted_arrow
Thinking
$ Bash
cd /tmp/scratchpad && cat > t5.py <<'EOF'
from segal import *
import time, sys
def holds(X,k,cond,mmax):
    for m in range(2*k, mmax+1):
        for I in gapped_subsets(m,k+1):
            if not CONDITIONS[cond](I,m): continue
            if not is_cartesian(X,m,I)[0]: return False
    return True
def prof(X,k,mm):
    return "".join('Y' if holds(X,k,c,mm) else '.' for c in
                   ["lower_odd","lower_even","upper_even","upper_odd"])
k=4; mm=2*k+2
X=Sphere(4); t=time.time()
px=prof(X,k,mm); print("X :",px, f"{time.time()-t:.0f}s"); sys.stdout.flush()
t=time.time(); pz=prof(Edgewise(X),k,mm); print("sd:",pz, f"{time.time()-t:.0f}s")
print("A:", (px[1]=='Y' and px[2]=='Y')==(pz[0]=='Y'), " B:", px[3]==pz[2])
EOF
python3 t5.py
Command running in background with ID: b8kccs5dc. Output is being written to: /tmp/claude-session/tasks/b8kccs5dc.output. You will be notified when it completes. To check interim output, use Read on that file path.
Session cwd remains ~/twisted_arrow; directory changes made by the backgrounded command do not apply to subsequent commands.
Thinking
$ Bash
cat /tmp/claude-session/tasks/b8kccs5dc.output 2>/dev/null; echo "---"
X : .YYY 0s
---
Thinking

$\Delta^4/\partial\Delta^4$ at $k=4$ reproduces the published theorem ($8$-Segal, not lower $7$-Segal) — good independent check. While sd computes, let me write up the structure I derived:

📝 Write edgewise-higher.md
~/twisted_arrow/notes/edgewise-higher.md
# Edgewise subdivision and the higher Segal conditions

Working notes. Conventions as in `from_coskel.tex`: $S \in \Delta$ a finite ordered
set, $X(S)$, $S_i = S \setminus \{i\}$, gapped $I \subset S$ of cardinality $k+1$,
cube $X\llbracket I \subset S\rrbracket \colon \mathcal P(I) \to \mathcal C$,
$U \mapsto X(S \setminus U)$.

## The two conjectures

Let $Z = \operatorname{sd} X$. For every $k \geq 1$:

* **(A)** $X$ is $2k$-Segal (upper *and* lower) $\iff$ $Z$ is lower $(2k{-}1)$-Segal.
* **(B)** $X$ is upper $(2k{+}1)$-Segal $\iff$ $Z$ is **upper** $2k$-Segal.

$k=1$ of (A) is the classical edgewise subdivision criterion.

Two consistency remarks:

* Since $\operatorname{sd}X = \operatorname{sd}(X^\op)$, any condition of the form
  "$P(\operatorname{sd}X)$" is invariant under $X \mapsto X^\op$, so the condition
  it characterizes must be self-dual. Both "$2k$-Segal" and "upper $(2k{+}1)$-Segal"
  are self-dual; a *one-sided even* criterion via $\operatorname{sd}$ is impossible.
* $P$ itself need *not* be self-dual, because $\operatorname{sd}X$ is **not**
  self-opposite ($\operatorname{sd}(X^\op) = \operatorname{sd}X \neq (\operatorname{sd}X)^\op$
  in general — verified computationally, e.g. $X = \Delta^3/\langle 0,1,23\rangle$).
  This is what makes the asymmetric (B) possible.

Empirically (see `notes/segal.py`), for $Z$ in the image of $\operatorname{sd}$ the
profile collapses: lower $(2k{-}1)$ $\iff$ lower $2k$, and upper $2k$ $\iff$ upper
$(2k{+}1)$. Only three profiles ever occur. The proof sketch below explains why.

## The doubling functor

Write $D(S) = S^\op \star S$, with elements $s^-$ (reversed block) and $s^+$
(forward block): $\max(S)^- < \cdots < \min(S)^- < \min(S)^+ < \cdots < \max(S)^+$.
Then $Z(S) = X(D(S))$ and, crucially,
$$D(S_i) = D(S) \setminus \{i^-, i^+\}.$$
So for $I \subset S$ gapped of cardinality $k+1$, the $(k{+}1)$-cube
$Z\llbracket I \subset S\rrbracket$ is the **diagonal** of the $(2k{+}2)$-cube
$X\llbracket I^\pm \subset D(S)\rrbracket$, where $I^{\pm} = \{i^-,i^+ : i \in I\}$:
each direction $i$ of the $Z$-cube is the composite of the two directions
$i^-, i^+$ of the $X$-cube.

Note $I^\pm$ is itself **not** gapped in $D(S)$ when $\min(S) \in I$ (the pair
$\min(S)^-,\min(S)^+$ is adjacent). This is the higher analogue of the
active-inert square $d_{n+1}d_{n+2}$ used in `lem decomp implies sd Segal`.

## Forward direction (both A and B), via iterated pasting

For $D \subseteq I$ ("doubled directions"), $E$ a set of single elements, and an
ambient $A$, let $V(D,E,A)$ be the cube
$U \mapsto X\big(A \setminus (U \cap D)^\pm \setminus (U \cap E)\big)$.
Splitting one doubled direction $i$ exhibits $V(D,E,A)$ as a composite of maps of
cubes
$$V(D_i, E\cup\{i^+\}, A) \quad\text{then}\quad V(D_i, E \cup \{i^-\}, A\setminus\{i^+\}),$$
so by the generalized pasting law (`from_hsd.tex`, `generalized pasting law`:
$P,Q$ cartesian $\Rightarrow$ $Q\circ P$ cartesian) induction on $|D|$ reduces
cartesianness of $Z\llbracket I \subset S\rrbracket$ to that of the $2^{k+1}$
**leaves**: for each section $\varepsilon \colon I \to I^\pm$
($\varepsilon_i \in \{i^-,i^+\}$),
$$X\llbracket E_\varepsilon \subset A_\varepsilon \rrbracket, \qquad
E_\varepsilon = \{\varepsilon_i\},\quad
A_\varepsilon = D(S) \setminus \{i^+ : \varepsilon_i = i^-\}.$$

**Leaf sets are gapped.** Same-block pairs inherit gaps from $I$ gapped in $S$
(taking the *minimal* $s\in S$ strictly between two elements of $I$; that $s \notin I$,
so $s^\pm$ survives). Cross pairs $i^-, j^+$ with $i \neq j$: if $i \neq \min(S)$
then $\min(S)^-$ separates them (no $^-$ element is ever deleted); if $i = \min(S)$
then $s^+$ separates them for $s\in S\setminus I$ minimal with $i<s<j$.

**Endpoints.** $\min(A_\varepsilon) = \max(S)^-$ always. So
$E_\varepsilon \ni \min(A_\varepsilon)$ iff $\max(S) \in I$ and
$\varepsilon_{\max S} = \max(S)^-$ — and in that case $\max(S)^+$ has been deleted,
so $\max(A_\varepsilon) = t^+$ with $t \in S$ the predecessor of $\max(S)$; since
$I$ is gapped and $\max(S)\in I$ we get $t \notin I$, hence
$t^+ \notin E_\varepsilon$.

Consequently:

* **No leaf ever contains both endpoints of its ambient set.** Hence
  $X$ $2k$-Segal (upper + lower) suffices: this is the forward direction of **(A)**,
  and it pins down *why the level is $2k$* — the two one-sided conditions are
  exactly what the two blocks of the subdivision demand.
* If moreover $\max(S) \notin I$ (i.e. we are checking the **upper** $2k$-Segal
  condition on $Z$), then no $\varepsilon_i$ is $\max(S)^\pm$, so every leaf avoids
  *both* endpoints and only upper $(2k{+}1)$-Segality of $X$ is needed: forward
  direction of **(B)**.
* If instead $\min(S) \notin I$ (lower $2k$-Segal on $Z$), nothing changes in the
  analysis above — which is exactly why lower $2k$ and lower $(2k{-}1)$ coincide on
  $\operatorname{sd}X$, as observed computationally.

## Converse directions — not yet done

Both should follow from a cube-level generalization of `lem ldec square as retract`
(`decomp.tex`), plus the path space criterion (`easy psc`):
$X$ lower $2k$-Segal $\iff \decbot X$ lower $(2k{-}1)$-Segal, and
$X$ upper $(2k{+}1)$-Segal $\iff \decbot X$ upper $2k$-Segal — note the
"$\max \notin I$" restriction matches on both sides, which is what (B) needs.

The comparison map is induced by the collapse $c\colon D(S) \to S^\triangleleft$
(crush the $^-$ block), which *is* natural; the retraction is induced by
$r\colon S^\triangleleft \to D(S)$, $\bot \mapsto \max(S)^-$, $s \mapsto s^+$, which
satisfies $cr = \operatorname{id}$ but is **not** natural in $S$ — as in the $k=1$
case, the corner maps of the cube must be adjusted ($d_1^n$ vs $d_0d_2^{n-1}$ in
`lem ldec square as retract`). Verifying that these adjusted corner maps assemble
into a map of $(k{+}1)$-cubes is the remaining gap.

## Computational evidence

`notes/segal.py` implements higher Segal conditions for finite simplicial sets and
$\operatorname{sd}$; `notes/search.py` runs the search. No counterexample to (A) or
(B) in ~350 examples ($\Delta^n/\partial\Delta^n$, $\partial\Delta^{N}$, all
quotients $\Delta^N/A$ by subcomplexes for $N \leq 3$), at $k = 1,2$ (and $k=3,4$
for the spheres). Known theorems for $\Delta^n/\partial\Delta^n$ are reproduced
exactly, which validates the implementation.

Key discriminating data points:

| $X$ | $k$ | $X$ | $\operatorname{sd}X$ |
|---|---|---|---|
| $\Delta^1/\partial$ | 1 | $2$-Segal, not lower 1 | Segal |
| $\Delta^2/\partial$ | 1 | not $2$-Segal | not Segal |
| $\Delta^2/\partial$ | 2 | $4$-Segal, not lower 3 | lower $3$-Segal |
| $\Delta^3/\partial$ | 2 | upper $5$, **not** $4$-Segal | upper $4$, **not** lower $4$ |
| $\Delta^3/\partial$ | 3 | $6$-Segal, not lower 5 | lower $5$-Segal |
| $\Delta^3/\langle 0,1,23\rangle$ | 1 | lower $2$, **not** upper $2$ | upper $2$, not Segal |

The $\Delta^3/\partial\Delta^3$ row at $k=2$ is the sharpest: it separates (B) from
(A), and shows the upper/lower asymmetry of the criterion is real.
File created successfully at: ~/twisted_arrow/notes/edgewise-higher.md (file state is current in your context — no need to Read it back)
$ Bash
cat /tmp/claude-session/tasks/b8kccs5dc.output
X : .YYY 0s
sd: YYYY 65s
A: True  B: True
Thinking

$\Delta^4/\partial\Delta^4$ at $k=4$: $X$ is $8$-Segal, $\operatorname{sd}X$ is lower $7$-Segal ✓. Let me put the code alongside the notes:

$ Bash
cp /tmp/scratchpad/segal.py /tmp/scratchpad/search.py notes/ && ls notes/ && git status --short
edgewise-higher.md
search.py
segal.py
?? notes/
✏️ Edit edgewise-higher.md
~/twisted_arrow/notes/edgewise-higher.md
| $\Delta^3/\partial$ | 3 | $6$-Segal, not lower 5 | lower $5$-Segal |
+
| $\Delta^3/\partial$ | 3 | $6$-Segal, not lower 5 | lower $5$-Segal |
| $\Delta^4/\partial$ | 4 | $8$-Segal, not lower 7 | lower $7$-Segal |
The file ~/twisted_arrow/notes/edgewise-higher.md has been updated successfully. (file state is current in your context — no need to Read it back)
Thinking

Here's where things stand.

Answer: yes, twice — and the odd case is the fun one

Both conjectures survive everything I threw at them. Writing $Z = \operatorname{sd}X$, for every $k \ge 1$:

  • (A) $X$ is $2k$-Segal (upper and lower) $\iff$ $Z$ is lower $(2k{-}1)$-Segal. (k=1 is the classical criterion.)
  • (B) $X$ is upper $(2k{+}1)$-Segal $\iff$ $Z$ is upper $2k$-Segal.

(B) is asymmetric, which surprised me until I noticed that $\operatorname{sd}X$ is not self-opposite — $\operatorname{sd}(X^\op) = \operatorname{sd}X$, but $(\operatorname{sd}X)^\op$ genuinely differs (verified numerically). So the condition on $X$ must be self-dual, but the condition on $\operatorname{sd}X$ need not be. That's what leaves room for an odd criterion at all.

The forward direction of both, from one lemma

$D(S) = S^\op \star S$ satisfies $D(S_i) = D(S)\setminus{i^-,i^+}$, so $Z\llbracket I \subset S\rrbracket$ is the diagonal of the $(2k{+}2)$-cube $X\llbracket I^\pm \subset D(S)\rrbracket$ — each $Z$-direction is the composite of two $X$-directions. Iterating your generalized pasting law one direction at a time reduces cartesianness to the $2^{k+1}$ leaves $X\llbracket E_\varepsilon \subset A_\varepsilon\rrbracket$, one per section $\varepsilon_i \in {i^-,i^+}$, with $A_\varepsilon = D(S)\setminus{i^+ : \varepsilon_i = i^-}$.

Then two combinatorial facts do all the work:

  1. Every $E_\varepsilon$ is gapped in $A_\varepsilon$ (cross-pairs $i^-, j^+$, $i\neq j$, are separated by $\min(S)^-$; the degenerate case $i=\min(S)$ is separated by $s^+$ for the minimal $s\in S\setminus I$ between them).
  2. No leaf contains both endpoints of its ambient: $\min(A_\varepsilon)=\max(S)^-$, and if $E_\varepsilon$ contains it then $\max(S)^+$ was deleted and the new max is $t^+$ with $t\notin I$ by gappedness.

So $2k$-Segality of $X$ suffices — and that's exactly why the level is $2k$: the two blocks of the subdivision demand the two one-sided conditions, never both at once. If additionally $\max(S)\notin I$ (i.e. you're checking upper $2k$-Segality of $Z$), every leaf avoids both endpoints, so only upper $(2k{+}1)$-Segality is needed — that's (B). And imposing $\min(S)\notin I$ instead changes nothing, which explains an odd pattern in the data: on $\operatorname{sd}X$, lower $(2k{-}1)$ $\iff$ lower $2k$, and upper $2k$ $\iff$ upper $(2k{+}1)$. Only three profiles ever occur.

Remaining gap: the converses. Both should come from a cube-level version of lem ldec square as retract plus easy psc (the "$\max\notin I$" restriction matches on both sides, which is what (B) needs). The comparison map comes from the natural collapse $c\colon D(S)\to S^\triangleleft$; the retraction $r(\bot)=\max(S)^-$, $r(s)=s^+$ has $cr=\mathrm{id}$ but isn't natural — same corner-map adjustment as your $d_1^n$ vs $d_0d_2^{n-1}$. I haven't checked those assemble into a map of $(k{+}1)$-cubes.

Evidence

No counterexample in ~350 finite simplicial sets ($\Delta^n/\partial\Delta^n$, $\partial\Delta^N$, all quotients $\Delta^N/A$ by subcomplexes, $N\le 3$) at $k=1,2$, plus spheres at $k=3,4$. The code reproduces your published sphere theorems exactly ($\Delta^4/\partial\Delta^4$ is $8$-Segal, not lower $7$-Segal), which is my main confidence in the implementation.

Sharpest data point, $X=\Delta^3/\partial\Delta^3$ at $k=2$: $X$ is upper $5$-Segal but not $4$-Segal, and $\operatorname{sd}X$ is upper $4$-Segal but not lower $4$-Segal. That single row separates (B) from (A) and shows the asymmetry is real, not an artifact.

Written up in notes/edgewise-higher.md, with notes/segal.py (higher Segal conditions + $\operatorname{sd}$ for finite simplicial sets) and notes/search.py. Left untracked — say the word and I'll commit them.

Want me to push on the retract lemma next, or hunt harder for counterexamples first (e.g. non-coskeletal or asymmetric examples at $k=2$, where my pool is thinnest)?

Please commit them. Then try out the retract lemma in the way you think best.

Thinking

Committing first (branching off main since that's the default branch):

$ Bash
git checkout -b notes/edgewise-higher-segal && git add notes/ && git commit -q -F - <<'EOF' && git log --oneline -2
Add notes and code on edgewise subdivision for higher Segal conditions

Investigating whether the edgewise subdivision criterion generalizes past
d=2. Two conjectures (A: X is 2k-Segal iff sd X is lower (2k-1)-Segal;
B: X is upper (2k+1)-Segal iff sd X is upper 2k-Segal), a proof sketch of
both forward directions via iterated pasting over the "doubled" cube, and
a brute-force checker for higher Segal conditions on finite simplicial
sets. No counterexample in ~350 examples.

Co-Authored-By: Claude <noreply@anthropic.com>
EOF
Switched to a new branch 'notes/edgewise-higher-segal'
bf4b43b Add notes and code on edgewise subdivision for higher Segal conditions
ad88309 Initialize repository
Thinking

Committed on notes/edgewise-higher-segal (git merge notes/edgewise-higher-segal from main to fast-forward it).

Now the retract lemma. Working with general $S \in \Delta$ rather than $[n]$ makes it come out much cleaner than I expected:

$ Bash
cd /tmp/scratchpad && cat > retract.py <<'EOF'
"""Verify the retract lemma COMBINATORIALLY (a statement about maps in Delta,
independent of X).

For S in Delta and gapped I subset S, pick t in S\I.  Define for U subset I:
   c_U : D(S\U) -> (S\U)^tri   s^+ |-> s,   s^- |-> bot      [natural: the collapse]
   r_U : (S\U)^tri -> D(S\U)   s |-> s^+,   bot |-> t^-      [NOT natural in general]
Claim: (i) c_U r_U = id ; (ii) for U subset V subset I both squares commute, so
c and r assemble into maps of cubes exhibiting the ldec-cube as a retract of the
sd-cube.  (ii) is where the choice t in S\I matters.
"""
from itertools import combinations

def D(S):          # S^op * S  as an ordered list
    return [('-', s) for s in sorted(S, reverse=True)] + [('+', s) for s in sorted(S)]
def tri(S):        # S^triangleleft
    return [('bot', None)] + [('S', s) for s in sorted(S)]

def c_map(S):      # D(S) -> tri(S)
    return {('-', s): ('bot', None) for s in S} | {('+', s): ('S', s) for s in S}
def r_map(S, t):   # tri(S) -> D(S)
    return {('bot', None): ('-', t)} | {('S', s): ('+', s) for s in S}

def monotone_ok(f, src, tgt):
    """is f: src -> tgt order preserving (src, tgt given as ordered lists)?"""
    pos = {x: i for i, x in enumerate(tgt)}
    vals = [pos[f[x]] for x in src]
    return all(vals[i] <= vals[i+1] for i in range(len(vals)-1))

def gapped(I, S):
    S = sorted(S); I = sorted(I)
    if set(I) >= set(S): return False
    for a, b in zip(I, I[1:]):
        if not any(a < s < b for s in S): return False
    return True

fails = []
checked = 0
for n in range(2, 9):
    S = list(range(n+1))
    for ksize in range(1, 5):
        for I in combinations(S, ksize):
            if not gapped(I, S): continue
            for t in [s for s in S if s not in I]:
                # (i) and (ii)
                for U in [set(u) for r in range(len(I)+1) for u in combinations(I, r)]:
                    SU = [s for s in S if s not in U]
                    c, r = c_map(SU), r_map(SU, t)
                    assert monotone_ok(c, D(SU), tri(SU)), "c not monotone"
                    assert monotone_ok(r, tri(SU), D(SU)), "r not monotone"
                    if any(c[r[x]] != x for x in tri(SU)):
                        fails.append(("cr != id", S, I, t, U))
                    for V in [set(v) for rr in range(len(I)+1) for v in combinations(I, rr)]:
                        if not U <= V: continue
                        SV = [s for s in S if s not in V]
                        cV, rV = c_map(SV), r_map(SV, t)
                        # square for c: (incl into D(SU)) o cV  ==  c_U o (incl into tri? )
                        # c is natural: D(SV) --cV--> tri(SV) --incl--> tri(SU)
                        #               D(SV) --incl--> D(SU) --cU--> tri(SU)
                        for x in D(SV):
                            if cV[x] != c[x]:
                                fails.append(("c square", S, I, t, U, V, x))
                        # r square: tri(SV) --rV--> D(SV) --incl--> D(SU)
                        #           tri(SV) --incl--> tri(SU) --rU--> D(SU)
                        for x in tri(SV):
                            if rV[x] != r[x]:
                                fails.append(("r square", S, I, t, U, V, x))
                        checked += 1
print(f"checked {checked} pairs (U subset V); failures: {len(fails)}")
for f in fails[:5]: print("  ", f)

# and the contrast: what if we choose t depending on U, e.g. t = min(S\U)?
fails2 = []
for n in range(2, 7):
    S = list(range(n+1))
    for ksize in range(1, 4):
        for I in combinations(S, ksize):
            if not gapped(I, S): continue
            for U in [set(u) for r in range(len(I)+1) for u in combinations(I, r)]:
                for V in [set(v) for rr in range(len(I)+1) for v in combinations(I, rr)]:
                    if not U <= V: continue
                    SU = [s for s in S if s not in U]; SV = [s for s in S if s not in V]
                    rU = r_map(SU, min(SU)); rV = r_map(SV, min(SV))
                    for x in tri(SV):
                        if rV[x] != rU[x]: fails2.append((S, I, U, V, x)); break
print(f"with the naive choice t = min(S\\U): {len(fails2)} broken squares "
      f"(e.g. {fails2[0] if fails2 else None})")
EOF
python3 retract.py
Exit code 1
  File "/tmp/scratchpad/retract.py", line 1
    """Verify the retract lemma COMBINATORIALLY (a statement about maps in Delta,
    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
SyntaxError: (unicode error) 'unicodeescape' codec can't decode bytes in position 184-185: truncated \UXXXXXXXX escape
$ Bash
cd /tmp/scratchpad && python3 - <<'EOF'
s = open('retract.py').read()
s = s.replace('For S in Delta and gapped I subset S, pick t in S\\I.', 'For S in Delta and gapped I subset S, pick t in S minus I.')
open('retract.py','w').write(s)
EOF
python3 /tmp/scratchpad/retract.py
Exit code 1
  File "/tmp/scratchpad/retract.py", line 1
    """Verify the retract lemma COMBINATORIALLY (a statement about maps in Delta,
    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
SyntaxError: (unicode error) 'unicodeescape' codec can't decode bytes in position 190-191: truncated \UXXXXXXXX escape
Thinking
$ Bash
cd /tmp/scratchpad && python3 - <<'PYEOF'
s = open('retract.py').read()
head, rest = s.split('"""', 2)[1], s.split('"""', 2)[2]
head = head.replace('\\', ' minus ')
open('retract.py','w').write('r"""' + head + '"""' + rest)
PYEOF
python3 /tmp/scratchpad/retract.py
checked 22638 pairs (U subset V); failures: 0
with the naive choice t = min(S\U): 140 broken squares (e.g. ([0, 1, 2], (0,), set(), {0}, ('bot', None)))
Shell cwd was reset to ~/twisted_arrow
Thinking

Retract lemma verified: 0 failures in 22,638 corner-pairs with a fixed $t \in S\setminus I$, while the corner-dependent choice $t=\min(S\setminus U)$ breaks 140 squares. That settles both converses. Updating the notes:

✏️ Edit edgewise-higher.md
~/twisted_arrow/notes/edgewise-higher.md
## Converse directions — not yet done

Both should follow from a cube-level generalization of `lem ldec square as retract`
(`decomp.tex`), plus the path space criterion (`easy psc`):
$X$ lower $2k$-Segal $\iff \decbot X$ lower $(2k{-}1)$-Segal, and
$X$ upper $(2k{+}1)$-Segal $\iff \decbot X$ upper $2k$-Segal — note the
"$\max \notin I$" restriction matches on both sides, which is what (B) needs.

The comparison map is induced by the collapse $c\colon D(S) \to S^\triangleleft$
(crush the $^-$ block), which *is* natural; the retraction is induced by
$r\colon S^\triangleleft \to D(S)$, $\bot \mapsto \max(S)^-$, $s \mapsto s^+$, which
satisfies $cr = \operatorname{id}$ but is **not** natural in $S$ — as in the $k=1$
case, the corner maps of the cube must be adjusted ($d_1^n$ vs $d_0d_2^{n-1}$ in
`lem ldec square as retract`). Verifying that these adjusted corner maps assemble
into a map of $(k{+}1)$-cubes is the remaining gap.
+
## Converse directions, via a retract lemma

**Retract Lemma.** *Let $S \in \Delta$ and let $I \subset S$ be any **proper**
subset. Then the cube $(\decbot X)\llbracket I \subset S\rrbracket$ is a retract of
$(\operatorname{sd}X)\llbracket I \subset S\rrbracket$.*

*Proof.* The collapse $c_S \colon D(S) \to S^\triangleleft$, $s^+ \mapsto s$,
$s^- \mapsto \bot$, is a natural transformation of endofunctors of $\Delta$, so
$X(c)$ is a map of cubes $(\decbot X)\llbracket I\rrbracket \to
(\operatorname{sd}X)\llbracket I \rrbracket$. For the retraction, **fix once and for
all a single $t \in S \setminus I$** (possible exactly because $I$ is proper) and put
$$r_U \colon (S\setminus U)^\triangleleft \to D(S\setminus U), \qquad
\bot \mapsto t^-, \quad s \mapsto s^+ \qquad (U \subseteq I).$$
Each $r_U$ is order-preserving and $c_{S\setminus U} \circ r_U = \operatorname{id}$,
so $X(r_U)X(c_{S\setminus U}) = \operatorname{id}$. For $U \subseteq V \subseteq I$ the
square
$$\begin{array}{ccc}
(S\setminus V)^\triangleleft & \xrightarrow{\ r_V\ } & D(S\setminus V)\\
\cap & & \cap\\
(S\setminus U)^\triangleleft & \xrightarrow{\ r_U\ } & D(S\setminus U)
\end{array}$$
commutes: on $s$ both composites give $s^+$, and on $\bot$ both give $t^-$ —
*because $t \notin I$, so $t \in S\setminus V$ for every $V \subseteq I$, and the two
maps do not have to be renormalized at different corners.* Hence the $r_U$ assemble
into a map of cubes retracting $X(c)$. $\square$

Since retracts of cartesian cubes are cartesian (`lem retract`), this gives both
converses:

* **(A)** If $\operatorname{sd}X$ is lower $(2k{-}1)$-Segal then every
  $(\decbot X)\llbracket I \subset S\rrbracket$ is cartesian, so $\decbot X$ is lower
  $(2k{-}1)$-Segal, so $X$ is lower $2k$-Segal (`easy psc` (1)). Applying this to
  $X^\op$ and using $\operatorname{sd}(X^\op) = \operatorname{sd}X$ gives upper
  $2k$-Segal as well.
* **(B)** The lemma preserves the restriction "$\max(S) \notin I$" verbatim, so if
  $\operatorname{sd}X$ is *upper* $2k$-Segal then $\decbot X$ is upper $2k$-Segal,
  hence $X$ is upper $(2k{+}1)$-Segal by `easy psc` (3b).

**Remark.** This is cleaner than the $k=1$ argument of `lem ldec square as retract`,
which uses *different* corner maps ($d_1^n$ at one corner, $d_0d_2^{n-1}$ at
another) and needs $d_1^ns_0^n = \id = d_0d_2^{n-1}s_0^n$. Those two maps are the
single map $r$ for $t = \max(S)$, read in the standard $[n]$-indexing at two corners
whose relabelings differ. Working with general $S\in\Delta$ and choosing
$t \in S\setminus I$ removes the bookkeeping entirely; the naive corner-local choice
$t = \min(S\setminus U)$ genuinely fails (verified: 140 non-commuting squares).

`notes/retract.py` checks the lemma combinatorially — it is a statement about maps
in $\Delta$, independent of $X$ — over 22638 corner pairs, with no failures.
The file ~/twisted_arrow/notes/edgewise-higher.md has been updated successfully. (file state is current in your context — no need to Read it back)
$ Bash
python3 - <<'PYEOF'
import re
p='notes/edgewise-higher.md'; s=open(p).read()
s = s.replace("""## The two conjectures""", """## Status

Both conjectures below now have proofs: the forward directions by an iterated
pasting argument over the doubled cube, the converses by the Retract Lemma. What
remains is to write the pasting induction out carefully (and to double-check the
gappedness bookkeeping at the leaves).

## The two conjectures""")
open(p,'w').write(s)
PYEOF
cp /tmp/scratchpad/retract.py notes/ && git add notes/ && git commit -q -F - <<'EOF' && git log --oneline -1
Prove the retract lemma, completing both converse directions

Working with general S in Delta (rather than [n]) and choosing a single
t in S\I -- available exactly because gapped subsets are proper -- makes
the retraction a strict map of cubes with no corner-by-corner adjustment,
unlike the k=1 argument in decomp.tex. Verified combinatorially over
22638 corner pairs; the naive corner-local choice t = min(S\U) fails.

Co-Authored-By: Claude <noreply@anthropic.com>
EOF
8b54b9b Prove the retract lemma, completing both converse directions
Thinking

Both directions are now done. Summary of where the investigation landed:

Result

For every $k\ge 1$, with $Z=\operatorname{sd}X$:

  • (A) $X$ is $2k$-Segal (upper and lower) $\iff$ $Z$ is lower $(2k{-}1)$-Segal.
  • (B) $X$ is upper $(2k{+}1)$-Segal $\iff$ $Z$ is upper $2k$-Segal.

So your instinct was right on both counts: the even case is where the criterion lives, and the odd case does have an analogue — but only after allowing the condition on $\operatorname{sd}X$ to be one-sided, which is legitimate because $\operatorname{sd}X$ is not self-opposite even though $\operatorname{sd}$ can't distinguish $X$ from $X^\op$.

The retract lemma

The clean version turned out to be stronger and simpler than the $k=1$ case in decomp.tex:

Lemma. For $S\in\Delta$ and any proper $I\subset S$, the cube $(\decbot X)\llbracket I\subset S\rrbracket$ is a retract of $(\operatorname{sd}X)\llbracket I\subset S\rrbracket$.

The comparison map is $X(c)$ for the natural collapse $c\colon D(S)\to S^\triangleleft$. For the retraction, the point is to fix one $t\in S\setminus I$ globally and set $r_U(\bot)=t^-$, $r_U(s)=s^+$ for every corner $U\subseteq I$. Then $c r=\id$, and the corner squares commute on the nose because $t\notin I$ guarantees $t$ survives in $S\setminus V$ for every $V\subseteq I$ — no corner-by-corner renormalization. Such a $t$ exists precisely because gapped subsets are proper.

This explains the awkward asymmetry in lem ldec square as retract: your $d_1^n$ and $d_0d_2^{n-1}$ are the same map $r$ (with $t=\max S$) read at two corners whose $[n]$-relabelings differ. I checked combinatorially — it's a statement about maps in $\Delta$, independent of $X$ — over 22,638 corner pairs with no failures, and confirmed that the naive corner-local choice $t=\min(S\setminus U)$ really does break (140 non-commuting squares), so the fixed-$t$ trick is doing genuine work.

Both converses follow immediately, since retracts of cartesian cubes are cartesian: (A) from easy psc (1) plus $\operatorname{sd}(X^\op)=\operatorname{sd}X$ for the upper half; (B) because the lemma carries the restriction "$\max(S)\notin I$" across verbatim, landing exactly on easy psc (3b).

Caveat on what's proved to what standard

The converses I'd now call proved. The forward directions are a solid sketch, not a finished proof: the leaf analysis (gappedness, and that no leaf contains both endpoints of its ambient) I checked carefully by hand, but the iterated-pasting induction that reduces the diagonal cube to those $2^{k+1}$ leaves is written as a recursion over "mixed double/single direction" cubes and deserves to be written out properly before you'd trust it in a paper. That's the one place I'd want a second pass.

Committed to notes/edgewise-higher-segal (two commits: bf4b43b, 8b54b9b), with notes/edgewise-higher.md, segal.py, search.py, retract.py. Merge with git merge notes/edgewise-higher-segal from main.

Next most useful thing, if you want it: write the pasting induction out in full LaTeX in your from_coskel conventions — at which point (A) and (B) are a short paper-section, since the two lemmas are each about a page.

sure let's do that

Thinking

Writing it up properly in your from_coskel conventions:

📝 Write edgewise.tex
~/twisted_arrow/notes/edgewise.tex
\documentclass{amsart}
\usepackage{amssymb}
\usepackage{mathtools}
\usepackage[only,llbracket,rrbracket]{stmaryrd}
\usepackage[capitalise,noabbrev]{cleveref}
\usepackage{tikz-cd}
\usepackage{microtype}
\frenchspacing
\usepackage[T1]{fontenc}
\usepackage{enumitem}

\newcommand{\cube}[1]{\llbracket #1 \rrbracket}
\newcommand{\ps}{\mathcal{P}}
\newcommand{\op}{\textup{op}}
\newcommand{\decbot}{\operatorname{dec}_\bot}
\newcommand{\dectop}{\operatorname{dec}_\top}
\newcommand{\sd}{\operatorname{sd}}
\newcommand{\lowev}{\mathsf{le}}
\newcommand{\lowod}{\mathsf{lo}}
\newcommand{\uppev}{\mathsf{ue}}
\newcommand{\uppod}{\mathsf{uo}}
\newcommand{\id}{\operatorname{id}}

\newtheorem{theorem}{Theorem}
\newtheorem{proposition}[theorem]{Proposition}
\newtheorem{corollary}[theorem]{Corollary}
\newtheorem{lemma}[theorem]{Lemma}
\theoremstyle{definition}
\newtheorem{definition}[theorem]{Definition}
\theoremstyle{remark}
\newtheorem{remark}[theorem]{Remark}
\newtheorem{question}[theorem]{Question}

\begin{document}

\title{The edgewise subdivision criterion for higher Segal objects}
\author{}
\date{\today}

\begin{abstract}
We show that the edgewise subdivision criterion for decomposition spaces admits
two generalizations to the higher Segal conditions: a simplicial object $X$ is
$2k$-Segal if and only if $\sd X$ is lower $(2k{-}1)$-Segal, and $X$ is upper
$(2k{+}1)$-Segal if and only if $\sd X$ is upper $2k$-Segal.
\end{abstract}

\maketitle

Throughout, $\mathcal{C}$ is a category or $\infty$-category with finite limits and
$X$ is a simplicial object in $\mathcal C$.
We use the conventions of \cite{from_coskel}: $\Delta$ is the category of nonempty
finite sets of integers and order-preserving maps, $X(S)$ denotes $X$ evaluated at
$S \in \Delta$, a \emph{gapped} subset $I \subset S$ is a proper subset containing
no pair of elements adjacent in $S$, and for such an $I$ we write
\[
	X\cube{I \subset S} \colon \ps(I) \to \mathcal C, \qquad U \mapsto X(S\setminus U)
\]
for the associated cube, with structure maps induced by the inclusions.
The higher Segal conditions of \cite[Definition 3.1]{from_coskel} are stated for
gapped subsets of $[n]$; we use them for gapped subsets of an arbitrary $S \in \Delta$,
transporting along the unique isomorphism $S \cong [n]$ in $\Delta$.
Thus, for $|I| = k+1$, the simplicial object $X$ is
\emph{lower $(2k{-}1)$-Segal} if $X\cube{I\subset S}$ is cartesian for all such $I$;
\emph{lower $2k$-Segal} if this holds whenever $\min(S) \notin I$;
\emph{upper $2k$-Segal} if it holds whenever $\max(S) \notin I$; and
\emph{upper $(2k{+}1)$-Segal} if it holds whenever $\min(S), \max(S) \notin I$.
We say $X$ is \emph{$2k$-Segal} if it is both upper and lower $2k$-Segal.

We use two facts about cubes from \cite[\S3.1]{from_hsd}: retracts of cartesian
cubes are cartesian, and the generalized pasting law, which says that if $P$, $Q$,
$R$ are $(n{+}1)$-cubes with $R = Q \circ P$ as maps of $n$-cubes and $Q$ is
cartesian, then $P$ is cartesian if and only if $R$ is.
We also use the path space criterion in the form of \cite[Proposition 3.7]{from_coskel}.

Our goal is the following pair of results, of which \cref{thm A} for $k=1$ is the
edgewise subdivision criterion for decomposition spaces \cite{BOORS:ESC}.

\begin{theorem}\label{thm A}
Let $k \geq 1$. A simplicial object $X$ is $2k$-Segal if and only if $\sd X$ is
lower $(2k{-}1)$-Segal.
\end{theorem}

\begin{theorem}\label{thm B}
Let $k \geq 1$. A simplicial object $X$ is upper $(2k{+}1)$-Segal if and only if
$\sd X$ is upper $2k$-Segal.
\end{theorem}

Note that no criterion of this shape can detect a \emph{one-sided even} condition:
since $\sd X = \sd(X^\op)$, any condition on $\sd X$ cuts out a class of $X$ closed
under $X \mapsto X^\op$, and $X$ is upper $2k$-Segal if and only if $X^\op$ is lower
$2k$-Segal.
On the other hand the condition imposed \emph{on $\sd X$} may perfectly well be
one-sided, as in \cref{thm B}; this is not in conflict with the above, because
$\sd X$ is in general not isomorphic to $(\sd X)^\op$.

\section{The doubling functor}

For $S \in \Delta$ let $D(S) = S^\op \star S$.
Concretely, $D(S)$ has two elements $s^-$ and $s^+$ for each $s \in S$, ordered by
\[
	s^- < t^- \iff s > t, \qquad s^+ < t^+ \iff s < t, \qquad s^- < t^+ \text{ always},
\]
so that
\[
	\max(S)^- < \cdots < \min(S)^- < \min(S)^+ < \cdots < \max(S)^+ .
\]
A map $f \colon S \to T$ in $\Delta$ induces $D(f) \colon D(S) \to D(T)$ with
$D(f)(s^{\pm}) = f(s)^{\pm}$, and $\sd X (S) = X(D(S))$.
For $U \subseteq S$ write $U^{\pm} = \{u^-, u^+ : u \in U\} \subseteq D(S)$.
The identity
\begin{equation}\label{eq doubling}
	D(S \setminus U) = D(S) \setminus U^{\pm},
\end{equation}
under which $D$ of an inclusion is again an inclusion, is the source of everything
below: it says that deleting one element on the $\sd X$ side deletes \emph{two}
elements, one from each block, on the $X$ side.
By \eqref{eq doubling}, for gapped $I \subset S$ the cube $(\sd X)\cube{I \subset S}$
is given by
\begin{equation}\label{eq sd cube}
	U \longmapsto X\big(D(S) \setminus U^{\pm}\big), \qquad U \subseteq I.
\end{equation}
So $(\sd X)\cube{I\subset S}$ is the ``diagonal'' of the $(2k{+}2)$-dimensional cube
$X\cube{I^{\pm} \subset D(S)}$: each of its $k+1$ directions is the composite of two
directions of the latter.
Observe that $I^{\pm}$ is \emph{not} gapped in $D(S)$ when $\min(S) \in I$, since
$\min(S)^-$ and $\min(S)^+$ are adjacent in $D(S)$; the cube
$X\cube{I^\pm \subset D(S)}$ is therefore not one of the cubes appearing in the
higher Segal conditions.
This is the higher analogue of the fact that the square used in the case $k=1$
(see \cite[Lemma 6.3]{decomp}) is an active-inert square rather than a $2$-Segal
square.

\section{The splitting lemma}

To handle the diagonal we work with cubes in which some directions delete one
element and others delete two.

\begin{definition}\label{def W}
Let $A \in \Delta$, let $\Lambda$ be a finite set, and let $(B_\lambda)_{\lambda \in \Lambda}$
be pairwise disjoint subsets of $A$ with $1 \leq |B_\lambda| \leq 2$.
For each $\lambda$ with $|B_\lambda| = 2$ choose a labelling $B_\lambda = \{b_\lambda, c_\lambda\}$.
Define a $|\Lambda|$-dimensional cube
\[
	W\big(A; (B_\lambda)\big) \colon \ps(\Lambda) \to \mathcal C,
	\qquad U \longmapsto X\Big(A \setminus \textstyle\bigcup_{\lambda \in U} B_\lambda\Big),
\]
with structure maps induced by the inclusions.
A \emph{section} is an element $\varepsilon \in \prod_{\lambda} B_\lambda$; for a
section we put
\[
	E_\varepsilon = \{ \varepsilon_\lambda : \lambda \in \Lambda \},
	\qquad
	A_\varepsilon = A \setminus \{ c_\lambda : |B_\lambda| = 2, \ \varepsilon_\lambda = b_\lambda \}.
\]
\end{definition}

In words: $A_\varepsilon$ is obtained from $A$ by deleting, in each two-element
direction, the element $c_\lambda$ that the section did \emph{not} choose --- but only
when the section chose $b_\lambda$. The asymmetry records the order in which the two
elements of $B_\lambda$ are deleted, namely $c_\lambda$ first.

\begin{lemma}[Splitting Lemma]\label{lem splitting}
With the notation of \cref{def W}, suppose that for every section $\varepsilon$ the
set $E_\varepsilon$ is a proper subset of $A_\varepsilon$ and the cube
$X\cube{E_\varepsilon \subset A_\varepsilon}$ is cartesian.
Then $W(A;(B_\lambda))$ is cartesian.
\end{lemma}

\begin{proof}
Induction on $d = \#\{\lambda : |B_\lambda| = 2\}$.

If $d = 0$ there is exactly one section $\varepsilon$, namely
$\varepsilon_\lambda$ the unique element of $B_\lambda$; then $A_\varepsilon = A$,
$E_\varepsilon = \bigcup_\lambda B_\lambda$, and
$W(A;(B_\lambda)) = X\cube{E_\varepsilon \subset A_\varepsilon}$ is cartesian by
hypothesis.

Suppose $d > 0$ and fix $\mu \in \Lambda$ with $|B_\mu| = 2$.
Define two new families indexed by the same set $\Lambda$:
\[
	B'_\mu = \{c_\mu\}, \quad B'_\lambda = B_\lambda \ (\lambda \neq \mu);
	\qquad
	B''_\mu = \{b_\mu\}, \quad B''_\lambda = B_\lambda \ (\lambda \neq \mu),
\]
and set $P = W(A; (B'_\lambda))$ and $Q = W(A \setminus \{c_\mu\}; (B''_\lambda))$.
Both are $|\Lambda|$-dimensional cubes with $d-1$ two-element directions.
Regard each of $P$, $Q$, and $W = W(A;(B_\lambda))$ as a map of
$(|\Lambda|{-}1)$-cubes in the direction $\mu$, that is, as a map from its
restriction to $\{U \subseteq \Lambda : \mu \notin U\}$ to its restriction to
$\{U : \mu \in U\}$.
Writing $A_U = A \setminus \bigcup_{\lambda \in U} B_\lambda$ for $U \subseteq \Lambda \setminus \mu$,
these three maps of cubes are
\[
	P \colon \big[X(A_U)\big] \to \big[X(A_U \setminus \{c_\mu\})\big],
	\qquad
	Q \colon \big[X(A_U \setminus \{c_\mu\})\big] \to \big[X(A_U \setminus B_\mu)\big],
\]
\[
	W \colon \big[X(A_U)\big] \to \big[X(A_U \setminus B_\mu)\big],
\]
all induced by inclusions, so that $W = Q \circ P$.
The sections of $(A;(B'_\lambda))$ are precisely the sections $\varepsilon$ of
$(A;(B_\lambda))$ with $\varepsilon_\mu = c_\mu$, and for such a section the data
$E_\varepsilon, A_\varepsilon$ computed in $(A;(B'_\lambda))$ agree with those
computed in $(A;(B_\lambda))$: indeed $B'_\mu$ is a singleton, so it contributes
nothing to $A_\varepsilon$, and neither does $B_\mu$ since $\varepsilon_\mu = c_\mu$.
Likewise the sections of $(A\setminus\{c_\mu\};(B''_\lambda))$ are precisely the
sections $\varepsilon$ with $\varepsilon_\mu = b_\mu$, and for such a section
\[
	\big(A \setminus \{c_\mu\}\big) \setminus \{c_\lambda : \lambda \neq \mu, \ \varepsilon_\lambda = b_\lambda\}
	= A \setminus \{c_\lambda : \varepsilon_\lambda = b_\lambda\}
	= A_\varepsilon,
\]
with $E_\varepsilon$ unchanged.
Hence $P$ and $Q$ satisfy the hypothesis of the lemma, so both are cartesian by
induction, and $W = Q\circ P$ is cartesian by the generalized pasting law.
\end{proof}

\section{The forward directions}

We now apply \cref{lem splitting} with
\[
	A = D(S), \qquad \Lambda = I, \qquad B_i = \{i^-, i^+\},
	\qquad b_i = i^-, \quad c_i = i^+,
\]
so that, by \eqref{eq sd cube}, $W(A;(B_i)) = (\sd X)\cube{I \subset S}$.
A section is a choice $\varepsilon_i \in \{i^-, i^+\}$ for each $i \in I$, and
\[
	E_\varepsilon = \{\varepsilon_i : i \in I\},
	\qquad
	A_\varepsilon = D(S) \setminus \{ i^+ : \varepsilon_i = i^- \}.
\]
In particular $A_\varepsilon$ contains the whole block $\{s^- : s \in S\}$, and the
only elements of $D(S)$ ever deleted are of the form $i^+$ with $i \in I$.

We record the following observation, used repeatedly.
If $i < j$ in $I$ then, $I$ being gapped in $S$, the set $\{s \in S : i<s<j\}$ is
nonempty; write $m(i,j)$ for its least element.
Then
\begin{equation}\label{eq mij}
	m(i,j) \notin I,
	\qquad\text{hence}\qquad
	m(i,j)^-,\, m(i,j)^+ \in A_\varepsilon \text{ for every section } \varepsilon.
\end{equation}
Indeed, if $m = m(i,j)$ were in $I$ then by minimality no element of $S$ lies
strictly between $i$ and $m$, so $i$ and $m$ would be adjacent in $S$, contradicting
gappedness.

\begin{lemma}\label{lem leaves gapped}
For every section $\varepsilon$, the set $E_\varepsilon$ is gapped in $A_\varepsilon$.
\end{lemma}

\begin{proof}
Since $I$ is gapped of cardinality $k+1$ in $S$, we have $|S| \geq 2k+1$, whence
$|A_\varepsilon| \geq |S| + (|S| - (k+1)) \geq 3k+1 > k+1 = |E_\varepsilon|$ and
$E_\varepsilon$ is a proper subset.
Let $x < y$ in $E_\varepsilon$; we exhibit $z \in A_\varepsilon$ with $x < z < y$.
There are three cases.

If $x = j^-$ and $y = i^-$ then $i < j$, and $z = m(i,j)^-$ works by \eqref{eq mij},
since $i < m(i,j) < j$ gives $j^- < m(i,j)^- < i^-$.

If $x = i^+$ and $y = j^+$ then $i<j$, and $z = m(i,j)^+$ works by \eqref{eq mij}.

Finally suppose $x = i^-$ and $y = j^+$ with $i \neq j$ (the case $i = j$ cannot
occur, as $\varepsilon$ chooses one element of $\{i^-,i^+\}$).
If $i > \min(S)$, take $z = \min(S)^-$: no element of the $^-$ block is ever
deleted, and $i^- < \min(S)^- < j^+$.
If $i = \min(S)$ then $j > i$, and $z = m(i,j)^+$ works: it lies in $A_\varepsilon$
by \eqref{eq mij}, and $i^- < m(i,j)^+ < j^+$.
\end{proof}

\begin{lemma}\label{lem leaves endpoints}
Let $\varepsilon$ be a section.
Then $E_\varepsilon$ does not contain both $\min(A_\varepsilon)$ and
$\max(A_\varepsilon)$.
If moreover $\max(S) \notin I$, then $E_\varepsilon$ contains neither.
\end{lemma}

\begin{proof}
The $^-$ block of $D(S)$ is contained in $A_\varepsilon$, so
$\min(A_\varepsilon) = \min(D(S)) = \max(S)^-$.
Suppose $\min(A_\varepsilon) \in E_\varepsilon$, i.e.\ $\max(S) \in I$ and
$\varepsilon_{\max(S)} = \max(S)^-$.
Then $\max(S)^+ \notin A_\varepsilon$.
As $|S| \geq 2k+1 \geq 3$, the element $\max(S)$ has a predecessor $t$ in $S$, and
$t \notin I$ because $I$ is gapped and contains $\max(S)$.
Hence $t^+ \in A_\varepsilon$, and $t^+ = \max(A_\varepsilon)$ because the only
element $s^+$ with $s > t$ is $\max(S)^+$, which has been deleted.
Since $t \notin I$ we have $t^+ \notin E_\varepsilon$, so
$\max(A_\varepsilon) \notin E_\varepsilon$, proving the first statement.

If $\max(S) \notin I$ then no $\varepsilon_i$ equals $\max(S)^{\pm}$, so
$\min(A_\varepsilon) = \max(S)^- \notin E_\varepsilon$; moreover $\max(S)^+$ is not
deleted, so $\max(A_\varepsilon) = \max(S)^+ \notin E_\varepsilon$.
\end{proof}

\begin{proposition}\label{prop forward}
Let $k \geq 1$ and let $I \subset S$ be gapped of cardinality $k+1$.
\begin{enumerate}
\item If $X$ is $2k$-Segal, then $(\sd X)\cube{I \subset S}$ is cartesian.
\item If $X$ is upper $(2k{+}1)$-Segal and $\max(S) \notin I$, then
$(\sd X)\cube{I\subset S}$ is cartesian.
\end{enumerate}
In particular, if $X$ is $2k$-Segal then $\sd X$ is lower $(2k{-}1)$-Segal, and if
$X$ is upper $(2k{+}1)$-Segal then $\sd X$ is upper $2k$-Segal.
\end{proposition}

\begin{proof}
By \cref{lem leaves gapped} each $E_\varepsilon$ is a gapped subset of
$A_\varepsilon$ of cardinality $k+1$, so the cubes
$X\cube{E_\varepsilon \subset A_\varepsilon}$ are among those appearing in the
higher Segal conditions for $X$.

For (1), \cref{lem leaves endpoints} says that each $E_\varepsilon$ omits
$\min(A_\varepsilon)$ or omits $\max(A_\varepsilon)$; in the first case
$X\cube{E_\varepsilon\subset A_\varepsilon}$ is cartesian because $X$ is lower
$2k$-Segal, and in the second because $X$ is upper $2k$-Segal.
For (2), \cref{lem leaves endpoints} says that each $E_\varepsilon$ omits both
endpoints of $A_\varepsilon$, so $X\cube{E_\varepsilon \subset A_\varepsilon}$ is
cartesian because $X$ is upper $(2k{+}1)$-Segal.
In either case \cref{lem splitting} applies.
\end{proof}

\begin{remark}
The proof explains why $2k$ is the correct level in \cref{thm A}.
The two blocks of $D(S)$ contribute leaves whose distinguished element sits at the
bottom of the ambient set and leaves whose distinguished element sits at the top,
and these are governed respectively by the lower and the upper $2k$-Segal
conditions; but by \cref{lem leaves endpoints} no single leaf is ever forced to
avoid both, which is exactly the assertion that the lower $(2k{-}1)$-Segal condition
on $X$ is not needed.
\end{remark}

\section{The retract lemma and the converse directions}

The converses rest on the following cube-level form of \cite[Lemma 6.5]{decomp}.
Recall $\decbot X(S) = X(S^\triangleleft)$, where $S^\triangleleft = \{\bot\} \cup S$
with $\bot = \min(S) - 1$.

\begin{lemma}[Retract Lemma]\label{lem retract}
Let $S \in \Delta$ and let $I \subset S$ be a proper subset.
Then the cube $(\decbot X)\cube{I \subset S}$ is a retract of the cube
$(\sd X)\cube{I\subset S}$.
\end{lemma}

\begin{proof}
Let $c_S \colon D(S) \to S^\triangleleft$ be given by $s^+ \mapsto s$ and
$s^- \mapsto \bot$; it is order-preserving, and it is natural in $S$, since for
$f \colon S \to T$ both $f^\triangleleft \circ c_S$ and $c_T \circ D(f)$ send
$s^-\mapsto \bot$ and $s^+ \mapsto f(s)$.
Hence $X(c)$ defines a map of cubes
$(\decbot X)\cube{I \subset S} \to (\sd X)\cube{I \subset S}$ whose value at
$U \subseteq I$ is $X(c_{S\setminus U})$.

For the retraction, use that $I$ is proper to \emph{fix a single element}
$t \in S \setminus I$, and for $U \subseteq I$ define
\[
	r_U \colon (S\setminus U)^\triangleleft \to D(S \setminus U),
	\qquad \bot \mapsto t^-, \qquad s \mapsto s^+ .
\]
This makes sense because $t \notin I$ implies $t \in S \setminus U$ for every
$U \subseteq I$, and it is order-preserving because $t^- < s^+$ for all $s$.
Clearly $c_{S\setminus U} \circ r_U = \id$, so
$X(r_U) \circ X(c_{S\setminus U}) = \id$.

It remains to check that the $X(r_U)$ form a map of cubes, i.e.\ that for
$U \subseteq V \subseteq I$ the square
\[ \begin{tikzcd}
(S\setminus V)^\triangleleft \rar{r_V} \dar[hook] & D(S\setminus V) \dar[hook] \\
(S\setminus U)^\triangleleft \rar{r_U} & D(S\setminus U)
\end{tikzcd} \]
commutes.
On $s \in S \setminus V$ both composites give $s^+$, and on $\bot$ both give $t^-$,
using once more that $t \notin I \supseteq V$, so that the \emph{same} $t$ is
available at every corner.
Thus $X(r)$ retracts $X(c)$.
\end{proof}

\begin{remark}\label{rmk why t}
The choice of a single $t \in S\setminus I$ is what makes the retraction a strict map
of cubes.
The naive corner-local choice $r_U(\bot) = \min(S\setminus U)^-$ does \emph{not}
define a map of cubes: the square above fails whenever $\min(S\setminus U) \in V$.
In the case $k=1$ of \cite[Lemma 6.5]{decomp} this is visible in the two distinct
corner maps $d_1^n$ and $d_0d_2^{n-1}$ of the retraction, which are the single map
$X(r)$ for $t = \max(S)$, read in the standard indexing by $[n]$ at two corners whose
relabellings differ.
\end{remark}

\begin{proof}[Proof of \cref{thm A}]
If $X$ is $2k$-Segal, then $\sd X$ is lower $(2k{-}1)$-Segal by
\cref{prop forward}(1).

Conversely, suppose $\sd X$ is lower $(2k{-}1)$-Segal, and let $I \subset S$ be
gapped of cardinality $k+1$.
Since $I$ is proper, \cref{lem retract} exhibits $(\decbot X)\cube{I\subset S}$ as a
retract of the cartesian cube $(\sd X)\cube{I \subset S}$, so it is cartesian.
As $I$ and $S$ were arbitrary, $\decbot X$ is lower $(2k{-}1)$-Segal, and therefore
$X$ is lower $2k$-Segal by the path space criterion.
Applying this to $X^\op$ and using $\sd (X^\op) = \sd X$, we conclude that $X^\op$ is
lower $2k$-Segal, i.e.\ that $X$ is upper $2k$-Segal.
\end{proof}

\begin{proof}[Proof of \cref{thm B}]
If $X$ is upper $(2k{+}1)$-Segal then $\sd X$ is upper $2k$-Segal by
\cref{prop forward}(2).

Conversely, suppose $\sd X$ is upper $2k$-Segal and let $I \subset S$ be gapped of
cardinality $k+1$ with $\max(S)\notin I$.
Then $(\sd X)\cube{I \subset S}$ is cartesian, hence so is its retract
$(\decbot X)\cube{I\subset S}$ by \cref{lem retract}.
Since the condition $\max(S) \notin I$ is exactly the upper $2k$-Segal condition for
the simplicial object $\decbot X$ at $S$, we conclude that $\decbot X$ is upper
$2k$-Segal, and therefore that $X$ is upper $(2k{+}1)$-Segal by the path space
criterion.
\end{proof}

\section{Sharpness and a remaining question}

The two theorems are genuinely different conditions on $\sd X$, and neither can be
improved to a statement about the remaining two conditions at level $k$.
Take $X = \Delta^n/\partial\Delta^n$, which is $2n$-Segal but not lower
$(2n{-}1)$-Segal, and is upper $(2n{-}1)$-Segal exactly when $n$ is odd
\cite{Hackney:SdSS}.
For $n = 3$ and $k = 2$: here $X$ is upper $5$-Segal but not $4$-Segal, and
correspondingly $\sd X$ is upper $4$-Segal (\cref{thm B}) but not lower $3$-Segal
(\cref{thm A}).
A direct computation shows that $\sd X$ is in this case also not lower $4$-Segal, so
the upper condition in \cref{thm B} cannot be replaced by the lower one.

Finally, we have observed computationally that for simplicial \emph{sets} the four
conditions at level $k$ collapse to two on objects of the form $\sd X$: the cube
$\sd X$ is lower $(2k{-}1)$-Segal if and only if it is lower $2k$-Segal, and upper
$2k$-Segal if and only if it is upper $(2k{+}1)$-Segal.
By \cref{thm A,thm B} this amounts to the following.

\begin{question}
If $\sd X$ is lower $2k$-Segal, is $X$ necessarily $2k$-Segal?
If $\sd X$ is upper $(2k{+}1)$-Segal, is $X$ necessarily upper $(2k{+}1)$-Segal?
\end{question}

By the Wiggle Lemma \cite[Lemma 3.10]{from_coskel}, the first question reduces to
the single lowest-dimensional cube: if $\sd X$ is lower $2k$-Segal and additionally
satisfies $\lowod^k_{2k}$, then it is lower $(2k{-}1)$-Segal, and \cref{thm A}
applies.

\begin{thebibliography}{9}
\bibitem{BOORS:ESC} J.~Bergner, A.~Osorno, V.~Ozornova, M.~Rovelli, C.~Scheimbauer,
\emph{The edgewise subdivision criterion for $2$-Segal objects}.
\bibitem{decomp} P.~Hackney, \emph{Decomposition spaces} (this volume).
\bibitem{from_coskel} P.~Hackney, \emph{Coskeletality and the higher Segal conditions}.
\bibitem{from_hsd} P.~Hackney, J.~Lynd, \emph{Higher Segal spaces and partial groups}.
\bibitem{Hackney:SdSS} P.~Hackney, \emph{Higher Segal conditions for spheres}.
\end{thebibliography}

\end{document}
File created successfully at: ~/twisted_arrow/notes/edgewise.tex (file state is current in your context — no need to Read it back)
Thinking
$ Bash
cd ~/twisted_arrow/notes && (which pdflatex || which latexmk || echo NOLATEX) 2>&1 | head -3
/Library/TeX/texbin/pdflatex
$ Bash
pdflatex -interaction=nonstopmode -halt-on-error edgewise.tex >/tmp/tex1.log 2>&1; echo "exit=$?"; grep -E "^(!|l\.[0-9]+)" /tmp/tex1.log | head -20; grep -c "Warning" /tmp/tex1.log
exit=0
39
Thinking
$ Bash
pdflatex -interaction=nonstopmode edgewise.tex >/tmp/tex2.log 2>&1; grep -iE "undefined|multiply.defined" /tmp/tex2.log | head; ls -la edgewise.pdf; grep -E "Output written" /tmp/tex2.log
-rw-r--r--  1 user  staff  350924 Aug  1 07:07 edgewise.pdf
Output written on edgewise.pdf (6 pages, 350924 bytes).
Thinking
$ Bash
cd ~/twisted_arrow && printf '*.aux\n*.log\n*.out\n*.pdf\n' > notes/.gitignore && python3 - <<'PYEOF'
p='notes/edgewise-higher.md'; s=open(p).read()
s = s.replace("""Both conjectures below now have proofs: the forward directions by an iterated
pasting argument over the doubled cube, the converses by the Retract Lemma. What
remains is to write the pasting induction out carefully (and to double-check the
gappedness bookkeeping at the leaves).""",
"""Both conjectures below are proved, and written up in full in `notes/edgewise.tex`
(6pp, compiles): the forward directions by the Splitting Lemma (an induction over
"mixed" cubes, some of whose directions delete one element and some two), the
converses by the Retract Lemma. This markdown file is the informal companion --- see
the `.tex` for the actual statements and proofs.""")
open(p,'w').write(s)
PYEOF
git add notes/ && git commit -q -F - <<'EOF' && git log --oneline -3 && git status --short
Write up both theorems in full

notes/edgewise.tex: complete proofs of

  (A) X is 2k-Segal  <=>  sd X is lower (2k-1)-Segal
  (B) X is upper (2k+1)-Segal  <=>  sd X is upper 2k-Segal

The forward directions go through a Splitting Lemma for cubes with mixed
one- and two-element directions, which reduces the "diagonal" cube
sd X[[I]] to the 2^{k+1} sections of X[[I^pm subset D(S)]] by iterated
application of the generalized pasting law; two combinatorial lemmas then
show every section is gapped and omits an endpoint of its ambient set,
which is exactly what makes 2k the right level. The converses follow from
the Retract Lemma.

Co-Authored-By: Claude <noreply@anthropic.com>
EOF
f7033ff Write up both theorems in full
8b54b9b Prove the retract lemma, completing both converse directions
bf4b43b Add notes and code on edgewise subdivision for higher Segal conditions
?? .DS_Store

Done — notes/edgewise.tex, 6 pages, compiles clean with no undefined references. Committed as f7033ff on notes/edgewise-higher-segal.

What the write-up contains

The Splitting Lemma is the piece that was only a sketch before, and writing it out clarified it. The trick is to prove something slightly more general than needed: cubes $W(A;(B_\lambda))$ indexed by a set of directions $\Lambda$, where each direction $\lambda$ deletes a subset $B_\lambda \subseteq A$ with $1 \le |B_\lambda| \le 2$, the $B_\lambda$ pairwise disjoint. Induction on the number of two-element directions, splitting one at a time via the generalized pasting law; the base case $d=0$ is literally a higher-Segal cube $X\llbracket E \subset A\rrbracket$.

Stating it that way makes the bookkeeping evaporate: the "which partner got deleted first" asymmetry is absorbed into the definition $A_\varepsilon = A \setminus {c_\lambda : \varepsilon_\lambda = b_\lambda}$, and the inductive step is just the observation that sections of the two halves are exactly the sections of the whole with $\varepsilon_\mu$ fixed, with the same $E_\varepsilon$ and $A_\varepsilon$. No ordering choices leak into the statement.

Then two short combinatorial lemmas ($E_\varepsilon$ gapped; no leaf contains both endpoints), both resting on one observation I isolated as equation \eqref{eq mij}: for $i<j$ in $I$, the least $s \in S$ with $i<s<j$ satisfies $s \notin I$, so $s^\pm$ is never deleted. That single fact does all three cases of gappedness and the endpoint argument.

Two things I'd flag for your review

  • The $|S| \ge 2k+1$ bound is used twice (properness of $E_\varepsilon \subset A_\varepsilon$, and existence of a predecessor of $\max(S)$). It's immediate from $I$ gapped of cardinality $k+1$, but it's the kind of thing worth a second look since the lemmas would be false without it in edge cases.
  • The $k=0$ case is excluded throughout ($k \ge 1$), matching your conventions. I didn't check whether either theorem degenerates sensibly there.

I also added a short final section recording the sharpness example ($\Delta^3/\partial\Delta^3$ at $k=2$: $\operatorname{sd}X$ is upper $4$-Segal but neither lower $3$- nor lower $4$-Segal, so (B)'s "upper" can't be swapped for "lower"), and stated the leftover collapse phenomenon as a Question — with the note that the Wiggle Lemma reduces its first half to the single cube $\lowod^k_{2k}$ on $\operatorname{sd}X$. That's the obvious next thing to try if you want it closed.

notes/.gitignore covers the LaTeX aux files and the PDF. There's an untracked .DS_Store at the repo root I left alone.