function [ n_data, n1, n2, lambda, x, fx ] = f_noncentral_cdf_values ( n_data ) %*****************************************************************************80 % %% F_NONCENTRAL_CDF_VALUES returns some values of the F CDF test function. % % Discussion: % % In Mathematica, the function can be evaluated by: % % Needs["Statistics`ContinuousDistributions`"] % dist = NoncentralFRatioDistribution [ n1, n2, lambda ] % CDF [ dist, x ] % % Licensing: % % This code is distributed under the GNU LGPL license. % % Modified: % % 16 September 2004 % % Author: % % John Burkardt % % Reference: % % Milton Abramowitz and Irene Stegun, % Handbook of Mathematical Functions, % US Department of Commerce, 1964. % % Stephen Wolfram, % The Mathematica Book, % Fourth Edition, % Wolfram Media / Cambridge University Press, 1999. % % Parameters: % % Input/output, integer N_DATA. The user sets N_DATA to 0 before the % first call. On each call, the routine increments N_DATA by 1, and % returns the corresponding data; when there is no more data, the % output value of N_DATA will be 0 again. % % Output, integer N1, integer N2, the numerator and denominator % degrees of freedom. % % Output, real LAMBDA, the noncentrality parameter. % % Output, real X, the argument of the function. % % Output, real FX, the value of the function. % n_max = 22; fx_vec = [ ... 0.5000000000000000E+00, ... 0.6367825323508774E+00, ... 0.5840916116305482E+00, ... 0.3234431872392788E+00, ... 0.4501187879813550E+00, ... 0.6078881441188312E+00, ... 0.7059275551414605E+00, ... 0.7721782003263727E+00, ... 0.8191049017635072E+00, ... 0.3170348430749965E+00, ... 0.4327218008454471E+00, ... 0.4502696915707327E+00, ... 0.4261881186594096E+00, ... 0.6753687206341544E+00, ... 0.4229108778879005E+00, ... 0.6927667261228938E+00, ... 0.3632174676491226E+00, ... 0.4210054012695865E+00, ... 0.4266672258818927E+00, ... 0.4464016600524644E+00, ... 0.8445888579504827E+00, ... 0.4339300273343604E+00 ]; lambda_vec = [ ... 0.00E+00, ... 0.00E+00, ... 0.25E+00, ... 1.00E+00, ... 1.00E+00, ... 1.00E+00, ... 1.00E+00, ... 1.00E+00, ... 1.00E+00, ... 2.00E+00, ... 1.00E+00, ... 1.00E+00, ... 1.00E+00, ... 2.00E+00, ... 1.00E+00, ... 1.00E+00, ... 0.00E+00, ... 1.00E+00, ... 1.00E+00, ... 1.00E+00, ... 1.00E+00, ... 1.00E+00 ]; n1_vec = [ ... 1, 1, 1, 1, ... 1, 1, 1, 1, ... 1, 1, 2, 2, ... 3, 3, 4, 4, ... 5, 5, 6, 6, ... 8, 16 ]; n2_vec = [ ... 1, 5, 5, 5, ... 5, 5, 5, 5, ... 5, 5, 5, 10, ... 5, 5, 5, 5, ... 1, 5, 6, 12, ... 16, 8 ]; x_vec = [ ... 1.00E+00, ... 1.00E+00, ... 1.00E+00, ... 0.50E+00, ... 1.00E+00, ... 2.00E+00, ... 3.00E+00, ... 4.00E+00, ... 5.00E+00, ... 1.00E+00, ... 1.00E+00, ... 1.00E+00, ... 1.00E+00, ... 1.00E+00, ... 1.00E+00, ... 2.00E+00, ... 1.00E+00, ... 1.00E+00, ... 1.00E+00, ... 1.00E+00, ... 2.00E+00, ... 2.00E+00 ]; if ( n_data < 0 ) n_data = 0; end n_data = n_data + 1; if ( n_max < n_data ) n_data = 0; n1 = 0; n2 = 0; lambda = 0.0; x = 0.0; fx = 0.0; else n1 = n1_vec(n_data); n2 = n2_vec(n_data); lambda = lambda_vec(n_data); x = x_vec(n_data); fx = fx_vec(n_data); end return end