1 | /*
|
---|
2 | * RefrIndex Class (deprecated)
|
---|
3 | *
|
---|
4 | * Methods for returning the refractive index, for a given wavelength,
|
---|
5 | * of gold, silver, fused quartz, crown glass, float glass,
|
---|
6 | * microscope slide glass, polymethacrylate, air,
|
---|
7 | * water, sodium chloride solutions, sucrose solutions, PVA solutions.
|
---|
8 | * Methods for calculating refractive index of mixtures and interconverting
|
---|
9 | * absorption coefficients and imaginary refractive indices.
|
---|
10 | *
|
---|
11 | * Methods for returning the physical properties of water:
|
---|
12 | * viscosity, density, refractive index,
|
---|
13 | * electrical permittivity, molecular weight.
|
---|
14 | *
|
---|
15 | * Author: Dr Michael Thomas Flanagan.
|
---|
16 | *
|
---|
17 | * Created: July 2003
|
---|
18 | * Updated: 1 July 2003, 1 May 2004,
|
---|
19 | * REPLACED:28 February 2006 - Replaced by RefractiveIndex in the optics section of this library
|
---|
20 | * The methods in RefrIndex now call the corresponding methods in RefractiveIndex
|
---|
21 | * RefrIndex has been retained to ensure backward compatibility
|
---|
22 | *
|
---|
23 | *
|
---|
24 | * DOCUMENTATION:
|
---|
25 | * See Michael Thomas Flanagan's Java library on-line web page:
|
---|
26 | * http://www.ee.ucl.ac.uk/~mflanaga/java/RefractiveIndex.html
|
---|
27 | * http://www.ee.ucl.ac.uk/~mflanaga/java/
|
---|
28 | * http://www.ee.ucl.ac.uk/~mflanaga/java/RefrIndex.html (deprecated)
|
---|
29 | *
|
---|
30 | * Copyright (c) July 2003 - May 2004 Michael Thomas Flanagan
|
---|
31 | *
|
---|
32 | * PERMISSION TO COPY:
|
---|
33 | * Permission to use, copy and modify this software and its documentation for
|
---|
34 | * NON-COMMERCIAL purposes is granted, without fee, provided that an acknowledgement
|
---|
35 | * to the author, Michael Thomas Flanagan at www.ee.ucl.ac.uk/~mflanaga, appears in all copies.
|
---|
36 | *
|
---|
37 | * Dr Michael Thomas Flanagan makes no representations about the suitability
|
---|
38 | * or fitness of the software for any or for a particular purpose.
|
---|
39 | * Michael Thomas Flanagan shall not be liable for any damages suffered
|
---|
40 | * as a result of using, modifying or distributing this software or its derivatives.
|
---|
41 | *
|
---|
42 | ***************************************************************************************/
|
---|
43 |
|
---|
44 | package agents.anac.y2015.agentBuyogV2.flanagan.physprop;
|
---|
45 |
|
---|
46 | import agents.anac.y2015.agentBuyogV2.flanagan.complex.Complex;
|
---|
47 | import agents.anac.y2015.agentBuyogV2.flanagan.optics.RefractiveIndex;
|
---|
48 |
|
---|
49 | public class RefrIndex{
|
---|
50 |
|
---|
51 | // METHODS
|
---|
52 | // Returns a complex refractive index given the real part of the refractive index (riReal),
|
---|
53 | // the extinction coefficient (extCoeff)and the concentration of the absorbing species (concn)
|
---|
54 | // and the wavelength (wavl). For a pure material with a given absorption coefficient set concn
|
---|
55 | // to unity and extCoeff to the value of the absorption coefficient.
|
---|
56 | // The units of the concentration, the absorption coefficient and the wavelength should match.
|
---|
57 | public static Complex absToComplex(double riReal, double extCoeff, double concn, double wavl){
|
---|
58 | return RefractiveIndex.absToComplex(riReal, extCoeff, concn, wavl);
|
---|
59 | }
|
---|
60 |
|
---|
61 | // Returns the absorption coefficient ( units - reciprocal metres) that corresponds
|
---|
62 | // to the imaginary part of a complex refractive index (riImag) at a wavelength wavl (metres)
|
---|
63 | public static double imagToAbs(double riImag, double wavl){
|
---|
64 | return RefractiveIndex.imagToAbs(riImag, wavl);
|
---|
65 | }
|
---|
66 |
|
---|
67 | // Returns the complex refractive index of GOLD for a given wavelength (in metres)
|
---|
68 | // Interpolation - natural cubic spline
|
---|
69 | // Data - P.B. Johnson and R.W. Christy, Phys. Rev. B. 6(12) 4370-4379, 1972
|
---|
70 | public static Complex gold(double wavelength){
|
---|
71 | return RefractiveIndex.gold(wavelength);
|
---|
72 | }
|
---|
73 |
|
---|
74 | // Returns the complex refractive index of SILVER for a given wavelength (in metres)
|
---|
75 | // Interpolation - natural cubic spline
|
---|
76 | // Data - P.B. Johnson and R.W. Christy, Phys. Rev. B. 6(12) 4370-4379, 1972
|
---|
77 | public static Complex silver(double wavelength){
|
---|
78 | return RefractiveIndex.silver(wavelength);
|
---|
79 | }
|
---|
80 |
|
---|
81 | // Returns the real refractive index of FUSED QUARTZ for a given wavelength (in metres)
|
---|
82 | // Interpolation - natural cubic spline
|
---|
83 | // Extrapolation - Cauchy equation
|
---|
84 | public static double quartz(double wavelength){
|
---|
85 | return RefractiveIndex.quartz(wavelength);
|
---|
86 | }
|
---|
87 |
|
---|
88 | // Returns the real refractive index of LAF78847 CROWN GLASS for a given wavelength (in metres)
|
---|
89 | // Interpolation - natural cubic spline
|
---|
90 | // Extrapolation - Cauchy equation
|
---|
91 | public static double crownGlass(double wavelength){
|
---|
92 | return RefractiveIndex.crownGlass(wavelength);
|
---|
93 | }
|
---|
94 |
|
---|
95 | // Returns the real refractive index of PILKINGTON PERMABLOC FLOAT GLASS for a given wavelength (in metres)
|
---|
96 | // Interpolation - natural cubic spline
|
---|
97 | // Extrapolation - Cauchy equation
|
---|
98 | public static double floatGlass(double wavelength){
|
---|
99 |
|
---|
100 | return RefractiveIndex.floatGlass(wavelength);
|
---|
101 | }
|
---|
102 |
|
---|
103 | // Returns the real refractive index of CHANCE POPPER MICROSCOPE SLIDE GLASS for a given wavelength (in metres)
|
---|
104 | // Interpolation - natural cubic spline
|
---|
105 | // Extrapolation - Cauchy equation
|
---|
106 | public static double microSlideGlass(double wavelength){
|
---|
107 | return RefractiveIndex.microscopeSlideGlass(wavelength);
|
---|
108 | }
|
---|
109 |
|
---|
110 | // Returns the real refractive index of POLYMETHACRYLATE for a given wavelength (in metres)
|
---|
111 | // Interpolation - natural cubic spline
|
---|
112 | // Extrapolation - Cauchy equation
|
---|
113 | public static double polymethacrylate(double wavelength){
|
---|
114 | return RefractiveIndex.polymethacrylate(wavelength);
|
---|
115 | }
|
---|
116 |
|
---|
117 | // Returns the real refractive index of AIR for a given wavelength (in metres)
|
---|
118 | // Interpolation - uses the Cauchy equation (see Born & Wolf section 2.3)
|
---|
119 | // Extrapolation - uses the Cauchy equation - may be invalid and will be invalid within an absorption band
|
---|
120 | public static double air(double wavelength){
|
---|
121 | return RefractiveIndex.air(wavelength);
|
---|
122 | }
|
---|
123 |
|
---|
124 | // Returns the real refractive index of WATER
|
---|
125 | // for a given wavelength (in metres)and a given temperature (Celsius)
|
---|
126 | // Interpolation - natural bicubic spline
|
---|
127 | public static double water(double wavelength, double temperature){
|
---|
128 | return RefractiveIndex.water(wavelength, temperature);
|
---|
129 | }
|
---|
130 |
|
---|
131 | // Returns the refractive index of pva solutions as a function of g/l pva concentration
|
---|
132 | // Data Poly(vinyl alcohol): basic properties and uses by J G Pritchard (1970)
|
---|
133 | // pva refractive index increment fitted to modified Cauchy equation:
|
---|
134 | // dn = 1 + a1*(1 + b1/(lambda*lambda))
|
---|
135 | // concn g/l concentration of pva
|
---|
136 | // temp temperature (degree Celsius) (t = 30C for original pva increment calculation)
|
---|
137 | // wavl wavelength in metres
|
---|
138 | public static double pva(double concn, double wavl, double temp){
|
---|
139 | return RefractiveIndex.pva(concn, wavl, temp);
|
---|
140 | }
|
---|
141 |
|
---|
142 | // Returns the refractive index of a NaCl solution for a given wavelength (in metres),
|
---|
143 | // a given temperature (degrees Celcius) and a given NaCl concentration (M)
|
---|
144 | // Interpolation - bicubic spline
|
---|
145 | public static double saline(double concentration, double wavelength, double temperature){
|
---|
146 | return RefractiveIndex.saline(concentration, wavelength, temperature);
|
---|
147 | }
|
---|
148 |
|
---|
149 | // Returns the refractive index of sucrose solutions as a function of g/l sucrose concentration
|
---|
150 | // Wavelength - sodium D line 589.3 nm
|
---|
151 | // Interpolation - natural cubic spline
|
---|
152 | // Extrapolation above 1208.2g/l Lorenz-lorenz equation based on
|
---|
153 | // average refraction of sucrose calculated from experimental data
|
---|
154 | // Data - Rubber Handbook
|
---|
155 | public static double sucrose(double concentration, double temperature){
|
---|
156 | return RefractiveIndex.water(concentration, temperature);
|
---|
157 | }
|
---|
158 |
|
---|
159 | // Returns the refractive index of a mixture of material A and material B,
|
---|
160 | // using the Lorenz-Lorentz equation, given the refractive index of A (na), of B (nb),
|
---|
161 | // the molecular wight of A (molwta), of B (molwtb), the mole fraction of A (molfracta),
|
---|
162 | // and the density of A (densa), of B (densb) and of the mixture (densab).
|
---|
163 | public static double lorenzLorentz(double na, double nb, double molwta, double molwtb, double molfracta, double densa, double densb, double densab){
|
---|
164 | return RefractiveIndex.lorenzLorentz(na, nb, molwta, molwtb, molfracta, densa, densb, densab);
|
---|
165 | }
|
---|
166 |
|
---|
167 |
|
---|
168 | // Returns the refractive index of a mixture of n materials,
|
---|
169 | // using the Lorenz-Lorentz equation, given an array of the refractive indices (ni),
|
---|
170 | // an array of the molecular wights (molwt), an array the mole fractions (molfract),
|
---|
171 | // and an array of the densities (dens) and the density of the mixture (densmix).
|
---|
172 | public static double lorenzLorentz(double[] ni, double[] molwt, double[] molfract, double[] dens, double densmix){
|
---|
173 | return RefractiveIndex.lorenzLorentz(ni, molwt, molfract, dens, densmix);
|
---|
174 | }
|
---|
175 |
|
---|
176 | }
|
---|
177 |
|
---|