One's can find following definition of tamagawa numbers in Dino Lorenzini paper "Torsion and Tamagawa numbers":

Let $K$ be any discrete valuation field with ring of integers $O_K$ , uniformizer $\pi$, and residue field $k$ of characteristic $p \ge 0$. Let $A/K$ be an abelian variety of dimension $g$. Let $A/O_K$ denote the Neron model of $A/K$. The special fiber $A_k/k$ of $A$ is the extension $$(0) \rightarrow A^0_k \rightarrow A_k \rightarrow Φ \rightarrow (0)$$ of a finite etale group scheme $Φ/k$, called the group of components, by a connected smooth group scheme $A^0_k/k$, the connected component of 0. The order of the finite abelian group $Φ(k)$ is called the Tamagawa number of A/K. Let now $K$ be a global field, and $v$ a non-archimedean place of $K$, with completion $K_v$ and residue field $k_v$. Let $c_v$ denote the Tamagawa number of $A_{K_v}/{K_v}$, and let $c = c(A/K) := \prod_v c_v$.

I have hyperelliptic curve of genus 2 over $\mathbb Q$. The questions are:

- Is it true that I can extract Tamagawa numbers ($c_v$ in definition) from Sage function
`genus2reduction`

(see below) output and calculate Tamagawa product (called $c$ in definition) from them? Is it ok that group of connected components is over an algebraic closure of $\mathbb F_p$? - Is it true that I can use Magma's
`RegularModel`

(see below) and get tamagawa numbers $c_p$ ($=c_v$) as orders of Magma's`ComponentGroup`

for corresponding $p$? I'm confused by`group of components of the Neron model of the Jacobian of C over the **completion** at P`

. There is no mentioned of completition in Sage function. I'm not sure that I understand all things right. - Is it true that in second case if I want to get Tamagawa product I should just calculate product of $c_p$ for all $p$ that divide discriminant of my curve?

There are Necessary documentation notes about corresponding Sage and Magma functions.

Sage genus2reduction function ducumentation says following:

Use $R = genus2reduction(Q, P)$ to obtain reduction information about the Jacobian of the projective smooth curve defined by $y^2+Q(x)y=P(x)$. $$\dots$$ The second datum is the GROUP OF CONNECTED COMPONENTS (over an ALGEBRAIC CLOSURE (!) of $\mathbb F_p$) of the Neron model of $J(C)$.

From the other side Stain in his note "What are Neron Models?" writes:

When $A$ is the Jacobian of a curve $X$, there is an alternative approach that involves the "minimal proper regular model" of $X$. For example, when $A$ is an elliptic curve, it is the Jacobian of itself, and the Neron model can be constructed in terms of the minimal proper regular model $X$ of $A$ as follows. In general, the model $X → R$ is not also smooth. Let $X'$ be the smooth locus of $X → R$, which is obtained by removing from each closed fiber $X_{F_p} = \sum n_i C_i$ all irreducible components with multiplicity $n_i \ge 2$ and all singular points on each $C_i$, and all points where at least two $C_i$ intersect each other. Then the group structure on $A$ extends to a group structure on $X'$ , and $X'$ equipped with this group structure is the Neron model of A.

And Magma documentation on RegularModel says:

RegularModel(C, P) : Crv, Any -> CrvRegModel

This computes a regular model of the curve $C$ at the prime $P$. Here $C$ is a curve over a field $F$ (the rationals, a number field or a univariate rational function field), and $P$ is a prime of the maximal order $O_F$ of $F$ (given as an element or as an ideal).

ComponentGroup(M) : CrvRegModel -> GrpAb

Given a regular model of a curve $C$ at a prime $P$, this returns (as an abstract abelian group) the group of components of the Neron model of the Jacobian of $C$ over the completion at $P$. (This is computed from the IntersectionMatrix of the model.)

I'm quite new in this field and I'm sorry if my questions are silly.