Reference

iricore.iri(dt, altrange, lat, lon, version=20, jf=None, **kwargs)

The main function of the package representing the IRI_SUB routine from the IRI source code. Provides access to all IRI calculations through the wide range of parameters.

Parameters:
  • dt (datetime) – Date and time - must be a single value.

  • altrange (Sequence[float]) – Range of altitudes in the form (alt_start, alt_stop, alt_step), all in [km].

  • lat (Union[float, Sequence[float]]) – Geographical latitude.

  • lon (Union[float, Sequence[float]]) – Geographical longitude.

  • version (Literal[16, 20], default: 20) –

    Version of the IRI to use:

    • version=16 - IRI-2016

    • version=20 - IRI-2020

  • jf (Optional[Union[ndarray, str]], default: None) – Array of JF parameters or string for predefined JF arrays to be used in the IRI_SUB function. See iricore.get_jf() for details. If not specified otherwise, the default IRI JF array will be used.

  • kwargs

    Use it to enter user input values for the IRI calculation. Names of parameters are ‘oarr’+’[oarr index you want to modify]’. Available parameters are:

    • oarr0 - float - user input for foF2/MHz or NmF2/m-3

    • oarr1 - float - user input for hmF2/km or M(3000)F2

    • oarr2 - float - user input for foF1/MHz or NmF1/m-3

    • oarr3 - float - user input for hmF1/km

    • oarr4 - float - user input for foE/MHz or NmE/m-3

    • oarr5 - float - user input for hmE/km

    • oarr9 - float - user input for B0

    • oarr14 - (float, float) - user input for Ne(300km), Ne(400km)/m-3. Use oarr14[…]=-1 if one of these values is not available. If jf(22)==False then Ne(300km), Ne(550km)/m-3.

    • oarr32 - float - user input for Rz12

    • oarr34 - float - user input for B1

    • oarr38 - float - user input for IG12

    • oarr40 - float - user input for daily F10.7 index (make sure to also specify oarr45, otherwise it will be copied from oarr40)

    • oarr45 - float - user input for 81-day avg F10.7

Return type:

IRIOutput

Returns:

iricore.IRIOutput dataclass.

class iricore.IRIOutput(lat, lon, height, edens, ntemp, itemp, etemp, o, h, he, o2, no, cluster, n, firi_output, oarr)

Dataclass containing iricore.iri() output. If lat/lon are 1D arrays, then the IRI returned values will a 2D array with shape (lat.size, alt.size). If lat/lon are a single number, the returned values will be an 1D array with shape (alt.size).

Parameters:
  • lat (ndarray) – Array of latitudes corresponding to the IRI output (0 axis).

  • lon (ndarray) – Array of longitudes corresponding to the IRI output (0 axis).

  • height (ndarray) – Array of heights corresponding to the IRI output (1 axis).

  • edens (ndarray) – Electron density in [m-3].

  • ntemp (ndarray) – Neutral temperature in [K].

  • itemp (ndarray) – Ion temperature in [K].

  • etemp (ndarray) – Electron temperature in [K].

  • o (ndarray) – O+ ion density in [%](default) or [m-3].

  • h (ndarray) – H+ ion density in [%](default) or [m-3].

  • he (ndarray) – He+ ion density in [%](default) or [m-3].

  • o2 (ndarray) – O2+ ion density in [%](default) or [m-3].

  • no (ndarray) – NO+ ion density in [%](default) or [m-3].

  • cluster (ndarray) – Cluster ion density in [%](default) or [m-3].

  • n (ndarray) – N+ ion density in [%](default) or [m-3].

  • firi_output (ndarray) –

    If FIRI was manually selected for the D-region, the firi_output will be an 1D array containing:

    • [0:10] standard IRI-Ne for 60,65,..,110km;

    • [11:21] Friedrich (FIRI) model at these heights;

    • [22:32] standard Danilov (SW=0, WA=0);

    • [33:43] for minor Stratospheric Warming (SW=0.5);

    • [55:65] weak Winter Anomaly (WA=0.5) conditions;

    • [44:54] for major Stratospheric Warming (SW=1);

    • [66:76] strong Winter Anomaly (WA=1) conditions.

  • oarr (ndarray) –

    Additional output data. First index axis corresponds to different coordinates, for example, oarr[0] will correspond to lat[0] and lon[0] and so on. The second index axis has size 100 and maps the extra output information. If only one coordinate was calculated, the first axis is discarded.

    • oarr[0] = NMF2/M-3

    • oarr[1] = HMF2/KM

    • oarr[2] = NMF1/M-3

    • oarr[3] = HMF1/KM

    • oarr[4] = NME/M-3

    • oarr[5] = HME/KM

    • oarr[6] = NMD/M-3

    • oarr[7] = HMD/KM

    • oarr[8] = HHALF/KM

    • oarr[9] = B0/KM

    • oarr[10] = VALLEY-BASE/M-3

    • oarr[11] = VALLEY-TOP/KM

    • oarr[12] = TE-PEAK/K

    • oarr[13] = TE-PEAK HEIGHT/KM

    • oarr[14] = TE-MOD(300KM)

    • oarr[15] = TE-MOD(400KM)/K

    • oarr[16] = TE-MOD(600KM)

    • oarr[17] = TE-MOD(1400KM)/K

    • oarr[18] = TE-MOD(3000KM)

    • oarr[19] = TE(120KM)=TN=TI/K

    • oarr[20] = TI-MOD(430KM)

    • oarr[21] = X/KM, WHERE TE=TI

    • oarr[22] = SOL ZENITH ANG/DEG

    • oarr[23] = SUN DECLINATION/DEG

    • oarr[24] = DIP/deg

    • oarr[25] = DIP LATITUDE/deg

    • oarr[26] = MODIFIED DIP LAT.

    • oarr[27] = Geographic latitude

    • oarr[28] = sunrise/dec. hours

    • oarr[29] = sunset/dec. hours

    • oarr[30] = ISEASON (1=spring)

    • oarr[31] = Geographic longitude

    • oarr[32] = Rz12

    • oarr[33] = Covington Index

    • oarr[34] = B1

    • oarr[35] = M(3000)F2

    • oarr[36] = TEC/m-2

    • oarr[37] = TEC_top/TEC*100.

    • oarr[38] = gind (IG12)

    • oarr[39] = F1 probability

    • oarr[40] = F10.7 daily

    • oarr[41] = c1 (F1 shape)

    • oarr[42] = daynr

    • oarr[43] = equatorial vertical ion drift in m/s

    • oarr[44] = foF2_storm/foF2_quiet

    • oarr[45] = F10.7_81

    • oarr[46] = foE_storm/foE_quiet

    • oarr[47] = spread-F probability

    • oarr[48] = Geomag. latitude

    • oarr[49] = Geomag. longitude

    • oarr[50] = ap at current time

    • oarr[51] = daily ap

    • oarr[52] = invdip/degree

    • oarr[53] = MLT-Te

    • oarr[54] = CGM-latitude

    • oarr[55] = CGM-longitude

    • oarr[56] = CGM-MLT

    • oarr[57] = CGM lat eq. aurl bodry

    • oarr[58] = CGM-lati(MLT=0)

    • oarr[59] = CGM-lati for MLT=1

    • oarr[60] = CGM-lati(MLT=2)

    • oarr[61] = CGM-lati for MLT=3

    • oarr[62] = CGM-lati(MLT=4)

    • oarr[63] = CGM-lati for MLT=5

    • oarr[64] = CGM-lati(MLT=6)

    • oarr[65] = CGM-lati for MLT=7

    • oarr[66] = CGM-lati(MLT=8)

    • oarr[67] = CGM-lati for MLT=9

    • oarr[68] = CGM-lati(MLT=10)

    • oarr[69] = CGM-lati for MLT=11

    • oarr[70] = CGM-lati(MLT=12)

    • oarr[71] = CGM-lati for MLT=13

    • oarr[72] = CGM-lati(MLT=14)

    • oarr[73] = CGM-lati for MLT=15

    • oarr[74] = CGM-lati(MLT=16)

    • oarr[75] = CGM-lati for MLT=17

    • oarr[76] = CGM-lati(MLT=18)

    • oarr[77] = CGM-lati for MLT=19

    • oarr[78] = CGM-lati(MLT=20)

    • oarr[79] = CGM-lati for MLT=21

    • oarr[80] = CGM-lati(MLT=22)

    • oarr[81] = CGM-lati for MLT=23

    • oarr[82] = Kp at current time

    • oarr[83] = magnetic declination

    • oarr[84] = L-value

    • oarr[85] = dipole moment

    • oarr[86] = SAX300

    • oarr[87] = SUX300

    • oarr[88] = HNEA

    • oarr[89] = HNEE

iricore.stec(el, az, dt, lat, lon, hobs=0, hbot=90, htop=2000, npoints=1000, heights=None, version=20, jf=None, return_details=False, **kwargs)

Slant TEC calculated by integrating the electron density on the line of sight. This function is not a part of the source IRI code.

Parameters:
  • el (float) – elevation of observation in [deg].

  • az (float) – azimuth of observation in [deg].

  • dt (datetime) – time of observation.

  • lat (float) – Geographical latitude.

  • lon (float) – Geographical longitude.

  • hobs (float, default: 0) – Height of the observer above the sea level.

  • hbot (float, default: 90) – Bottom height limit for integration in [km].

  • htop (float, default: 2000) – Upper height limit for integration in [km].

  • npoints (int, default: 1000) – Number of points to integrate.

  • heights (Optional[ndarray], default: None) – Overrides the height grid with a custom array of height in [km]

  • version (Literal[16, 20], default: 20) – IRI version number.

  • jf (Optional[Union[ndarray, str]], default: None) – Array of JF parameters or string for predefined JF arrays to be used in the IRI_SUB function. See iricore.get_jf() for details. If not specified otherwise, the default IRI JF array will be used.

  • return_details (bool, default: False) – If True - also returns history with ray position, corresponding electron density and the oarr array. Dict keys: [‘lat’, ‘lon’, ‘h’, ‘edens’, ‘oarr’]

  • kwargs

    Use it to enter user input values for the IRI calculation. Names of parameters are ‘oarr’+’[oarr index you want to modify]’. Available parameters are:

    • oarr0 - float - user input for foF2/MHz or NmF2/m-3

    • oarr1 - float - user input for hmF2/km or M(3000)F2

    • oarr2 - float - user input for foF1/MHz or NmF1/m-3

    • oarr3 - float - user input for hmF1/km

    • oarr4 - float - user input for foE/MHz or NmE/m-3

    • oarr5 - float - user input for hmE/km

    • oarr9 - float - user input for B0

    • oarr14 - (float, float) - user input for Ne(300km), Ne(400km)/m-3. Use oarr14[…]=-1 if one of these values is not available. If jf(22)==False then Ne(300km), Ne(550km)/m-3.

    • oarr32 - float - user input for Rz12

    • oarr34 - float - user input for B1

    • oarr38 - float - user input for IG12

    • oarr40 - float - user input for daily F10.7 index (make sure to also specify oarr45, otherwise it will be copied from oarr40)

    • oarr45 - float - user input for 81-day avg F10.7

Return type:

Union[float, Sequence]

Returns:

Slant TEC.

iricore.vtec(dt, lat, lon, hbot=90, htop=2000, hstep=0.5, version=20, jf=None, **kwargs)

Vertical TEC calculated by integrating the electron density on the line of sight. This function is not a part of the source IRI code.

Parameters:
  • dt (datetime) – time of observation.

  • lat (float | ndarray) – Geographical latitude.

  • lon (float | ndarray) – Geographical longitude.

  • hbot (float, default: 90) – Bottom height limit for integration in [km].

  • htop (float, default: 2000) – Upper height limit for integration in [km].

  • hstep (float, default: 0.5) – Height step for integration in [km].

  • version (Literal[16, 20], default: 20) – IRI version number.

  • jf (Optional[Union[ndarray, str]], default: None) – Array of JF parameters or string for predefined JF arrays to be used in the IRI_SUB function. See iricore.get_jf() for details. If not specified otherwise, the default IRI JF array will be used.

  • kwargs

    Use it to enter user input values for the IRI calculation. Names of parameters are ‘oarr’+’[oarr index you want to modify]’. Available parameters are:

    • oarr0 - float - user input for foF2/MHz or NmF2/m-3

    • oarr1 - float - user input for hmF2/km or M(3000)F2

    • oarr2 - float - user input for foF1/MHz or NmF1/m-3

    • oarr3 - float - user input for hmF1/km

    • oarr4 - float - user input for foE/MHz or NmE/m-3

    • oarr5 - float - user input for hmE/km

    • oarr9 - float - user input for B0

    • oarr14 - (float, float) - user input for Ne(300km), Ne(400km)/m-3. Use oarr14[…]=-1 if one of these values is not available. If jf(22)==False then Ne(300km), Ne(550km)/m-3.

    • oarr32 - float - user input for Rz12

    • oarr34 - float - user input for B1

    • oarr38 - float - user input for IG12

    • oarr40 - float - user input for daily F10.7 index (make sure to also specify oarr45, otherwise it will be copied from oarr40)

    • oarr45 - float - user input for 81-day avg F10.7

Returns:

Vertical TEC.

iricore.update()

Download the newest version of files with solar indices. The files are updated daily.

iricore.get_jf(preset='default')

Generates and returns an integer array of IRI JF parameters with 50 elements. So far, the 'default' and 'default_edens' presets are available. Both follow the default IRI settings, but with disabled messages. The 'default_edens' option additionally disables calculation of all other models, leaving only electron density.

The following table was reconstructed from the IRI official documentation and provides a summary of available IRI parameters. Some of them cannot be used in iricore because the user input is handled separately. You can directly enter manual user input using iricore.iri() kwargs (see iricore.iri() documentation), which will modify JF flags automatically.

Index

If True

If False

Default

Used

0

Ne computed

Ne not computed

True

1

Te, Ti computed

Te, Ti not computed

True

2

Ne & Ni computed

Ni not computed

True

3

B0,B1 - Bil-2000

B0,B1 - other models jf(30)

False

4

foF2 - CCIR

foF2 - URSI

False

5

Ni - DS-1995 & DY-1985

Ni - RBV-2010 & TBT-2015

False

6

Ne - Tops: f10.7<188

f10.7 unlimited

True

7

foF2 from model

foF2 or NmF2 - user input

True

8

hmF2 from model

hmF2 or M3000F2 - user input

True

9

Te - Standard

Te - Using Te/Ne correlation

True

10

Ne - Standard Profile

Ne - Lay-function formalism

True

11

Messages to unit 6

to messages.txt on unit 11

True

12

foF1 from model

foF1 or NmF1 - user input

True

13

hmF1 from model

hmF1 - user input (only Lay version)

True

14

foE from model

foE or NmE - user input

True

15

hmE from model

hmE - user input

True

16

Rz12 from file

Rz12 - user input

True

17

IGRF dip, magbr, modip old

FIELDG using POGO68/10 for 1973

True

18

F1 probability model

only if foF1>0 and not NIGHT

True

19

standard F1

standard F1 plus L condition

True

[18, 19]

[True, True]: f1-prob(t,f)

[False, True]: old F1

[18, 19]

[True, False]: f1-prob-L

[False, False]: (f,f) no F1

20

ion drift computed

ion drift not computed

True

21

ion densities in %

ion densities in m-3

True

22

Te_tops (Bil-1985)

Te_topside (TBT-2012)

False

23

D-region: IRI-1990

FT-2001 and DRS-1995

True

24

F107D from APF107.DAT

F107D user input (oarr(40))

True

25

foF2 storm model

no storm updating

True

26

IG12 from file

IG12 - user

True

27

spread-F probability

not computed

True

28

IRI01-topside

new options as def. by JF[29]

True

29

IRI01-topside corr.

NeQuick topside model

False

[28, 29]

[True, True]: IRIold

[False, True]: IRIcor

[28, 29]

[True, False]: IRIcor2

[False, False]: (f,f) NeQuick

30

B0,B1 ABT-2009

B0 Gulyaeva-1987 h0.5

True

[4, 30]

[True, True]: Bil-00

[False, True]: ABT-09

[4, 30]

If [True, False]: not used

If [False, False]: (f,f) Gul-87

31

F10.7_81 from file

F10.7_81 - user input (oarr(44))

True

32

Auroral boundary model on

ABM off

False

33

Messages on

Messages off

True

34

foE storm model

no foE storm updating

False

35

hmF2 w/out foF2_storm

with foF2-storm

True

36

topside w/out foF2-storm

with foF2-storm

True

37

turn WRITEs off in IRIFLIP

turn WRITEs on

True

38

hmF2 (M3000F2)

new models

False

39

hmF2 AMTB-model

Shubin-COSMIC model

False

[38, 39]

[True, True]: hmF2-old

[False, True]: AMTB

[38, 39]

[True, False]: not used

[False, False]: (f,f) Shubin

40

Use COV=F10.7_365

COV=f(IG12) (IRI before Oct 2015)

True

41

Te with PF10.7 dep.

w/o PF10.7 dependance

True

42

B0 from model

B0 user input in OARR(9)

True

43

B1 from model

B1 user input in OARR(34)

True

46

CGM computation on

CGM computation off

False

47

Ti Tru-2021

Bil-1981

True

48

Plasmasphere: Ozhogin

Gallagher model

True

Parameters:

preset (str, default: 'default') – Preset

Return type:

ndarray

Returns:

A preset of JF IRI parameters.