Application of linear functions to predict life expectancy