# Non-Adiabatic Calculations

This chapter introduces the various approaches GYRE offers for
undertaking *non-adiabatic* calculations. These provide linear growth
or damping rates to accompany the usual frequencies/periods of
oscillation modes, and are therefore capable of predicting which
mode(s) will be self-excited.

Note

Not all types of stellar mode include the necessary data (e.g., thermodynamic coefficients, opacity partial derivatives) to undertake non-adiabatic calculations. The Model Capabilities section summarizes this information.

## Overview

To include non-adiabatic effects, GYRE augments the linearized mass, momentum and Poisson equations with the linearized heat and radiative diffusion equations (see the Linearized Equations section for full details). With these additions, the equations and their solutions become complex quantities. The assumed time dependence for perturbations is \(\propto \exp (-\ii \sigma t)\); therefore, the real part \(\sigmar\) and imaginary part \(\sigmai\) of the eigenfrequency are related to the mode period \(\Pi\) and growth e-folding time \(\tau\), respectively, via

Solving the non-adiabatic equations proceeds using the same general approach as in the adiabatic case, by searching for the roots of a discriminant function \(\Dfunc(\omega)\) (see the GYRE Fundamentals chapter for more details). However, a challenge is that there is no simple way to bracket roots in the complex plane. Instead, GYRE must generate initial trial roots that are close to the true roots, and then refine them iteratively. Currently, GYRE offers three methods for establishing the trial roots.

## Adiabatic Method

The adiabatic method involves adopting the (real) roots found from adiabatic calculations as the initial trial roots for the non-adiabatic problem. This works well as long as the adiabatic and non-adiabatic roots lie close together in the complex plane — typically, when the oscillation modes are only weakly non-adiabatic, with \(|\sigmai/\sigmar| \ll 1\).

To perform non-adiabatic calculations with the adiabatic method, set
the following parameters in the `&osc`

namelist group:

`nonadiabatic`

=`.TRUE.`

`adiabatic`

=`.TRUE.`

1

and the following parameters in the `&num`

namelist group:

You may also wish to use the following setting in the `&num`

namelist group:

`diff_scheme`

=`'MAGNUS_GL2'`

This tells GYRE to evaluate the finite-difference equations using the 2nd order Magnus scheme; experience suggests that this gives the most reliable convergence for the root refinement.

An example of the adiabatic method in action can be found in the

namelist input file,
which is set up to find \(\ell=0,\ldots,3\) modes of a
\(20\,\Msun\) \(\beta\) Cephei model using the adiabatic
method. The important parts are as follows:*$GYRE_DIR*/test/nad/mesa/bcep/gyre.in

```
&osc
nonadiabatic = .TRUE.
/
&num
diff_scheme = 'MAGNUS_GL2'
restrict_roots = .FALSE.
/
&scan
grid_type = 'LINEAR'
freq_min = 3.0
freq_max = 10.0
n_freq = 50
/
```

Note the `nonadiabatic`

parameter in the `&osc`

namelist
group, and the `diff_scheme`

parameter in the `&num`

namelist group. The `restrict_roots`

=`.FALSE.`

setting, also in the `&num`

namelist group, tells GYRE not to
reject any modes that have \(\sigmar\) outside the frequency range
specified by the `&scan`

namelist group; this ensures that modes
whose non-adiabatic frequencies fall just outside the frequency grid
are still found.

## Minmod Method

The minmod method involves evaluating the discriminant function along the real-\(\omega\) axis, and then adopting local minima in its modulus \(|\Dfunc|\) as the initial trial roots for the non-adiabatic problem. The method is described in full in Goldstein & Townsend (2020); as shown there, it does not perform significantly better than the adiabatic method, and is included in GYRE for the sake of completeness.

To perform non-adiabatic calculations with the minmod method, set
the following parameters in the `&osc`

namelist group:

`nonadiabatic`

=`.TRUE.`

`adiabatic`

=`.FALSE.`

2

and the following parameters in the `&num`

namelist group:

`nad_search`

=`'MINMOD'`

As with the adiabatic method, you may also wish to use the following
setting in the `&num`

namelist group:

`diff_scheme`

=`'MAGNUS_GL2'`

An example of the minmod method in action can be found in the

namelist input
file, which is equivalent to
*$GYRE_DIR*/test/nad/mesa/bcep-minmod/gyre.in

but using the
minmod method. The important parts are as follows:*$GYRE_DIR*/test/nad/mesa/bcep/gyre.in

```
&osc
adiabatic = .FALSE.
nonadiabatic = .TRUE.
/
&num
diff_scheme = 'MAGNUS_GL2'
nad_search = 'MINMOD'
restrict_roots = .FALSE.
/
&scan
grid_type = 'LINEAR'
freq_min = 3.0
freq_max = 10.0
n_freq = 250
/
```

Note the additional `nad_search`

=`'MINMOD'`

parameter
in the `&num`

namelist group, which stipulates that the minmod
method should be used.

## Contour Method

The contour method involves evaluating the discriminant function on a grid in the complex-\(\omega\) plane, and then adopting intersections between the real zero-contours \(\Dfuncr=0\), and the corresponding imaginary ones \(\Dfunci=0\), as the initial trial roots for the non-adiabatic problem. The method is described in full in Goldstein & Townsend (2020); it is very effective even for strongly non-adiabatic modes with \(|\sigmai/\sigmar| \sim 1\), although there is an increased computational cost (see here for one strategy for mitigating this cost).

To perform non-adiabatic calculations with the contour method, set
the following parameters in the `&osc`

namelist group:

`nonadiabatic`

=`.TRUE.`

`adiabatic`

=`.FALSE.`

2

and the following parameters in the `&num`

namelist group:

`nad_search`

=`'CONTOUR'`

You must also ensure that at least one `&scan`

namelist
group with `axis`

=`'REAL'`

is present, and likewise
at least one with `axis`

=`'IMAG'`

. Together, these
groups define the real and imaginary axes of the discriminant grid in
the complex-\(\omega\) plane. As a rule of thumb, the resolution
along the imaginary axis should be comparable to that along the real
axis; this ensures that the contour-tracing algorithm behaves well.

Finally, as with the adiabatic method, you may also wish to use the
following setting in the `&num`

namelist group:

`diff_scheme`

=`'MAGNUS_GL2'`

Note

Because g modes are spaced uniformly in period (in the asymptotic
limit of large radial order), it would seem sensible to set
`grid_type`

=`'INVERSE'`

in the `&scan`

namelist group(s) that correspond to the real axis (i.e.,
`axis`

=`'REAL'`

). However, this typically results
in a mismatch between the resolution of the real and imaginary
axes, and the contour method doesn’t perform well. A fix for this
issue will be forthcoming in the next release of GYRE, but in the
meantime it’s probably best to avoid the contour method for g
modes.

An example of the minmod method in action can be found in the

namelist input
file, which is equivalent to
*$GYRE_DIR*/test/nad/mesa/bcep-contour/gyre.in

but using the
minmod method. The important parts are as follows:*$GYRE_DIR*/test/nad/mesa/bcep/gyre.in

```
&osc
adiabatic = .FALSE.
nonadiabatic = .TRUE.
/
&num
diff_scheme = 'MAGNUS_GL2'
restrict_roots = .FALSE.
nad_search = 'CONTOUR'
/
&scan
axis = 'REAL'
grid_type = 'LINEAR'
freq_min = 3.0
freq_max = 10.0
n_freq = 50
/
&scan
axis = 'IMAG'
grid_type = 'LINEAR'
freq_min = -0.28
freq_max = 0.28
n_freq = 5
/
```

Note the additional `nad_search`

=`'CONTOUR'`

parameter in the `&num`

namelist group, which stipulates that
the contour method should be used; and, the fact that there are now
two `&scan`

namelist groups, one with `axis`

=`'REAL'`

and the other with `axis`

=`'IMAG'`

.

Footnotes