/* Generate the figures for M[] using intxtdat.class which takes its input from infln.txt and puts them in infln2.txt */ class infln { //Inflation multipliers relative to year 2000 starting with 1966 private static double M[] = { 11.06377835626627, // 1966 = 0 10.686242816091953, // 1967 = 1 10.418665732796358, // 1968 = 2 9.844639311714097, // 1969 = 3 9.40132722389003, // 1970 = 4 8.712988724557036, // 1971 = 5 8.014682112068966, // 1972 = 6 7.442276422764228, // 1973 = 7 6.721757794848622, // 1974 = 8 5.651690729483283, // 1975 = 9 4.521696177521088, // 1976 = 10 3.9271995247838425, // 1977 = 11 3.4998529498264808, // 1978 = 12 3.229712858926342, // 1979 = 13 2.7560794849228776, // 1980 = 14 2.3934432823813356, // 1981 = 15 2.136634587762137, // 1982 = 16 2.0278440460772953, // 1983 = 17 1.9251625845277769, // 1984 = 18 1.8404837761761885, // 1985 = 19 1.7426998213396596, // 1986 = 20 1.6796804426377596, // 1987 = 21 1.619515514425694, // 1988 = 22 1.5167605597899514, // 1989 = 23 1.4082410300104138, // 1990 = 24 1.2879004329004329, // 1991 = 25 1.2328491805316701, // 1992 = 26 1.2018461662761575, // 1993 = 27 1.1789847031782517, // 1994 = 28 1.1458806763471094, // 1995 = 29 1.1099897397630818, // 1996 = 30 1.0835503432702638, // 1997 = 31 1.0456198928037959, // 1998 = 32 1.0176329741747905, // 1999 = 33 1.0000000000000000 // 2000 = 34 }; public static double getValue( double x, // amount of money in £s int y // year in which it is contexed 1966 is year zero ) { if(y > 34) return x; // don't apply inflation if beyond Y2k return x * M[y]; // equivalent number of £s priced in the year 2000 } public static int getInt( int x, //amount of money in integral pence int y //year ) { //if beyond the year 2000, don't apply inflation if(y < 1966 || y > 2000) return x; return (int)Math.round(M[y - 1966] * x); } }