This page was generated by nbsphinx from docs/notebooks/braginskii.ipynb.
Interactive online version: Binder badge.

[1]:
%matplotlib inline

Braginskii coefficients

A short example of how to calculate classical transport coefficients from Bragiński’s theory.

[2]:
from astropy import units as u
from plasmapy.formulary import ClassicalTransport

We’ll use some sample ITER data, without much regard for whether the regime is even fit for classical transport theory:

[3]:
thermal_energy_per_electron = 8.8 * u.keV
electron_concentration = 10.1e19 / u.m**3

thermal_energy_per_ion = 8.0 * u.keV
ion_concentration = electron_concentration
ion = 'D+'  # a crude approximation

We now make the default ClassicalTransport object:

[4]:
braginskii = ClassicalTransport(thermal_energy_per_electron,
                                electron_concentration,
                                thermal_energy_per_ion,
                                ion_concentration,
                                ion)
WARNING: ImplicitUnitConversionWarning: The argument 'T_e' to function __init__() has a non-standard unit conversion...converting keV to K [plasmapy.utils.decorators.validators]
WARNING: ImplicitUnitConversionWarning: The argument 'T_i' to function __init__() has a non-standard unit conversion...converting keV to K [plasmapy.utils.decorators.validators]
/home/docs/checkouts/readthedocs.org/user_builds/plasmapy/envs/latest/lib/python3.7/site-packages/plasmapy-0.3.2.dev44+g511c25b-py3.7.egg/plasmapy/utils/decorators/checks.py:1393: RelativityWarning: thermal_speed is yielding a velocity that is 18.561% of the speed of light. Relativistic effects may be important.
  RelativityWarning,
/home/docs/checkouts/readthedocs.org/user_builds/plasmapy/envs/latest/lib/python3.7/site-packages/plasmapy-0.3.2.dev44+g511c25b-py3.7.egg/plasmapy/utils/decorators/checks.py:1393: RelativityWarning: V is yielding a velocity that is 18.561% of the speed of light. Relativistic effects may be important.
  RelativityWarning,
/home/docs/checkouts/readthedocs.org/user_builds/plasmapy/envs/latest/lib/python3.7/site-packages/plasmapy-0.3.2.dev44+g511c25b-py3.7.egg/plasmapy/utils/decorators/checks.py:1393: RelativityWarning: thermal_speed is yielding a velocity that is 18.559% of the speed of light. Relativistic effects may be important.
  RelativityWarning,
WARNING: UnitsWarning: The argument 'z_mean' to function collision_frequency() has no specified units. Assuming units of . To silence this warning, explicitly pass in an astropy Quantity (e.g. 5. * astropy.units.cm) (see http://docs.astropy.org/en/stable/units/) [plasmapy.utils.decorators.validators]
/home/docs/checkouts/readthedocs.org/user_builds/plasmapy/envs/latest/lib/python3.7/site-packages/plasmapy-0.3.2.dev44+g511c25b-py3.7.egg/plasmapy/utils/decorators/checks.py:1393: RelativityWarning: V is yielding a velocity that is 18.559% of the speed of light. Relativistic effects may be important.
  RelativityWarning,

These variables are calculated during initialization and can be referred to straight away:

[5]:
print(braginskii.coulomb_log_ei)
print(braginskii.coulomb_log_ii)
print(braginskii.hall_e)
print(braginskii.hall_i)
18.015542112815666
20.41557520752423
0.0
0.0

These quantities are not calculated during initialization and can be referred to via methods. To signify the need to calculate them, we call them via ().

[6]:
print(braginskii.resistivity)
print(braginskii.thermoelectric_conductivity)
print(braginskii.electron_thermal_conductivity)
print(braginskii.ion_thermal_conductivity)
1.1541382845331304e-09 m Ohm
0.7110839986207994
1065176076.6192665 W / (K m)
21360464.463766705 W / (K m)
WARNING: UnitsWarning: The argument 'z_mean' to function Coulomb_logarithm() has no specified units. Assuming units of . To silence this warning, explicitly pass in an astropy Quantity (e.g. 5. * astropy.units.cm) (see http://docs.astropy.org/en/stable/units/) [plasmapy.utils.decorators.validators]

They also change with magnetization:

[7]:
mag_braginskii = ClassicalTransport(thermal_energy_per_electron,
                                    electron_concentration,
                                    thermal_energy_per_ion,
                                    ion_concentration,
                                    ion,
                                    B = 0.1 * u.T)

print(mag_braginskii.resistivity)
print(mag_braginskii.thermoelectric_conductivity)
print(mag_braginskii.electron_thermal_conductivity)
print(mag_braginskii.ion_thermal_conductivity)
1.1541382845331304e-09 m Ohm
0.7110839986207994
1065176076.6192665 W / (K m)
21360464.463766705 W / (K m)

They also change with direction with respect to the magnetic field. Here, we choose to print out, as arrays, the (parallel, perpendicular, and cross) directions. Take a look at the docs to ClassicalTransport for more information on these.

[8]:
all_direction_braginskii = ClassicalTransport(thermal_energy_per_electron,
                                              electron_concentration,
                                              thermal_energy_per_ion,
                                              ion_concentration,
                                              ion,
                                              B = 0.1 * u.T,
                                              field_orientation = 'all')

print(all_direction_braginskii.resistivity)
print(all_direction_braginskii.thermoelectric_conductivity)
print(all_direction_braginskii.electron_thermal_conductivity)
print(all_direction_braginskii.ion_thermal_conductivity)
[1.15413828e-09 2.25078755e-09 1.39690568e-15] m Ohm
[7.11083999e-01 6.76676822e-13 5.46328992e-07]
[1.06517608e+09 2.08451764e-04 3.06777888e+02] W / (K m)
[2.13604645e+07 4.24754851e-03 2.69422221e+02] W / (K m)

The viscosities return arrays:

[9]:
print(braginskii.electron_viscosity)
print(mag_braginskii.electron_viscosity)
print(braginskii.ion_viscosity)
print(mag_braginskii.ion_viscosity)
[16.29411376 16.28874805 16.28874805  0.          0.        ] Pa s
[1.62941138e+01 2.00480711e-25 8.01922844e-25 1.47442522e-12
 2.94885044e-12] Pa s
[1271.38945503 1267.52435833 1267.52435833    0.            0.        ] Pa s
[1.27138946e+03 5.99222933e-17 2.39689173e-16 2.57162285e-07
 5.14324570e-07] Pa s