Life Expectancy for Scotland: Methodology Guide [1]
Decennial life tables (also known as period, graduated or smoothed life tables) for males and females have been constructed based on the mortality experience of the population of Scotland during the three years based around the Census year. For example, the latest decennial life tables are based the mortality experiences during the years 2000, 2001 and 2002.
As well as the normal life tables constructed from single sex mortality rates, a life table for persons has been calculated for the latest period (20002002). This notional life table has been constructed assuming that 100,000 persons born are divided in the ratio 105:100 between males and females and that the resulting male and female populations develop in line with the respective single sex life tables. This table is useful for both historical and international comparisons where there are no separate figures for males and females. This table cannot be used to derive mortality rates for persons, which would have any general application, since they would only reflect the mortality of a population which at any particular age has the same ratio of males to females as underlies the 'persons' table.
Decennial life tables are produced by smoothing crude rates of mortality for each year. Crude rates of mortality for each year are obtained by dividing total deaths in each of the three calendar years by an exposedtorisk population derived from the midyear population estimates for the three years added together. These crude death rates are not suitable as the basis for a full life table because they tend to vary erratically from age to age owing to the small numbers of deaths involved. This is particularly so in childhood and at very advanced ages. Errors are also present in the data because no census is perfectly accurate or complete and neither are the midyear estimates of the population. Errors arising because of the small numbers of deaths can be reduced by a process of smoothing the crude death rates. The intention of smoothing is to replace the crude rates by a series of graduated rates which, while forming a smooth progression over the whole age range covered, still preserves the general shape of the mortality curve. The graduated death rates are then converted into initial rates of mortality (q_{x}) which give the probability of a person aged exactly x dying before reaching (x+1).
l_{x}
The number of survivors to age x out of 100,000 live births of the same sex for a given country, subsequently experiencing mortality similar to that of the population of that sex, in the period on which life expectancy is based (e.g. 200002).
d_{x}
The number dying between age x and age (x+1), described similarly to l_{x},
that is l_{x } (l_{x}+1)
q_{x}
The initial mortality rate between age x and (x+1), that is d_{x }/ l_{x}
p_{x}
Conditional probability that an individual entering the age interval will survive the age interval q_{x} and p_{x} values will therefore always sum to 1.

The average expectation of life, the average number of years that those aged x will live thereafter, and calculated as
T_{x}
Cumulative number of years lived by the cohort population in the age interval and all subsequent age intervals.
And calculated as 
ω
The earliest age by which all the survivors are assumed to have died, so that q*1 is assumed to equal 1. For each country, * is assumed to equal 121.
Links
[1] https://www.nrscotland.gov.uk/files//statistics/lifeexpectancy1517/lemethodologyfeb19.pdf