## broccoli - a program to compute broccoli invariants

Broccoli is a GAP program to compute broccoli invariants as in the paper by A. Gathmann, H. Markwig, and F. Schroeter: Broccoli curves and the tropical invariance of Welschinger numbers, E-print arXiv:1104.3118 pdf. As a special case of this, Welschinger invariants (of two-dimensional projective space) can be computed as well.

Broccoli invariants are enumerative numbers in tropical geometry that generalize Welschinger invariants (with real or complex conjugate point conditions) of the plane. They count so-called broccoli curves - certain tropical curves of given degree $d$ in the plane passing through $r+s$ fixed general points, where $r$ of the points correspond to real and the other $s$ to complex conjugate point conditions. Additionally, the curves can be required to have certain weights at their left ends: for this one has to give two multi-indices $\alpha = (\alpha_1,\alpha_2,\dots)$ and $\beta = (\beta_1,\beta_2,\dots)$, signifying that for all $i$ the curves must have $\alpha_i$ fixed and $\beta_i$ unfixed left ends of weight $i$. If no such additional weight conditions are given, one obtains exactly the Welschinger invariants. This can be achieved by choosing $\alpha=()$ and $\beta=(d)$, i.e. by requiring no fixed and $d$ unfixed left ends of weight 1.

As shown in the above paper, the broccoli invariants satisfy recursive Caporaso-Harris type equations. These equations are used by the program to compute the numbers.

#### Examples

To compute the invariants, one passes the program broccoli to GAP and calls the function Broccoli with the above values in the order $d$, $r$, $s$, $\alpha$, and $\beta$. The lists $\alpha$ and $\beta$ can have any length (including 0), missing entries are set to 0. To get a finite invariant the parameters have to satisfy the dimension condition $r+2s = 2d+|\beta|-1$, where $|\beta|$ denotes the sum of the entries of $\beta$. Moreover, the degree condition $\sum_i (i \alpha_i + i \, \beta_i) = d$ has to be satisfied.

gap> Read("broccoli");
gap> Broccoli(3,4,1,[0,1],[1]);
-8


The Welschinger invariants can also be computed with the function Welschinger(d,r,s); this is just a short-hand notation for Broccoli(d,r,s,[],[d]).

gap> Welschinger(2,5,0);
1
gap> Welschinger(3,8,0);
8
gap> Welschinger(3,6,1);
6


#### Remarks

If desired, the program broccoli can also indicate during the computation which Caporaso-Harris formula is used for an invariant and which terms are occurring in it. For this one has to set the variable output to 1 before the computation:

gap> output := 1;;
gap> Broccoli(3,4,1,[0,1],[1]);

Computing the invariant (3,4,1,[0,1],[1]) ...

Move real point:
A: 1 (3,3,1,[1,1],[0]) -> -4
D: -4 (2,3,1,[],[2]) -> -4
Result from moving real point: -8

-8


The notations in this output correspond to those in chapter 6 of the paper mentioned above.