9 September 2021 7:20:59.178 PM INTERP_TEST FORTRAN90 version: Test the INTERP library. TEST01 INTERP_NEAREST evaluates a nearest-neighbor interpolant. In this example, the function we are interpolating is Runge's function, with Chebyshev knots. The data to be interpolated: Spatial dimension = 1 Number of data values = 11 T_data P_data -1.00000 0.384615E-01 -0.951057 0.423501E-01 -0.809017 0.575947E-01 -0.587785 0.103764 -0.309017 0.295221 0.612323E-16 1.00000 0.309017 0.295221 0.587785 0.103764 0.809017 0.575947E-01 0.951057 0.423501E-01 1.00000 0.384615E-01 Interpolation: T_interp P_interp P_exact Error -1.0489 0.384615E-01 0.350790E-01 0.34E-02 -1.0367 0.384615E-01 0.358821E-01 0.26E-02 -1.0245 0.384615E-01 0.367127E-01 0.17E-02 -1.0122 0.384615E-01 0.375720E-01 0.89E-03 -1.0000 0.384615E-01 0.384615E-01 0.0 -0.9878 0.384615E-01 0.393826E-01 -0.92E-03 -0.9755 0.384615E-01 0.403366E-01 -0.19E-02 -0.9633 0.423501E-01 0.413252E-01 0.10E-02 -0.9511 0.423501E-01 0.423501E-01 0.0 -0.9155 0.423501E-01 0.455464E-01 -0.32E-02 -0.8800 0.575947E-01 0.491120E-01 0.85E-02 -0.8445 0.575947E-01 0.531049E-01 0.45E-02 -0.8090 0.575947E-01 0.575947E-01 0.0 -0.7537 0.575947E-01 0.657811E-01 -0.82E-02 -0.6984 0.103764 0.757914E-01 0.28E-01 -0.6431 0.103764 0.881895E-01 0.16E-01 -0.5878 0.103764 0.103764 0.0 -0.5181 0.103764 0.129693 -0.26E-01 -0.4484 0.295221 0.165931 0.13 -0.3787 0.295221 0.218078 0.77E-01 -0.3090 0.295221 0.295221 0.0 -0.2318 0.295221 0.426831 -0.13 -0.1545 1.00000 0.626244 0.37 -0.0773 1.00000 0.870166 0.13 0.0000 1.00000 1.00000 0.0 0.0773 1.00000 0.870166 0.13 0.1545 0.295221 0.626244 -0.33 0.2318 0.295221 0.426831 -0.13 0.3090 0.295221 0.295221 0.0 0.3787 0.295221 0.218078 0.77E-01 0.4484 0.103764 0.165931 -0.62E-01 0.5181 0.103764 0.129693 -0.26E-01 0.5878 0.103764 0.103764 0.0 0.6431 0.103764 0.881895E-01 0.16E-01 0.6984 0.575947E-01 0.757914E-01 -0.18E-01 0.7537 0.575947E-01 0.657811E-01 -0.82E-02 0.8090 0.575947E-01 0.575947E-01 0.0 0.8445 0.575947E-01 0.531049E-01 0.45E-02 0.8800 0.423501E-01 0.491120E-01 -0.68E-02 0.9155 0.423501E-01 0.455464E-01 -0.32E-02 0.9511 0.423501E-01 0.423501E-01 0.0 0.9633 0.423501E-01 0.413252E-01 0.10E-02 0.9755 0.384615E-01 0.403366E-01 -0.19E-02 0.9878 0.384615E-01 0.393826E-01 -0.92E-03 1.0000 0.384615E-01 0.384615E-01 0.0 1.0122 0.384615E-01 0.375720E-01 0.89E-03 1.0245 0.384615E-01 0.367127E-01 0.17E-02 TEST02 INTERP_LINEAR evaluates a piecewise linear spline. In this example, the function we are interpolating is Runge's function, with evenly spaced knots. The data to be interpolated: Spatial dimension = 1 Number of data values = 11 T_data P_data -1.00000 0.384615E-01 -0.800000 0.588235E-01 -0.600000 0.100000 -0.400000 0.200000 -0.200000 0.500000 0.00000 1.00000 0.200000 0.500000 0.400000 0.200000 0.600000 0.100000 0.800000 0.588235E-01 1.00000 0.384615E-01 Interpolation: T_interp P_interp P_exact Error -1.2000 0.180995E-01 0.270270E-01 -0.89E-02 -1.1500 0.231900E-01 0.293578E-01 -0.62E-02 -1.1000 0.282805E-01 0.320000E-01 -0.37E-02 -1.0500 0.333710E-01 0.350109E-01 -0.16E-02 -1.0000 0.384615E-01 0.384615E-01 0.0 -0.9500 0.435520E-01 0.424403E-01 0.11E-02 -0.9000 0.486425E-01 0.470588E-01 0.16E-02 -0.8500 0.537330E-01 0.524590E-01 0.13E-02 -0.8000 0.588235E-01 0.588235E-01 0.0 -0.7500 0.691176E-01 0.663900E-01 0.27E-02 -0.7000 0.794118E-01 0.754717E-01 0.39E-02 -0.6500 0.897059E-01 0.864865E-01 0.32E-02 -0.6000 0.100000 0.100000 0.0 -0.5500 0.125000 0.116788 0.82E-02 -0.5000 0.150000 0.137931 0.12E-01 -0.4500 0.175000 0.164948 0.10E-01 -0.4000 0.200000 0.200000 0.0 -0.3500 0.275000 0.246154 0.29E-01 -0.3000 0.350000 0.307692 0.42E-01 -0.2500 0.425000 0.390244 0.35E-01 -0.2000 0.500000 0.500000 0.0 -0.1500 0.625000 0.640000 -0.15E-01 -0.1000 0.750000 0.800000 -0.50E-01 -0.0500 0.875000 0.941176 -0.66E-01 0.0000 1.00000 1.00000 0.0 0.0500 0.875000 0.941176 -0.66E-01 0.1000 0.750000 0.800000 -0.50E-01 0.1500 0.625000 0.640000 -0.15E-01 0.2000 0.500000 0.500000 0.0 0.2500 0.425000 0.390244 0.35E-01 0.3000 0.350000 0.307692 0.42E-01 0.3500 0.275000 0.246154 0.29E-01 0.4000 0.200000 0.200000 0.0 0.4500 0.175000 0.164948 0.10E-01 0.5000 0.150000 0.137931 0.12E-01 0.5500 0.125000 0.116788 0.82E-02 0.6000 0.100000 0.100000 0.0 0.6500 0.897059E-01 0.864865E-01 0.32E-02 0.7000 0.794118E-01 0.754717E-01 0.39E-02 0.7500 0.691176E-01 0.663900E-01 0.27E-02 0.8000 0.588235E-01 0.588235E-01 0.0 0.8500 0.537330E-01 0.524590E-01 0.13E-02 0.9000 0.486425E-01 0.470588E-01 0.16E-02 0.9500 0.435520E-01 0.424403E-01 0.11E-02 1.0000 0.384615E-01 0.384615E-01 0.0 1.0500 0.333710E-01 0.350109E-01 -0.16E-02 1.1000 0.282805E-01 0.320000E-01 -0.37E-02 TEST03 INTERP_LAGRANGE evaluates a polynomial interpolant. In this example, the function we are interpolating is Runge's function, with evenly spaced knots. The data to be interpolated: Spatial dimension = 1 Number of data values = 6 T_data P_data -1.00000 0.384615E-01 -0.600000 0.100000 -0.200000 0.500000 0.200000 0.500000 0.600000 0.100000 1.00000 0.384615E-01 Interpolation: T_interp P_interp P_exact Error -1.4000 1.79231 0.200000E-01 1.8 -1.3000 1.07512 0.231214E-01 1.1 -1.2000 0.567308 0.270270E-01 0.54 -1.1000 0.232812 0.320000E-01 0.20 -1.0000 0.384615E-01 0.384615E-01 0.0 -0.9000 -0.460337E-01 0.470588E-01 -0.93E-01 -0.8000 -0.480769E-01 0.588235E-01 -0.11 -0.7000 0.781250E-02 0.754717E-01 -0.68E-01 -0.6000 0.100000 0.100000 0.0 -0.5000 0.209736 0.137931 0.72E-01 -0.4000 0.321154 0.200000 0.12 -0.3000 0.421274 0.307692 0.11 -0.2000 0.500000 0.500000 0.0 -0.1000 0.550120 0.800000 -0.25 0.0000 0.567308 1.00000 -0.43 0.1000 0.550120 0.800000 -0.25 0.2000 0.500000 0.500000 0.0 0.3000 0.421274 0.307692 0.11 0.4000 0.321154 0.200000 0.12 0.5000 0.209736 0.137931 0.72E-01 0.6000 0.100000 0.100000 0.0 0.7000 0.781250E-02 0.754717E-01 -0.68E-01 0.8000 -0.480769E-01 0.588235E-01 -0.11 0.9000 -0.460337E-01 0.470588E-01 -0.93E-01 1.0000 0.384615E-01 0.384615E-01 0.0 1.1000 0.232813 0.320000E-01 0.20 1.2000 0.567308 0.270270E-01 0.54 TEST03 INTERP_LAGRANGE evaluates a polynomial interpolant. In this example, the function we are interpolating is Runge's function, with evenly spaced knots. The data to be interpolated: Spatial dimension = 1 Number of data values = 11 T_data P_data -1.00000 0.384615E-01 -0.800000 0.588235E-01 -0.600000 0.100000 -0.400000 0.200000 -0.200000 0.500000 0.00000 1.00000 0.200000 0.500000 0.400000 0.200000 0.600000 0.100000 0.800000 0.588235E-01 1.00000 0.384615E-01 Interpolation: T_interp P_interp P_exact Error -1.2000 -146.421 0.270270E-01 -0.15E+03 -1.1500 -67.7068 0.293578E-01 -68. -1.1000 -26.7006 0.320000E-01 -27. -1.0500 -7.48022 0.350109E-01 -7.5 -1.0000 0.384615E-01 0.384615E-01 0.0 -0.9500 1.92363 0.424403E-01 1.9 -0.9000 1.57872 0.470588E-01 1.5 -0.8500 0.719459 0.524590E-01 0.67 -0.8000 0.588235E-01 0.588235E-01 0.0 -0.7500 -0.231462 0.663900E-01 -0.30 -0.7000 -0.226196 0.754717E-01 -0.30 -0.6500 -0.726042E-01 0.864865E-01 -0.16 -0.6000 0.100000 0.100000 0.0 -0.5500 0.215592 0.116788 0.99E-01 -0.5000 0.253755 0.137931 0.12 -0.4500 0.234969 0.164948 0.70E-01 -0.4000 0.200000 0.200000 0.0 -0.3500 0.190580 0.246154 -0.56E-01 -0.3000 0.235347 0.307692 -0.72E-01 -0.2500 0.342641 0.390244 -0.48E-01 -0.2000 0.500000 0.500000 0.0 -0.1500 0.678990 0.640000 0.39E-01 -0.1000 0.843407 0.800000 0.43E-01 -0.0500 0.958627 0.941176 0.17E-01 0.0000 1.00000 1.00000 0.0 0.0500 0.958627 0.941176 0.17E-01 0.1000 0.843407 0.800000 0.43E-01 0.1500 0.678990 0.640000 0.39E-01 0.2000 0.500000 0.500000 0.0 0.2500 0.342641 0.390244 -0.48E-01 0.3000 0.235347 0.307692 -0.72E-01 0.3500 0.190580 0.246154 -0.56E-01 0.4000 0.200000 0.200000 0.0 0.4500 0.234969 0.164948 0.70E-01 0.5000 0.253755 0.137931 0.12 0.5500 0.215592 0.116788 0.99E-01 0.6000 0.100000 0.100000 0.0 0.6500 -0.726042E-01 0.864865E-01 -0.16 0.7000 -0.226196 0.754717E-01 -0.30 0.7500 -0.231462 0.663900E-01 -0.30 0.8000 0.588235E-01 0.588235E-01 0.0 0.8500 0.719459 0.524590E-01 0.67 0.9000 1.57872 0.470588E-01 1.5 0.9500 1.92363 0.424403E-01 1.9 1.0000 0.384615E-01 0.384615E-01 0.0 1.0500 -7.48022 0.350109E-01 -7.5 1.1000 -26.7006 0.320000E-01 -27. TEST04 INTERP_LAGRANGE evaluates a polynomial interpolant. In this example, the function we are interpolating is Runge's function, with Clenshaw Curtis knots. The data to be interpolated: Spatial dimension = 1 Number of data values = 6 T_data P_data -1.00000 0.384615E-01 -0.809017 0.575947E-01 -0.309017 0.295221 0.309017 0.295221 0.809017 0.575947E-01 1.00000 0.384615E-01 Interpolation: T_interp P_interp P_exact Error -1.1910 0.145943 0.274266E-01 0.12 -1.1432 0.103332 0.296958E-01 0.74E-01 -1.0955 0.720028E-01 0.322554E-01 0.40E-01 -1.0477 0.507607E-01 0.351565E-01 0.16E-01 -1.0000 0.384615E-01 0.384615E-01 0.0 -0.9523 0.340121E-01 0.422481E-01 -0.82E-02 -0.9045 0.363701E-01 0.466127E-01 -0.10E-01 -0.8568 0.445444E-01 0.516768E-01 -0.71E-02 -0.8090 0.575947E-01 0.575947E-01 0.0 -0.6840 0.108521 0.787589E-01 0.30E-01 -0.5590 0.172640 0.113475 0.59E-01 -0.4340 0.238045 0.175154 0.63E-01 -0.3090 0.295221 0.295221 0.0 -0.1545 0.344126 0.626244 -0.28 0.0000 0.361359 1.00000 -0.64 0.1545 0.344126 0.626244 -0.28 0.3090 0.295221 0.295221 0.0 0.4340 0.238045 0.175154 0.63E-01 0.5590 0.172640 0.113475 0.59E-01 0.6840 0.108521 0.787589E-01 0.30E-01 0.8090 0.575947E-01 0.575947E-01 0.0 0.8568 0.445444E-01 0.516768E-01 -0.71E-02 0.9045 0.363701E-01 0.466127E-01 -0.10E-01 0.9523 0.340121E-01 0.422481E-01 -0.82E-02 1.0000 0.384615E-01 0.384615E-01 0.0 1.0477 0.507607E-01 0.351565E-01 0.16E-01 1.0955 0.720028E-01 0.322554E-01 0.40E-01 TEST04 INTERP_LAGRANGE evaluates a polynomial interpolant. In this example, the function we are interpolating is Runge's function, with Clenshaw Curtis knots. The data to be interpolated: Spatial dimension = 1 Number of data values = 11 T_data P_data -1.00000 0.384615E-01 -0.951057 0.423501E-01 -0.809017 0.575947E-01 -0.587785 0.103764 -0.309017 0.295221 0.612323E-16 1.00000 0.309017 0.295221 0.587785 0.103764 0.809017 0.575947E-01 0.951057 0.423501E-01 1.00000 0.384615E-01 Interpolation: T_interp P_interp P_exact Error -1.0489 -0.144661 0.350790E-01 -0.18 -1.0367 -0.674828E-01 0.358821E-01 -0.10 -1.0245 -0.148301E-01 0.367127E-01 -0.52E-01 -1.0122 0.189172E-01 0.375720E-01 -0.19E-01 -1.0000 0.384615E-01 0.384615E-01 0.0 -0.9878 0.476960E-01 0.393826E-01 0.83E-02 -0.9755 0.498032E-01 0.403366E-01 0.95E-02 -0.9633 0.473462E-01 0.413252E-01 0.60E-02 -0.9511 0.423501E-01 0.423501E-01 0.0 -0.9155 0.262348E-01 0.455464E-01 -0.19E-01 -0.8800 0.217659E-01 0.491120E-01 -0.27E-01 -0.8445 0.336614E-01 0.531049E-01 -0.19E-01 -0.8090 0.575947E-01 0.575947E-01 0.0 -0.7537 0.100419 0.657811E-01 0.35E-01 -0.6984 0.127317 0.757914E-01 0.52E-01 -0.6431 0.126626 0.881895E-01 0.38E-01 -0.5878 0.103764 0.103764 0.0 -0.5181 0.712070E-01 0.129693 -0.58E-01 -0.4484 0.749766E-01 0.165931 -0.91E-01 -0.3787 0.147264 0.218078 -0.71E-01 -0.3090 0.295221 0.295221 0.0 -0.2318 0.521674 0.426831 0.95E-01 -0.1545 0.757220 0.626244 0.13 -0.0773 0.934320 0.870166 0.64E-01 0.0000 1.00000 1.00000 0.0 0.0773 0.934320 0.870166 0.64E-01 0.1545 0.757220 0.626244 0.13 0.2318 0.521674 0.426831 0.95E-01 0.3090 0.295221 0.295221 0.0 0.3787 0.147264 0.218078 -0.71E-01 0.4484 0.749766E-01 0.165931 -0.91E-01 0.5181 0.712070E-01 0.129693 -0.58E-01 0.5878 0.103764 0.103764 0.0 0.6431 0.126626 0.881895E-01 0.38E-01 0.6984 0.127317 0.757914E-01 0.52E-01 0.7537 0.100419 0.657811E-01 0.35E-01 0.8090 0.575947E-01 0.575947E-01 0.0 0.8445 0.336614E-01 0.531049E-01 -0.19E-01 0.8800 0.217659E-01 0.491120E-01 -0.27E-01 0.9155 0.262348E-01 0.455464E-01 -0.19E-01 0.9511 0.423501E-01 0.423501E-01 0.0 0.9633 0.473462E-01 0.413252E-01 0.60E-02 0.9755 0.498032E-01 0.403366E-01 0.95E-02 0.9878 0.476960E-01 0.393826E-01 0.83E-02 1.0000 0.384615E-01 0.384615E-01 0.0 1.0122 0.189172E-01 0.375720E-01 -0.19E-01 1.0245 -0.148301E-01 0.367127E-01 -0.52E-01 INTERP_TEST Normal end of execution. 9 September 2021 7:20:59.178 PM