\section{Introduction}

A foundational result due to Davenport--Heilbronn \cite{MR491593} provides asymptotics for
the number of real and cubic fields, when these fields are ordered by
their discriminants. Specifically, the theorem states:
\begin{theorem}[Davenport--Heilbronn]\label{thDH}
Let $N^{\pm}_{\Disc}(X)$ denote the number of cubic fields $K$, up to
isomorphism, that satisfy $|\Disc(K)|<X$ and $\pm\Disc(K)>0$. Then
\begin{equation*}
\begin{array}{rcccl}
N^{+}_{\Disc}(X)&=&\displaystyle\frac{1}{12\zeta(3)}X&+&o(X);\\[.2in]
N^{-}_{\Disc}(X)&=&\displaystyle\frac{1}{4\zeta(3)}X&+&o(X).
\end{array}
\end{equation*}
\end{theorem}

The above theorem, its extensions, and the methods of their proofs, have had a host of applications. Among many other applications, they are used by Yang \cite{MR2713725} to verify the Katz--Sarnak heuristics \cite{MR1659828} for low-lying zeroes of Dedekind zeta
functions of cubic fields; by
Bhargava--Wood \cite{MR2373587}, Belabas--Fouvry \cite{MR2740719} and Wang \cite{MR4219215} to prove Malle's conjecture for various different Galois
groups; by Martin--Pollack \cite{MR3022705} and Cho--Kim \cite{MR4211852} to obtain
the average value of the smallest prime satisfying certain prescribed
splitting conditions.

Theorem \ref{thDH} has also been generalized in numerous ways: Belabas--Bhargava--Pomerance \cite{MR2641942} prove power saving error terms; Bhargava \cite{MR2183288,MR2745272}
determines the asymptotics of quartic and quintic fields, when
ordered by discriminant; Taniguchi \cite{TTNFcubic} and Bhargava--AS--Wang \cite{global1} count cubic extensions of number fields and function fields; Belabas--Fouvry \cite{MR2740719} count subfamilies of cubic fields satisfying congruence conditions on their discriminants; Terr \cite{TerrThesis} proves that the ``shapes'' of cubic rings and fields are equidistributed (see also work of Bhargava--Harron \cite{MR3518306}, who give a uniform proof that shapes of cubic, quartic, and quintic rings and fields are equidistributed); Taniguchi--FT \cite{MR3127806} and Bhargava--AS--Tsimerman \cite{MR3090184} compute secondary terms (of size $\asymp X^{5/6}$) for the asymptotics of $N^{\pm}_{\Disc}(X)$.

In this paper, we consider generalizations along a different direction: namely, we determine asymptotics for families of
cubic fields ordered by invariants more general than the
discriminant. Let $C(K)$ be the radical of $|\Disc(K)|$. That is, we
have $C(K):=\prod_{p\mid\Disc(K)}p$. We then prove the following
result.
\begin{theorem}\label{thradical}
Let $N^\pm_C(X)$ denote the number of cubic fields $K$, up to
isomorphism, that satisfy $C(K)<X$ and $\pm\Disc(K)>0$. Then
\begin{equation*}
\begin{array}{rcl}
  N_C^+(X)&=&
  \displaystyle\frac{11}{12}\prod_{p}\Bigl(1+\frac{2}{p}\Bigr)
  \Bigl(1-\frac{1}{p}\Bigr)^2X\log X
  +o(X\log X);\\[.2in]
  N_C^-(X)&=&\displaystyle\frac{11}{4}\prod_{p}\Bigl(1+\frac{2}{p}\Bigr)
  \Bigl(1-\frac{1}{p}\Bigr)^2X\log X
  +o(X\log X).
\end{array}
\end{equation*}
\end{theorem}

The above theorem will be deduced as a special case of a more
general result that counts cubic fields ordered by various different
types of invariants.

\subsection*{Generalized discriminants of cubic fields}

Let $M$ be a Galois sextic field with Galois group $S_3$ over $\mathbb{Q}$. Then $K$ has three cubic $S_3$-subfields, which are conjugate to each other. One would therefore expect to be able to understand the family of sextic $S_3$-fields via the
family of cubic $S_3$-fields. Bhargava--Wood \cite{MR2373587} and Belabas--Fouvry \cite{MR2740719} independently use this philosophy to prove the
following result.
\begin{theorem}[Belabas--Fouvry, Bhargava--Wood]\label{thm:s3}
Let $N^\pm_{\Delta_6}(X)$ denote the number of Galois sextic number
fields $M$ with Galois group $S_3$, such that $\Disc(M)<X$ and
$\pm\Disc(M)>0$.

Then, we have
\begin{equation*}
N^\pm_{\Delta_6}(X)=\frac{C^\pm}{12}\prod_p c_p\cdot X^{1/3}+o(X^{1/3}),
\end{equation*}
where $C^+=1,C^-=3$, the product is over all primes, and
\begin{equation*}
c_p=\begin{cases}
(1-p^{-1})(1+p^{-1}+p^{-4/3}) & p\neq3,\\
(1-\frac13)(\frac43+\frac1{3^{5/3}}+\frac2{3^{7/3}})
& p=3.
\end{cases}
\end{equation*}
\end{theorem}
A power saving error term for the above quantity was obtained by work of Taniguchi--FT \cite{MR3208868}. In this work, they also speculate about a possible secondary term, and discuss tensions between theoretical predictions and the data.

Similarly to $C(K)$, we will regard $\Disc(M)$ as a ``generalized
discriminant'' of its cubic subfield. More specifically, let $K$ be a non-Galois cubic field $K$, and denote the Galois closure of $K$ by $M$. Then $M$ has a unique quadratic subfield, denoted $L$. We say that $L$ is the {\it quadratic resolvent field} of $K$. Denote the discriminant of the quadratic resolvent $L$ of $K$ by $\iD(K)$. Then
$\iD(K)\mid \Disc(K)$, and moreover, $\Disc(K)/\iD(K)$ is always a
perfect integer square. Denote its positive integer squareroot by
$\iF(K)$. We note that apart from a factor of a bounded power of $3$,
the quantity $\iF(K)$ is simply the product of primes that totally
ramify in $K$, where $p$ is said to totally ramify in $K$ if $p$ splits as $p=\mathfrak{p}^3$. For a cubic $S_3$-field $K$, let $\Delta_6(K)$ denote the
discriminant of the Galois closure $M$ of $K$.  Then
we have the decompositions
\begin{equation}\label{eq:disc_decomp}
\Disc(K) = \iD(K) \iF(K)^2,\quad \Delta_6(K)=\iD(K)^3\iF(K)^4,\quad
C(K)=\iD(K)\iF(K),
\end{equation}
where the latter two equalities are true up to bounded factors of $2$
and $3$. For positive real numbers $\alpha$ and $\beta$, we say that
the invariant $\iD^\alpha\iF^\beta$ is a {\it generalized
  discriminant}.  This notion of generalized discriminant encompasses
all three invariants we have seen so far, namely, $\Disc(K)$,
$\Delta_6(K)$, and $C(K)$.

\begin{comment}
Let $\Sigma=(\Sigma_v)_v$ denote a {\it collection of cubic local
  specifications}, where for each place $v$ of $\mathbb{Q}$, the set
$\Sigma_v$ is a nonempty subset of the set of cubic \'etale extensions
of $\mathbb{Q}_v$. The collection $\Sigma$ is said to be a {\it finite
  collection} if the following two conditions are satisfied: {\bf (1)} For all large enough primes $p$, $\Sigma_p$ is the
set of all cubic \'etale extensions of $\mathbb{Q}_p$, and {\bf (2)} If for some $p$, a totally ramified (resp.\ partially ramified) extension belongs to $\Sigma_p$, then all totally ramified (resp.\ partially ramified) extensions belong to $\Sigma_p$. We will also call $\Sigma$
a collection of cubic {\it splitting types} if, for each $p$ and allowable collection
of inertial degrees and ramification indices, $\Sigma_p$ contains either all or none of
the corresponding cubic \'etale extensions.
\end{comment}

Let $\Sigma=(\Sigma_v)_v$ be a {\it collection of cubic
  splitting types}, where for each place $v$ of $\mathbb{Q}$, the set
$\Sigma_v$ is the set of cubic \'etale extensions
of $\mathbb{Q}_v$ with specified inertial and ramification indices.
The collection $\Sigma$ is said to be a {\it finite
collection} if for all large enough primes $p$, $\Sigma_p$ is the
set of all cubic \'etale extensions of $\mathbb{Q}_p$ (i.e., all inertial and ramification indices are allowed).
Throughout, we write $P_\Sigma$ for the product of those primes
where $\Sigma_p$ is a proper subset of these extensions.

Given a finite
collection of cubic splitting types $\Sigma$, let $\mathcal{F}(\Sigma)$
denote the set of cubic fields $K$ such that $K\otimes\mathbb{Q}_v\in\Sigma_v$
for all $v$. For a generalized discriminant $I$, we define
\begin{equation*}
N_{I}(\Sigma;X):=\#\{K\in\mathcal{F}(\Sigma):I(K)<X\}.
\end{equation*}
The next result determines asymptotics for the family
$\mathcal{F}(\Sigma)$ ordered by generalized discriminants.

\begin{theorem}\label{thGD}
Fix positive real numbers $\alpha$ and $\beta$, and let
$I=\iD^\alpha\iF^\beta$ be a generalized discriminant. Let $\Sigma$ be
a finite collection of cubic splitting types. Then
\begin{itemize}
\item[{\rm (a)}] When $\alpha<\beta$, we have
\begin{equation*}
N_I(\Sigma;X) = \frac12\Bigl(\sum_{K\in\Sigma_\infty}\frac{1}{|\Aut(K)|}\Bigr)
\prod_p\Bigl(\sum_{K\in\Sigma_p}\frac{|\iD(K)|_p|\iF(K)|_p^{\beta/\alpha}}{|\Aut(K)|}\Bigr)
\Bigl(1-\frac1{p}\Bigr)
\cdot X^{\frac{1}{\alpha}}
+O_\epsilon\big( (X^{\frac{2}{\alpha+\beta}+\epsilon}+X^{\frac{5}{6\alpha}}) P_\Sigma^{2/3} \big).
\end{equation*}
\item[{\rm (b)}] When $\alpha>\beta$, we have
\begin{equation*}
N_I(\Sigma;X)=
\Bigl(\sum_{d\,{\rm fund.}\,{\rm disc}}\frac{\Res_{s=1}\Phi_{\Sigma,d}(s)}{|d|^{\alpha/\beta}}
\Bigr)\cdot X^{\frac{1}{\beta}}+O\big((X^{\frac{3}{2\alpha+\beta}+\epsilon}+X^{\frac{2}{3\beta}+\epsilon}) P_\Sigma^{1/3} \big),
\end{equation*}
where $\Phi_{\Sigma,d}(s)$ are Dirichlet series introduced in \S2.
\item[{\rm (c)}] When $\alpha=\beta$, we have
\begin{equation*}
N_I(\Sigma;X)=
\frac1{2\alpha} \Bigl(\sum_{K\in\Sigma_\infty}\frac{1}{|\Aut(K)|}\Bigr)
\prod_{p}\Bigl(\sum_{K\in\Sigma_p}
\frac{|\iD(K)|_p|\iF(K)|_p}{|\Aut(K)|}\Bigr)\Bigl(1-\frac1{p}\Bigr)^2
\cdot X^{\frac{1}{\alpha}}\log X+o_\Sigma(X^{\frac1{\alpha}}\log X).
\end{equation*}
\end{itemize}
\end{theorem}

We recover Theorem \ref{thm:s3}, with a power saving error term of
$O(X^{\frac{2}{7} + \epsilon})$, by taking $\alpha = 3$ and $\beta =
4$ and carrying out an appropriate calculation at the $2$- and
$3$-adic places.  (This was also noted in \cite{BTT}.) When
$\frac{\beta}{\alpha} > \frac{7}{5}$, the error term of
$O(X^{\frac{5}{6\alpha}})$ in case (1) dominates the other error term
and can be refined into a secondary term extrapolating that proved in
\cite{MR3090184,MR3127806} for $\alpha = 1$ and $\beta = 2$. More precisely, we have the following result.

\begin{theorem}\label{thm:secterm}
Let $\alpha$ and $\beta$ be positive real numbers with $\frac{\beta}{\alpha} > \frac{7}{5}$, and let $I=\iD^\alpha\iF^\beta$. Then we have
\begin{equation*}
N_I(\Sigma;X) = C_1(I;\Sigma)\cdot X^{\frac{1}{\alpha}}
+C_{\frac{5}{6}}(I;\Sigma)\cdot X^{\frac{5}{6\alpha}}
+O_\epsilon\big( (X^{\frac{2}{\alpha+\beta}+\epsilon}+X^{\frac{2}{3\alpha}+\epsilon}) P_\Sigma^{2/3} \big),
\end{equation*}
where $C_1(I;\Sigma)$ is the leading constant appearing in the right hand side of the displayed equation in Part (a) of the above theorem, and
\begin{equation*}
C_{\frac{5}{6}}(I;\Sigma)=C\frac{\zeta(\frac23)\Gamma(\frac13)(2\pi)^{\frac13}}{10\zeta(2)\Gamma(\frac{2}{3})}
\prod_{p}\Bigl[\Bigl(\sum_{\substack{K_p\in\Sigma_p}}
\frac{|\iD(K_p)|_p|\iF(K_p)|_p^{(5\beta-2\alpha)/(6\alpha)}}{|\Aut(K_p)|}\Bigr)\Bigl(1-\frac1{p^{\frac13}}\Bigr)\int_{(\mathcal{O}_{K_p}/\mathbb{Z}_p)^{\rm{prim}}}i(x)^{2/3}dx\Bigr],
\end{equation*}
where $C$ is $1$, $1/\sqrt{3}$ or $1+1/\sqrt{3}$
depending on whether $\Sigma_\infty$ consists of $\mathbb{R}^3$, $\mathbb{R}\oplus\mathbb{C}$ or both, respectively.
\end{theorem}

\subsection*{The Malle--Bhargava heuristics}

In \cite{MR1884706,MR2068887}, Malle develops heuristics for asymptotics of the number of degree-$n$ number fields with Galois group $G$ and bounded discriminant, where $n>1$ is any integer and $G$ is a finite group with an action on a set with $n$ elements. These heuristics are believed to be true in most cases. However, see \cite{MR2135320} where Kl\"{u}ners demonstrates a counter example in the case $n=3$ and $G=C_3\wr C_2$, and \cite{MR3349443}, where T\"{u}rkelli modifies Malle's conjecture so that it holds in the above and similar cases. While Malle's conjecture has been formulated only for families of fields ordered by discriminant, the same method applies to other orderings, in particular to the generalized discriminants that we work with.

Interestingly, the leading constants appearing in front of Malle's heuristics are still shrouded with mystery. In the case of degree-$n$ $S_n$ number fields ordered by discriminant, Bhargava \cite{MR2354798} formulates a conjecture for the leading coefficients, using a general recipe which constructs these constants from mass formulae counting \'etale extensions of local fields. Once again, this recipe is quite general, applying to any family of number fields ordered by analogous generalized discriminants. However, there are many instances where this prediction gives the incorrect leading constant. The prototypical example is the family of quartic $D_4$-fields ordered by discriminant, where the asymptotic constant determined by Cohen--Diaz y Diaz--Olivier \cite{MR1918290} does not equal the constant that this recipe would predict, even up to any rational multiple. On the other hand, when quartic $D_4$-fields are ordered by conductor, Altu\u{g}--AS--Varma--Wilson \cite{D4preprint} establish that the leading asymptotic constant does arise from the Malle--Bhargava recipe. This leads to the natural question of which families of number fields ordered by which invariants satisfy this property.

A necessary condition is that the splitting behaviour of primes is independent. We now precisely define this notion. Let $\mathcal{G}$ be a family of number fields having the same degree
$n$.\footnote{It is not entirely clear exactly what constitutes a {\it
    family} of number fields. Being the set of all number fields
  having the same degree and the same Galois group is assumed to be a
  sufficient though not a necessary condition. See \cite{MR3675175}, where a similar question is discussed in detail.} Let $\Sigma=(\Sigma_v)_v$ be a {\it
  collection of degree-$n$ splitting types}, where for each place $v$ of $\mathbb{Q}$,
$\Sigma_v$ is the set of degree-$n$ \'etale extensions of $\mathbb{Q}_v$ satisfying specified inertial and ramification behaviour. For
each place $v$, let $\Sigma_v^{\rm{all}}$ denote the set of all degree-$n$
\'etale extensions of $\mathbb{Q}_v$. Then $\Sigma$ is said to be {\it finite}
if $\Sigma_p=\Sigma_p^{\rm{all}}$ for all sufficiently large primes $p$.
Let $h:\mathcal{G}\to\mathbb{R}_{>0}$ be a height function (i.e., there are only
finitely many elements of $\mathcal{G}$ having bounded height). Let
$N_{h}(\mathcal{G}_\Sigma;X)$ denote the number of elements in $\mathcal{G}$ satisfying $\Sigma$ and
having height less than $X$. Then we say that the family $\mathcal{G}$ ordered
by $h$ satisfies {\it independence of primes} if the following is
true. For all places $v$ of $\mathbb{Q}$, there exist functions
$\sigma_v:\Sigma_v^{\rm{all}}\to\mathbb{R}_{\geq 0}$ with
\begin{equation*}
\sum_{K_v\in\Sigma_v^{\rm{all}}}\sigma_v(K_v)=1,
\end{equation*}
such that the following condition is satisfied. For each finite
collection of splitting type $\Sigma$, we have
\begin{equation*}
N_{h}(\mathcal{G}_\Sigma;X)\sim \Bigl(\prod_{v}\sum_{K_v\in\Sigma_v}
\sigma_v(K_v)\Bigr)\cdot N_{h}(\mathcal{G};X).
\end{equation*}
There are many known examples of families of number fields which do not satisfy independence of primes. See for example \cite{MR2581243}, in which Wood studies families of number fields with any fixed abelian Galois group, and proves in many cases that, when ordered by discriminant, these families do not satisfy independence of primes.

For the family of all cubic fields ordered by generalized
discriminants, we have the following result.
\begin{theorem}\label{thIndPr}
Let $I=\iD^\alpha\iF^\beta$ be a generalized discriminant. Then the family of all cubic fields
ordered by $I$ satisfies independence of primes and the Malle--Bhargava heuristic if and only if $\alpha\leq \beta$.
\end{theorem}

The ``if'' part of the above result follows immediately from the shape
of the leading asymptotics in Parts (a) and (c) of Theorem \ref{thGD}. The ``only if'' part requires more work since the residues of the Dirichlet series appearing in Part (b) of Theorem \ref{thGD} are not explicit. We give a general proof which also applies to many different situations, such as the family of quartic $D_4$-fields ordered by discriminant.

Finally, we note that our counting results also have implications towards families of Artin $L$-functions associated to cubic $S_3$-fields. Let $\rho:S_3\to\GL_n(\mathbb{C})$ be any representation of $S_3$. Given a cubic $S_3$-field $K$, with normal closure $M$, we obtain a Galois representation
\begin{equation*}
\Gal(\overline{\mathbb{Q}}/\mathbb{Q})\to\Gal(M/\mathbb{Q})\cong S_3\to\GL_n(\mathbb{C}),
\end{equation*}
where the final map is $\rho$. We associate to this Galois representation its Artin $L$-function, denoted $L(s;\rho,K)$. Throughout, we assume that $\rho$ contains at least one copy of the standard representation of $S_3$, which is necessary to ensure that different cubic fields give rise to different $L$-functions. Then, given a family of cubic $\mathcal{F}(\Sigma)$ of cubic $S_3$-fields $K$, we obtain a family of Artin $L$-functions $L(s;\rho,K)$ that we denote by ${\mathcal L}(\rho,\Sigma)$. We order the $L$-functions in ${\mathcal L}(\rho,\Sigma)$ by their conductors.

Ordering ${\mathcal L}(\rho,\Sigma)$ by conductor corresponds to ordering $\mathcal{F}(\Sigma)$ by a certain generalized discriminant $I=\iD^\alpha\iF^\beta$ depending on $\rho$. Indeed, we have
$(\alpha, \beta) = c_1(1, 2) + c_2(1, 0)$ where $c_1 \geq 1$ and $c_2 \geq 0$ are the multiplicities of
the standard and sign representations respectively, so that $\alpha > 0$ and $\beta > 0$.
A consequence of Theorem \ref{thGD} is that the family ${\mathcal L}(\rho,\Sigma)$ satisfies Sato--Tate equidistribution in the sence of \cite[Conjecture 1]{MR3675175}. Loosely speaking, a family of $L$-functions arising from number fields satisfies Sato--Tate equidistribution when the asymptotics of these number fields, ordered by the conductors of their $L$-functions, satisfy the Malle-Bhargava heuristics on average over primes $p$. Identically to the arguments in \cite[\S3.1]{MR3993807}, when $\alpha\leq\beta$, this follows immediately from the shape of the leading constant in Parts (a) and (c) of Theorem \ref{thGD}. When $\alpha>\beta$ the situation is similar to the case of the family of Dedekind zeta functions of $D_4$-fields considered in \cite[\S6.2]{MR3993807}. As there, we consider the family of cubic fields ordered by $I$ to be a countable union of subfamilies, one for each fixed quadratic resolvent field. Since each of these subfamilies contributes a positive proportion to the full family, Sato--Tate equidistribution for the full family follows from Sato--Tate equidistribution for each subfamily. Thus, we have the following consequence to Theorem \ref{thGD}:
\begin{corollary}
With notation as above, the families ${\mathcal L}(\rho,\Sigma)$ satisfy Sato--Tate equidistribution.
\end{corollary}
It is interesting to note that despite independence of primes not always holding, Sato--Tate equidistribution is always satisfied for our families.

\subsection*{Organization of the paper}
We begin in \S2 by considering families of cubic fields with one fixed invariant. Invoking work of Bhargava--Taniguchi--FT \cite{BTT} on the Davenport-Heilbronn theorem, we obtain asymptotics for families of cubic fields with fixed $\iF$; using work of Cohen--Morra \cite{CM} and Cohen--FT \cite{CT} on a Kummer-theoretic approach, we deduce asymptotics for families of cubic fields with fixed $\iD$. The leading constants appearing in the asymptotics for the latter family are somewhat inexplicit, but in \S3 we prove that the average values of these constants have an explicit description given in terms of products of mass formulae.

The results of the previous two subsections allow us to determine asymptotics for $\mathcal{F}(\Sigma)$ ordered by generalized discriminants. This is accomplished in \S4, and we extract secondary terms and power saving error terms when possible. Finally, we establish exactly when independence of primes holds, thereby proving Theorem \ref{thIndPr}.

Throughout, implied constants may
depend on $\epsilon$, $\alpha$, and $\beta$, but not $\Sigma$ unless otherwise noted.

\begin{comment}
Finally, in \S5, we study our families of Artin $L$-functions. The generalized setup of AS--S\"{o}dergren--Templier \cite{MR3993807} allows us to deduce Sato--Tate equidistribution for families when independence of primes holds for invididual primes. For the remaining families, we use in addition the version of effective Chebotarev proved by ???.
\end{comment}

\section{Families of cubic fields with a fixed invariant}

Recall that for each cubic field or \'etale algebra $K/\mathbb{Q}$
or $K/\mathbb{Q}_p$, we have a decomposition
\begin{equation}\label{eq:disc_decomp_repeat}
\Disc(K) = \iD(K)\iF(K)^2,
\end{equation}
where $\iD(K)$ is the discriminant of the {\itshape quadratic
  resolvent} algebra of $K$. When $K$ is a $S_3$-cubic field
  $\iD(K)$ is the discriminant of the unique quadratic field contained in the
Galois closure of $K$, and when $K$ is a cyclic cubic field $\iD(K) = 1$.
We decompose these quantities into local factors
\begin{equation}
  \Disc(K) = \prod_p \Disc_p(K),\quad \iD(K) = \prod_{p} \iD_p(K),
  \quad \iF(K) = \prod_p \iF_p(K),
\end{equation}
with $\iD_p(K) = p^{v_p(\iD(K))}$ and $\iF_p(K) = p^{v_p(\iF(K))}$.
Then these quantities enjoy the following properties:
\begin{itemize}
\item[{\rm (a)}] When $p > 3$, then
\[
(d_p, f_p)
\in \{ (1, 1), (p, 1), (1, p) \},
\]
with the three cases corresponding to
the ramification type of $p$ in $K$:
unramified, partially ramified, or totally ramified,
respectively.
\item[{\rm (b)}] When $p = 3$, we have
\[
(d_3, f_3) \in \{ (1, 1), (p, 1), (p, p), (1, p^2), (p, p^2) \}.
\]
Here $p$ is unramified in the first case, partially ramified in the second case,
and totally ramified in the remaining cases.
\item[{\rm (c)}] When $p = 2$, we have
\[
(d_2, f_2) \in \{ (1, 1), (p^2, 1), (p^3, 1), (1, p) \}.
\]
Here $p$ is unramified in the first case, partially ramified in the
next two cases, and totally ramified in the last case.
\end{itemize}

Given a positive number $f$, squarefree away from $3$, and indivisible by $27$, we let $\mathcal{F}(\Sigma)^{(f)}$ denote the set of cubic $S_3$-fields $K\in\mathcal{F}(\Sigma)$ with $\iF(K)=f$. Given a fundamental discriminant $d$, we let $\mathcal{F}(\Sigma)_d$ denote the set of cubic $S_3$-fields $K\in\mathcal{F}(\Sigma)$ with $\iD(K)=d$.
In this section, we obtain asymptotics for the number of $K\in\mathcal{F}(\Sigma)^{(f)}$ with $\iD(K)<Y$ in \S2.2, and the number of $K\in\mathcal{F}(\Sigma)_{d}$ with $\iF(K)<Z$ in \S2.3. In particular, we obtain error terms that control the dependence on $\Sigma$.

\subsection{Counting cubic fields $K$ with fixed $\iF(K)$}

Let $f$ be a fixed positive integer, squarefree away from $3$. To count cubic
fields $K$ where $\iF(K)$ is fixed, we appeal to a strengthening of the
Davenport-Heilbronn theorem.
Define the quantity
\[
N(\mathcal{F}(\Sigma)^{(f)};Y) :=  \#\{ K\in\mathcal{F}(\Sigma)^{(f)} :  \iD(K) < Y\}.
\]
Then we have the following:
\begin{theorem}[\cite{BTT}]\label{thm:dh}
We have
\begin{equation}\label{eq:dh}
N(\mathcal{F}(\Sigma)^{(f)};Y) =  C_1(\Sigma, f) \cdot Y
+ C_2(\Sigma,f)\cdot Y^{5/6} + O\big(E(Y; f,\Sigma)\big),
\end{equation}
for constants $C_1(\Sigma,f)$ and $C_2(\Sigma,f)$ described below, and with the following
`averaged' bound on $E(Y; f, \Sigma)$: for each $f \leq F$,
choose independent and arbitrary values $Y_f \leq Y$. Then, we
have
\[
\sum_{f \leq F} E(Y_f; f, \Sigma) \ll_\epsilon Y^{2/3 + \epsilon} F^{4/3} P_\Sigma^{2/3},
\]
uniformly in $F$.
\end{theorem}
The leading constant $C_1(\Sigma, f)$ is described as follows. First, for a
prime $p$ and a positive integer $f$, define the set $\Sigma_p(f)$ of
{\it $f$-compatible algebras in $\Sigma_p$} to be those \'etale cubic
extensions $K_p$ of $\mathbb{Q}_p$ such that the powers of $p$ dividing
$\iF(K_p)$ and $f$ are the same. Then we have
\[
C_1(\Sigma, f) := \frac12\Bigl(\sum_{K_\infty\in\Sigma_\infty}
\frac{1}{|\Aut(K_\infty)|}\Bigr)
\prod_{p}\Bigl[\Bigl(\sum_{\substack{K_p\in\Sigma_p(f)}}
\frac{|\iD(K_p)|_p}{|\Aut(K_p)|}\Bigr)\Bigl(1-\frac1{p}\Bigr)\Bigr].
\]
For prime $p>3$, when $\Sigma_p=\Sigma_p^{\rm{all}}$, we have
\begin{equation}\label{eq:shapeC1}
\Bigl(\sum_{\substack{K_p\in\Sigma_p(f)}}
\frac{|\iD(K_p)|_p}{|\Aut(K_p)|}\Bigr)\Bigl(1-\frac1{p}\Bigr)=
\left\{
\begin{array}{rcl}
\Bigl(1-\frac{1}{p}\Bigr)&\mbox{when}& p\mid f;\\[.2in]
\Bigl(1-\frac{1}{p^2}\Bigr)&\mbox{when}& p\nmid f.
\end{array}\right.
\end{equation}
Meanwhile, the secondary constant $C_2(\Sigma,f)$ is given by
\[
C_2(\Sigma, f) := C(\infty)\frac{\zeta(\frac23)\Gamma(\frac13)(2\pi)^{\frac13}}{10\zeta(2)\Gamma(\frac{2}{3})}f^{-\frac13}
\prod_{p}\Bigl[\Bigl(\sum_{\substack{K_p\in\Sigma_p(f)}}
\frac{|\iD(K_p)|_p}{|\Aut(K_p)|}\Bigr)\Bigl(1-\frac1{p^{\frac13}}\Bigr)\int_{(\mathcal{O}_{K_p}/\mathbb{Z}_p)^{\rm{prim}}}i(x)^{2/3}dx\Bigr],
\]
where $C(\infty)$ is $1$, $1/\sqrt{3}$, or $1+1/\sqrt{3}$ depending on whether $\Sigma_\infty$ consists of $\mathbb{R}^3$, $\mathbb{R}\oplus\mathbb{C}$, or both, respectively, and $i(x)$ denotes the index of $\mathbb{Z}_p[x]$ in $\mathcal{O}_{K_p}$.
Moreover we have $C(\Sigma, f) < 1$ and $|C'(\Sigma, f)| < 1$ for all $\Sigma$ and~$f$.

To compute average values of these constants, we introduce the Dirichlet series $L_1(\Sigma, s)$ and $L_2(\Sigma, s)$ given by
\begin{equation}\label{eq:constantL}
L_1(\Sigma, s):=\sum_{f}C_1(\Sigma,f)f^{-s};
\quad
L_2(\Sigma, s):=\sum_{f}C_2(\Sigma,f)f^{-s};
\end{equation}
These series satisfy the following Euler product decomposition in their domains of absolute convergence.
\begin{proposition}\label{prop:L12Euler}
For $\Re(s)>1$, we have
\begin{equation*}
\begin{array}{rcl}
L_1(\Sigma, s)&=&\displaystyle
\frac12\Bigl(\sum_{K\in\Sigma_\infty}\frac{1}{|\Aut(K)|}\Bigr)\prod_{p}\Bigl(\sum_{K\in\Sigma_p}
\frac{|\iD(K)|_p|\iF(K)|_p^s}{|\Aut(K)|}\Bigr)\Bigl(1-\frac1{p}\Bigr);
\\[.2in]
L_2(\Sigma, s+1/3)&=&\displaystyle
C\frac{\zeta(\frac23)\Gamma(\frac13)(2\pi)^{\frac13}}{10\zeta(2)\Gamma(\frac{2}{3})}
\prod_{p}\Bigl[\Bigl(\sum_{\substack{K\in\Sigma_p}}
\frac{|\iD(K)|_p|\iF(K)|_p^s}{|\Aut(K)|}\Bigr)\Bigl(1-\frac1{p^{\frac13}}\Bigr)\int_{(\mathcal{O}_{K_p}/\mathbb{Z}_p)^{\rm{prim}}}i(x)^{2/3}dx\Bigr].
\end{array}
\end{equation*}
\end{proposition}
\begin{proof}
To prove the first equality in the above displayed notation, note that we have
\begin{equation} \label{eqLs}
\begin{array}{rcl}
\displaystyle L_1(\Sigma, s)
&=&\displaystyle\sum_{f\geq 1}\frac{C_1(\Sigma,f)}{f^{s}}
\\[.2in]&=&
\displaystyle
\Big(\sum_{K\in\Sigma_\infty}\frac{1}{|\Aut(K)|}\Big)\sum_{f\geq 1}\frac{1}{f^s}
\prod_p\Bigl(\sum_{K\in\Sigma_p(f)}
\frac{|\iD(K)|_p}{|\Aut(K)|}\Bigr)\Bigl(1-\frac1{p}\Bigr)
\\[.2in]&=&\displaystyle
\Big(\sum_{K\in\Sigma_\infty}\frac{1}{|\Aut(K)|}\Big)\prod_{p}\Bigl(\sum_{K\in\Sigma_p}
\frac{|\iD(K)|_p|\iF(K)|_p^s}{|\Aut(K)|}\Bigr)\Bigl(1-\frac1{p}\Bigr),
\end{array}
\end{equation}
as necessary. The second equality follows in identical fashion.
\end{proof}

\subsection{Counting cubic fields $K$ with fixed $\iD(K)$}\label{sec:small_d}
For each nonzero fundamental discriminant $d$, define a Dirichlet series
\[
\Phi_{\Sigma,d}(s) :=
\sum_{K\in\mathcal{F}(\Sigma)_d}\frac{1}{f(K)^s}.
\]

Using Kummer theory and class field theory, Cohen, Morra, and the
second author \cite{CM, CT} proved the following explicit formula for
$\Phi_{\Sigma, d}(s)$ when $P_\Sigma = 1$, i.e.~for counting all cubic fields
whose quadratic resolvent is $\mathbb{Q}(\sqrt{d})$.

\begin{theorem}[\cite{CT}, Theorem 2.5]\label{thm:cm_explicit}
For any nonzero fundamental discriminant $d$ we
have
\begin{equation}\label{eqn_main_cubic}
c_d\Phi_d(s)=\dfrac{1}{2}M_{1, d}(s) \prod_p
\left(1+\dfrac{1+\bigl(\frac{-3d}{p}\bigr)}{p^s}\right)
+\sum_{E\in{\mathcal L}_3(d)}M_{2,E}(s)\prod_{p \neq
  3}\left(1+\dfrac{\omega_E(p)}{p^s}\right)\;,\end{equation} where:
\begin{itemize}
\item $c_d=1$ if $d = 1$ or $d < -3$, and $c_d=3$ if $d = -3$ or $d > 1$.
\item ${\mathcal L}_3(d)$ is equal to the set of cubic fields of discriminant
  $-d/3$, $-3d$, and $-27d$.  (The first case can of course only occur
  if $3 \mid d$, and the second only if $3 \nmid d$.)
\item For any cubic field $F$ and prime $p\nmid\Disc(F)$,
  we define
\begin{equation*
\omega_E(p):=\begin{cases}
2&\text{\quad if $p$ is totally split in $E$,}\\
0&\text{\quad if $p$ is partially split in $E$,}\\
-1&\text{\quad if $p$ is inert in $E$,}
\end{cases}
\end{equation*}

\item
The $3$-Euler factors $M_{1, d}(s)$ and $M_{2,E}(s)$ are given in
the following table.
\end{itemize}
\end{theorem}

\bigskip

\centerline{
\begin{tabular}{|c||c|c|c|}
\hline
Condition on $d$ & $M_{1, d}(s)$ & $M_{2,E}(s),\ \Disc(E) \in \{ -d/3, -3d \}$ & $M_{2,E}(s),\ \Disc(E) = -27d$\\
\hline\hline
$3\nmid d$       & $1+2/3^{2s}$ & $1+2/3^{2s}$        & $1-1/3^{2s}$\\
\hline
$d\equiv3\pmod9$ & $1+2/3^s$    & $1+2/3^s$           & $1-1/3^s$\\
\hline
$d\equiv6\pmod9$ & $1+2/3^s+6/3^{2s}$ & $1+2/3^s+3\omega_E(3)/3^{2s}$ & $1-1/3^s$\\
\hline
\end{tabular}}

\medskip
We will use this result, together with standard analytic techniques,
to count cubic fields $K$ with fixed $D(K)$ and varying $F(K)$. Such a result
was given as \cite[Proposition 6.3]{CM} and we give a version where the dependence
of the error term on $D(K)$ is specified.

We also extend these results to $P_\Sigma > 1$, counting cubic fields with specified splitting types.
The key result is where $\Sigma_p = \mathbb{Q}_p^3$ for each $p \mid P_\Sigma$, corresponding
to a demand that each such $p$ split completely in each cubic field being counted.
Write ${\mathcal L}_3(P_\Sigma, d)$ for the set of cubic fields whose
discriminant is $-k^2d/3$, $-3k^2d$, or $-27k^2d$, where $k$ is any
squarefree positive integer whose prime factors all divide $P_\Sigma$. Thus the quadratic
resolvent of every field in ${\mathcal L}_3(P_\Sigma, d)$ is $\mathbb{Q}(\sqrt{d})$.

\begin{theorem}\label{thm:cm_explicit_lc}
With $\Sigma_p = \mathbb{Q}_p^3$ for each $p \mid P_\Sigma$ and ${\mathcal L}_3(P_\Sigma, d)$ defined as above, we have
\begin{equation}\label{eqn_main_cubic_lc}
c_d 3^{\omega(P_\Sigma)} \Phi_{\Sigma, d}(s)=\dfrac{1}{2}M_{1, d}(s) \prod_{p \nmid P_\Sigma} \left(1+\dfrac{1+\bigl(\frac{-3d}{p}\bigr)}{p^s}\right)
+\sum_{E\in{\mathcal L}_3(P_\Sigma, d)}M_{2,E}(s)\prod_{\substack{p \neq 3 \\ p \not \in S}}\left(1+\dfrac{\omega_E(p)}{p^s}\right)\end{equation}
provided that $\big( \frac{d}{p} \big) = 1$ for every prime $p \mid P_\Sigma$, and $\Phi_{\Sigma, d}(s) = 0$ otherwise.
\end{theorem}

The special cases $3 \mid P_\Sigma$ and/or $d \in \{ 1, -3 \}$ are all allowed; if $d = 1$ then $ \Phi_{\Sigma, d}(s)$ counts
cyclic cubic fields, and if $d = -3$ then the fields in ${\mathcal L}_3(P_\Sigma, d)$ are cyclic.

\begin{remark}
As a double check on our work we verified \eqref{eqn_main_cubic_lc} numerically using PARI/GP \cite{pari} and a list of cubic fields obtained from {\upshape \url{lmfdb.org}} \cite{LMFDB};
as of publication, our source code and data may be downloaded from the second author's website at {\upshape \url{thornef.github.io}}.
\end{remark}

To handle other splitting types one proceeds as follows:

\begin{itemize}
\item
$(21)$ -- A prime $p$ is partially split in $K$ if and only if it is unramified in $K$ and inert in $\mathbb{Q}(\sqrt{d})$. Therefore,
if $\big( \frac{d}{p} \big) = 1$ for any such prime $p$ then $\Phi_{\Sigma, d}(s) = 0$, and
otherwise we eliminate all of the $p$-Euler factors from $\Phi_{\Sigma, d}(s)$.
\item
$(1^2 1)$ -- A prime $p$ is partially ramified in $K$ if and only if it is ramified in $Q(\sqrt{d})$; therefore,
$\Phi_{\Sigma, d} = 0$ if $p \nmid d$ for any such $p$, and otherwise $\Phi_{\Sigma, d}(s)$ is unchanged.
\item
$(1^3)$ -- A prime $p$ is totally ramified in $K$ if and only if $p \mid f(K)$. Accordingly we remove the constant terms
from the $p$-Euler factors.
\item
The remaining primes $p$ are required to have splitting types $(111)$ or $(3)$. We handle the $(111)$ case by applying \eqref{eqn_main_cubic_lc} directly,
and the $(3)$ case by inclusion-exclusion.
\end{itemize}

In summary, the proof of Theorem \ref{thm:cm_explicit_lc} follows from a careful reading of \cite{CM} and \cite{CT}. The proof in \cite{CM} proceeds by setting $L = \mathbb{Q}(\sqrt{d}, \sqrt{-3})$, and
enumerating those cyclic cubic extensions $N_z/L$ which contain an appropriate $K$. By Kummer theory, any such extension is of the form
$N_z = L(\sqrt[3]{\alpha})$. Writing $\alpha\mathbb{Z}_L = \mathfrak{a}_0 \mathfrak{a}_1^2 \mathfrak{q}^3$ for squarefree integral coprime ideals $\mathfrak{a}_0$ and $\mathfrak{a}_1$,
the conductor $\mathfrak{f}(N/\mathbb{Q}(\sqrt{d}))$ is given (see \cite[Theorem 3.7]{CM}) by $\mathfrak{a}_0 \mathfrak{a}_1$ times a $3$-adic factor, and this $3$-adic factor
depends on the solubility of $x^3 - \alpha$ modulo powers of $3$.

The splitting conditions in $K/\mathbb{Q}$ are equivalent to solubility in $L$ of $x^3 - \alpha$ modulo $P_\Sigma$, or modulo $3P_\Sigma$ if $3 \mid P_\Sigma$, and hence the existing machinery of \cite{CM}
is well suited to select for them. This is the reason that Theorem \ref{thm:cm_explicit_lc} has a very similar shape to Theorem \ref{thm:cm_explicit}.

\medskip
We now proceed to explain the proof of  Theorem \ref{thm:cm_explicit_lc} in more detail.
As discussed above we may assume that $\big( \frac{d}{p} \big) = 1$ for every $p \mid P_\Sigma$, as
otherwise $\Phi_{\Sigma, d}(s) = 0$. Write $\mathcal{P} = P_\Sigma$ if $3 \nmid P_\Sigma$, and
$\mathcal{P} = 3P_\Sigma$ if $3 \mid P_\Sigma$.

\medskip
{\bf Step 1 -- Parametrization}.
Let $L = \mathbb{Q}(\sqrt{d}, \sqrt{-3})$ as before.
In \cite[Proposition 2.7]{CM}, Cohen and Morra enumerate the set of cubic fields $K$ with resolvent $\mathbb{Q}(\sqrt{d})$; each occurs
as the cubic subextension (unique up to isomorphism) of a field $N_z = L(\sqrt[3]{\alpha})$ with $\alpha = \alpha_0 u$, where $\alpha_0$ is determined
by the class in $I/I^3$ of the ideal $(\alpha)$, and $u$ represents an element
$\overline{u}$ of a $3$-Selmer group $S_3(L)[T]$. The notation $[T]$ indicates that $\overline{u}$ is annihilated by two particular elements of
$\mathbb{F}_3[\Gal(L/\mathbb{Q})]$ (one if $d = 1$ or $d = -3$).

A prime $p$ splits in such a $K$ if and only if: (1) it splits in $\mathbb{Q}(\sqrt{d})$, and
(2) every prime $\mathfrak{p}_z$ of $L$ above $p$ splits completely in $N_z$.
Since $L$ contains the third roots of unity,
each such $\mathfrak{p}_z$ of $L$ splits completely in $N_z$ if and only if $x^3 = \alpha$ is soluble in the completion of $L$ at $\mathfrak{p}_z$. By Hensel's
lemma, if $3 \nmid \mathfrak{p}_z$ this happens if and only if $x^3/\alpha \equiv 1 \pmod{ {}^\ast \mathfrak{p}_z}$ is soluble in $L$. Further, if $\alpha$ is coprime
to $3$, the primes
above $3$ split in $N_z/L$ if and only if $x^3/\alpha \equiv 1$ is soluble modulo $9$; to see this, note that if $v_3(\beta^3 - \alpha) > \frac{3}{2}$ with
$\alpha, \beta$ integral, then $v_3((\beta')^3 - \alpha) > v_3(\beta^3 - \alpha)$ with $\beta' := \beta - \frac{\beta^3 - \alpha}{3 \beta^2}$, yielding
a sequence of $\beta_i$ converging to a solution of $x^3 = \alpha$ in each $3$-adic completion of $L$.

\smallskip
{\bf Step 2 -- Conductors and Selmer group counting.}
In \cite[Theorem 3.7]{CM}, a formula is given for the conductor $\mathfrak{f}(N/\mathbb{Q}(\sqrt{d}))$. One writes $\alpha \mathbb{Z}_L = \mathfrak{a}_0 \mathfrak{a}_1^2 \mathfrak{q}^3$ where $\mathfrak{a}_0$ and $\mathfrak{a}_1$ are integral
coprime squarefree ideals, has $\mathfrak{a}_0 \mathfrak{a}_1 = \mathfrak{a}_{\alpha} \mathbb{Z}_L$ for an ideal $\mathfrak{a}_{\alpha}$ of $\mathbb{Q}(\sqrt{d})$, and has that $\mathfrak{f}(N/\mathbb{Q}(\sqrt{d}))$ is the product of $\mathfrak{a}_\alpha$
times a complicated $3$-adic factor, depending on the solubility of $x^3/\alpha \equiv 1 \pmod{ {}^* \mathfrak{p}_z^n }$ for ideals $\mathfrak{p}_z$ over $3$. They enumerate these
$3$-adic factors by inclusion-exclusion, involving a quantity
\[
f_{\alpha_0}(\mathfrak{b}) = \# | \{ \overline{u} \in S_3(L)[T], \ x^3/(\alpha_0 u) \equiv 1 \pmod{ {}^* \mathfrak{b}} \ \textnormal{ soluble in } L \} |,
\]
where $\mathfrak{b}$ ranges over (possibly fractional) powers of $3$. This leads (\cite[Proposition 4.6]{CM}) to a formula for $\Phi_d(s)$, where $\mathfrak{b}$ ranges over
a set of $3$-adic ideals $\mathcal{B}$, and $f_{\alpha_0}(\mathfrak{b})$ appears as a counting function for the number of ideals with fixed conductor.

As discussed above, the splitting conditions in places in $S$ are equivalent to requiring that
$x^3/(\alpha_0 u) \equiv 1$ be soluble modulo other ideals. If $3 \nmid P_\Sigma$, multiply each $\mathfrak{b}$ by $\mathcal{P}$.
If $3 \mid P_\Sigma$, then $3$ cannot ramify in any cubic field being counted: the sum over $\mathfrak{b} \in \mathcal{B}$ and all $3$-adic factors disappear from $\Phi_d(s)$.
In place of this sum, one takes $\mathfrak{b}$ equal to $\mathcal{P}$.

The computation of $f_{\alpha_0}(\mathfrak{b})$ is carried out in Section 5 of \cite{CM}, and also in Morra's thesis \cite{morra} where more detailed proofs are presented.
One checks that, when varying $\mathfrak{b}$ as above, the proofs are identical through Lemma 5.4.

We diverge somewhat in Lemma 5.6, which computes the size of $(Z_\mathfrak{b} / Z_\mathfrak{b}^3)[T]$, where
$Z_{\mathfrak{b}} := (\mathbb{Z}_L / \mathfrak{b} \mathbb{Z}_L)^*$. By the Chinese remainder theorem, the size of this group is multiplicative in $\mathfrak{b}$, so it suffices to carry out the computation for $\mathfrak{b} = (9)$ or
$\mathfrak{b} = (p)$ for $p$ a rational prime other than $3$.

For $F$ equal to $L$, $\mathbb{Q}(\sqrt{-3D})$, or $\mathbb{Q}$ write $\Gamma_{F, \mathfrak{b}}$
for the multiplicative group of $\mathbb{Z}_F / (\mathbb{Z}_F \cap \mathfrak{b})$ modulo cubes, so that $\Gamma_{L, \mathfrak{b}} = Z_\mathfrak{b}/Z_\mathfrak{b}^3$ by
definition. Then for $d \neq 1, -3$ a `descent' argument similar to that
presented in the proof of \cite[Proposition 3.4]{CT} yields an isomorphism
$\Gamma_{L, \mathfrak{b}}[T] \simeq \Gamma_{\mathbb{Q}(\sqrt{-3d}), \mathfrak{b}}[1 + \tau]$, and when $d = 1$ this
holds (tautologically) as an equality. Similarly to \cite[Lemma 5.6]{CT},
we obtain
\begin{equation}\label{eq:zb_size}
|(Z_\mathfrak{b}/Z_\mathfrak{b}^3)[T]| = \begin{cases}
|\Gamma_{\mathbb{Q}(\sqrt{-3d}), \mathfrak{b}}|/|\Gamma_{\mathbb{Q}, \mathfrak{b}}|
& \textnormal{if \ } d \neq -3 \\
|\Gamma_{\mathbb{Q}, \mathfrak{b}}| & \textnormal{if \ } d = -3. \\
\end{cases}
\end{equation}
By direct computation, we readily check that the right side of \eqref{eq:zb_size} is $3$ in all cases.
(Recall that $\big( \frac{d}{p} \big) = 1$.)
This yields a version of \cite[Theorem 6.1]{CM}, which gives an expression for $\Phi_d(s)$ in terms
of characters of $G_\mathfrak{b} := (\textnormal{Cl}_{\mathfrak{b}}(L) / \textnormal{Cl}_{\mathfrak{b}}(L)^3)[T]$,
with the following modifications:
\begin{itemize}
\item
If $3 \nmid P_\Sigma$, then each ideal $\mathfrak{b} \in \mathcal{B}$ is multiplied by $\mathcal{P}$, and
$|(Z_\mathfrak{b} / Z_\mathfrak{b}^3)[T]|$ is multiplied by $3^{\omega(P_\Sigma)}$.
\item
If $3 \mid P_\Sigma$, then the sum over $\mathfrak{b} \in \mathcal{B}$ is replaced with the single choice $\mathfrak{b} = \mathcal{P}$;
$(Z_\mathfrak{b} / Z_\mathfrak{b}^3)[T]$ has size $3^{\omega(P_\Sigma)}$.
\end{itemize}

\smallskip
{\bf Step 3 -- Interpretation in terms of field counting.}
For $d \neq 1, -3$ the analogue of \cite[Proposition 3.4]{CT} continues to hold, yielding a `descent' isomorphism $G_\mathfrak{b} \simeq H_{\mathfrak{a}'}$, where
$\mathfrak{a}' := \mathfrak{b} \cap \mathbb{Z}_{\mathbb{Q}(\sqrt{-3d})}$, and $H_{\mathfrak{a}'} :=  \big(\textnormal{Cl}_{\mathfrak{a}'}(\mathbb{Q}(\sqrt{-3d})) / \textnormal{Cl}_{\mathfrak{a}'}^3(\mathbb{Q}(\sqrt{-3d})) \big)[1 + \tau]$. Then,
Proposition 4.1 of \cite{CT} uses class field theory to establish
a bijection between pairs of nontrivial characters of $G_{\mathfrak{b}}$ and cubic fields $E$. The same argument
continues to hold, with the set of cubic fields $E$ is expanded to those whose discriminant is equal to $-3d$ times the
square of any rational integer divisor of $\mathfrak{b}$. The second half of the proof of Proposition 4.1 in \cite{CT} is unnecessary, as the conclusion follows more simply from Lemma 1.3 and equation (1.3) of earlier work of Nakagawa \cite{nakagawa}.

If $d = 1$ then as before the `descent' isomorphism is replaced by an equality and we proceed identically. If $d = -3$ then we obtain
$G_\mathfrak{b} \simeq \textnormal{Cl}_{\mathfrak{a}'}(\mathbb{Q}) / \textnormal{Cl}_{\mathfrak{a}'}^3(\mathbb{Q})$ with $\mathfrak{a}' = \mathfrak{b} \cap \mathbb{Z}$ and a more direct
application of class field theory establishes the required bijection.

This completes the proof.

\bigskip
We turn now to the analytic consequences. For a fundamental discriminant $d$, define the quantity
\begin{equation*}
N(\mathcal{F}(\Sigma)_d;Z):=\#\bigl\{K\in \mathcal{F}(\Sigma)_d:\iF(K)<Z\bigr\}.
\end{equation*}
Denote $(c_D 3^{\omega(P_\Sigma})^{-1}$ times the first summand of the right hand side of
\eqref{eqn_main_cubic_lc} by $\phi^{(0)}_{\Sigma,d}(s)$.  Then we have the following consequence of Theorem \ref{thm:cm_explicit_lc}.
\begin{theorem}\label{thm:cmcount}
Let $\Sigma$ be a finite collection of local splitting types and let $d\in\mathbb{Z}$ be a fundamental discriminant. Then we have
\begin{equation*}
N(\mathcal{F}(\Sigma)_d;Z)
=\Res_{s=1}\bigl(\phi^{(0)}_{\Sigma,d}(s)\bigr)\cdot Z
+O_{\epsilon}\Bigl(|{\mathcal L}_3(\Sigma,d)||d|^{1/6}P_\Sigma^{1/3}Z^{2/3+\epsilon}\Bigr).
\end{equation*}
\end{theorem}
\begin{proof}
As this is standard, we give a brief account. Write the left side as
\begin{equation*}
\#\bigl\{K\in \mathcal{F}(\Sigma)_d:\iF(K)<Z\bigr\}
=\frac{1}{2\pi i}\int_{2 - i \infty}^{2 + i \infty} \Phi_{\Sigma, d}(s) \frac{Z^s}{s}ds.
\end{equation*}
We then write each Euler product in $\Phi_{\Sigma, d}(s)$
as the product of an incomplete zeta function $\zeta_{\mathbb{Q}(\sqrt{-3d})}(s)$ or an incomplete irreducible degree $2$ Artin $L$-function, times
a function holomorphic and bounded in any half plane $\Re(s) \geq \sigma_0 > \frac12$.

As all of the $L$-functions have conductor $\ll |d|P_\Sigma^2$, the convexity bound yields
\begin{equation*}
\bigg|\Phi_{\Sigma, d}(s) - \frac{\Res_{s=1}\bigl(\phi^{(0)}_{\Sigma,d}(s)\bigr)}{s - 1}\bigg| \ll |d|^{1/4}\big((1 + t)P_\Sigma\big)^{1/2},
\end{equation*}
uniformly in $\Re(s) = \sigma + it$ with
$1>\sigma \geq \sigma_0$.

Pick $T>1$ to be optimized later. We shift the contour to the left, picking up one residue at $1$, ending up with a sum of the following integrals: from $1+\epsilon\pm iT$ to
$1+\epsilon\pm i\infty$; from $1+\epsilon\pm iT$ to $\sigma_0\pm iT$; and from $\sigma_0-iT$ to $\sigma_0+iT$. The residue gives the required main term, while the sum of these integrals is
\begin{equation*}
\ll\frac{Z^{1+\epsilon}}{T}+Z^{\sigma_0}T^{1/2}|d|^{1/4}P_\Sigma^{1/2}.
\end{equation*}
The result now follows by optimizing the value of $T$ to be $Z^{1/3}/(d^{1/6}P_\Sigma^{1/3})$.
\end{proof}

\begin{remark}
The error terms in the above theorem can clearly be improved by using subconvex estimates in place of the convexity bound. However, we do not state this improvement since we have no need for it.
\end{remark}

\section{The asymptotics of cubic fields with bounded invariants}

For a finite collection $\Sigma$ of local splitting types and positive real numbers $Y$ and $Z$, define
\begin{equation*}
N(\Sigma;Y,Z):=\bigl\{K\in\mathcal{F}(\Sigma):|\iD(K)|<Y,\;\iF(K)<Z\bigr\}.
\end{equation*}
In this section, we compute asymptotics for $N(\mathcal{F}(\Sigma);Y,Z)$. We will handle the `large $Y$ case'
using Theorem \ref{thm:dh} and the
`small $Y$ case' using Theorem \ref{thm:cmcount}. Our error terms are strong enough that these ranges of $Y$ overlap, yielding
an asymptotic estimate for all $Y$ and $Z$.
Indeed, we obtain asymptotic formulas with different expressions for the main terms, which we may then conclude are equal.

These results will be used in the proofs of Theorems \ref{thradical} and
\ref{thGD}(c), where $\iD$ and $\iF$ are given equal weight. For parts (a) and (b)
of Theorem \ref{thGD} we will instead use a more direct approach so as to optimize the error terms.
All of these proofs will be given
in Section \ref{sec:ordering}.

\smallskip
We begin with the following proposition.

\begin{proposition}\label{proproughcount}
Let $\Sigma$ be an finite collection of local splitting types, and let $Y$ and $Z$ be positive real numbers. Then
\begin{equation*}
\begin{array}{rcl}
\displaystyle N(\Sigma;Y,Z)&=&
\displaystyle\Bigl(\sum_{\substack{f<Z}} C_1(\Sigma,f)
\Bigr)
\cdot Y
+O_{\epsilon}(Y^{5/6}Z^{2/3}+Y^{2/3+\epsilon}Z^{4/3}  P_\Sigma^{2/3} );\\[.25in]
\displaystyle N(\Sigma;Y,Z)&=&
\displaystyle \Bigl(\sum_{\substack{|d|<Y\\{\rm fund. disc}}}
\Res_{s=1}\Phi_{\Sigma,d}(s)
\Bigr)\cdot Z+O_{\epsilon,\Sigma}\Bigl(Y^{7/6}Z^{2/3+\epsilon}  P_\Sigma^{1/3} \Bigr).
\end{array}
\end{equation*}
\end{proposition}
\begin{proof}
To prove the first equality, we fiber by $\iF(K)$ and apply Theorem
\ref{thm:dh} (Davenport-Heilbronn), obtaining
\begin{equation*}
\begin{array}{rcl}
\displaystyle N(\Sigma;Y,Z);Y,Z)&=&\displaystyle
\sum_{f<Z} N(\mathcal{F}(\Sigma)^{(f)};Y)
\\[.2in]&=&\displaystyle
\Bigl(\sum_{f<Z} C_1(\Sigma,f)\Bigr)
\cdot Y+O\Bigl(\sum_{ f< Z}(f^{-1/3}Y^{5/6}+E(Y,f))\Bigr)
\\[.2in]&=&\displaystyle
\Bigl(\sum_{f<Z} C_1(\Sigma,f)\Bigr)
\cdot Y+O\Bigl(Y^{5/6}Z^{2/3}+Y^{2/3+\epsilon}Z^{4/3} P_\Sigma^{2/3} \Bigr),
\end{array}
\end{equation*}
as necessary. To prove the second equality, we fiber by $\iD(K)$ and
apply Theorem \ref{thm:cmcount} (Cohen-Morra):
\begin{equation*}
\begin{array}{rcl}
\displaystyle N(\Sigma;Y,Z)&=&\displaystyle
\sum_{\substack{|d|<Y\\{\rm fund. disc}}} N(\mathcal{F}(\Sigma)_d;Z)
\\[.2in]&=&\displaystyle
\Bigl(\sum_{\substack{|d|<Y\\{\rm fund. disc}}}
\Res_{s=1}\Phi_{\Sigma,d}(s)
\Bigr)\cdot Z+O_{\Sigma,\epsilon}\Bigl(\sum_{\substack{|d|<Y\\{\rm fund. disc}}}
|{\mathcal L}_3(\Sigma,d)||d|^{1/6+\epsilon}Z^{2/3+\epsilon} P_\Sigma^{1/3} \Bigr)
\\[.2in]&=&\displaystyle
\Bigl(\sum_{\substack{|d|<Y\\{\rm fund. disc}}}
\Res_{s=1}\Phi_{\Sigma,d}(s)\Bigr)\cdot Z
+O_{\Sigma,\epsilon}(Y^{7/6}Z^{2/3+\epsilon} P_\Sigma^{1/3}),
\end{array}
\end{equation*}
where the bound on the sum over $d$ of the sizes of ${\mathcal L}_3(\Sigma,d)$ follows from the Davenport--Heilbronn theorem.
This concludes the proof of the proposition.
\end{proof}

Next, we estimate the leading constant in the right hand side of the
first equation of Proposition \ref{proproughcount}.
\begin{proposition}\label{propconstant}
We have
\begin{equation*}
\displaystyle\sum_{f<Z}
C_1(\Sigma,f)
=\displaystyle\frac12
\Bigl(\sum_{K\in\Sigma_\infty}\frac{1}{|\Aut(K)|}\Bigr)
\prod_{p}\Bigl(\sum_{K\in\Sigma_p}
\frac{|\iD(K)|_p|\iF(K)|_p}{|\Aut(K)|}\Bigr)\Bigl(1-\frac1{p}\Bigr)^2
\cdot Z+O_\epsilon(Z^{3/5+\epsilon});
\end{equation*}
\end{proposition}
\begin{proof}
Recall the Dirichlet series $L_1(\Sigma, s):=\sum_{f}C_1(\Sigma,f)f^{-s}$ from \S2.1. It is easy to see that
$L(s)$ is holomorphic to the right of $\Re(s)>1/2$ with a simple pole
at $s=1$. Indeed, the shape of $C_1(\Sigma,f)$ described in \eqref{eq:shapeC1} implies that $L_1(\Sigma, s)/\zeta(s)$ converges absolutely and is bounded uniformly in $\Sigma$ and $s$
to the right of $\Re(s)=\sigma$ for any $\sigma>1/2$. Pick a real number $T$ to be optimized later. Following the proof of Theorem \ref{thm:cmcount}, we have
\begin{equation}\label{eqCavg1}
\begin{array}{rcl}
  \displaystyle\sum_{f<Z}
  C_1(\Sigma,f)&=&
\displaystyle\int_{\Re(s)=2}L_1(\Sigma, s)(s)\frac{Z^s}{s} ds
\\[.2in]&=&\displaystyle
\Res_{s=1}L_1(\Sigma, s)\cdot Z+ O_\epsilon\Bigl(\frac{Z^{1+\epsilon}}{T}+
Z^{1/2+\epsilon}T^{1/4} \Bigr),
\end{array}
\end{equation}
where we use the convex bound to estimate the growth of $\zeta(s)$ (and therefore $L_1(\Sigma, s)$) on the line $\Re(s)=1/2+\epsilon$.
From the Euler product expansion of $L_1(\Sigma, s)$ derived in Proposition \ref{prop:L12Euler}, it follows that the residue of $L_1(\Sigma, s)$ at $s=1$ is given by
\begin{equation}\label{eqLres}
\Res_{s=1}L_1(\Sigma, s)=\frac12\Bigl(\sum_{K\in\Sigma_\infty}\frac{1}{|\Aut(K)|}\Bigr)\prod_{p}\Bigl(\sum_{K\in\Sigma_p}
\frac{|\iD(K)|_p|\iF(K)|_p}{|\Aut(K)|}\Bigr)\Bigl(1-\frac1{p}\Bigr)^2.
\end{equation}
The proposition follows by choosing $T=Z^{2/5}$.
\end{proof}

The above two propositions have the following consequence:
\begin{corollary}\label{corconstant}
We have
\begin{equation*}
\frac{1}{Y}\sum_{\substack{|d|<Y\\{\rm fund. disc}}}
\Res_{s=1}\Phi_{\Sigma,D}(s)=
\frac12\prod_{p}\Bigl(\sum_{K\in\Sigma_p}
\frac{|\iD(K)|_p|\iF(K)|_p}{|\Aut(K)|}\Bigr)\Bigl(1-\frac1{p}\Bigr)^2+O(Y^{-1/12 + \epsilon}).
\end{equation*}
\end{corollary}
\begin{proof}
The result follows from Propositions \ref{proproughcount} and
\ref{propconstant} by setting $Z=Y^{3/4}$.
\end{proof}

In particular, the two estimates of Proposition \ref{proproughcount} are asymptotic formulas
for $Y > Z^{1 + \epsilon}$ and $Y < Z^{2 - \epsilon}$, respectively. Since these ranges overlap, we obtain
the following result.
\begin{theorem}\label{thdyadicmain}
We have
\begin{equation*}
N(\Sigma;Y,Z)=
\frac12\Bigl(\sum_{K\in\Sigma_\infty}\frac{1}{|\Aut(K)|}\Bigr)
\prod_{p}\Bigl(\sum_{K\in\Sigma_p}
\frac{|\iD(K)|_p|\iF(K)|_p}{|\Aut(K)|}\Bigr)\Bigl(1-\frac1{p}\Bigr)^2
  \cdot YZ+o_\Sigma(Y)Z+Yo_\Sigma(Z).
\end{equation*}
\end{theorem}
\begin{proof}
The leading constant above is $C_1(\iD\iF;\Sigma)$. Combining the above results yields
\begin{equation*}
N(\Sigma;Y,Z)=C_1(\iD\iF;\Sigma)YZ+
O_{\epsilon,\Sigma}\Bigl(\big(YZ)^\epsilon(YZ^{3/5}+Y^{11/12}Z+\min(Y^{2/3}Z^{4/3},Y^{7/6}Z^{2/3})\big)\Bigr),
\end{equation*}
which is sufficiently small.
\end{proof}

\section{Ordering cubic fields by generalized discriminants}\label{sec:ordering}
In this section we determine asymptotics for the number of cubic
fields with bounded generalized discriminant, thereby proving Theorem
\ref{thGD}. We also then determine which generalized discriminants $I$
are such that the family of cubic fields ordered by $I$ satisfy
independence of primes, thus also proving Theorem \ref{thIndPr}.

For a generalized discriminant $I = \iD^\alpha \iF^\beta$, after normalizing we may assume
that one of $\alpha$ or $\beta$ equals $1$ and the other is $\geq 1$. We handle each of the three possible cases
in turn.

\medskip
{\itshape Case 1: $\alpha = 1, \beta > 1$.}
We begin with the following important uniformity estimate due to
Davenport--Heilbronn.
\begin{lemma}\label{unifDH}
The number of cubic fields $K$ such that $|\Disc(K)|<X$ and $\iF(K)=f$
is bounded by $O_\epsilon(X^{1+\epsilon}/f^2)$.
\end{lemma}

Let $\Sigma$
denote a finite collection of cubic local splitting types, and let
$\mathcal{F}(\Sigma)$ denote the associated family of cubic fields. We
let $\Delta_{\iF;\beta}$ denote the generalized discriminant $\iD \cdot \iF^\beta$,
and denote
the number of fields $K$ in $\mathcal{F}(\Sigma)$ such that
$|\Delta_{\iF;\beta}(K)|<X$ by $N_{\iF;\beta}(\mathcal{F}(\Sigma);X)$. Then
we have the following result.

\begin{proposition}\label{propMT1}
For a finite collection $\Sigma$ of cubic splitting types and a
real number $\beta>1$, we have
\begin{comment}
\begin{equation*}
\begin{array}{rcl}
N_{\iF;\beta}(\mathcal{F}(\Sigma);X)
&=&\displaystyle
\frac12\Bigl(\sum_{K\in\Sigma_\infty}\frac{1}{|\Aut(K)|}\Bigr)
\prod_p\Bigl(\sum_{K\in\Sigma_p}\frac{|\Delta_{\iF;\beta}|_p}{|\Aut(K)|}\Bigr)
\Bigl(1-\frac1{p}\Bigr)
\cdot X
\\[.2in]&&\displaystyle
+C(\infty)\frac{\zeta(\frac23)\Gamma(\frac13)(2\pi)^{\frac13}}{10\zeta(2)\Gamma(\frac{2}{3})}f^{-\frac13}
\prod_{p}\Bigl[\Bigl(\sum_{\substack{K_p\in\Sigma_p(f)}}
\frac{|\iD(K_p)|_p}{|\Aut(K_p)|}\Bigr)\Bigl(1-\frac1{p^{\frac13}}\Bigr)\int_{(\mathcal{O}_{K_p}/\mathbb{Z}_p)^{\rm{prim}}}i(x)^{2/3}dx\Bigr]
\cdot X^{5/6}
\\[.2in]&&\displaystyle
O(X^{\frac{2}{\beta+1}+\epsilon}).
\end{array}
\end{equation*}
\end{comment}
\begin{equation*}
N_{\iF;\beta}(\mathcal{F}(\Sigma);X)=
L_1(\Sigma, \beta)\cdot X+L_2(\Sigma, 5\beta/6)X^{5/6}+O\big( (X^{\frac{2}{\beta+1}}+  X^{\frac{2}{3}+\epsilon})
P_\Sigma^{2/3}\big),
\end{equation*}
with $L_1(\Sigma, \beta)$ and $L_2(\Sigma, 5\beta/6)$ as given in Proposition \ref{prop:L12Euler}.
\end{proposition}
\begin{proof}
We may assume that $|F(K)|_p$ is fixed for each prime $p$ for which $\Sigma_p \neq \Sigma_p^{\rm{all}}$. (If not,
decompose $\Sigma$ into finitely many subcollections for which this condition holds, and add the results.) We write $F_\Sigma$ for the product
of these $|F(K)|_p$ and fiber over $f\geq 1$ which are divisible by $F_\Sigma$, for which $(f/F_\Sigma, F_\Sigma) = 1$, and which are squarefree
away from $3$. We then have
\begin{equation*}
  N_{\iF;\beta}(\mathcal{F}(\Sigma);X)=
  \sum_f N(\mathcal{F}(\Sigma)^{(f)};f^{-\beta}X)
  =\sum_{f}
  N_{\Disc}(\mathcal{F}(\Sigma);f^{2-\beta}X;\iF=f),
\end{equation*}
where
$N_{\Disc}(\mathcal{F}(\Sigma);f^{2-\beta}X;\iF=f)$ denotes the
number of cubic fields $K\in\mathcal{F}(\Sigma)$ such that $\iF(K)=f$ and $|\Disc(K)|<f^{2-\beta}X$.
For any $Y > 1$, by Lemma \ref{unifDH} we have
\begin{equation*}
\displaystyle\sum_{f > Y}
N_{\Disc}(\mathcal{F}(\Sigma);f^{2-\beta}X;\iF=f)
\ll_\epsilon \displaystyle\sum_{f > Y} \frac{f^{2-\beta}X^{1+\epsilon}}{f^2}
\ll_\epsilon \
\frac{X^{1+\epsilon}}{Y^{\beta-1}}.
\end{equation*}
For $f \leq Y$, by Theorem \ref{thm:dh} we have
\begin{equation*}
\displaystyle\sum_{f \leq Y}
N(\mathcal{F}(\Sigma)^{(f)};f^{-\beta}X)
=\displaystyle
\displaystyle\sum_{f \leq Y} \Bigl(\frac{C_1(\Sigma,f)}{f^{\beta}}X
+\frac{C_2(\Sigma,f)}{f^{5\beta/6}}X^{5/6}+O\bigl(E(X/f^\beta,f,\Sigma)\bigr)\Bigr).
\end{equation*}
The error term is bounded by
\begin{align*}
\sum_{k\leq\log_2 Y}\sum_{2^k\leq f< 2^{k+1}} E(X/f^\beta;f,\Sigma)
\ &\ll
\sum_{k\leq\log_2 Y} X^{2/3+\epsilon} (2^k)^{4/3-2/3\beta}P_\Sigma^{2/3}
\\
&\ll
\displaystyle
X^{2/3+\epsilon}P_\Sigma^{2/3} \cdot \max(Y^{4/3-2\beta/3}, 1).
\end{align*}
Meanwhile, the two main terms are:
\begin{equation*}
\begin{array}{rcl}
\displaystyle\sum_{f \leq Y} \frac{C_1(\Sigma,f)}{f^{\beta}}
&=&\displaystyle\sum_{f\geq 1} \frac{C(\Sigma,f)}{f^{\beta}}+O(Y^{1-\beta})
\\[.2in]&=&\displaystyle
L_1(\Sigma, \beta)+O(Y^{1-\beta});
\\[.05in]\displaystyle
\sum_{f\leq Y}\frac{C_2(\Sigma,f)}{f^{5\beta/6}}
&=&\displaystyle
\sum_{f\geq 1}\frac{C_2(\Sigma,f)}{f^{5\beta/6}}+O(Y^{1-5\beta/6})
\\[.2in]&=&\displaystyle
L_2(\Sigma, 5\beta/6)+O(Y^{1-5\beta/6}).
\end{array}
\end{equation*}
Optimizing (in $X$ aspect), we
pick $Y=X^{\frac1{\beta+1}}$ and obtain the result.
\end{proof}

\medskip
{\itshape Case 2: $\alpha > 1, \beta = 1$.}
Next, let $\Delta_{\iD;\alpha}$ denote
the generalized discriminant $\iD^\alpha\cdot \iF$, and for primes $p$
let $|\Delta_{\iD;\alpha}|_p$ denote $|\iD|_p^\alpha|\iF|_p$. For a
finite collection $\Sigma$ of local cubic splitting types, we denote the
number of fields $K$ in $\mathcal{F}(\Sigma)$ such that
$|\Delta_{\iD;\alpha}(K)|<X$ by $N_{\iD;\alpha}(\mathcal{F}(\Sigma);X)$. Then
we have the following result.
\begin{proposition}\label{propMT2}
For a finite collection $\Sigma$ of cubic local splitting types and a
real number $\alpha>1$, we have
\begin{equation*}
N_{\iD;\alpha}(\mathcal{F}(\Sigma);X)=
\Bigl(\sum_{d\,{\rm fund.}\,{\rm disc}}\frac{\Res_{s=1}\Phi_{\Sigma,d}(s)}{|d|^\alpha}
\Bigr)\cdot X+O_\epsilon((X^{3/(2\alpha+1)+\epsilon}+X^{2/3+\epsilon})P_\Sigma^{1/3}).
\end{equation*}
\end{proposition}
\begin{proof}
We fiber over $\iD$ and write
\begin{equation*}
N_{\iD;\alpha}(\mathcal{F}(\Sigma);X)=
\sum_{d\,{\rm fund.}\,{\rm disc}}N(\mathcal{F}(\Sigma)_d;X/|d|^\alpha),
\end{equation*}
Pick a real number $1<Y\ll X^{1/\alpha}$ to be optimized later. For each fundamental discriminant $d$ such that $|d|\geq Y$, the condition
$f|d|^\alpha < X$ implies that $f < X/Y^\alpha$. Hence by Lemma \ref{unifDH} we have
\begin{equation*}
\begin{array}{rcl}
\displaystyle
\sum_{\substack{d\,{\rm fund.}\,{\rm disc}\\|d|>Y}}
N(\mathcal{F}(\Sigma)_d;X/|d|^\alpha)
&\ll&\displaystyle
\sum_{f\ll X/Y^\alpha}\#\{K\in\mathcal{F}(\Sigma)^{(f)}:|\Disc(K)| \ll X^{1/\alpha}f^{2-1/\alpha}
\}
\\[.2in]&\ll&\displaystyle
\sum_{f \ll X/Y^\alpha} (X/f)^{1/\alpha + \epsilon}
\\[.2in]&\ll&\displaystyle
\frac{X^{1 + \epsilon}}{Y^{\alpha-1}}.
\end{array}
\end{equation*}

To estimate the main term, we use Theorem \ref{thm:cmcount} to write
\begin{equation*}
\sum_{\substack{d\,{\rm fund.}\,{\rm disc}\\|d|<Y}}N(\mathcal{F}(\Sigma)_d;X/|d|^\alpha)
=
\Bigl(\sum_{\substack{d\,{\rm fund.}\,{\rm disc}\\|d|<Y}}
\frac{\Res_{s=1}\Phi_{\Sigma,d}(s)}{|d|^\alpha}\Bigr)\cdot X
+O(E),
\end{equation*}
where the error term $E$ is easily bounded by breaking up the sum over
$d$ into dyadic ranges and using Lemma \ref{unifDH} to
estimate the size of ${\mathcal L}_3(\Sigma,d)$:
\begin{equation*}
\begin{array}{rcl}
E&\ll&
\displaystyle \sum_{\substack{d\,{\rm fund.}\,{\rm disc}\\|d|<Y}}
|{\mathcal L}_3(\Sigma,d)| \cdot |d|^{1/6+\epsilon}P_\Sigma^{1/3}(X/|d|^\alpha)^{2/3+\epsilon}
\\[.2in]&\ll&
X^{2/3+\epsilon}\max(Y^{7/6-2\alpha/3},1)P_\Sigma^{1/3}.
\end{array}
\end{equation*}
Optimizing, we pick $Y=X^{2/(2\alpha+1)}$ and obtain the required result.
\end{proof}

\medskip
{\itshape Case 3: $\alpha = \beta = 1$.}
Finally, let $\Delta_{\iD\iF}$ denote the generalized discriminant
$\iD\cdot \iF$. For a finite collection $\Sigma$ of
local cubic splitting types, we denote the number of fields $K$ in
$\mathcal{F}(\Sigma)$ such that $|\Delta_{\iD\iF}(K)|<X$ by
$N_{\iD\iF}(\mathcal{F}(\Sigma);X)$. Then we have
\begin{theorem}\label{thCond}
We have
\begin{equation}\label{eqMT}
N_{\iD\iF}(\mathcal{F}(\Sigma);X)=
\frac12\Bigl(\sum_{K\in\Sigma_\infty}\frac{1}{|\Aut(K)|}\Bigr)
\prod_{p}\Bigl(\sum_{K\in\Sigma_p}
\frac{|\Delta_{\iD\iF}|_p}{|\Aut(K)|}\Bigr)\Bigl(1-\frac1{p}\Bigr)^2
\cdot X\log X+o(X \log X).
\end{equation}
\end{theorem}
\begin{proof}
Given $\epsilon > 0$, choose $\epsilon' < \epsilon$ so that
the interval $[1, \sqrt{X}]$ may be divided exactly into
$\frac12 (\epsilon'^{-1} + O(1)) \log X$
intervals of the form $[(1 + \epsilon')^k, (1 + \epsilon')^{k + 1}]$,
and write $Y_k := (1 + \epsilon')^k$ and $Z_k := X/(1 + \epsilon')^k$.
By Theorem \ref{thdyadicmain}, we have that
\[
N(\Sigma; Y_{k + 1}, Z_k) - N(\Sigma; Y_k, Z_k) = C_1(\textnormal{DF}, \Sigma) \cdot
\epsilon' X + o(Y_k) Z_k,
\]
and the same is true with the roles of $Y$ and $Z$ reversed. Since every field
counted by $N_{\iD\iF}(\mathcal{F}(\Sigma);X)$ is counted in one of the above rectangles,
we obtain
\[
N_{\iD\iF}(\mathcal{F}(\Sigma);X) \leq C_1(\textnormal{DF}; \Sigma) X \log X \cdot
(1 + O(\epsilon) + \epsilon'^{-1} o_X(1)).
\]
Choosing $\epsilon \rightarrow 0$ as $X \rightarrow \infty$, we obtain the result
as an upper bound. To obtain the lower bound, proceed analogously, choosing
$Z_k := X/(1 + \epsilon')^{k + 1}$ and subtracting the $O(X)$ points in
$N(\Sigma; \sqrt{X}, \sqrt{X})$ which are counted twice.
\end{proof}

Theorems \ref{thGD} and \ref{thm:secterm} follow immediately from Propositions \ref{propMT1}
and \ref{propMT2}, and Theorem \ref{thCond}.
We conclude
by proving Theorems \ref{thradical} and \ref{thIndPr}.

\medskip
\noindent{\bf Proof of Theorem \ref{thradical}:} Let $p>3$ be prime,
and let $K$ be an \'etale cubic extension of $\mathbb{Q}_p$. Then as noted previously we have
that $p^2\nmid \iD(K)\iF(K)$. Therefore, for a cubic field $K$, we
have ${\rm rad}(\Disc(K))=\iD(K)\iF(K)$ up to bounded powers of $2$
and $3$. Let $\delta_2$ and $\delta_3$ be powers of $2$ and $3$, respectively. Let $S(\delta_2)$ (resp.\ $S(\delta_3)$) be the set of \'etale extensions of $\mathbb{Q}_2$ (resp.\ $\mathbb{Q}_3$) whose discriminants have $p$-adic part $\delta_2$ (resp.\ $\delta_3$), respectively. Let $\Sigma(\delta_2,\delta_3)$ be the finite collection of
local cubic splitting types defined by $\Sigma_2=S(\delta_2)$,
$\Sigma_3=S(\delta_3)$, and $\Sigma_v=\Sigma_v^{\rm all}$ for all other
places $v$. Then we have
\begin{equation*}
\begin{array}{rcl}
\displaystyle\#\bigl\{K\in\mathcal{F}(\Sigma):C(K)<X,\,\pm\Disc(K)>0\bigr\}&=&
\displaystyle N_{\iD\iF}\Bigl(\mathcal{F}(\Sigma);
\frac{\delta_2\delta_3}{{\rm rad}(\delta_2\delta_3)}
\cdot X\Bigr)
\\[.2in]&=&\displaystyle
\frac{1}{2\sigma_\pm}
{\mathcal C}(\delta_2){\mathcal C}(\delta_3)
\prod_{p\geq 5}\Bigl(1+\frac{2}{p}\Bigr)
  \Bigl(1-\frac{1}{p}\Bigr)^2
\cdot X\log X\\[.2in]&&+o(X\log X),
\end{array}
\end{equation*}
where $\sigma_+=6$ and $\sigma_-=2$ are the sizes of the automorphism
groups of $\mathbb{R}^3$ and $\mathbb{R}\times\mathbb{C}$, respectively, and
\begin{equation*}
  {\mathcal C}(\delta_2)=\Bigl(1-\frac{1}{2}\Bigr)^2\sum_{K_2\in S(\delta_2)}\frac{|{\rm rad}(\Delta_{\iD\iF}(K_2))|_2}{|\Aut(K_2)|};
  \quad\quad
  {\mathcal C}(\delta_3)=\Bigl(1-\frac{1}{3}\Bigr)^2\sum_{K_3\in S(\delta_3)}\frac{|{\rm rad}(\Delta_{\iD\iF}(K_3))|_3}{|\Aut(K_3)|}.
\end{equation*}
Summing over all $\delta_2$ and $\delta_3$, we
obtain
\begin{equation*}
\#\bigl\{K\in\mathcal{F}:C(K)<X,\,\pm\Disc(K)>0\bigr\}=
\frac{1}{2\sigma_\pm}
\prod_{p}
{\mathcal C}(p)
  \Bigl(1-\frac{1}{p}\Bigr)^2
\cdot X\log X+o(X\log X),
\end{equation*}
where for any prime $p$, the quantity ${\mathcal C}(p)$ is defined to be
\begin{equation*}
{\mathcal C}(p):=
\sum_{K\in\Sigma_p^{\rm{all}}}\frac{|{\rm rad}(\Delta_{\iD\iF}(K))|_p}{|\Aut(K)|}.
\end{equation*}
To compute these constants, we use the database of local fields available at \url{lmfdb.org} \cite{LMFDB}, which lists each
quadratic or cubic ramified extension of $\mathbb{Q}_2$ and $\mathbb{Q}_3$ with its Galois group; we obtain that
${\mathcal C}(2)=3$ and
${\mathcal C}(3)=11/3$, thereby completing the proof. $\Box$

\medskip
\medskip

\noindent{\bf Proof of Theorem \ref{thIndPr}:} It is clear from the
shape of the leading constants in Theorem \ref{thGD} that the family
of all cubic fields ordered by $\iD^\alpha\iF^\beta$ does satisfy
independence of primes when $\alpha\leq \beta$. It only remains to
prove the result when $\alpha>\beta$, and as before we may assume
that $\beta=1$. We will construct a finite
collection of cubic local splitting types $\Sigma^{(\epsilon)}$, for
each $\epsilon>0$, such that the following two conditions are satisfied:
\begin{itemize}
\item[{\rm (a)}] We have $\Sigma^{(\epsilon)}_5=\Sigma_5^{\rm{all}}$ for
  each $\epsilon>0$.
\item[{\rm (b)}] We have
\[
0 < \lim_{X \rightarrow \infty}
\frac{\#\{K\in\mathcal{F}(\Sigma^{(\epsilon)}):\iD(K)^\alpha\iF(K)<X,\, K\otimes\mathbb{Q}_5\cong\mathbb{Q}_5^3\} }
{\#\{K\in\mathcal{F}(\Sigma^{(\epsilon)}):\iD(K)^\alpha\iF(K)<X \} }
< \epsilon.
\]
\end{itemize}
The construction of such families immediately implies the result,
since this demonstrates that the probability of the prime $5$ spliting
completely in $\mathcal{F}(\Sigma^{(\epsilon)})$ changes with $\epsilon$
despite the fact that $\Sigma^{(\epsilon)}_5$ is constant for all
$\epsilon$.

We now construct these families $\Sigma^{(\epsilon)}$. Let $K$ be an
$S_3$-cubic field, and let $L$ denote the Galois closure of
$K$. Recall that the discriminant of the (unique) quadratic subfield
$F$ of $L$ is equal to $\iD(K)$. (When $K$ is a cyclic cubic field,
then $\iD(K)=1$.) Furthermore, if $p$ is any prime, then the splitting
type of $p$ at $K$ determines the splitting type of $p$ at $F$. In
particular, every prime that splits completely in $K$ also splits
completely in $F$. Now, for fixed $\epsilon>0$ let $N(\epsilon)$ be
the smallest positive integer such that the following inequality is
satisfied:
\begin{equation}\label{eqindprimes}
\epsilon\cdot\frac{\Res_{s=1}\Phi_{\Sigma^{\rm{all}},-3}}{3^\beta}>
\sum_{\substack{|d|>N(\epsilon)\\{\rm fund. disc.}}}
\frac{\Res_{d=1}\Phi_{\Sigma^{\rm{all}},d}}{|d|^\beta}.
\end{equation}
Such an $N(\epsilon)$ exists for each $\epsilon$ since the sum of
$\Res_{d=1}(\Phi_{\Sigma^{\rm{all}},d})/|d|^\beta$ is convergent, as can be seen from
Corollary \ref{corconstant} for example.
Next, for
each fundamental discriminant $d$ with $|d|\leq N(\epsilon)$, let
$p_d\neq 5$ be a prime such that the splitting types of $p_d$ at
$\mathbb{Q}(\sqrt{-3})$ and $\mathbb{Q}(\sqrt{d})$ differ. Define
$\Sigma_{p_d}^{(\epsilon)}$ to be the set of all \'etale cubic
extensions $E$ of $\mathbb{Q}_{p_d}$ such that the quadratic resolvent of $E$
is equal to $\mathbb{Q}(\sqrt{-3})\otimes\mathbb{Q}_{p_d}$.

Define the collection $\Sigma^{(\epsilon)}$ by taking
$\Sigma_{p_d}^{(\epsilon)}$ as above, and choosing
$\Sigma_{p}^{(\epsilon)}=\Sigma_p^{\rm{all}}$ for $p$ not equal to any of the
$p_d$. Then we claim that
$\Sigma^{(\epsilon)}$ satisfies the conditions (a) and (b) above.
Condition (a) is satisfied by construction. To verify
Condition (b), note that if $K$ is a cubic field with resolvent
$\mathbb{Q}(\sqrt{-3})$, then $5$ does not split completely in $K$, as it does not split completely in $\mathbb{Q}(\sqrt{-3})$. Furthermore,
we have $\mathcal{F}(\Sigma^{(\epsilon)})_{-3}=\mathcal{F}(\Sigma^{\rm{all}})_{-3}$ since
the splitting conditions imposed at the primes $p_d$ include all
possible splitting types of cubic fields with
resolvent $\mathbb{Q}(\sqrt{-3})$. Therefore, the inequality
\eqref{eqindprimes} is satisfied with $\Sigma^{\rm{all}}$ replaced by
$\Sigma^{(\epsilon)}$. Therefore, the result follows from Theorem
\ref{propMT2}. $\Box$

\subsection*{Acknowledgments}

It is a pleasure to thank Manjul Bhargava and Robert Lemke Oliver for helpful conversations.
AS is supported by an
NSERC Discovery Grant and a Sloan Research Fellowship. FT
was partially supported by the National Science Foundation under Grant
No. DMS-2101874, by the National Security Agency under Grant
H98230-16-1-0051, and by grants from the Simons Foundation (Nos.~563234 and~586594).

Finally, this project was begun at the Palmetto Number Theory Series in Columbia, SC in
December 2016, hosted by Matthew Boylan, Michael Filaseta, and FT. We would like to thank
Boylan and Filaseta for hosting, and the NSF (Grant No. DMS-1601239) and NSA
(Grant No. H98230-14-1-0151) for funding the conference.

\bibliographystyle{abbrv}


\section{INTRODUCTION}
\label{sec:intro}

Direct imaging allows to spatially separate and directly measure radiation from an exoplanet, which enables the spectral analysis of its atmosphere with minimized impact from the host star. Direct imagers such as SPHERE\cite{Beuzit:2019}, GPI\cite{Macintosh:2014}, and SCExAO\cite{Jovanovic:2015} are designed to find and detect young planets around nearby stars\cite{Macintosh:2015,Chauvin:2017a,Keppler:2018}, which can be used to study the population of young giant exoplanets through large direct imaging surveys\cite{Vigan:2012,Galicher:2016,Vigan:2017,Vigan:2021}. However, current instruments are limited for the characterization of companions by their spectral resolution of $R=\lambda/\Delta\lambda=400$ at most\cite{Vigan:2008}.

High-dispersion spectrographs have been used to detect the thermal radiation of various giant exoplanets by relying on the large number of molecular lines detectable in the atmospheres of these planets, which can only be accessed at spectral resolutions above a few 10\,000s. Important results have been obtained on both transiting and non-transiting planets\cite{Snellen:2010,Brogi:2012,Birkby:2013}, as well as on spatially resolved low-mass companions\cite{Snellen:2014,Schwarz:2016,Hoeijmakers:2018}. For the latter, the most well-known case is that of the directly-imaged exoplanet $\beta$\,Pictoris\,b\cite{Snellen:2014} using the CRIRES instrument\cite{Kaeufl:2004} on the ESO Very Large Telescope (VLT). This method has since provided more atmospheric detections and rotation speeds of young directly imaged companions\cite{Schwarz:2016,Hoeijmakers:2018,Bryan:2018}, providing unique insight into the properties of this population of objects\cite{Bryan:2018}.

Measurements on young companions have been obtained with low-order adaptive optics systems like MACAO\cite{Arsenault:2003} for the $\beta$~Pictoris\,b result. With such systems, the atmospheric turbulence correction  concentrates a moderate fraction of the energy in the PSF core (typically 50--60\% in the $K$ band\cite{Paufique:2006}), but the level of the uncorrected halo is high. This means that the strongest limiting factor of the signal-to-noise ratio (S/N) of the planet signal close to the star remains the noise contributed by the uncorrected stellar halo. To significantly decrease the halo, it is necessary to rely on high-order adaptive optics known as extreme adaptive optics (ExAO), which can provide diffraction-limited images in the near-infrared (NIR) and therefore decrease the level of stellar halo (and noise) at the location of the planet\cite{Kawahara:2014a,Snellen:2015,Wang:2017,Mawet:2017,Vigan:2018}. Diffraction-suppressing coronagraphs can also be used to further improve the contrast and decrease the level of stellar residuals at the location of the planet.

Until recently, no instrument dedicated to high-contrast imaging was equipped with means of characterizing detected companions at very high spectral resolutions. Conversely, none of the existing high-resolution spectrographs in the near infrared is equipped with either an ExAO system or with a coronagraph, which would facilitate the characterization of known companions. In recent years, several projects have proposed combining ExAO systems with existing mid- or high-resolution spectrographs using single-mode fibers (SMF) either in the NIR, for example between NIRC2 and NIRSPEC at Keck (KPIC)\cite{Mawet:2016,Mawet:2017} or between SCExAO and IRD at Subaru (REACH)\cite{Kawahara:2014,Kawahara:2014a,Kotani:2018}, or in the visible, for example between SPHERE and ESPRESSO at the VLT\cite{Lovis:2017}. For the NIR, the VLT offers a unique opportunity to achieve a similar feat by coupling the high-contrast imager SPHERE\cite{Beuzit:2019} with the recently upgraded high-resolution spectrograph CRIRES+\cite{Dorn:2016}, which are now both available at the VLT/UT3. The coupling between these two flagship instruments has been proposed as the High-Resolution Imaging and Spectroscopy of Exoplanets project (HiRISE)\cite{Vigan:2018,Otten:2021}.

SPHERE offers a unique ExAO system (SAXO)\cite{Fusco:2006} that has demonstrated exquisite performance on-sky\cite{Sauvage:2014,Petit:2014,Milli:2017} and efficient coronagraphs\cite{Carbillet:2011,Guerri:2011}; its infrared arm covers the $Y$, $J$, $H$, and $K_s$ bands. CRIRES+ is a refurbished and upgraded version of the CRIRES spectrograph\cite{Kaeufl:2004}, operating in the $Y$, $J$, $H$, $K$, $L$, and $M$ bands (0.9-5.3\,\ensuremath{\muup\mathrm{m}}\xspace) at $R=100\,000$ resolving power with a 0.2$''$-slit. It features three Hawaii-2RG 2k$\times$2k detectors and a cross-disperser to cover more than 50\% of the $H$ band in a single observation. The large overlap in terms of spectral coverage between SPHERE and CRIRES+ is a key advantage in particular in the $H$ and $K$ bands, which contain strong molecular features for CO, CH$_4$, H$_2$O, or NH$_3$. The high angular resolution and high-contrast capabilities of SPHERE at these wavelengths, combined with the high spectral resolution of CRIRES+, will provide a unique system capable of characterizing known directly imaged companions.

In this paper we present the final proposed implementation of the system in Sect.~\ref{sec:implementation}, an assessment of the expected performance based on the final hardware in Sect.~\ref{sec:expected_perf}, and finally the current status of the project and its schedule in Sect.~\ref{sec:project_status}.

\section{IMPLEMENTATION}
\label{sec:implementation}

\subsection{Overview}
\label{sec:implementation_overview}

\begin{figure}
  \centering
  \includegraphics[width=0.8\textwidth]{Figures/implementation_overview}
  \caption{Overview of the implementation at the telescope. SPHERE and CRIRES+ are both located on the VLT Unit Telescope 3 (UT3), on Nasmyth platforms A and B respectively. The bundle cannot be routed along structure that supports the primary mirror due to the altitude motion during science observations. The favored option is to route the bundle along the Nasmyth structures and beneath the floor. The route depicted here is not exactly the final one that has been studied and proposed by ESO.}
  \label{fig:implementation_overview}
\end{figure}

The HiRISE coupling will be implemented on the VLT-UT3 between SPHERE and CRIRES+, which are located on Nasmyth platforms A and B, respectively. This is illustrated in Fig.~\ref{fig:implementation_overview}. The system consists in three main sub-systems:

\begin{enumerate}
    \item the fiber injection module (FIM) implemented inside of SPHERE. The role of the FIM is to pick-up the SPHERE scientific beam and inject the signal of a known exoplanet in a science fiber. The FIM will be described in Sect.~\ref{sec:implementation_fim};
    \item the fiber bundle that connects SPHERE and CRIRES+ around the telescope. The bundle transmits the planetary and stellar signals up to the entrance of the spectrograph. The bundle will be described in Sect.~\ref{sec:implementation_fb};
    \item and the fiber extraction module (FEM) implemented inside of CRIRES+. The role of the FEM is to reimage the output of the bundle's fibers in the VLT focal plane with the appropriate focal ratio. The FEM will be described in Sect.~\ref{sec:implementation_fem};
\end{enumerate}

In addition to these main sub-systems, HiRISE also includes a dedicated electronics cabinet located on the SPHERE Nasmyth platform, and a dedicated control software developed following the VLT Software standards. These additional components will be described in Sect.~\ref{sec:implementation_electronics}.

\subsection{Fiber injection module}
\label{sec:implementation_fim}

\begin{figure}
  \centering
  \includegraphics[width=0.7\textwidth]{Figures/fim_optical_design}
  \caption{Optical design and photon sharing of the FIM located in SPHERE. The science channel transmits only the $H$ band for the injection into the science fiber. The tracking channel transmits the $Y$ and $J$ bands for acquisition and monitoring with the tracking camera. All the optics are coated with appropriate AR-coatings. Figure borrowed from [\citenum{ElMorsy:2022}].}
  \label{fig:fim_optical_design}
\end{figure}

\begin{figure}
  \centering
  \includegraphics[width=1\textwidth]{Figures/fim_implementation_full}
  \caption{\emph{Left:} Overview of the implementation of the FIM inside of SPHERE. \emph{Right:} Detailed view of the mechanical design of the FIM. The main elements are highlighted on the figure. An additional cover (not shown) will be implemented over the injection optics and fiber mount at the top of the FIM.}
  \label{fig:fim_implementation_full}
\end{figure}

The FIM is an additional sub-system implemented inside of the SPHERE enclosure, on the main CPI bench. It diverts the beam of the SPHERE/IFS towards a dedicated optical bench. The optical design with photon sharing is presented in Fig.~\ref{fig:fim_optical_design} and the mechanical implementation is presented in Fig.~\ref{fig:fim_implementation_full}. Images of the final hardware being integrated or tested in the lab are presented in Fig.~\ref{fig:fim_pictures}.

Originally, the VLT/HiRISE system has been proposed for both the $H$ and $K$ bands\cite{Vigan:2018}. However, following the simulation study presented in [\citenum{Otten:2021}], the expected performance in $K$-band was considered to be insufficient to justify the added complexity of implementing the $K$ band in the system. Most of all, the $K$ band requires the use of ZBLAN fibers that provide a high-tranmission at wavelengths longer than 1.6\,\ensuremath{\muup\mathrm{m}}\xspace, which corresponds to the typical wavelength cutoff of pure silica fibers. However, ZBLAN fibers are expensive and not easy to handle without suffering damages. Moreover, few industrial companies are ready to accept the risk to work with this type of fibers for manufacturing a long fiber bundle such as the one required for HiRISE. For these reasons, we decided to drop support for the $K$ band and focus only on the $H$ band using a pure silica fiber, reference 1310M-HP, manufactured by Coherent (formerly Nufern).

In the FIM, the pick-off mirror is immediately followed by a relay lens that reimages the telescope pupil on a piezo tip-tilt stage. This tip-tilt is used to move the focal-plane image with respect to the fiber bundle and the tracking camera. The beam is (almost) recollimated by a custom cemented doublet, and then a custom dichroic filter designed and manufactured by the Fresnel institute\footnote{\url{https://www.fresnel.fr/}} that splits the wavelengths between the tracking channel (0.95--1.2\,\ensuremath{\muup\mathrm{m}}\xspace) and the science channel (1.4--1.8\,\ensuremath{\muup\mathrm{m}}\xspace). Finally, an air-gap doublet is used to reimage the focal-plane at F/3.5 on top of the science fibers in the bundle. F/3.5 does not exactly match the F-number expected by fibers (NA=0.16; F/3.3), but adopting a slightly larger value was mandatory to free some physical space for the mechanical implementation of the system. In the tracking channel, a doublet reimages the focal plane on the tracking camera, a C-RED 2 from First Light Imaging, with an focal ratio of F/40. The images on the tracking camera are Nyquist-sampled starting at 0.95\,\ensuremath{\muup\mathrm{m}}\xspace.

A retro-injection channel is included in the system to emit light from calibration fibers included in the fiber bundle and reimage them on the tracking camera on top of the astrophysical scene. These calibration fibers will be used for the acquisition procedure to center the planet's PSF on the science fiber, as detailed in [\citenum{ElMorsy:2022}]. Because the beam is not exactly collimated at the level of the dichroic filter, a corrector plate with a very long focal length was added in front of the corner cube to compensate for the small additional length between the dichroic and corner cube. The wavelength of the calibration source is at 1.3\,\ensuremath{\muup\mathrm{m}}\xspace, i.e. in the transition region of the dichroic filter.

The system is implemented on a vertical bench above the SPHERE/IFS beam. The pick-off mirror is introduced in the beam with an OWIS precision translation stage, which will be controlled from the SPHERE control software. Most mechanical parts are custom made from aluminum or Invar 36, manufactured by the mechanical workshop at the Georg-August-Universität in Göttingen. The other parts are off-the-shelf components from Thorlabs and Newport. The optics are a mix between off-the-shelf lenses and mirrors from Thorlabs and Edmund, and custom optics manufactured by \emph{Optique Fichou}\footnote{\url{https://www.optique-fichou.com/}} (France).

\begin{figure}
  \centering
  \includegraphics[width=1\textwidth]{Figures/fim_pictures}
  \caption{Pictures of some of the final FIM hardware. \emph{Left:} pre-assembly of the FIM mechanical structure. \emph{Top right:} custom dichroic filter. \emph{Bottom right:} FLI C-RED 2 tracking camera and its Pleora frame grabber.}
  \label{fig:fim_pictures}
\end{figure}

The fiber bundle will be held in a multi-axis fiber optic positioner from Newport using a custom interface piece. The multi-axis positioner will be used for the fine positioning of the bundle with respect to the injection optics. The focus and tip and tilt of the bundle were used as compensator in the tolerancing analysis of the optical design, so these degrees of freedom are essential for a fine alignment of the system.

\subsection{Fiber bundle}
\label{sec:implementation_fb}

\begin{figure}
  \centering
  \includegraphics[width=1\textwidth]{Figures/fb_concept}
  \caption{Global concept for the fiber bundle. The bundle is a single piece of hardware with no intermediate connectors in order to maximize the transmission of the astrophysical signal. It is divided in three sections: section A on the SPHERE side, section B around the telescope structure, and section C on the CRIRES+ side. Section B is more heavily protected than sections A and C, which lie in relatively protected environment inside of SPHERE and CRIRES+. The bundle includes 4 science fibers and a number of additional fibers used for target acquisition and for calibration. The bundle will be manufactured by Fibertech Optica (FTO) in Canada.}
  \label{fig:fb_concept}
\end{figure}

A schematic of the proposed design for the fiber bundle is presented in Fig.~\ref{fig:fb_concept}. The bundle is a single piece of hardware composed of three main sections. It features four science fibers (one dedicated to the planet) and ancillary fibers for calibration purposes. The bundle will be manufactured by Fibertech Optica\footnote{\url{https://fibertech-optica.com/}} (FTO) in Canada.

Section A is located on the SPHERE side and has a length of $\sim$3\,m. Most of its length is located inside of the SPHERE enclosure. A part of section A is located outside of the enclosure because the ancillary calibration fibers get in/out of the bundle at the level of the interface between section A and B, and they connect to calibration sources located inside the HiRISE electronics cabinet. The input of the bundle features an hexagonal pattern of fibers that includes the four science fibers, one fiber connected to a fluxmeter, and four retro-injection fibers connected to a calibration source at 1.3\,\ensuremath{\muup\mathrm{m}}\xspace. The purpose of these five calibration fibers is further described in [\citenum{ElMorsy:2022}]. The input of the bundle will be directly AR-coated with a coating covering both the science and calibration wavelengths.

Section B is the long section of the bundle that goes around the telescope structure. It is more heavily protected because it will be exposed to the harsh environment of the telescope where it can be crushed or stepped on. It includes a central glass rod and a tensile element to maintain the length, minimize the mechanical stresses on the fibers inside, and protect the fibers from breaking. The route around the telescope has been investigated by the Paranal observatory and a steel cable has been pulled all the way to verify the routing feasibility and measure the exact length (75\,m).

Finally, section C is located on the CRIRES+ side and has again a length of $\sim$3\,m. In the output ferrule, the fibers are arranged in a double line. The main line includes the four science fibers plus two external calibration fibers that will be used during AIT; this line of fibers will be aligned along the slit of the spectrograph. The second line includes two calibration fibers, which will be used for the MACAO system to maintain the deformable mirror flat during the HiRISE observations. One of the two calibration fibers is a SMF identical to the science fibers, and the other is a multi-mode fiber (MMF) with a 50\,\ensuremath{\muup\mathrm{m}}\xspace core. Again, the output of the bundle will be directly AR-coated with a coating covering both the science and calibration wavelengths.

The interface parts between sections A, B and C have been specified to minimize impact during the installation of the bundle at the telescope. For the installation, it is foreseen to start the routing on the SPHERE side, which has both the main bundle and ancillary fibers, and then route section B and C step-by-step around the telescope. It was originally proposed to have connectors at the interfaces between sections to make the installation easier, but designing connectors with losses lower than 0.2\,dB revealed to be extremely risky and costly, and the final level of losses could not be guaranteed.

\subsection{Fiber extraction module}
\label{sec:implementation_fem}

The FEM is implemented on the carrier stage unit (CSU) of the warm bench of CRIRES+. It is used to reimage the output of the science and calibration fibers in the VLT focal plane at F/15, which is the focal ratio expected by CRIRES+ for direct observations with the VLT. The opto-mechanical implementation of the FEM on the CSU is presented in Fig.~\ref{fig:fem_implementation}.

Compared to the FIM, the FEM is a much simpler system with no active device to be controlled. Its role is to simply reimage the fibers in the VLT focal plane. To make the installation easier and avoid unnecessary bending of the fibers, a folding mirror is implemented in the FEM so that the bundle's ferrule is simply inserted vertically at the top of the FEM. Since it is installed in the visitor gas cell slot of CRIRES+, the FEM must be easily removable in a matter of minutes. It is held in place by 3 screws that can be accessed without removing the cover. The FEM can then be put back in place quickly using a set of calibrated shims and the precision pins available on the CSU.

The FEM does not include active elements, but it must be able to deal with the MACAO adaptive optics system of CRIRES+, which is located downstream in the optical train. One of the difficulties of the MACAO system is that its deformable mirror cannot be maintained flat in open-loop on the timescale of hours, which are foreseen for the observations with HiRISE. To cope with that limitation, the fiber bundle include two calibration fibers (1 SMF, 1 MMF) located nearby the science fibers, which will be fed by a broadband source and will serve as an AO guide star for the MACAO system. Only one of the two will be used, but to keep some flexibility two different types of fibers were included in the design of the bundle: the SMF will be totally unresolved so that it truly resembles a stellar object, but the transmitted flux might be too low for MACAO; the MMF will be slightly resolved with its large 50\,\ensuremath{\muup\mathrm{m}}\xspace core, but it will provide a much higher flux. The two options will be tested during the commissioning.

\begin{figure}[h!]
  \centering
  \includegraphics[width=1\textwidth]{Figures/fem_implementation}
  \caption{\emph{Left:} Overview of the implementation of the FEM of the CSU at the entrance of CRIRES+. \emph{Right:} Detailed view of the opto-mechanical design of the FEM with a cut through the module. The interface part at the top that will hold the ferrule of the fiber bundle is not the final one in this drawing. The full module is about 15\,cm-long and 8\,cm-wide.}
  \label{fig:fem_implementation}
\end{figure}

\subsection{Electronics and control}
\label{sec:implementation_electronics}

\begin{figure}
  \centering
  \includegraphics[width=0.8\textwidth]{Figures/network_implementation}
  \caption{Devices and network implementation of HiRISE. The HiRISE workstation is directly embedded in the HiRISE electronics cabinet to make the installation of the system as easy as possible.}
  \label{fig:network_implementation}
\end{figure}

\begin{figure}
  \centering
  \includegraphics[width=1\textwidth]{Figures/fim_plc}
  \caption{Programmable logic controller (PLC) for the FIM, which controls some of the devices: calibration sources, temperature probes, flux meter and pick-off mirror translation stage. Other important devices such as the tip-tilt mirror and the tracking camera are controlled directly by the workstation through a private network.}
  \label{fig:fim_plc}
\end{figure}

\begin{figure}
  \centering
  \includegraphics[width=0.5\textwidth]{Figures/software_gui}
  \caption{Graphical user interface of the FIM control panel for HiRISE. The HiRISE instrument software is entirely developed following the VLT Software standards.}
  \label{fig:software_gui}
\end{figure}

The FIM in HiRISE includes several active and passive devices, which must be interfaced with the HiRISE workstation for operating the system. All the controllers are located in the HiRISE electronics cabinet (HiCab), which will be installed underneath the SPHERE instrument on the Nasmyth platform. To simplify the implementation, the HiRISE workstation is directly embedded within the HiCab in the form of an industrial computer running VLT Software (CentOS Linux 7.7 + VLT common software 2020).

The HiRISE workstation is connected to the devices and sensors through different means (Fig.~\ref{fig:network_implementation}). The iPORT frame grabber from Pleora Technologies is connected to the workstation using a dedicated 10GB/s network interface and short-range optical link. The tip-tilt stage controller (E272 from PI) and the connected power switch (iBoot-G2) are connected on the private HiRISE instrument network through a Cisco switch. Finally, the other devices and sensors are connected to a Beckhoff PLC computer, which is itself connected to the private HiRISE network to be accessible from the workstation. Pictures of the hardware in the integration clean room at LAM are presented in Fig.~\ref{fig:fim_plc}.

Finally, a dedicated control software and interface is in development for the control of the system. The main interface is presented in Fig.~\ref{fig:software_gui}. The HiRISE control software follows the same logic and organization as all VLT instruments in order to make the future operations as transparent as possible for the observatory staff. In particular, it is foreseen to develop dedicated templates for the main calibrations of FIM, as well as for the target centering, which corresponds to the accurate placement of the planet's PSF on the science fiber. The target (star) acquisition will be performed by the SPHERE system, and the scientific data acquisition by the CRIRES+ system.

\section{EXPECTED PERFORMANCE}
\label{sec:expected_perf}

\begin{figure}
  \centering
  \includegraphics[width=0.8\textwidth]{Figures/transmission_design=as-built_budget.pdf}
  \includegraphics[width=0.8\textwidth]{Figures/transmission_design=as-built_end-to-end.pdf}
  \caption{\emph{Top:} Individual components in the transmission budget for HiRISE, based on the final hardware (FIM, FEM), on simulations (fiber coupling), on lab measurements and theoretical values (fiber transmission), on measurements provided by the instrument consortia (SPHERE, CRIRES+), and on theoretical values (sky, telescope). See Sect.~\ref{sec:expected_perf} for more detailed explanations. \emph{Bottom:} Expected end-to-end transmission of the system based on the transmission budget. The plot includes a comparison with the values published in [\citenum{Otten:2021}], which were the current baseline for the development of the project.}
  \label{fig:transmission_budget}
\end{figure}

The end-to-end simulations of [\citenum{Otten:2021}] have clearly demonstrated that the final detection performance of HiRISE is driven by the overall transmission of the system. The transmission budget has been updated based on the final optical components and AR coatings. The complete budget is presented in Fig.~\ref{fig:transmission_budget}.

For SPHERE and CRIRES+ we rely on values that have been measured either in the lab or on sky, which have been kindly provided by the two instrument consortia. For the lenses in the FIM and the FEM, we use the AR coatings information provided by the optics manufacturers. For the mirrors, purchased from Edmund, we use a value 0.98 for the reflectivity at all wavelengths.

One of the important budget contributors is the fiber bundle, and in particular the coupling efficiency of the planet's PSF into the science fiber. For the fused silica fiber itself, we use the attenuation values provided in [\citenum{Cozmuta:2020}] and scaled to the attenuations provided at 1300 and 1500\,nm by Coherent for the 1310M-HP fiber (which are very slightly worse than the values from [\citenum{Cozmuta:2020}]). For the coupling efficiency we use the HiRISE simulation model\cite{Otten:2021} to compute the overlap integrals between the planet's PSF electric field and the field transmitted by the science fiber. For this computation, we include ExAO residuals (for a 0.8\hbox{$^{\prime\prime}$}\xspace seeing), SPHERE non-common path aberrations measured with ZELDA\cite{N'Diaye:2016,Vigan:2019,Vigan:2022,pyZELDA:2018}, and the wavefront errors of the FIM based on the Zemax model with as-built optics. We also include a centering error of $\sim$8\,mas ($\sim$0.2\,$\lambda/D$ at 1.6\,\ensuremath{\muup\mathrm{m}}\xspace) on the science fiber, which corresponds to a realistic pointing error after centering the planet on the science fiber\cite{ElMorsy:2022}.

The updated transmission budget shows a small gain of $\sim$20\% at 1.6\,\ensuremath{\muup\mathrm{m}}\xspace compared to the values previously reported in [\citenum{Otten:2021}]. This is encouraging for the final performance of HiRISE, which should hopefully be better than anticipated from previous end-to-end simulations. An update of the astrophysical simulations is currently on-going in preparation for the on-sky validation. The gains are mainly due to the high quality of the AR coatings for the custom optics, the quality of the coatings for the FIM dichroic, and the use of highly transmissive fused silica fibers. The current model does not take into account the transmitance of the glasses used for the custom lenses. This may have a slight negative impact that will be evaluated in the near future.

A significant contributor to the transmission budget is the SPHERE \texttt{DICH-K} dichroic, which is used to send the $K$ band light to IRDIS and the $YJH$ bands to the IFS and HiRISE. This dichroic shows a strong decrease of its transmission starting at 1.6\,\ensuremath{\muup\mathrm{m}}\xspace, which is clearly visible in the top panel of Fig.~\ref{fig:transmission_budget}. As part of the SPHERE+ project\cite{Boccaletti:2020}, an updated version of that dichroic could be considered to improve the transmission budget of HiRISE and the SPHERE IFS. Another possibility to improve the global transmission would be to switch to a dedicated fiber-fed spectrograph such as the VIPA concept\cite{Bourdarot:2018}, which recently demonstrated a transmission of the order of 40\% in H-band on sky Carlotti et al. (this conference).

\section{PROJECT STATUS AND SCHEDULE}
\label{sec:project_status}

HiRISE has followed a step-by-step approach for its validation by ESO. First, the science case for the instrument was submitted to ESO's observing programmes committee (OPC) in September 2019, which expressed a strong scientific support for the project at the end of 2019 and offered the technical aspects to be evaluated by the Paranal observatory and the ESO's scientific and technical committee (STC). Then, a visitor instrument proposal containing a full technical description was submitted to the STC in April 2020, leading to a validation by the STC and ESO's council at the end of 2020 and the acceptance of HiRISE as a visitor instrument for the VLT. The project will now hold a final review of the project with the observatory at the end of July 2022. This final review is not a final design review in the common sense of the term but a final validation of the technical aspects and interfaces that have already been thoroughly discussed between the project and the observatory. As a result, the procurement of the hardware has already started since 2020 (from long lead-time elements) and is now almost complete.

The HiRISE project is therefore entering its main AIT phase in Europe. At the time of writing (end of June 2022), all the hardware for the FIM has been received at LAM, which is the most complex part of the whole system. The bundle is expected to be delivered by FTO in October 2022, and the mechanical parts of the FEM will start to be manufactured over the summer. A ``SPHERE simulator'' is currently being aligned to deliver a beam with the same properties as the SPHERE IFS beam in which the FIM will be placed. In parallel, a fine pre-assembly of the FIM and its optics will be performed using metrology. Then, the SPHERE simulator and FIM will be aligned relative to each other so that the final optical alignment of the FIM can be performed. Because the fiber bundle will arrive later in the year and because the bundle will not easily be usable to assess the optical quality, we anticipate the use of a Phasics near-infrared wavefront sensor in the injection focal plane to evaluate the optical quality of the alignment. The procedure for the validation of the full system including the bundle and the FEM is still under study.

The current schedule foresees an installation of the system at the VLT between February and March 2023. Although this schedule may shift in case of major issues during AIT in Europe, slots have already been allocated in the observing schedule for period P110. These slots will be dedicated to the installation, which requires the telescope to be put offline for some days and nights, and to the on-sky validation of the system to assess the final performance. Assuming a reasonable level of performance, scientific observations could start at the beginning of P111 in April 2023.

HiRISE is a visitor instrument, which means that it will not be offered for observations to the community as a regular facility instrument. However, anyone interested to observe with HiRISE is cordially invited to contact the project to discuss opportunities. The project anticipates the submission of a large observing programme to observe most known sub-stellar companions observable from Paranal but additional programmes in collaboration with the HiRISE project team are a highly desirable possibility.

\acknowledgments

This project has received funding from the European Research Council (ERC) under the European Union’s Horizon 2020 research and innovation programme, grant agreements No. 757561 (HiRISE) and 678777 (ICARUS), from the \emph{Commission Spécialisée Astronomie-Astrophysique} (CSAA) of CNRS/INSU, and from the \emph{Action Spécifique Haute Résolution Angulaire} (ASHRA) of CNRS/INSU co-funded by CNES, and from Région Provence-Alpes-Côte d'Azur under grant agreement 2014-0276 (ASOREX).