From 026e61469d304df5bf746990668d03dbf8118f00 Mon Sep 17 00:00:00 2001 From: Jaysukh-409 Date: Mon, 23 Dec 2024 23:04:38 +0530 Subject: [PATCH 1/5] feat: add stats/base/dists/planck/logpmf --- type: pre_commit_static_analysis_report description: Results of running static analysis checks when committing changes. report: - task: lint_filenames status: passed - task: lint_editorconfig status: passed - task: lint_markdown status: passed - task: lint_package_json status: passed - task: lint_repl_help status: passed - task: lint_javascript_src status: passed - task: lint_javascript_cli status: na - task: lint_javascript_examples status: passed - task: lint_javascript_tests status: passed - task: lint_javascript_benchmarks status: passed - task: lint_python status: passed - task: lint_r status: na - task: lint_c_src status: na - task: lint_c_examples status: na - task: lint_c_benchmarks status: na - task: lint_c_tests_fixtures status: na - task: lint_shell status: na - task: lint_typescript_declarations status: passed - task: lint_typescript_tests status: passed - task: lint_license_headers status: passed --- --- type: pre_push_report description: Results of running various checks prior to pushing changes. report: - task: run_javascript_examples status: na - task: run_c_examples status: na - task: run_cpp_examples status: na - task: run_javascript_readme_examples status: na - task: run_c_benchmarks status: na - task: run_cpp_benchmarks status: na - task: run_fortran_benchmarks status: na - task: run_javascript_benchmarks status: na - task: run_julia_benchmarks status: na - task: run_python_benchmarks status: na - task: run_r_benchmarks status: na - task: run_javascript_tests status: na --- --- .../stats/base/dists/planck/logpmf/README.md | 155 +++++++++++++++ .../planck/logpmf/benchmark/benchmark.js | 79 ++++++++ .../base/dists/planck/logpmf/docs/repl.txt | 64 ++++++ .../dists/planck/logpmf/docs/types/index.d.ts | 114 +++++++++++ .../dists/planck/logpmf/docs/types/test.ts | 98 ++++++++++ .../dists/planck/logpmf/examples/index.js | 41 ++++ .../base/dists/planck/logpmf/lib/factory.js | 78 ++++++++ .../base/dists/planck/logpmf/lib/index.js | 60 ++++++ .../base/dists/planck/logpmf/lib/main.js | 77 ++++++++ .../base/dists/planck/logpmf/package.json | 67 +++++++ .../test/fixtures/python/large_lambda.json | 1 + .../logpmf/test/fixtures/python/runner.py | 87 +++++++++ .../test/fixtures/python/small_lambda.json | 1 + .../dists/planck/logpmf/test/test.factory.js | 182 ++++++++++++++++++ .../base/dists/planck/logpmf/test/test.js | 38 ++++ .../dists/planck/logpmf/test/test.logpmf.js | 140 ++++++++++++++ 16 files changed, 1282 insertions(+) create mode 100644 lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/README.md create mode 100644 lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/benchmark/benchmark.js create mode 100644 lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/docs/repl.txt create mode 100644 lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/docs/types/index.d.ts create mode 100644 lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/docs/types/test.ts create mode 100644 lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/examples/index.js create mode 100644 lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/lib/factory.js create mode 100644 lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/lib/index.js create mode 100644 lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/lib/main.js create mode 100644 lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/package.json create mode 100644 lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/test/fixtures/python/large_lambda.json create mode 100644 lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/test/fixtures/python/runner.py create mode 100644 lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/test/fixtures/python/small_lambda.json create mode 100644 lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/test/test.factory.js create mode 100644 lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/test/test.js create mode 100644 lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/test/test.logpmf.js diff --git a/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/README.md b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/README.md new file mode 100644 index 000000000000..616d684092b6 --- /dev/null +++ b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/README.md @@ -0,0 +1,155 @@ + + +# Logarithm of Probability Mass Function + +> Planck distribution logarithm of [probability mass function][pmf] (PMF). + +
+ +The [probability mass function][pmf] (PMF) for a Planck random variable is defined as + + + +```math +\Pr(X = x, \lambda) = \begin{cases}(1 - e^{-\lambda})e^{-\lambda x} & \text{for } x = 0, 1, 2, \ldots \\ 0 & \text{otherwise} \end{cases} +``` + + + +where `lambda > 0` is the shape parameter. The random variable `X` denotes the count of events in a quantized system. + +
+ + + +
+ +## Usage + +```javascript +var logpmf = require( '@stdlib/stats/base/dists/planck/logpmf' ); +``` + +#### logpmf( x, lambda ) + +Evaluates the logarithm of the [probability mass function][pmf] (PMF) of a Planck distribution with shape parameter `lambda`. + +```javascript +var y = logpmf( 4.0, 0.3 ); +// returns ~-2.5502 + +y = logpmf( 2.0, 1.7 ); +// returns ~-3.6017 + +y = logpmf( -1.0, 2.5 ); +// returns -Infinity +``` + +If provided `NaN` as any argument, the function returns `NaN`. + +```javascript +var y = logpmf( NaN, 0.0 ); +// returns NaN + +y = logpmf( 0.0, NaN ); +// returns NaN +``` + +If provided a shape parameter `lambda` which is negative number, the function returns `NaN`. + +```javascript +var y = logpmf( 2.0, -1.0 ); +// returns NaN +``` + +#### logpmf.factory( lambda ) + +Returns a function for evaluating the logarithm of the [probability mass function][pmf] (PMF) of a Planck distribution with shape parameter `lambda`. + +```javascript +var mylogpmf = logpmf.factory( 0.5 ); +var y = mylogpmf( 3.0 ); +// returns ~-2.4328 + +y = mylogpmf( 1.0 ); +// returns ~-1.4328 +``` + +
+ + + +
+ +## Notes + +- In virtually all cases, using the `logpmf` or `logcdf` functions is preferable to manually computing the logarithm of the `pmf` or `cdf`, respectively, since the latter is prone to overflow and underflow. + +
+ + + +
+ +## Examples + + + +```javascript +var discreteUniform = require( '@stdlib/random/array/discrete-uniform' ); +var uniform = require( '@stdlib/random/array/uniform' ); +var logpmf = require( '@stdlib/stats/base/dists/planck/logpmf' ); + +var lambda; +var x; +var y; +var i; + +x = discreteUniform( 10, 0, 5 ); +lambda = uniform( 10, 0.0, 5.0 ); + +for ( i = 0; i < 10; i++ ) { + y = logpmf( x[ i ], lambda[ i ] ); + console.log( 'x: %d, lambda: %d, ln( P( X = x; lambda ) ): %d', x[ i ], lambda[ i ].toFixed( 4 ), y.toFixed( 4 ) ); +} +``` + +
+ + + + + + + + + + + + + + diff --git a/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/benchmark/benchmark.js b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/benchmark/benchmark.js new file mode 100644 index 000000000000..0d2c33428b13 --- /dev/null +++ b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/benchmark/benchmark.js @@ -0,0 +1,79 @@ +/** +* @license Apache-2.0 +* +* Copyright (c) 2024 The Stdlib Authors. +* +* Licensed under the Apache License, Version 2.0 (the "License"); +* you may not use this file except in compliance with the License. +* You may obtain a copy of the License at +* +* http://www.apache.org/licenses/LICENSE-2.0 +* +* Unless required by applicable law or agreed to in writing, software +* distributed under the License is distributed on an "AS IS" BASIS, +* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +* See the License for the specific language governing permissions and +* limitations under the License. +*/ + +'use strict'; + +// MODULES // + +var bench = require( '@stdlib/bench' ); +var discreteUniform = require( '@stdlib/random/array/discrete-uniform' ); +var uniform = require( '@stdlib/random/array/uniform' ); +var isnan = require( '@stdlib/math/base/assert/is-nan' ); +var pkg = require( './../package.json' ).name; +var logpmf = require( './../lib' ); + + +// MAIN // + +bench( pkg, function benchmark( b ) { + var lambda; + var x; + var y; + var i; + + x = discreteUniform( 100, 0, 40 ); + lambda = uniform( 100, 0.0, 10.0 ); + + b.tic(); + for ( i = 0; i < b.iterations; i++ ) { + y = logpmf( x[ i % x.length ], lambda[ i % lambda.length ] ); + if ( isnan( y ) ) { + b.fail( 'should not return NaN' ); + } + } + b.toc(); + if ( isnan( y ) ) { + b.fail( 'should not return NaN' ); + } + b.pass( 'benchmark finished' ); + b.end(); +}); + +bench( pkg+':factory', function benchmark( b ) { + var mylogpmf; + var x; + var y; + var i; + + x = discreteUniform( 100, 0, 40 ); + mylogpmf = logpmf.factory( 0.3 ); + + b.tic(); + for ( i = 0; i < b.iterations; i++ ) { + y = mylogpmf( x[ i % x.length ] ); + if ( isnan( y ) ) { + b.fail( 'should not return NaN' ); + } + } + b.toc(); + if ( isnan( y ) ) { + b.fail( 'should not return NaN' ); + } + b.pass( 'benchmark finished' ); + b.end(); +}); diff --git a/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/docs/repl.txt b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/docs/repl.txt new file mode 100644 index 000000000000..508c6d6dbd91 --- /dev/null +++ b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/docs/repl.txt @@ -0,0 +1,64 @@ + +{{alias}}( x, lambda ) + Evaluates the logarithm of the probability mass function (PMF) for a + Planck distribution with shape parameter `lambda` at a value `x`. + + If provided `NaN` as any argument, the function returns `NaN`. + + If `lambda < 0`, the function returns `NaN`. + + Parameters + ---------- + x: number + Input value. + + lambda: number + Shape parameter. + + Returns + ------- + out: number + Evaluated logPMF. + + Examples + -------- + > var y = {{alias}}( 4.0, 0.3 ) + ~-2.5502 + > y = {{alias}}( 2.0, 1.7 ) + ~-3.6017 + > y = {{alias}}( -1.0, 2.5 ) + -Infinity + > y = {{alias}}( 0.0, NaN ) + NaN + > y = {{alias}}( NaN, 0.5 ) + NaN + // Invalid shape parameter: + > y = {{alias}}( 2.0, -1.0 ) + NaN + + +{{alias}}.factory( lambda ) + Returns a function for evaluating the logarithm of the probability mass + function (PMF) of a Planck distribution with shape parameter `lambda`. + + Parameters + ---------- + lambda: number + Shape parameter. + + Returns + ------- + logpmf: Function + Logarithm of probability mass function (PMF). + + Examples + -------- + > var mylogpmf = {{alias}}.factory( 0.5 ); + > var y = mylogpmf( 3.0 ) + ~-2.4328 + > y = mylogpmf( 1.0 ) + ~-1.4328 + + See Also + -------- + diff --git a/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/docs/types/index.d.ts b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/docs/types/index.d.ts new file mode 100644 index 000000000000..f092565169b2 --- /dev/null +++ b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/docs/types/index.d.ts @@ -0,0 +1,114 @@ +/* +* @license Apache-2.0 +* +* Copyright (c) 2024 The Stdlib Authors. +* +* Licensed under the Apache License, Version 2.0 (the "License"); +* you may not use this file except in compliance with the License. +* You may obtain a copy of the License at +* +* http://www.apache.org/licenses/LICENSE-2.0 +* +* Unless required by applicable law or agreed to in writing, software +* distributed under the License is distributed on an "AS IS" BASIS, +* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +* See the License for the specific language governing permissions and +* limitations under the License. +*/ + +// TypeScript Version: 4.1 + +/** +* Evaluates the natural logarithm of the probability mass function (PMF) for a Planck distribution. +* +* @param x - input value +* @returns evaluated PMF +*/ +type Unary = ( x: number ) => number; + +/** +* Interface for the natural logarithm of the probability mass function (PMF) of a Planck distribution. +*/ +interface LogPMF { + /** + * Evaluates the logarithm of the probability mass function (PMF) for a Planck distribution with shape parameter `lambda` at a value `x`. + * + * ## Notes + * + * - If `lambda < 0`, the function returns `NaN`. + * + * @param x - input value + * @param lambda - shape parameter + * @returns logarithm of PMF + * + * @example + * var y = logpmf( 4.0, 0.3 ); + * // returns ~-2.5502 + * + * @example + * var y = logpmf( 2.0, 1.7 ); + * // returns ~-3.6017 + * + * @example + * var y = logpmf( -1.0, 2.5 ); + * // returns -Infinity + * + * @example + * var y = logpmf( 0.0, NaN ); + * // returns NaN + * + * @example + * var y = logpmf( NaN, 0.5 ); + * // returns NaN + * + * @example + * // Invalid shape parameter: + * var y = logpmf( 2.0, -1.0 ); + * // returns NaN + */ + ( x: number, lambda: number ): number; + + /** + * Returns a function for evaluating the logarithm of the probability mass function (PMF) for a Planck distribution with shape parameter `lambda`. + * + * @param lambda - shape parameter + * @returns logPMF + * + * @example + * var mylogpmf = logpmf.factory( 0.5 ); + * var y = mylogpmf( 3.0 ); + * // returns ~-2.4327 + * + * y = mylogpmf( 1.0 ); + * // returns ~-1.4327 + */ + factory( lambda: number ): Unary; +} + +/** +* Planck distribution natural logarithm of probability mass function (PMF). +* +* @param x - input value +* @param lambda - shape parameter +* @returns evaluated logPMF +* +* @example +* var y = logpmf( 4.0, 0.3 ); +* // returns ~-2.5502 +* +* y = logpmf( 2.0, 1.7 ); +* // returns ~-3.6017 +* +* var mylogpmf = logpmf.factory( 0.5 ); +* y = mylogpmf( 3.0 ); +* // returns ~-2.4327 +* +* y = mylogpmf( 1.0 ); +* // returns ~-1.4327 +*/ +declare var logPMF: LogPMF; + + +// EXPORTS // + +export = logPMF; diff --git a/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/docs/types/test.ts b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/docs/types/test.ts new file mode 100644 index 000000000000..7052a140ebc7 --- /dev/null +++ b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/docs/types/test.ts @@ -0,0 +1,98 @@ +/* +* @license Apache-2.0 +* +* Copyright (c) 2024 The Stdlib Authors. +* +* Licensed under the Apache License, Version 2.0 (the "License"); +* you may not use this file except in compliance with the License. +* You may obtain a copy of the License at +* +* http://www.apache.org/licenses/LICENSE-2.0 +* +* Unless required by applicable law or agreed to in writing, software +* distributed under the License is distributed on an "AS IS" BASIS, +* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +* See the License for the specific language governing permissions and +* limitations under the License. +*/ + +import logpmf = require( './index' ); + + +// TESTS // + +// The function returns a number... +{ + logpmf( 2, 0.4 ); // $ExpectType number + logpmf( 1, 0.2 ); // $ExpectType number +} + +// The compiler throws an error if the function is provided values other than two numbers... +{ + logpmf( true, 0.3 ); // $ExpectError + logpmf( false, 0.2 ); // $ExpectError + logpmf( '5', 0.1 ); // $ExpectError + logpmf( [], 0.1 ); // $ExpectError + logpmf( {}, 0.4 ); // $ExpectError + logpmf( ( x: number ): number => x, 0.2 ); // $ExpectError + + logpmf( 0, true ); // $ExpectError + logpmf( 1, false ); // $ExpectError + logpmf( 0, '5' ); // $ExpectError + logpmf( 1, [] ); // $ExpectError + logpmf( 2, {} ); // $ExpectError + logpmf( 3, ( x: number ): number => x ); // $ExpectError +} + +// The compiler throws an error if the function is provided an unsupported number of arguments... +{ + logpmf(); // $ExpectError + logpmf( 0 ); // $ExpectError + logpmf( 1, 0.3, 4 ); // $ExpectError +} + +// Attached to main export is a `factory` method which returns a function... +{ + logpmf.factory( 0.4 ); // $ExpectType Unary +} + +// The `factory` method returns a function which returns a number... +{ + const fcn = logpmf.factory( 0.4 ); + fcn( 2 ); // $ExpectType number +} + +// The compiler throws an error if the function returned by the `factory` method is provided an invalid argument... +{ + const fcn = logpmf.factory( 0.4 ); + fcn( true ); // $ExpectError + fcn( false ); // $ExpectError + fcn( '5' ); // $ExpectError + fcn( [] ); // $ExpectError + fcn( {} ); // $ExpectError + fcn( ( x: number ): number => x ); // $ExpectError +} + +// The compiler throws an error if the function returned by the `factory` method is provided an unsupported number of arguments... +{ + const fcn = logpmf.factory( 0.4 ); + fcn(); // $ExpectError + fcn( 2, 0 ); // $ExpectError + fcn( 2, 0, 1 ); // $ExpectError +} + +// The compiler throws an error if the `factory` method is provided a value other than a number... +{ + logpmf.factory( true ); // $ExpectError + logpmf.factory( false ); // $ExpectError + logpmf.factory( '5' ); // $ExpectError + logpmf.factory( [] ); // $ExpectError + logpmf.factory( {} ); // $ExpectError + logpmf.factory( ( x: number ): number => x ); // $ExpectError +} + +// The compiler throws an error if the `factory` method is provided an unsupported number of arguments... +{ + logpmf.factory( 0, 0.2 ); // $ExpectError + logpmf.factory( 0, 0.4, 8 ); // $ExpectError +} diff --git a/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/examples/index.js b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/examples/index.js new file mode 100644 index 000000000000..b95b9aa5e787 --- /dev/null +++ b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/examples/index.js @@ -0,0 +1,41 @@ +/** +* @license Apache-2.0 +* +* Copyright (c) 2024 The Stdlib Authors. +* +* Licensed under the Apache License, Version 2.0 (the "License"); +* you may not use this file except in compliance with the License. +* You may obtain a copy of the License at +* +* http://www.apache.org/licenses/LICENSE-2.0 +* +* Unless required by applicable law or agreed to in writing, software +* distributed under the License is distributed on an "AS IS" BASIS, +* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +* See the License for the specific language governing permissions and +* limitations under the License. +*/ + +'use strict'; + +var discreteUniform = require( '@stdlib/random/array/discrete-uniform' ); +var uniform = require( '@stdlib/random/array/uniform' ); +var logpmf = require( './../lib' ); + +var lambda; +var x; +var y; +var i; + +x = discreteUniform( 10, 0, 5 ); +lambda = uniform( 10, 0.0, 5.0 ); + +for ( i = 0; i < 10; i++ ) { + y = logpmf( x[ i ], lambda[ i ] ); + console.log( 'x: %d, lambda: %d, ln( P( X = x; lambda ) ): %d', x[ i ], lambda[ i ].toFixed( 4 ), y.toFixed( 4 ) ); +} + +console.log( logpmf(4.0, 0.3) ); +console.log( logpmf(2.0, 1.7) ); +console.log( logpmf(3.0, 0.5) ); +console.log( logpmf(1.0, 0.5) ); diff --git a/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/lib/factory.js b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/lib/factory.js new file mode 100644 index 000000000000..c5ae979a4dc9 --- /dev/null +++ b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/lib/factory.js @@ -0,0 +1,78 @@ +/** +* @license Apache-2.0 +* +* Copyright (c) 2024 The Stdlib Authors. +* +* Licensed under the Apache License, Version 2.0 (the "License"); +* you may not use this file except in compliance with the License. +* You may obtain a copy of the License at +* +* http://www.apache.org/licenses/LICENSE-2.0 +* +* Unless required by applicable law or agreed to in writing, software +* distributed under the License is distributed on an "AS IS" BASIS, +* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +* See the License for the specific language governing permissions and +* limitations under the License. +*/ + +'use strict'; + +// MODULES // + +var constantFunction = require( '@stdlib/utils/constant-function' ); +var isNonNegativeInteger = require( '@stdlib/math/base/assert/is-nonnegative-integer' ); +var isnan = require( '@stdlib/math/base/assert/is-nan' ); +var expm1 = require( '@stdlib/math/base/special/expm1' ); +var ln = require( '@stdlib/math/base/special/ln' ); +var NINF = require( '@stdlib/constants/float64/ninf' ); + + +// MAIN // + +/** +* Returns a function for evaluating the logarithm of the probability mass function (PMF) for a Planck distribution with shape parameter `lambda`. +* +* @param {NonNegativeNumber} lambda - shape parameter +* @returns {Function} logPMF +* +* @example +* var logpmf = factory( 0.5 ); +* var y = logpmf( 3.0 ); +* // returns ~-2.4328 +* +* y = logpmf( 1.0 ); +* // returns ~-1.4328 +*/ +function factory( lambda ) { + if ( isnan( lambda ) || lambda < 0.0 ) { + return constantFunction( NaN ); + } + return logpmf; + + /** + * Evaluates the logarithm of the probability mass function (PMF) for a Planck distribution. + * + * @private + * @param {number} x - input value + * @returns {NonPositiveNumber} evaluated logPMF + * + * @example + * var y = logpmf( 2.0 ); + * // returns + */ + function logpmf( x ) { + if ( isnan( x ) ) { + return NaN; + } + if ( isNonNegativeInteger( x ) ) { + return ln( -expm1( -lambda ) ) - ( lambda * x ); + } + return NINF; + } +} + + +// EXPORTS // + +module.exports = factory; diff --git a/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/lib/index.js b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/lib/index.js new file mode 100644 index 000000000000..3f602ad63d6e --- /dev/null +++ b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/lib/index.js @@ -0,0 +1,60 @@ +/** +* @license Apache-2.0 +* +* Copyright (c) 2024 The Stdlib Authors. +* +* Licensed under the Apache License, Version 2.0 (the "License"); +* you may not use this file except in compliance with the License. +* You may obtain a copy of the License at +* +* http://www.apache.org/licenses/LICENSE-2.0 +* +* Unless required by applicable law or agreed to in writing, software +* distributed under the License is distributed on an "AS IS" BASIS, +* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +* See the License for the specific language governing permissions and +* limitations under the License. +*/ + +'use strict'; + +/** +* Planck distribution logarithm of probability mass function (PMF). +* +* @module @stdlib/stats/base/dists/planck/logpmf +* +* @example +* var logpmf = require( '@stdlib/stats/base/dists/planck/logpmf' ); +* +* var y = logpmf( 4.0, 0.3 ); +* // returns ~-2.5502 +* +* y = logpmf( 2.0, 1.7 ); +* // returns ~-3.6017 +* +* y = logpmf( -1.0, 0.5 ); +* // returns 0.0 +* +* var mylogpmf = logpmf.factory( 0.5 ); +* y = mylogpmf( 3.0 ); +* // returns ~-2.4328 +* +* y = mylogpmf( 1.0 ); +* // returns ~-1.4328 +*/ + +// MODULES // + +var setReadOnly = require( '@stdlib/utils/define-nonenumerable-read-only-property' ); +var main = require( './main.js' ); +var factory = require( './factory.js' ); + + +// MAIN // + +setReadOnly( main, 'factory', factory ); + + +// EXPORTS // + +module.exports = main; diff --git a/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/lib/main.js b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/lib/main.js new file mode 100644 index 000000000000..ac110102cbce --- /dev/null +++ b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/lib/main.js @@ -0,0 +1,77 @@ +/** +* @license Apache-2.0 +* +* Copyright (c) 2024 The Stdlib Authors. +* +* Licensed under the Apache License, Version 2.0 (the "License"); +* you may not use this file except in compliance with the License. +* You may obtain a copy of the License at +* +* http://www.apache.org/licenses/LICENSE-2.0 +* +* Unless required by applicable law or agreed to in writing, software +* distributed under the License is distributed on an "AS IS" BASIS, +* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +* See the License for the specific language governing permissions and +* limitations under the License. +*/ + +'use strict'; + +// MODULES // + +var isNonNegativeInteger = require( '@stdlib/math/base/assert/is-nonnegative-integer' ); +var isnan = require( '@stdlib/math/base/assert/is-nan' ); +var expm1 = require( '@stdlib/math/base/special/expm1' ); +var ln = require( '@stdlib/math/base/special/ln' ); +var NINF = require( '@stdlib/constants/float64/ninf' ); + + +// MAIN // + +/** +* Evaluates the logarithm of the probability mass function (PMF) for a Planck distribution with shape parameter `lambda` at a value `x`. +* +* @param {number} x - input value +* @param {NonNegativeNumber} lambda - shape parameter +* @returns {NonPositiveNumber} logarithm of PMF +* +* @example +* var y = logpmf( 4.0, 0.3 ); +* // returns ~-2.5502 +* +* @example +* var y = logpmf( 2.0, 1.7 ); +* // returns ~-3.6017 +* +* @example +* var y = logpmf( -1.0, 2.5 ); +* // returns -Infinity +* +* @example +* var y = logpmf( 0.0, NaN ); +* // returns NaN +* +* @example +* var y = logpmf( NaN, 0.5 ); +* // returns NaN +* +* @example +* // Invalid shape parameter: +* var y = logpmf( 2.0, -1.0 ); +* // returns NaN +*/ +function logpmf( x, lambda ) { + if ( isnan( x ) || isnan( lambda ) || lambda < 0.0 ) { + return NaN; + } + if ( isNonNegativeInteger( x ) ) { + return ln( -expm1( -lambda ) ) - ( lambda * x ); + } + return NINF; +} + + +// EXPORTS // + +module.exports = logpmf; diff --git a/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/package.json b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/package.json new file mode 100644 index 000000000000..5403559719e0 --- /dev/null +++ b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/package.json @@ -0,0 +1,67 @@ +{ + "name": "@stdlib/stats/base/dists/planck/logpmf", + "version": "0.0.0", + "description": "Planck distribution logarithm of probability mass function (PMF).", + "license": "Apache-2.0", + "author": { + "name": "The Stdlib Authors", + "url": "https://github.com/stdlib-js/stdlib/graphs/contributors" + }, + "contributors": [ + { + "name": "The Stdlib Authors", + "url": "https://github.com/stdlib-js/stdlib/graphs/contributors" + } + ], + "main": "./lib", + "directories": { + "benchmark": "./benchmark", + "doc": "./docs", + "example": "./examples", + "lib": "./lib", + "test": "./test" + }, + "types": "./docs/types", + "scripts": {}, + "homepage": "https://github.com/stdlib-js/stdlib", + "repository": { + "type": "git", + "url": "git://github.com/stdlib-js/stdlib.git" + }, + "bugs": { + "url": "https://github.com/stdlib-js/stdlib/issues" + }, + "dependencies": {}, + "devDependencies": {}, + "engines": { + "node": ">=0.10.0", + "npm": ">2.7.0" + }, + "os": [ + "aix", + "darwin", + "freebsd", + "linux", + "macos", + "openbsd", + "sunos", + "win32", + "windows" + ], + "keywords": [ + "stdlib", + "stdmath", + "statistics", + "stats", + "distribution", + "dist", + "probability", + "pmf", + "discrete distribution", + "logarithm", + "log", + "planck", + "univariate", + "discrete" + ] +} diff --git a/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/test/fixtures/python/large_lambda.json b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/test/fixtures/python/large_lambda.json new file mode 100644 index 000000000000..d4cd2afb2208 --- /dev/null +++ b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/test/fixtures/python/large_lambda.json @@ -0,0 +1 @@ +{"x": [9.0, 9.0, 2.0, 6.0, 0.0, 7.0, 3.0, 4.0, 5.0, 7.0, 1.0, 5.0, 10.0, 3.0, 1.0, 4.0, 6.0, 10.0, 5.0, 1.0, 5.0, 1.0, 6.0, 9.0, 0.0, 5.0, 3.0, 2.0, 3.0, 5.0, 8.0, 2.0, 3.0, 7.0, 9.0, 2.0, 1.0, 4.0, 7.0, 9.0, 5.0, 7.0, 9.0, 8.0, 6.0, 4.0, 4.0, 1.0, 9.0, 3.0, 0.0, 4.0, 9.0, 9.0, 6.0, 2.0, 2.0, 3.0, 5.0, 0.0, 7.0, 3.0, 2.0, 1.0, 1.0, 6.0, 7.0, 2.0, 8.0, 8.0, 8.0, 10.0, 6.0, 5.0, 0.0, 8.0, 9.0, 7.0, 1.0, 9.0, 1.0, 1.0, 8.0, 5.0, 3.0, 2.0, 0.0, 2.0, 9.0, 4.0, 3.0, 6.0, 5.0, 8.0, 1.0, 1.0, 5.0, 5.0, 6.0, 7.0, 9.0, 1.0, 5.0, 8.0, 2.0, 8.0, 9.0, 7.0, 4.0, 4.0, 7.0, 8.0, 6.0, 4.0, 4.0, 5.0, 5.0, 7.0, 10.0, 6.0, 7.0, 2.0, 2.0, 3.0, 9.0, 3.0, 4.0, 2.0, 3.0, 3.0, 6.0, 2.0, 6.0, 8.0, 9.0, 4.0, 2.0, 10.0, 1.0, 5.0, 0.0, 4.0, 8.0, 6.0, 8.0, 3.0, 1.0, 5.0, 10.0, 1.0, 4.0, 7.0, 3.0, 7.0, 3.0, 4.0, 6.0, 0.0, 2.0, 10.0, 2.0, 4.0, 5.0, 5.0, 4.0, 7.0, 9.0, 3.0, 4.0, 7.0, 0.0, 4.0, 3.0, 0.0, 4.0, 0.0, 0.0, 5.0, 4.0, 9.0, 0.0, 9.0, 1.0, 4.0, 4.0, 8.0, 10.0, 6.0, 3.0, 8.0, 2.0, 6.0, 2.0, 4.0, 10.0, 9.0, 9.0, 1.0, 3.0, 2.0, 1.0, 2.0, 6.0, 5.0, 2.0, 6.0, 2.0, 5.0, 4.0, 6.0, 7.0, 2.0, 9.0, 9.0, 3.0, 8.0, 8.0, 4.0, 10.0, 1.0, 3.0, 6.0, 1.0, 9.0, 2.0, 8.0, 10.0, 2.0, 2.0, 9.0, 0.0, 9.0, 1.0, 5.0, 2.0, 2.0, 8.0, 3.0, 6.0, 2.0, 9.0, 8.0, 2.0, 9.0, 2.0, 3.0, 4.0, 10.0, 1.0, 3.0, 1.0, 8.0, 6.0, 4.0, 10.0, 9.0, 8.0, 6.0, 5.0, 3.0, 5.0, 4.0, 0.0, 3.0, 10.0, 7.0, 4.0, 5.0, 1.0, 3.0, 10.0, 2.0, 9.0, 4.0, 9.0, 8.0, 8.0, 4.0, 9.0, 9.0, 10.0, 7.0, 6.0, 9.0, 10.0, 2.0, 3.0, 6.0, 2.0, 5.0, 0.0, 5.0, 1.0, 9.0, 1.0, 4.0, 3.0, 5.0, 8.0, 4.0, 0.0, 1.0, 10.0, 10.0, 8.0, 2.0, 7.0, 6.0, 9.0, 6.0, 0.0, 6.0, 1.0, 1.0, 4.0, 0.0, 7.0, 0.0, 9.0, 7.0, 10.0, 4.0, 5.0, 9.0, 4.0, 4.0, 8.0, 8.0, 3.0, 1.0, 4.0, 6.0, 0.0, 0.0, 7.0, 8.0, 8.0, 10.0, 5.0, 7.0, 3.0, 1.0, 7.0, 4.0, 7.0, 8.0, 7.0, 8.0, 9.0, 1.0, 4.0, 3.0, 2.0, 2.0, 6.0, 5.0, 7.0, 8.0, 4.0, 2.0, 10.0, 0.0, 7.0, 8.0, 2.0, 2.0, 2.0, 5.0, 9.0, 7.0, 3.0, 1.0, 6.0, 2.0, 5.0, 3.0, 6.0, 8.0, 2.0, 1.0, 9.0, 7.0, 3.0, 1.0, 9.0, 3.0, 10.0, 9.0, 8.0, 5.0, 9.0, 3.0, 0.0, 2.0, 3.0, 4.0, 7.0, 5.0, 9.0, 5.0, 3.0, 1.0, 4.0, 8.0, 4.0, 7.0, 7.0, 7.0, 9.0, 3.0, 3.0, 10.0, 3.0, 2.0, 3.0, 2.0, 1.0, 5.0, 3.0, 2.0, 7.0, 3.0, 4.0, 7.0, 3.0, 10.0, 3.0, 9.0, 1.0, 8.0, 7.0, 9.0, 7.0, 7.0, 4.0, 8.0, 8.0, 3.0, 2.0, 9.0, 2.0, 5.0, 9.0, 3.0, 9.0, 8.0, 1.0, 6.0, 4.0, 3.0, 3.0, 6.0, 2.0, 3.0, 6.0, 1.0, 2.0, 8.0, 5.0, 2.0, 8.0, 2.0, 7.0, 1.0, 6.0, 10.0, 8.0, 7.0, 2.0, 5.0, 10.0, 2.0, 10.0, 3.0, 0.0, 9.0, 2.0, 7.0, 6.0, 1.0, 4.0, 0.0, 1.0, 4.0, 5.0, 5.0, 5.0, 5.0, 8.0, 4.0, 3.0, 6.0, 8.0, 8.0, 5.0, 9.0, 5.0, 7.0, 2.0, 1.0, 8.0, 1.0, 8.0, 0.0, 6.0, 7.0, 1.0, 2.0, 1.0, 2.0, 1.0, 2.0, 4.0, 3.0, 2.0, 2.0, 6.0, 10.0, 7.0, 10.0, 8.0, 9.0, 7.0, 7.0, 2.0, 2.0, 4.0, 4.0, 6.0, 0.0, 6.0, 3.0, 4.0, 4.0, 2.0, 1.0, 7.0, 10.0, 1.0, 3.0, 7.0, 6.0, 9.0, 3.0, 2.0, 3.0, 9.0, 2.0, 6.0, 2.0, 3.0, 3.0, 0.0, 6.0, 6.0, 6.0, 10.0, 1.0, 10.0, 7.0, 0.0, 3.0, 0.0, 2.0, 9.0, 9.0, 3.0, 2.0, 6.0, 9.0, 6.0, 1.0, 3.0, 2.0, 4.0, 4.0, 7.0, 10.0, 5.0, 1.0, 1.0, 2.0, 1.0, 8.0, 6.0, 10.0, 3.0, 5.0, 7.0, 3.0, 1.0, 9.0, 3.0, 10.0, 6.0, 3.0, 0.0, 2.0, 2.0, 1.0, 1.0, 8.0, 9.0, 9.0, 2.0, 6.0, 1.0, 7.0, 9.0, 7.0, 6.0, 6.0, 5.0, 7.0, 4.0, 7.0, 4.0, 8.0, 0.0, 10.0, 3.0, 6.0, 5.0, 7.0, 1.0, 3.0, 1.0, 6.0, 2.0, 3.0, 9.0, 9.0, 4.0, 8.0, 9.0, 8.0, 2.0, 6.0, 1.0, 7.0, 8.0, 1.0, 1.0, 4.0, 8.0, 3.0, 0.0, 3.0, 8.0, 8.0, 8.0, 8.0, 3.0, 2.0, 4.0, 7.0, 4.0, 9.0, 1.0, 5.0, 2.0, 9.0, 8.0, 7.0, 1.0, 6.0, 7.0, 1.0, 9.0, 7.0, 9.0, 9.0, 8.0, 6.0, 9.0, 6.0, 3.0, 4.0, 7.0, 9.0, 5.0, 4.0, 4.0, 8.0, 8.0, 7.0, 6.0, 0.0, 9.0, 4.0, 3.0, 6.0, 6.0, 1.0, 8.0, 9.0, 1.0, 2.0, 5.0, 7.0, 9.0, 2.0, 6.0, 7.0, 9.0, 3.0, 1.0, 8.0, 7.0, 4.0, 5.0, 1.0, 6.0, 1.0, 6.0, 3.0, 3.0, 2.0, 6.0, 10.0, 8.0, 3.0, 9.0, 2.0, 9.0, 0.0, 7.0, 7.0, 5.0, 7.0, 8.0, 4.0, 8.0, 8.0, 0.0, 3.0, 7.0, 1.0, 8.0, 9.0, 8.0, 2.0, 7.0, 8.0, 3.0, 4.0, 4.0, 1.0, 2.0, 7.0, 3.0, 6.0, 6.0, 3.0, 3.0, 10.0, 0.0, 3.0, 0.0, 8.0, 1.0, 9.0, 1.0, 6.0, 0.0, 4.0, 4.0, 2.0, 6.0, 1.0, 1.0, 5.0, 2.0, 0.0, 7.0, 6.0, 9.0, 10.0, 5.0, 3.0, 8.0, 3.0, 0.0, 8.0, 2.0, 2.0, 9.0, 7.0, 8.0, 6.0, 8.0, 1.0, 9.0, 9.0, 9.0, 6.0, 8.0, 2.0, 2.0, 3.0, 2.0, 6.0, 1.0, 7.0, 5.0, 3.0, 7.0, 6.0, 10.0, 5.0, 3.0, 0.0, 10.0, 8.0, 4.0, 9.0, 2.0, 1.0, 4.0, 7.0, 8.0, 1.0, 5.0, 2.0, 8.0, 1.0, 0.0, 1.0, 0.0, 9.0, 7.0, 1.0, 6.0, 2.0, 7.0, 8.0, 1.0, 4.0, 4.0, 8.0, 4.0, 4.0, 5.0, 9.0, 7.0, 2.0, 7.0, 4.0, 9.0, 2.0, 10.0, 0.0, 1.0, 7.0, 3.0, 4.0, 3.0, 3.0, 5.0, 3.0, 2.0, 9.0, 0.0, 6.0, 7.0, 1.0, 5.0, 1.0, 3.0, 0.0, 6.0, 5.0, 1.0, 1.0, 0.0, 3.0, 8.0, 8.0, 8.0, 5.0, 8.0, 2.0, 5.0, 10.0, 5.0, 2.0, 10.0, 4.0, 6.0, 10.0, 4.0, 10.0, 8.0, 7.0, 9.0, 9.0, 2.0, 8.0, 5.0, 6.0, 0.0, 6.0, 9.0, 10.0, 9.0, 2.0, 1.0, 8.0, 7.0, 1.0, 10.0, 4.0, 5.0, 7.0, 9.0, 6.0, 6.0, 8.0, 5.0, 8.0, 1.0, 5.0, 8.0, 10.0, 2.0, 10.0, 0.0, 3.0, 2.0, 10.0, 1.0, 5.0, 9.0, 1.0, 9.0, 10.0, 10.0, 9.0, 9.0, 4.0, 3.0, 4.0, 9.0, 5.0, 3.0, 0.0, 8.0, 4.0, 1.0, 9.0, 8.0, 4.0, 4.0, 4.0, 5.0, 6.0, 5.0, 4.0, 5.0, 1.0, 9.0, 2.0, 4.0, 10.0, 5.0, 6.0, 5.0, 5.0, 1.0, 1.0, 8.0, 3.0, 3.0, 4.0, 3.0, 6.0, 9.0, 1.0, 1.0, 5.0, 3.0, 1.0, 3.0, 1.0, 4.0, 0.0, 4.0, 10.0, 3.0, 7.0, 9.0, 3.0, 0.0, 4.0, 7.0, 4.0, 9.0, 7.0, 9.0, 7.0], "lambda": [14.517417650065793, 10.500259555267803, 18.933359033691985, 15.323533610533119, 11.978348732880711, 11.436860570809385, 14.672160556532216, 17.49226315582475, 19.770194280475327, 13.260434381304648, 19.4294199064568, 16.32303104210846, 11.55297654011212, 13.782470314979506, 14.99043616566452, 16.36331480496053, 11.787867544575366, 16.461034002376692, 10.320409214567457, 19.01563031570774, 16.362626407475044, 17.685220948708782, 19.658142222133, 13.521393819571184, 17.998266768678832, 11.246038016355836, 19.806836427940954, 13.470686493891803, 11.93952643981779, 17.1929049838724, 12.635519592363693, 14.283978637648413, 10.729235141023333, 13.383513338137012, 15.748800922711686, 19.25650633917598, 18.599729381057042, 16.21527676229465, 16.470470508798954, 10.461972170262237, 10.316623520928323, 16.303481301110132, 11.072001047077356, 11.058706020302019, 15.923334328439978, 16.166089538730432, 13.311735218758045, 17.829753932054672, 13.838918096898068, 15.847964685834729, 16.64011785892432, 12.874447654620619, 19.818641265642263, 11.250266933195727, 18.065461507340643, 19.077329300197647, 10.77349603294013, 17.026831910077703, 18.145997399451517, 10.53564495004925, 10.838295375568036, 11.077598506406732, 12.306365368492997, 16.380385696960452, 12.376439231398667, 14.347164168347398, 17.969798715768018, 10.079215637390774, 16.004778220992904, 18.862876033346865, 10.33115931807624, 16.385511833603175, 12.42267497816071, 13.438356265985792, 17.170806877773114, 17.095384007366405, 10.296397606122367, 19.130342931390672, 11.146483193349383, 19.19508204866724, 19.171600359484934, 17.127446586714967, 12.039011376661406, 16.097695055373705, 16.55912279861176, 10.274028875215397, 12.389050440023178, 10.454557405408721, 14.172375563052963, 14.872340671374905, 16.092424162031833, 18.2369731363168, 19.85999967378248, 19.471523511920058, 17.488356306473662, 10.38184322807584, 11.047482561671444, 17.14092966633212, 13.097578368777043, 16.358341771989338, 15.64854589935155, 15.66620953307472, 16.891519953575077, 12.03256195363163, 15.339927696882452, 17.815630464408216, 18.21893054687304, 19.615048147984048, 14.810395502942328, 14.406736706288767, 18.75183894166407, 10.569669977665333, 12.945837824712385, 13.049770768012614, 13.015393361603103, 11.084808429422246, 19.395054800604587, 13.011446320671745, 17.8460489338709, 14.607735722277729, 14.040228440903824, 18.26789328290141, 10.107247984673675, 10.453244025872069, 16.25621732872059, 15.100498376189124, 13.945686338050438, 19.995944953960723, 17.037752787102907, 10.774350058618694, 14.619879110743225, 10.38066413336227, 19.88613536273646, 14.93872417083603, 10.588588040589762, 14.943128815984277, 18.64674757214749, 16.670348637388727, 18.63415573346213, 12.121004318262422, 16.71928034267714, 13.217390788342762, 11.322090385260953, 19.26692573268112, 19.96591617296613, 12.812483509779701, 14.462533590654068, 13.781675902165986, 14.005171306074207, 19.81623447558384, 16.775667518523154, 13.478138151957241, 14.313887503177368, 16.644293267715025, 11.958588661109669, 19.875545934101456, 14.429378050163324, 16.557958404504138, 16.122951523803145, 17.94173781918313, 10.298582202607777, 13.371642181438272, 13.837003030441506, 16.514692687631587, 12.872286712616791, 19.240471797029716, 13.156674836079103, 11.306740739019753, 17.745098522247883, 17.343482893068384, 11.894434713410579, 11.203980747242134, 11.705553719570055, 18.958466410950457, 11.206126183580162, 12.91456571747941, 10.048081392423038, 15.464147760257061, 18.685422729546914, 11.091716537824482, 10.82547727224886, 18.456783974928854, 11.730093152635122, 19.485890009455357, 14.474074989920389, 18.685805433306584, 10.630889680448757, 13.054117275888908, 17.23322297479014, 15.465020944112137, 13.75868651515262, 15.037844184963738, 15.402382515957509, 15.062235639642275, 11.513792293369598, 18.40118866455756, 19.320308207647884, 17.556844477721224, 17.557788345860384, 14.751294732770909, 17.303265597825437, 19.54828139359481, 15.962437077850812, 15.403210522526287, 19.739233992721495, 16.83844948016702, 11.616494394319124, 13.26241543162147, 15.869461199945011, 18.978471396139525, 14.86325466558305, 10.71573724131156, 13.11832568041272, 16.237693928640113, 19.88126573297993, 19.892431390457652, 10.19798427226099, 11.813469418053469, 19.392782751099148, 10.487593524860186, 19.27823321912512, 17.28842938578675, 12.952578992106574, 18.99738389468468, 13.93092625534708, 10.562273436536922, 19.377688497473223, 16.254055371269853, 11.511726320617548, 10.209240836352748, 10.463473723108104, 12.064031267837228, 17.265763295370153, 16.242469495498074, 16.505951388978016, 10.034996403758855, 12.88877877170913, 15.91558162021565, 17.62357505330793, 11.420725194824499, 15.71748655032184, 12.31938249757023, 19.524807409266778, 14.69817023165909, 12.076309414008714, 13.837732543593598, 16.43549190810037, 14.414740852468215, 11.856385116407447, 19.942346451393792, 13.339683983798672, 10.928693779430853, 13.614374535781362, 13.605232103898068, 17.44798301653187, 17.209219834785436, 14.072459354453981, 18.23385416113647, 16.76455786837968, 11.479266368244899, 14.686089889130184, 15.541850664759986, 10.731240027276096, 12.737088632257871, 18.895639826013948, 13.404045135720171, 10.349868239288766, 17.08206884392287, 19.05154550606553, 13.892440816797798, 13.514453083226247, 12.165345620315136, 17.55541027276045, 17.381870532178496, 13.74436110548955, 12.036984482879504, 13.559218727481055, 10.383188825498497, 17.527602924537607, 13.835647577995159, 17.54059192486883, 18.190172790742448, 14.831651126944395, 17.08464132636749, 16.70065376110145, 14.13023745339372, 12.703943681129454, 16.27283184534571, 17.94266761414371, 14.058092754642292, 12.20217787202558, 19.455906453550803, 18.330920952020406, 16.10972631014318, 11.673575401854775, 14.396037221948047, 14.004502763219438, 19.85888514627205, 18.76022929253184, 19.356825713732068, 15.845559512244964, 18.64170281711508, 17.89140503543484, 14.94644529366246, 10.667237329907584, 17.209429256990116, 15.111641080406534, 10.407635108501117, 17.192212508488026, 18.895063660068793, 18.615868002257685, 13.984012392783736, 13.856353795780322, 17.99830125536759, 17.554742400559206, 13.008757510185815, 17.395534725366957, 13.446641492714825, 16.231842529809963, 11.188295248078425, 16.640308959219716, 17.780961275077303, 14.236768791423923, 10.888348317704828, 17.863262639910122, 11.695728495373656, 11.86072825888436, 14.760944399985682, 10.45848919728763, 13.749816229592605, 17.922593565664933, 12.330266149026432, 19.530151295483293, 13.526896416507075, 10.564749565903186, 16.83123535086903, 11.543642960932903, 16.451150598838858, 12.421831870231157, 12.587370618244432, 11.007505053010101, 14.827145504161685, 10.545411736916222, 17.273220390081125, 14.899962150956314, 10.47931271682825, 10.118680719679938, 19.93797575295411, 10.24053041972144, 12.578511861144095, 18.711484312265696, 11.497399118862123, 16.500633335191342, 14.123798003203234, 18.479164727677947, 17.003331837574493, 16.021997950337216, 16.15614129575488, 17.88383955538042, 18.837429851594692, 19.187572633717874, 10.147368347247536, 16.46225829150681, 18.694832388300224, 18.874083369237276, 10.063572516010796, 10.526626662076744, 10.278141485513068, 17.136874242185904, 15.45681802122074, 11.382493543512195, 15.773276649976616, 11.701872465044145, 18.472473933802164, 15.818545140559758, 18.32957127299502, 12.451364304278249, 11.171588668609962, 15.308567412916139, 17.39931083364861, 15.08969832759011, 12.23917404119857, 11.367950556594899, 14.070770458956316, 14.249331071829213, 14.060818991722039, 18.389534349903343, 16.255521824895702, 11.268615408977587, 12.138060882989173, 10.643989436727722, 12.253264838436067, 18.654221383015255, 17.330841066834335, 14.700798277810522, 11.831700198273783, 13.291676076918915, 14.988719593987065, 18.87469550835975, 14.401258219387826, 19.66949486831119, 19.15930752575843, 12.239380527717836, 11.090476165434795, 19.71344333420207, 19.572595705919436, 14.871701744164433, 17.233253925049148, 14.142285590220869, 19.138294981267386, 15.206411075381975, 17.774723701446018, 13.920509246613843, 19.861883037418593, 12.663334810888383, 18.905239781198407, 16.67899229979041, 13.793928034933067, 10.620255175696279, 15.834818356005176, 14.010719445476594, 18.92066185488795, 11.660455782010608, 13.683623508637101, 17.36947010058472, 18.29136933876119, 19.38569288639653, 18.00393755445571, 17.243961708907616, 15.722669462896874, 14.345229920137971, 10.387837209323813, 18.10205585361147, 12.939751287826017, 14.905380761933841, 12.016249979537113, 14.858918734094786, 16.259289444574666, 11.295870974746727, 11.862217363082921, 19.587032594904862, 12.143491199947462, 17.817463675704293, 15.678678777285578, 10.439502559439553, 10.969441589038569, 17.994515502601146, 16.091285357643578, 12.417029619082209, 19.902123774312543, 11.629837530570201, 14.280820757413526, 19.12893595630502, 17.363055869092896, 14.825882050901173, 17.743070530653615, 17.158539600641838, 11.507479362484915, 15.522634015292887, 12.180410784197077, 10.641853280829475, 14.457363533791888, 14.964165148042945, 19.629623485331383, 10.766683340479524, 17.955362168228906, 11.606277834083325, 11.474636920445088, 11.530243383677208, 13.484419539435143, 10.03906853297307, 11.183111023328728, 17.06189965250548, 13.1752047590813, 19.153441180754978, 17.989163489274414, 18.40867141714121, 12.751946760361854, 17.39115062946913, 19.923904653545073, 12.088309315583654, 19.513319104007998, 16.66097994378395, 17.33665964540868, 17.99880445251325, 17.087991471235497, 15.320121426446072, 13.48958715794938, 11.290575849021026, 17.242013738345065, 13.196530967920385, 12.27100439845432, 11.151011657738412, 15.361497520955592, 15.544249794776054, 12.836953526120167, 17.74084493005745, 10.817698185675539, 11.570656392489262, 18.54831926099645, 10.624869627926497, 11.126353836073307, 17.591554498599066, 13.942730713919744, 11.576040064321774, 14.231230429978062, 16.155802695249918, 12.147357427683438, 18.59484603824053, 16.71613876117799, 14.974483758014273, 13.114205502081761, 13.69144729884417, 11.882266347627125, 10.235991377394365, 13.631753366974218, 14.505183076923796, 12.288908795843072, 18.00176638023639, 13.608869604172503, 12.70301610450523, 10.7059576434483, 17.75155364932677, 19.120535483756214, 11.077675600638251, 18.33852837463501, 12.052568672387023, 13.157152004296002, 19.467316091454784, 18.101367401640108, 19.686654987875592, 15.998939814393813, 12.404179975050017, 12.521519052217148, 14.833021850950098, 11.77372252161804, 13.956151989229712, 15.243137393740955, 18.342985190638927, 14.056950408142411, 11.064639304212385, 18.590996335057177, 19.693099190609768, 18.267779979919975, 18.336585642664655, 13.619762277462373, 15.756944161085368, 10.11588453997086, 19.87730316245084, 17.928601189506168, 15.849217342896065, 19.80261036762563, 14.634940368690582, 14.941653498702681, 16.689890637859456, 11.403923497907675, 13.815863986859203, 16.235321946593956, 17.793719454957195, 12.725918651433396, 15.136988143874296, 17.292613979403377, 14.411667099424886, 16.171725386281565, 17.960109876756494, 17.758508525262172, 11.6544689605064, 15.405978090125496, 18.523894555650763, 13.287067761745757, 12.721349770532502, 19.4352249638917, 19.160044392711733, 17.468413637476345, 13.211269390072092, 15.724237140354393, 19.517643548248703, 12.678116807471119, 18.793611255967825, 19.85158996400764, 14.56872147021949, 16.582307553823924, 14.376288961724164, 10.225788717554849, 12.679090992937144, 11.711013354117258, 16.225099486187652, 13.597074386592505, 18.007118629442868, 14.224659324953091, 15.665656042169232, 10.325791901591261, 18.558436961737435, 19.02440000738479, 14.28418068046829, 11.415558157547546, 12.773259780695525, 11.291253635010989, 12.356053214036294, 10.52971465823933, 13.736011442581614, 18.128283950782453, 11.956845222197947, 19.76623601885617, 10.160568246153494, 10.909374271106122, 13.010100142365527, 10.243321616104192, 19.20824658692561, 16.65566828675147, 12.51220838334372, 12.93507514258976, 19.808181082872462, 13.421022660812273, 15.626703189331575, 16.445214328047566, 15.704219387578757, 11.333179139564345, 17.898894619894875, 10.85791339027763, 18.273490215426914, 17.89267709554298, 19.52246884496636, 17.33481478898812, 18.67562687253547, 11.010277370352235, 13.089601017389052, 19.02230167622006, 10.022145122531015, 10.26772408305174, 12.991427945032587, 12.474103078837695, 14.891162158513822, 14.224027102444746, 18.495862135924273, 10.874763636622394, 12.51864144161907, 10.915532435038456, 13.439775179161249, 12.953204635640905, 15.513268760646445, 17.460508638953424, 15.491383502378222, 16.882543362855902, 12.842792917773927, 12.303552218340677, 10.038388843465398, 15.579315455773417, 16.6706284394787, 18.00762470862086, 16.69461919141156, 10.065017346258582, 17.476211338132412, 18.640381854170208, 12.584782993539031, 11.55817703715908, 18.858955876137323, 15.734385548541034, 18.336566678902095, 19.392386762346238, 11.793316653606244, 11.325927902825034, 18.79664343123052, 19.72832364713361, 14.333919354526481, 15.569862509748194, 19.932265841958113, 19.76976382241091, 18.83162866936986, 13.599333552876978, 11.523151998175521, 14.925383084153754, 18.040377293354897, 19.71117880811193, 18.443968654184296, 14.09921782400413, 17.6106466540459, 18.316619807827017, 14.452633006332421, 13.012012783126506, 17.60010232238759, 15.513938405327497, 11.733866143298519, 17.608496821139763, 18.546946934746877, 13.04587961312107, 13.151224220919762, 19.771315576875455, 13.496045365061814, 12.807939379486424, 17.26024542760605, 14.488521580716291, 18.815000384370318, 17.924577984463482, 13.551138128146494, 19.589558670487673, 16.99939493398137, 19.32800602714817, 15.278756747007117, 19.62914489748824, 11.6653419691143, 10.00109483193272, 10.031167213820213, 13.614921492495375, 12.016630799524197, 17.61220348120333, 10.333838890560138, 14.196861003294252, 19.97957006532886, 16.115847703134136, 18.646883676822377, 17.130264377745803, 17.618044851420365, 16.43180496758778, 17.97657985164582, 11.507093699172074, 11.717884695039935, 18.05465987360671, 13.259358885307755, 19.753507669229915, 10.734338149292197, 10.44531316443808, 11.023030940533015, 15.19175404702569, 19.164029591451488, 10.622010591115803, 17.350341072774597, 12.036783946875827, 17.623858907704797, 11.622470716486445, 10.285737998847022, 16.24192702121396, 19.66253015169589, 12.050523208144883, 16.00678725556498, 17.218257661877473, 18.033265142926712, 12.74588102782776, 10.63542713357244, 15.331941533556336, 15.385680511199817, 14.02369472511938, 16.778246067085007, 15.325219815713208, 13.864065188971109, 17.74510150044042, 17.93192264826223, 10.62303482166468, 17.37977731662883, 18.79105210709148, 17.685511988029926, 16.902530740905863, 18.29899237358839, 13.967976898922075, 14.302560274056638, 10.128709447739935, 12.519969947562139, 18.638609535974837, 11.572386826546762, 18.69663066877689, 15.769357990135921, 11.881883435903205, 13.898439246407142, 19.746735421065033, 16.71618618925817, 19.925537923556618, 13.321878888393124, 12.483955034561063, 11.147519949718474, 13.022293398434842, 11.98503525242969, 12.561082806531909, 19.949291763319472, 12.732165252988482, 13.245377300669192, 12.882236042335883, 19.60257064383927, 13.238583527222321, 15.30119641295773, 14.531022264878622, 14.493270425208742, 12.067945865285504, 14.392774824074205, 18.80000439576556, 14.314876833611612, 13.890244165400915, 11.716217908671405, 18.756013391427025, 13.121637780720423, 11.837223725008853, 17.52802913247294, 14.772458283285903, 15.117758688429985, 19.074024999523402, 17.407472347723335, 17.758385573373218, 17.335716016781944, 17.53044812839292, 19.154947854236276, 18.85495533728877, 10.46638170386264, 19.48092798612219, 11.780714747318399, 13.645687067006307, 12.027635603240565, 10.06895924402929, 19.16019756494766, 17.0815545545075, 14.717635111106455, 12.928322574586447, 15.089799250535467, 19.818711147795224, 13.116790522399423, 15.470951564310687, 17.64387410475122, 12.99226088532131, 18.182714346820724, 13.40300067897766, 18.740156095170974, 19.981943396704995, 12.775271535890244, 10.586268912265966, 16.721256388728246, 19.301662356098475, 15.891125961533234, 13.564324616866129, 17.74667890024622, 17.66814590141408, 11.044420070065888, 15.12862148523358, 17.060112926734607, 10.381432020672133, 10.412046511247372, 11.58051747960771, 15.72233236061739, 12.534447811516014, 15.25296539892784, 15.890580152772705, 18.823799660525495, 14.867118291014403, 10.58432718053503, 16.227853804635785, 15.295716128539851, 16.389517234479285, 11.006975556562837, 12.715966550707659, 10.660967892680418, 18.648912690136328, 14.51026175334766, 12.04977620742374, 18.47568815375045, 18.77210064523749, 14.843215346926854, 10.138980695000543, 10.74276944929671, 10.473561102882671, 12.181843521834168, 15.085783477159936, 17.25088737168397, 17.846366747385314, 17.896442743382217, 10.265065396516599, 13.807631271863094, 19.302033930513332, 10.961647379915506, 16.99393734804428, 12.073706087051924, 16.470224257284205, 15.552532456864476, 11.689738567597153, 19.29114916771487, 12.322135722494572, 15.286475349863432, 15.978550038357113, 16.756567235115586, 14.879852297165597, 18.940627257311323, 15.680329352065097, 13.5061818141233, 10.25084911531345, 10.404809496730508, 15.691266987801285, 10.057732568240679, 13.00782298111967, 13.390727514256017, 13.548419839084858, 10.96384538034873, 17.444879940170807, 15.952469738783904, 10.814428917443339, 16.835825222357368, 13.366892702836713, 16.242337118567328, 13.116401729825911, 11.511614029546939, 14.355670630963283, 10.649867418187387, 12.902168618792675, 18.92039015196715, 10.167032485260261, 17.377125359653665, 15.702866272131928, 18.216987830858397, 13.161830802018727, 19.52375013097332, 19.16382085310869, 10.896703931371881, 19.11423064177726, 17.406585742368545, 14.52003469444673, 10.26700354190499, 15.22785966880408, 14.504887477056029, 13.628061844885842, 12.69626600282478, 19.936355594315604, 16.829918878536066, 12.822670869140502, 18.48250670460356, 16.587606838071416, 11.322628677945731, 11.601329800242212, 18.69583451964625, 15.143379671281696, 10.046681919726304, 12.08148601707962, 12.428618923148784, 17.233339238768234, 15.05725662446683, 18.129936390040463, 17.567950356349453, 11.716082237801949, 15.802989805039234, 19.545028400663412, 17.935688322131682, 13.662898005276901, 19.93994486658835, 11.547961847889525, 13.58239697616115, 17.871985614289407, 16.767481001410026, 12.953448521815545, 17.86821803886861, 13.403088794731001, 10.520240743797252, 12.309276796627133, 10.904211264922214, 17.575397451296872, 14.769386057047813, 19.776950752737083, 17.167420744361717, 19.08090562823049, 12.862563397362436, 15.537993002301146, 17.083716701976208, 16.827284016698965, 16.893656267271506, 13.575935423979386, 17.511177726823206, 13.61240181512892, 12.328416894777792, 17.967282371408665, 18.298375839211857, 14.170507268928887, 19.031997567346977, 17.854328617012598, 11.946143628708857, 15.896428683176591, 17.987563522601533, 12.67873935887402, 14.956677538210931, 15.666149437476555, 12.726061960259527, 16.48297593702432, 12.797445381004318, 14.034204490991977, 16.65676102501373, 15.367410113654117, 18.229546702352103, 13.083191661891878, 16.29658444631453, 18.08800067060904, 14.274245087354169, 19.39406406411811, 14.46085590497675, 18.612845180537605, 12.238670364263935, 12.874017337206372, 17.211432058917424, 18.044734260337133, 11.641839109983152, 11.78974905197798, 17.652468559925808, 19.68165829770787, 11.765436311687413, 14.0948474865453, 13.141697983059869, 14.392734297833343, 19.60305370047962, 17.746719456291004], "expected": [-130.6567593462314, -94.50236352709221, -37.866718073372866, -91.94120188454588, -6.278712631211285e-06, -80.05803478604986, -44.016482094178784, -69.96905264860402, -98.8509714049703, -92.82304241120774, -19.429419910103586, -81.61515529201229, -115.52977500857102, -41.347411978531184, -14.990436474506522, -65.45325929809543, -70.72721286364225, -164.61034009473514, -51.60207902700768, -19.015630321223643, -81.81313211568242, -17.685220969573194, -117.94885333569921, -121.69254571808212, -1.5256399815505043e-08, -56.230203140799034, -59.42050928632322, -26.941374399526122, -35.81858584671421, -85.96452495349827, -101.08415999325963, -28.56795790125748, -32.18772731868448, -93.68459490729111, -141.73920844907656, -38.513012682687126, -18.599729389417693, -64.86110713991776, -115.29329363189433, -94.15777813653524, -51.58315068380492, -114.12436919084931, -99.64802496524929, -88.4696639119759, -95.54000609214197, -64.6643582502357, -53.24694252999107, -17.829753950111282, -124.55026384894738, -47.543894188517804, -5.9331953667244824e-08, -51.497793181189635, -178.3677713932514, -101.25241540267214, -108.39276905830879, -38.15465860558116, -21.54701301349948, -51.08049577053644, -90.72998701041872, -2.657255441356741e-05, -75.86808726223492, -33.23281097402243, -24.612735259859175, -16.38038577388924, -12.376443448185546, -86.08298559771701, -125.78859102607308, -20.158473217963515, -128.038225879942, -150.90300827320115, -82.6493071464112, -163.8551184125672, -74.53605389522299, -67.19178278805929, -3.489902794363828e-08, -136.76307209656426, -92.66761221014434, -133.9124005246528, -11.146497619384633, -172.75573844261496, -19.171600364204256, -17.127446623160512, -96.31209692244207, -80.48847537892955, -49.67736846017281, -20.54809226905264, -4.163941909069817e-06, -20.9091436278771, -127.55138076734389, -59.48936303305546, -48.27727258869589, -109.42183882991743, -99.2999983712833, -155.7721880988569, -17.488356331877736, -10.381874218641517, -55.23742873567859, -85.70464836761803, -78.58547226285378, -114.5083924825688, -140.83691325409134, -15.666209690202033, -84.45759981401842, -96.26050157643775, -30.679855611512863, -142.52504373357917, -163.97037493409277, -137.3053370389173, -59.241582381535366, -57.62694737880323, -131.2628725988294, -84.55738550494235, -77.67502933440699, -52.199085222637535, -52.061575672216655, -55.4240574908854, -96.97527400679722, -91.08012647930916, -178.46048935647377, -87.64641478650252, -98.28159988506862, -36.5357865774536, -20.214536753066653, -31.359760932549015, -146.3059560455846, -45.30149540522137, -55.78274623014323, -39.991889909990974, -51.11325840117429, -32.323071105592945, -87.71927511182977, -20.761359293853147, -119.3168121787285, -119.50979369192123, -95.2973175676043, -59.77251558774071, -37.293495152271625, -166.7034864314524, -18.634155741539853, -60.605027035284216, -5.481618631591803e-08, -52.869564972068716, -90.57673518475926, -115.60155440037695, -159.72732938586165, -38.437453255865485, -14.46253411425641, -68.90838054524403, -140.05171388798212, -19.8162344780608, -67.1026701259034, -94.34696846496247, -42.94166311704818, -116.51005293308991, -35.87577238734376, -79.50218373874014, -86.57626884223362, -6.441248397829232e-08, -32.245903147121886, -179.41737820797496, -20.597198086596688, -53.48657028447961, -69.18501613094485, -82.57346350541845, -51.489149418718185, -134.68330258361323, -118.4100754572548, -33.92023450693686, -70.9803941086433, -121.40438028084309, -6.828324022145459e-06, -44.815936608932034, -35.11666940662946, -5.840400846681587e-09, -44.82451832509451, -2.461931172566907e-06, -4.3269621217630487e-05, -77.32073899359713, -74.7416909258617, -99.82546407856252, -1.9886542147714392e-05, -166.1110557840051, -11.730101200617545, -77.94356004126799, -57.89630047727553, -149.48644347412377, -106.30892096290717, -78.32470579659326, -51.69966895715778, -123.72016774504108, -27.517374088775348, -90.22706540432449, -30.804765236479536, -60.248942846013755, -115.13793292508136, -165.61069799121486, -173.88277387289816, -17.556844501443663, -52.67336506128121, -29.502589857820023, -17.30326562839486, -39.09656279042771, -95.7746225839476, -77.01605281702663, -39.47846798811821, -101.03069692966014, -23.232997804817625, -66.31207889673482, -63.47784492800737, -113.87082838256188, -104.04278300980948, -21.431496675789333, -118.06493313180822, -146.1392454464887, -59.643797201260796, -159.13945112595644, -81.58391142410105, -47.25388507639489, -193.92782751477435, -10.487621405456474, -57.83469966161735, -103.73057634574683, -12.952581362208003, -170.9764550577796, -27.86185340169024, -84.49821336659176, -193.77688497857264, -32.50811082982749, -23.023462653283854, -91.88320435626893, -2.8561256038724148e-05, -108.57628717367335, -17.265763327107766, -81.21234756579534, -33.01190284580706, -20.07003664705438, -103.11023269991561, -47.74674498309469, -105.74145034203868, -22.841461355553253, -141.45737910216994, -98.55506444494159, -39.04961482184856, -132.28353249861308, -24.152624520827516, -41.51319860880437, -65.74196770520571, -144.14740907391655, -11.856392209553606, -59.82703935636486, -13.339685593143857, -87.42956817173166, -81.68624843748, -54.42092964961466, -174.47983019176942, -154.88297854665282, -112.57967560903997, -109.40312497887301, -83.822789394288, -34.43780944710791, -73.43044986435991, -62.167402836974404, -2.1851759760713416e-05, -38.21126883681423, -188.95639826635858, -93.82831745906986, -41.39950495467242, -85.4103442577518, -19.051545511386845, -41.67732337634825, -135.14453218355038, -24.33069644848256, -157.99869247860053, -69.52748215697251, -123.69925102314821, -96.29588178417626, -108.47375111197903, -41.53278625088624, -157.74842634526482, -124.52082918202129, -175.40591927279945, -127.33120954778953, -88.98990712365575, -153.76177197534687, -167.00653766686128, -28.26047563677592, -38.11183408250957, -97.63699115773838, -35.88533524441608, -70.29046455781102, -5.019524437746017e-06, -97.27953227130547, -18.33092096295952, -144.98753689212907, -11.673583917792328, -57.58414944739591, -42.01350911745162, -99.2944257337338, -150.08183434737563, -77.42730285884964, -1.3132910044733908e-07, -18.641702825132068, -178.91405037132543, -149.4644532593561, -85.33792193533532, -34.41885854755707, -105.78148783643417, -62.44584085247523, -154.72991261055216, -113.37038196663545, -8.22680593701776e-09, -83.90407520163248, -13.856354755760389, -17.998301270623465, -70.21896962600918, -2.2406234837319783e-06, -121.76874310544373, -1.446099292416708e-06, -146.08658285753805, -78.31808057183419, -166.40308965151777, -71.1238451192687, -71.18384461334045, -97.99515353407914, -71.45305057710208, -46.78292231085133, -94.88583313348119, -118.08755558839651, -31.375496295840694, -13.749817297493417, -71.69037427911543, -73.98160131021295, -3.2973349660642157e-09, -1.3345775619450416e-06, -73.95327277162902, -134.64988285596255, -92.34915338500517, -164.51150606006166, -62.10916338081054, -88.1115977425886, -33.02253173599054, -14.827145867785738, -73.81790847269936, -69.09288159182633, -104.29973539478141, -83.83452984705796, -70.8308053578553, -159.50380602582592, -92.16480947204187, -12.578515306407699, -74.84593725653941, -34.49220751311301, -33.001266738595504, -28.24759674111084, -110.87498837549961, -85.01665922913413, -112.15398576244719, -129.24913046230594, -71.53535823862762, -37.674859709781245, -191.87572634182328, -3.9179819304062066e-05, -115.23580811142904, -149.55865911400397, -37.74816674482918, -20.127187636498697, -21.053280137433898, -51.390741804514626, -154.2318682157767, -108.19772634227178, -34.14749202380523, -15.773276791150064, -70.21124306860294, -36.94494787709958, -79.09272583772402, -54.98871382993895, -74.70818973805859, -89.37272341724841, -30.617135050517078, -17.399310861418574, -135.80728522796903, -85.674223125604, -34.10386322995715, -14.070771233671739, -128.24398029449168, -42.182457757629585, -183.8953435093498, -146.29969651122119, -90.14893603930349, -60.69030976684968, -95.79592877455974, -36.75979928483981, -7.917254216926877e-09, -34.661682163406645, -44.1023952460271, -47.32680806351465, -93.04173422692355, -74.94359827930793, -169.8722595815885, -72.00629165362876, -59.00848460780202, -19.159307530536125, -48.95752694708663, -88.72382458053339, -78.85377333955338, -137.00816994459637, -104.10191255692901, -120.63277750813036, -127.28057103323405, -57.414884948681305, -45.61923347499706, -177.7472370335383, -41.76152864016763, -39.72376607720362, -37.99000759774197, -37.8104795685565, -16.67899235686012, -68.96964119648297, -31.860789943795336, -31.669636844757683, -98.0750369409993, -56.761985570729266, -46.64183175644245, -95.7853657014398, -52.10841033036529, -182.91369339899234, -58.15707866299938, -162.03543800527152, -17.24396174134476, -125.78135585167671, -100.41661002973615, -93.49056568927587, -126.71439098903265, -90.57826141548239, -59.62152338399556, -96.13000588149106, -118.87135022501045, -48.77786842055611, -22.59175437368863, -106.75996331964373, -39.174065192924736, -60.71746132265728, -160.35717309961854, -47.03603648703695, -93.95555228914054, -87.75554993241325, -17.994515517914884, -96.54771224857876, -49.66812252538158, -59.706371325210725, -34.889521488384396, -85.68492517242164, -38.25787191753507, -52.089167636073924, -88.9552926694908, -17.743070550345276, -34.31707923661346, -92.05984495453946, -77.61317025785125, -24.36082669837712, -85.13485014163562, -28.91472759390018, -104.74915635336372, -19.62962348831651, -64.60012113369478, -179.55362169821427, -92.8502317814329, -80.32246883347955, -23.060496595714458, -67.42209908966322, -100.3907289911062, -22.366235953854627, -170.61899656396926, -39.52561617430661, -4.8058054318305214e-09, -161.90247141886564, -36.817342844403235, -89.26363021921296, -104.34690380481229, -19.923904655769192, -48.353242887239595, -3.3533060828806976e-09, -16.660980001890938, -69.34663861120016, -89.99402227781447, -85.43995739408975, -76.60060735433407, -67.44793717505712, -90.32461928232595, -68.96805498588066, -39.58959476079502, -73.62603107639397, -89.20810762276199, -122.8919803807462, -77.72124915138835, -115.53258439569933, -88.70422467002278, -75.72390734157489, -23.14132222406199, -18.548319269798167, -84.99898132770694, -11.126368555439893, -140.7324360117057, -8.805401828648209e-07, -69.45624977433349, -99.61861366971173, -16.155802791549423, -24.294720157746905, -18.59484604664211, -33.43227757734465, -14.974484071822555, -26.22841302054804, -54.765790327464806, -35.64680595480282, -20.47201861172788, -27.263507935673157, -87.03109896328324, -122.88909256095111, -126.01236467685783, -136.08869727126682, -101.62413187798337, -96.35364120230835, -124.26087556481271, -133.84374839126008, -22.155366654887292, -36.677056760126234, -48.21028051912718, -52.62860994880496, -116.80389655223988, -1.3761824885541665e-08, -118.1199299300732, -47.99681955583599, -49.61672400161752, -50.08607985619106, -29.666044063393734, -11.773730226020309, -97.69306479340914, -152.4313741772871, -18.34298520144686, -42.17085200992359, -77.45249078587577, -111.54597801877705, -177.23789271828943, -54.80333995141201, -36.67317129620663, -40.85928804860858, -141.8124975932664, -20.231809512939748, -119.26381897703526, -35.85720239536948, -47.54765215953779, -59.40783110538782, -4.4068295264104895e-07, -89.64992131649777, -100.13934388360786, -68.42355213915367, -138.15864086823916, -16.235322035532352, -177.9371945682911, -89.08143353309872, -2.667409136274729e-07, -51.87784196910691, -5.509251813557772e-07, -32.34345086734143, -161.64098890665824, -159.82657674674957, -34.96341556173107, -30.811956384081306, -111.14336734292392, -119.58361155200204, -76.32810160987465, -19.435224967517374, -57.48013318290938, -34.93682730086847, -52.84507939015317, -62.89694870968666, -136.62350484107975, -126.78117119334588, -93.96805628672625, -19.851589966398556, -14.568721941071859, -33.164615170510885, -14.376289532488933, -81.80634596509337, -76.07454907322091, -117.11014174418376, -48.675298548415185, -67.9853731770929, -126.04983042122203, -42.6739786390749, -15.665656199383537, -92.9321598915834, -55.67531089392541, -190.24400007931567, -85.70508470864394, -34.24668549535508, -2.8355961437391456e-06, -22.582519751716887, -24.712110731705355, -10.52974138884704, -13.736012525326801, -145.02627161965597, -107.61161341497105, -177.89612417230947, -20.321175158345028, -65.45626391281392, -13.010102379982692, -71.70328690778489, -172.87421928688002, -116.58967806567674, -75.07325398150246, -77.61045326749115, -99.0409054168593, -93.94716010931124, -62.506812920785386, -115.11650036843278, -62.81687770158203, -90.66544508572338, -1.6850346593458394e-08, -108.57915315461925, -54.82047065786649, -107.35606259021331, -97.61234422815458, -121.34370355253687, -18.67562688028505, -33.03084864212361, -13.089603084001098, -114.13381006279958, -20.04433465164123, -30.8032069861011, -116.92285378508424, -112.26693153396909, -59.56464897513079, -113.79221748419366, -166.46275923259424, -86.99812802313856, -25.037286541071325, -65.49321278414365, -13.439776635224087, -90.67243481810539, -124.1061502682651, -17.460508665074883, -15.49138368952298, -67.5301734979827, -102.7423459873181, -36.910661190636674, -4.369106242212082e-05, -46.73794653871176, -133.36502757337865, -144.06099768408117, -133.55695358747732, -80.52018131303267, -52.42863404011172, -37.280763716368, -50.33913539788159, -80.90724881772933, -75.43582351100078, -141.60947008364133, -18.336566689779623, -96.96193381551555, -23.58664086212248, -101.93336318174144, -150.37314745671046, -138.09826553263986, -14.333919949993962, -93.41917523150852, -139.52586089591242, -19.76976382500569, -169.48465803095894, -95.1953361114617, -103.70837788188447, -134.32844808698482, -144.32301836146647, -118.26707285142292, -165.99571789742848, -84.5953076970121, -52.83193998461755, -73.26647924240474, -101.16843157313902, -117.10811728148005, -88.00051163465608, -62.05575380428096, -46.93547259086863, -140.86797459164634, -148.37557548678882, -91.32115945081914, -78.90734726862377, -2.590757389756367e-09, -121.46440966194874, -51.23176025688998, -51.78073631473138, -86.931129994468, -112.89000231296329, -17.924578000886566, -108.40910632778603, -176.3060280374962, -16.999394975405806, -38.656012058332365, -76.39378396651922, -137.40401428540423, -104.98808630837138, -20.002235015145462, -60.187047290653375, -95.30445166959083, -108.14968323861022, -52.83661046605487, -10.333871405118044, -113.57488870929276, -139.85699045940572, -64.4633909127616, -93.23441839208743, -17.1302644140888, -105.70826913083634, -16.431805040660922, -107.85947912546578, -34.52129115605484, -35.15366223195829, -36.10931976163327, -79.55615505579634, -197.53507669493646, -85.87472697850195, -31.33596857800473, -99.20729478637094, -30.3835083465768, -172.47626632781856, -2.4373882112108962e-05, -121.45238753858588, -84.25749355045853, -88.11929456070878, -81.35730397786135, -82.28593810756546, -64.96770817320873, -157.30024121645562, -96.40419150667458, -1.117739622264306e-07, -51.654773018914135, -126.23285601521867, -12.745883942131647, -85.08344111762842, -137.98747402150093, -123.08544429760839, -28.04739026229656, -117.44772252127241, -122.6017587466799, -41.59219651951908, -70.98040602141339, -71.72769060935182, -10.623059170594795, -34.7595546615754, -131.53736475654514, -53.05653598494811, -101.41518449107294, -109.79395425282436, -41.90393155535438, -42.90768143660659, -101.28713439514863, -3.6529769462716113e-06, -55.91582861596634, -9.422763801947175e-06, -149.57304535780364, -15.769358131863665, -106.93695783769746, -13.898440166824347, -118.48041252904542, -5.4986058663662244e-08, -79.70215169644696, -53.28751719182887, -24.96791385605876, -66.88513410939746, -13.022295608933804, -11.985041489299503, -62.80541753849728, -39.89858352880731, -2.9545512623755376e-06, -92.71764287318861, -77.2934187968406, -176.42313579762043, -132.38583705278322, -76.50598229113571, -43.59306728357784, -115.94616390942322, -36.20384333647849, -5.61432354224973e-07, -150.4000351729677, -28.629754274138563, -27.780489258792926, -105.44596933847156, -131.2920937471402, -104.97310424721711, -71.02334958042483, -140.22423308419948, -14.772458667349342, -136.0598284677897, -171.66622500091364, -156.66725115705427, -106.5503134596317, -138.68572816384892, -35.0608962811428, -38.309895713271125, -56.56486601834366, -20.932791886045198, -116.88556792019683, -11.780722398037442, -95.5198106541405, -60.138183992958815, -30.20692010767841, -134.12138295940707, -102.48932736520207, -147.17635151677143, -64.64161530122684, -45.26939803123624, -2.4708314313997573e-09, -131.1679072351731, -123.7676127054933, -70.57549644075004, -116.93035024578461, -36.36542870632811, -13.403002189583267, -74.9606243879492, -139.8736037790337, -102.2021751170193, -10.58629417307832, -83.6062819983492, -38.60332471634071, -127.12900781774506, -13.564325902416053, -1.9620735562249683e-08, -17.66814592263781, -1.597617381756955e-05, -136.15759363608421, -119.42079052612632, -10.381463023984177, -62.47230913601336, -23.16104430567626, -110.05632667287351, -100.27558609259866, -15.252965636459413, -63.56232073663852, -75.29519864878431, -118.93694667749088, -42.33733403205047, -64.91141530814822, -76.47858087029017, -147.50565518654307, -77.04884548167993, -25.431936104216284, -74.62679869135135, -74.59565076850471, -130.5923562793277, -24.099558260728262, -184.75688154696928, -7.036882101797197e-09, -14.843215704754225, -70.9729043748384, -32.22832994915581, -41.89427268612269, -36.545535688140795, -45.25735071223483, -86.25443689063312, -53.53910025991506, -35.792885503656144, -92.38562339807442, -1.0079109172983653e-06, -115.81220358722221, -76.73154901425593, -16.99393738969541, -60.368536142909306, -16.470224327603177, -46.65759754663734, -8.379398887018204e-06, -115.74689501047678, -61.610683064578055, -15.28647557956722, -15.978550153332245, -5.2809897628239015e-08, -44.6395572364517, -151.52501806443613, -125.44263497144507, -108.04945587549754, -51.254280904682275, -83.2385062607722, -31.38253412884159, -50.2887056952217, -130.0782320539151, -66.95363910053986, -27.096840984329503, -109.63847112023028, -69.77951978721615, -95.71481855071659, -108.14430928190954, -67.34330093821534, -133.6689285945144, -129.93869703685527, -91.81481412074231, -103.60453627909554, -129.2010362613247, -21.299758540639825, -103.21735144298339, -94.60195076590283, -61.00223332845443, -2.8392939069934152e-08, -94.21719778426339, -163.95289048998478, -131.61830994279165, -175.7137511820784, -38.32764171097356, -10.896722450717341, -152.91384513921608, -121.84610022414849, -14.520035188790612, -102.67007018103463, -60.911438918786786, -72.52443788716896, -95.39643412037, -114.26639708796746, -119.61813356809023, -100.97951332029128, -102.58136965201527, -92.41253353241827, -132.7008547671021, -11.322640774104295, -58.00665815515973, -149.56667616476457, -151.43379697785844, -20.093407169672183, -120.81486583421292, -4.002397817938672e-06, -51.70001774908824, -30.114513537813078, -181.29936391377885, -17.56795037980989, -58.58041935054586, -142.22690838239356, -19.545028403912056, -161.42119491542675, -136.62898121764326, -199.3994486680722, -103.93166628675519, -122.24157404797602, -71.48794247446756, -50.30244305646676, -51.81379645530363, -160.81396236719274, -67.01544548412751, -31.560749216449793, -4.509724279159075e-06, -87.23370850021156, -70.30158982847387, -14.769386442292996, -177.99255677720996, -137.33936598991113, -76.32362251808931, -51.45025618279451, -62.15197218782678, -85.41858354795572, -100.96370414939813, -84.4682813824021, -54.3037429666275, -87.55588865894691, -13.612403040335364, -110.95575647722846, -35.93456475855384, -73.19350336814841, -141.70507339046486, -95.15998784216124, -107.12597171969388, -59.73072462775545, -79.48214354069853, -17.987563538022105, -12.67874247556781, -119.65342062513352, -46.99844846956642, -38.1781888534175, -65.93190381752527, -38.392338910851095, -84.2052277495198, -149.9108492834762, -15.36741032549932, -18.22954671445832, -65.41596038935964, -48.88975342259694, -18.08800068455605, -42.82273589414573, -19.394064067896135, -57.84342414438852, -8.251711681356683e-09, -48.954686296706754, -128.74017593587388, -51.63429621026194, -126.31313983692363, -104.77656078038574, -35.36925473784508, -2.1559084638994216e-08, -78.72663319366525, -82.35806195031994, -56.37939070246653, -118.27528380924296, -100.74914064628851, -176.4274833073821, -124.22703621365697]} diff --git a/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/test/fixtures/python/runner.py b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/test/fixtures/python/runner.py new file mode 100644 index 000000000000..c2e03300d034 --- /dev/null +++ b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/test/fixtures/python/runner.py @@ -0,0 +1,87 @@ +#!/usr/bin/env python +# +# @license Apache-2.0 +# +# Copyright (c) 2024 The Stdlib Authors. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +"""Generate fixtures.""" + +import os +import json +import numpy as np +from scipy.stats import planck + +# Get the file path: +FILE = os.path.realpath(__file__) + +# Extract the directory in which this file resides: +DIR = os.path.dirname(FILE) + + +def gen(x, lam, name): + """ + Generate fixture data and write to file. + + # Arguments + + * `x`: input values. + * `lam`: shape parameter. + * `name::str`: output filename. + + # Examples + + ```python + python> x = np.random.rand(1000) * 10 + python> lam = np.random.rand(1000) + python> gen(x, lam, "data.json") + ``` + """ + # Compute PDF values: + z = np.array(planck.logpmf(x, lam)) + + # Store data to be written to file as a dictionary: + data = { + "x": x.tolist(), + "lambda": lam.tolist(), + "expected": z.tolist() + } + + # Based on the script directory, create an output filepath: + filepath = os.path.join(DIR, name) + + # Write the data to the output filepath as JSON: + with open(filepath, "w", encoding='utf-8') as outfile: + json.dump(data, outfile) + + # Include trailing newline + with open(filepath, "a", encoding='utf-8') as outfile: + outfile.write("\n") + + +def main(): + """Generate fixture data.""" + # Large shape paramter: + x = np.round(np.random.rand(1000) * 10.0) + lam = (np.random.rand(1000) * 10) + 10 + gen(x, lam, "large_lambda.json") + + # Small shape parameter: + x = np.round(np.random.rand(1000) * 10.0) + lam = np.random.rand(1000) * 0.5 + gen(x, lam, "small_lambda.json") + + +if __name__ == "__main__": + main() diff --git a/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/test/fixtures/python/small_lambda.json b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/test/fixtures/python/small_lambda.json new file mode 100644 index 000000000000..e80bd8696bdd --- /dev/null +++ b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/test/fixtures/python/small_lambda.json @@ -0,0 +1 @@ +{"x": [9.0, 2.0, 5.0, 6.0, 7.0, 7.0, 8.0, 2.0, 3.0, 0.0, 5.0, 5.0, 9.0, 3.0, 6.0, 2.0, 6.0, 8.0, 5.0, 4.0, 3.0, 1.0, 6.0, 7.0, 2.0, 1.0, 7.0, 6.0, 1.0, 8.0, 9.0, 2.0, 6.0, 0.0, 3.0, 3.0, 1.0, 1.0, 6.0, 2.0, 3.0, 3.0, 7.0, 3.0, 6.0, 4.0, 5.0, 3.0, 1.0, 9.0, 2.0, 3.0, 5.0, 10.0, 4.0, 2.0, 6.0, 8.0, 4.0, 1.0, 5.0, 7.0, 1.0, 5.0, 5.0, 1.0, 0.0, 0.0, 3.0, 7.0, 1.0, 6.0, 9.0, 1.0, 5.0, 8.0, 1.0, 6.0, 2.0, 4.0, 1.0, 8.0, 8.0, 9.0, 4.0, 9.0, 7.0, 4.0, 5.0, 1.0, 8.0, 8.0, 8.0, 3.0, 1.0, 6.0, 4.0, 4.0, 1.0, 1.0, 5.0, 2.0, 3.0, 7.0, 1.0, 2.0, 7.0, 3.0, 2.0, 9.0, 5.0, 4.0, 4.0, 5.0, 1.0, 4.0, 1.0, 4.0, 0.0, 6.0, 8.0, 4.0, 7.0, 6.0, 8.0, 7.0, 6.0, 4.0, 3.0, 8.0, 2.0, 0.0, 6.0, 9.0, 3.0, 8.0, 3.0, 2.0, 2.0, 7.0, 1.0, 9.0, 1.0, 7.0, 3.0, 9.0, 5.0, 7.0, 7.0, 7.0, 5.0, 5.0, 3.0, 3.0, 5.0, 4.0, 2.0, 9.0, 8.0, 0.0, 1.0, 5.0, 2.0, 9.0, 9.0, 0.0, 7.0, 10.0, 7.0, 9.0, 8.0, 8.0, 9.0, 10.0, 5.0, 6.0, 8.0, 5.0, 9.0, 4.0, 4.0, 0.0, 9.0, 1.0, 6.0, 7.0, 5.0, 5.0, 4.0, 9.0, 9.0, 3.0, 10.0, 8.0, 7.0, 2.0, 2.0, 1.0, 5.0, 8.0, 2.0, 6.0, 2.0, 5.0, 5.0, 3.0, 9.0, 7.0, 5.0, 10.0, 2.0, 7.0, 5.0, 4.0, 1.0, 6.0, 0.0, 5.0, 1.0, 3.0, 10.0, 8.0, 9.0, 2.0, 1.0, 8.0, 10.0, 8.0, 4.0, 9.0, 2.0, 7.0, 3.0, 8.0, 5.0, 2.0, 6.0, 6.0, 4.0, 9.0, 8.0, 8.0, 7.0, 4.0, 0.0, 7.0, 1.0, 10.0, 1.0, 9.0, 8.0, 9.0, 4.0, 10.0, 1.0, 9.0, 9.0, 6.0, 7.0, 7.0, 0.0, 5.0, 4.0, 7.0, 3.0, 7.0, 10.0, 1.0, 4.0, 4.0, 3.0, 4.0, 3.0, 5.0, 3.0, 5.0, 6.0, 6.0, 1.0, 5.0, 2.0, 0.0, 6.0, 6.0, 0.0, 1.0, 8.0, 2.0, 3.0, 10.0, 1.0, 7.0, 3.0, 1.0, 0.0, 4.0, 8.0, 9.0, 4.0, 4.0, 9.0, 9.0, 3.0, 10.0, 8.0, 0.0, 1.0, 6.0, 7.0, 4.0, 4.0, 9.0, 5.0, 3.0, 1.0, 4.0, 1.0, 6.0, 9.0, 9.0, 3.0, 6.0, 2.0, 0.0, 2.0, 0.0, 4.0, 6.0, 5.0, 5.0, 3.0, 4.0, 10.0, 1.0, 2.0, 9.0, 4.0, 6.0, 9.0, 1.0, 5.0, 9.0, 0.0, 2.0, 7.0, 9.0, 5.0, 5.0, 8.0, 5.0, 10.0, 9.0, 5.0, 5.0, 10.0, 1.0, 9.0, 6.0, 7.0, 7.0, 6.0, 4.0, 4.0, 6.0, 6.0, 1.0, 6.0, 2.0, 6.0, 8.0, 0.0, 7.0, 9.0, 1.0, 2.0, 8.0, 2.0, 4.0, 6.0, 3.0, 2.0, 7.0, 6.0, 5.0, 6.0, 8.0, 8.0, 3.0, 5.0, 1.0, 7.0, 0.0, 2.0, 2.0, 3.0, 10.0, 5.0, 0.0, 7.0, 2.0, 0.0, 1.0, 8.0, 8.0, 9.0, 8.0, 8.0, 3.0, 6.0, 9.0, 9.0, 5.0, 6.0, 6.0, 9.0, 4.0, 6.0, 6.0, 3.0, 4.0, 5.0, 6.0, 9.0, 7.0, 4.0, 3.0, 8.0, 9.0, 9.0, 4.0, 6.0, 5.0, 1.0, 3.0, 1.0, 1.0, 9.0, 0.0, 9.0, 3.0, 9.0, 1.0, 5.0, 9.0, 9.0, 5.0, 2.0, 5.0, 9.0, 9.0, 5.0, 3.0, 6.0, 5.0, 3.0, 2.0, 3.0, 6.0, 6.0, 6.0, 10.0, 1.0, 5.0, 4.0, 2.0, 4.0, 5.0, 8.0, 8.0, 7.0, 8.0, 1.0, 8.0, 1.0, 3.0, 5.0, 1.0, 6.0, 7.0, 1.0, 8.0, 0.0, 6.0, 0.0, 10.0, 0.0, 4.0, 1.0, 9.0, 6.0, 3.0, 9.0, 8.0, 3.0, 3.0, 6.0, 9.0, 4.0, 3.0, 4.0, 2.0, 4.0, 6.0, 6.0, 10.0, 3.0, 5.0, 7.0, 6.0, 2.0, 8.0, 8.0, 9.0, 3.0, 0.0, 7.0, 8.0, 7.0, 10.0, 4.0, 10.0, 8.0, 8.0, 6.0, 1.0, 4.0, 4.0, 6.0, 9.0, 2.0, 7.0, 4.0, 3.0, 7.0, 3.0, 4.0, 9.0, 7.0, 9.0, 8.0, 7.0, 1.0, 7.0, 4.0, 9.0, 3.0, 8.0, 5.0, 8.0, 6.0, 0.0, 3.0, 4.0, 6.0, 10.0, 8.0, 2.0, 7.0, 0.0, 8.0, 0.0, 0.0, 2.0, 6.0, 3.0, 6.0, 9.0, 3.0, 10.0, 5.0, 8.0, 5.0, 1.0, 7.0, 3.0, 4.0, 9.0, 6.0, 5.0, 2.0, 8.0, 0.0, 6.0, 5.0, 4.0, 3.0, 3.0, 2.0, 1.0, 9.0, 8.0, 9.0, 2.0, 4.0, 7.0, 2.0, 5.0, 8.0, 1.0, 4.0, 10.0, 8.0, 9.0, 7.0, 8.0, 6.0, 4.0, 9.0, 8.0, 9.0, 1.0, 2.0, 1.0, 2.0, 9.0, 8.0, 1.0, 8.0, 4.0, 1.0, 7.0, 2.0, 4.0, 7.0, 8.0, 8.0, 2.0, 7.0, 4.0, 4.0, 8.0, 2.0, 5.0, 7.0, 5.0, 4.0, 3.0, 9.0, 7.0, 4.0, 10.0, 9.0, 7.0, 9.0, 4.0, 2.0, 0.0, 9.0, 4.0, 7.0, 10.0, 2.0, 2.0, 6.0, 7.0, 3.0, 5.0, 3.0, 6.0, 2.0, 3.0, 0.0, 5.0, 8.0, 8.0, 9.0, 7.0, 1.0, 4.0, 6.0, 1.0, 6.0, 5.0, 3.0, 1.0, 7.0, 8.0, 0.0, 0.0, 2.0, 5.0, 5.0, 2.0, 6.0, 4.0, 1.0, 2.0, 10.0, 4.0, 9.0, 7.0, 2.0, 5.0, 2.0, 4.0, 9.0, 5.0, 7.0, 5.0, 6.0, 2.0, 7.0, 3.0, 7.0, 1.0, 9.0, 3.0, 2.0, 9.0, 9.0, 3.0, 10.0, 5.0, 6.0, 3.0, 4.0, 9.0, 0.0, 6.0, 10.0, 5.0, 10.0, 9.0, 4.0, 2.0, 8.0, 6.0, 8.0, 10.0, 9.0, 2.0, 7.0, 4.0, 6.0, 4.0, 5.0, 4.0, 8.0, 0.0, 6.0, 10.0, 6.0, 9.0, 9.0, 3.0, 2.0, 4.0, 6.0, 1.0, 5.0, 6.0, 9.0, 1.0, 9.0, 5.0, 1.0, 8.0, 8.0, 4.0, 2.0, 2.0, 3.0, 9.0, 2.0, 8.0, 10.0, 5.0, 5.0, 4.0, 3.0, 3.0, 3.0, 3.0, 1.0, 7.0, 10.0, 9.0, 6.0, 3.0, 3.0, 5.0, 6.0, 0.0, 9.0, 8.0, 2.0, 5.0, 3.0, 3.0, 1.0, 7.0, 7.0, 0.0, 10.0, 2.0, 6.0, 8.0, 1.0, 8.0, 1.0, 6.0, 2.0, 8.0, 1.0, 9.0, 7.0, 2.0, 1.0, 8.0, 4.0, 8.0, 4.0, 6.0, 2.0, 1.0, 8.0, 7.0, 9.0, 1.0, 2.0, 1.0, 6.0, 5.0, 7.0, 4.0, 7.0, 7.0, 8.0, 5.0, 4.0, 2.0, 1.0, 2.0, 10.0, 2.0, 0.0, 4.0, 8.0, 7.0, 1.0, 5.0, 10.0, 6.0, 0.0, 5.0, 2.0, 7.0, 8.0, 2.0, 8.0, 9.0, 5.0, 4.0, 4.0, 9.0, 9.0, 7.0, 8.0, 3.0, 2.0, 8.0, 10.0, 3.0, 0.0, 5.0, 0.0, 4.0, 4.0, 4.0, 8.0, 1.0, 6.0, 2.0, 6.0, 6.0, 2.0, 8.0, 4.0, 7.0, 7.0, 3.0, 6.0, 6.0, 3.0, 1.0, 3.0, 7.0, 5.0, 1.0, 2.0, 9.0, 2.0, 8.0, 6.0, 1.0, 5.0, 5.0, 4.0, 9.0, 3.0, 4.0, 2.0, 5.0, 3.0, 0.0, 4.0, 1.0, 0.0, 8.0, 3.0, 1.0, 3.0, 5.0, 3.0, 10.0, 0.0, 8.0, 5.0, 8.0, 1.0, 6.0, 8.0, 1.0, 4.0, 3.0, 9.0, 4.0, 9.0, 8.0, 1.0, 1.0, 9.0, 8.0, 1.0, 5.0, 9.0, 9.0, 4.0, 8.0, 7.0, 5.0, 0.0, 5.0, 2.0, 1.0, 4.0, 2.0, 7.0, 7.0, 6.0, 3.0, 6.0, 1.0, 4.0, 8.0, 1.0, 7.0, 6.0, 4.0, 2.0, 6.0, 4.0, 3.0, 4.0, 3.0, 2.0, 2.0, 4.0, 10.0, 4.0, 1.0, 2.0, 7.0, 10.0, 8.0, 1.0, 3.0, 6.0, 1.0, 8.0, 3.0, 5.0, 9.0, 4.0, 2.0, 7.0, 1.0, 7.0, 4.0, 2.0, 7.0, 1.0, 5.0, 4.0, 4.0, 2.0, 3.0, 4.0, 4.0, 8.0], "lambda": [0.23421079099056874, 0.3201210865486436, 0.019587424870426362, 0.15955815237077686, 0.017076273134265407, 0.1992451402145688, 0.031954106033458496, 0.1952735943470002, 0.15431889335482535, 0.23835833813871488, 0.04235078326633984, 0.3636399471373613, 0.168723526620972, 0.20568561638522642, 0.4363746469972793, 0.25765850182520306, 0.22024530942422793, 0.36689406358413534, 0.46274513679925394, 0.248041881537639, 0.34292824295271046, 0.29180116642384213, 0.43196245198970457, 0.39064356077277596, 0.3369164340205975, 0.4391592867037491, 0.4611619165967514, 0.12549885305029812, 0.34349324508639517, 0.03886765774361489, 0.27566910629899055, 0.020650216940392097, 0.07572908388513044, 0.2503182755634239, 0.08659876694514951, 0.18453432807203707, 0.37447556295794326, 0.469821789016505, 0.46751210889077416, 0.35460049496104673, 0.07938063365628306, 0.006728845816492912, 0.080745510081555, 0.26713613856175294, 0.4427758079922847, 0.39726683650905253, 0.3610591967777023, 0.030767721031508544, 0.3221880480655331, 0.3242870499033103, 0.2039176512747894, 0.18516926946281848, 0.23660738067202247, 0.055111592913567875, 0.10977152388585132, 0.3122354830571861, 0.1285672603773108, 0.41899151311298777, 0.4994724082225284, 0.10938914232280034, 0.4870249506313579, 0.3541293404153169, 0.3612851417867698, 0.434150763716177, 0.023782389525677017, 0.16826045335518885, 0.1267932825019102, 0.36299052762382095, 0.2762067861677085, 0.454688388523739, 0.42515818823029977, 0.04918883435095989, 0.24832138115920993, 0.2080603722188768, 0.0008825315841041181, 0.1575145212979126, 0.4713375596416941, 0.0688759163653394, 0.4519250799688742, 0.10658405671731203, 0.31059533315599136, 0.1572350340589781, 0.4785474424232396, 0.35936524740981696, 0.04938125301090468, 0.03129323591098698, 0.320539692247626, 0.2615171549768535, 0.4714228659694726, 0.43060188099732993, 0.06845114764460297, 0.2943057203199711, 0.4666606947366479, 0.29555682627034896, 0.083700904251643, 0.08419760107767682, 0.14032790279179458, 0.13188414903581647, 0.282756016642614, 0.34802309497664985, 0.20825126462894522, 0.1745649620145348, 0.49465956049475895, 0.3186172935797443, 0.13390823633710458, 0.24873891183404045, 0.43783952673337645, 0.27462624361932153, 0.2192610411892582, 0.15424842971153935, 0.44188147604731265, 0.1861049960738318, 0.23975462066891695, 0.19552928355762877, 0.34519281576373, 0.42802187747650644, 0.45916189360181636, 0.3088658357789577, 0.029374837562327616, 0.4922854119186678, 0.01100616615055211, 0.4140206867658991, 0.2815966960635408, 0.12197084362279464, 0.126518590704855, 0.167991105991446, 0.45463315026825685, 0.4797321604753257, 0.356472034668509, 0.16751328804797, 0.44870451160717745, 0.18008909397497846, 0.28878390025059025, 0.3482232261534106, 0.2514283513300228, 0.41599600801905695, 0.02408775612734887, 0.308445969728132, 0.24685793966316488, 0.38534429958749183, 0.033852046666715596, 0.3209302758779897, 0.27043340247472364, 0.49597058644540315, 0.32805913013150334, 0.44050588111936545, 0.40616465000718655, 0.32744328718766413, 0.2644985214952268, 0.17077575886025914, 0.1033098144915599, 0.36449578617232753, 0.38037472913398324, 0.3649600448138212, 0.06729637636179497, 0.15105928063235408, 0.16134710974175298, 0.3008641653903247, 0.09467761904345495, 0.2285958246264403, 0.4482335118753987, 0.4036048326194179, 0.4918930373861635, 0.1681150171360843, 0.37644487823726897, 0.43181626757225117, 0.23239681172073706, 0.43677044291380734, 0.4700940982516152, 0.44284242904789395, 0.41024344815981223, 0.05202597993887331, 0.36172744951519253, 0.16907336400415585, 0.23267822013754696, 0.24967089019229655, 0.15307369546229566, 1.672984832301605e-05, 0.1476571699017889, 0.3525224207560184, 0.2859854758811884, 0.41067995509575084, 0.25236304376401403, 0.0985720106035251, 0.398910018082744, 0.460243681019915, 0.26331488457427893, 0.16771904510885471, 0.3591384289408351, 0.417571712687686, 0.12238870600680496, 0.241906130697584, 0.2628922155851003, 0.38576442006125033, 0.02061525371083045, 0.4780852678256458, 0.1897029255316261, 0.0919975960176671, 0.08057379279669319, 0.05529023259150584, 0.11773314777374388, 0.31479669305389474, 0.03465821595400159, 0.08557918910460671, 0.42977855067355586, 0.1727685139826965, 0.07058263047727753, 0.2725637302599085, 0.45634729297998367, 0.4317370614622735, 0.10259122544125959, 0.3853235717622766, 0.18694963719661134, 0.4026391061825961, 0.4517277295757012, 0.17485350296969843, 0.20724014248966321, 0.2326762007120428, 0.1809471073119177, 0.4178143237650903, 0.23707677092324736, 0.18165227624149288, 0.26446596855921595, 0.3123851168740784, 0.0777701922655924, 0.3689454324808215, 0.2142148388959062, 0.11521942564929405, 0.485568738869349, 0.43039597159457843, 0.48219913262672903, 0.19239976612922532, 0.45532959328728806, 0.107066108578039, 0.4325373636955255, 0.3142664593249083, 0.09818081888969676, 0.27763092340894385, 0.16031540003668854, 0.1334920963193988, 0.27059498409690635, 0.03616441718754443, 0.13950173561867502, 0.3418565848850183, 0.11185989816554975, 0.26026031891306817, 0.28896542822755567, 0.2465666509008087, 0.4660027169956258, 0.46771309123574534, 0.15704301415757316, 0.18745212640542502, 0.06161707174169717, 0.12342158035075451, 0.4289715302167322, 0.38452749199044894, 0.2119370718849271, 0.34708458595686503, 0.18595459981508322, 0.4550720703883042, 0.0969074529436103, 0.17511149336593979, 0.17267203665353176, 0.08962706997819453, 0.2878821787428281, 0.15390082470874178, 0.27346900015887365, 0.303164575096546, 0.2086750671108849, 0.31579090027404005, 0.19618227981944514, 0.046641215761209, 0.3899820516462951, 0.13279861994631542, 0.16143580253780576, 0.1299119283441627, 0.01750222861927392, 0.47878056618768294, 0.4634359004397131, 0.3290088961897091, 0.3816247786860767, 0.22039498132852997, 0.2776411342499618, 0.40317498460786144, 0.43399531349343723, 0.30664353893046087, 0.4820616169689648, 0.14227280781974194, 0.04400984423666754, 0.07507527415559812, 0.4194092125934362, 0.07723820986610708, 0.22290088674914427, 0.005425032234720628, 0.23274332710807405, 0.056037709478675535, 0.17014807250622715, 0.24184681537160357, 0.21109151966253825, 0.2553645205688588, 0.08939321878963347, 0.3881263780542996, 0.3687670923437447, 0.035614827533372195, 0.28392233130507377, 0.3400975784360748, 0.004364683267874092, 0.038116702436361005, 0.3614548886363809, 0.29310859690103275, 0.13999577660285595, 0.40473161406502345, 0.11342050618230498, 0.4432202489810043, 0.13979440502614104, 0.3510163713013619, 0.04121381505464228, 0.14415336839895532, 0.46567126990989205, 0.3308406173363997, 0.40443985331923515, 0.12936504838498725, 0.13860646395230536, 0.1875669289392513, 0.20208491904559, 0.499163901851329, 0.45047673943835786, 0.1650764313315652, 0.06941093415031246, 0.23068018919023547, 0.3497469556814567, 0.4750058265251099, 0.43918143483448746, 0.34252009605258155, 0.4314010122565487, 0.3073485210163029, 0.36717804200545073, 0.44356890169430824, 0.0008276690698517108, 0.4532220433395628, 0.35787353901287844, 0.001993302007382236, 0.4931363620162585, 0.01207226389809224, 0.34247261684252317, 0.15265940423636482, 0.32450878615000606, 0.0823622988158616, 0.1640457954447871, 0.006843451315824645, 0.32384368490954535, 0.0033558831379234544, 0.13344319360526868, 0.27726415327245957, 0.13577849560819732, 0.1714032563323712, 0.25867603501290587, 0.44233714179166583, 0.426000542283171, 0.004879756093265686, 0.4850875267485801, 0.16981749256201484, 0.06107207073942722, 0.2781712185913884, 0.17038621773519147, 0.1237611630373282, 0.38848802341801275, 0.2849114008669487, 0.36004049085184897, 0.3571775152033262, 0.1292896901562091, 0.49193345882210743, 0.014041123931989086, 0.1311704103690236, 0.1642780120846961, 0.429615931179095, 0.25825028950755824, 0.29685663690513403, 0.36889941153934935, 0.31094028463709394, 0.18643354914961224, 0.23037478086848068, 0.46808568524469146, 0.37729021571933163, 0.2580146840890989, 0.20104291934481905, 0.183449178240442, 0.26288650483717524, 0.3913323445868305, 0.24367239979759842, 0.2461117505847441, 0.36298237467125916, 0.4332617649437593, 0.11917746762661335, 0.43289208745877766, 0.45825430005769413, 0.1302870807116917, 0.4339318307225652, 0.20326481703788102, 0.49545570187762233, 0.2352224401613024, 0.20673386862784987, 0.22983733489049024, 0.4258754772276029, 0.32301205647720377, 0.31914682309095427, 0.06379358187235568, 0.4815115448825899, 0.4377361639621273, 0.37455212909234636, 0.3507755923635707, 0.1892628754851451, 0.49575067797539957, 0.192738665479475, 0.11203768334510156, 0.014514815616369692, 0.002428344788665826, 0.36463522171208623, 0.3152031157577128, 0.20156808655997155, 0.37211405739341613, 0.0897065764889412, 0.46919330383837304, 0.18248601261045622, 0.19669940324318352, 0.057244395711725404, 0.4139681959866245, 0.21570309846858948, 0.27641030684119466, 0.3199237636701469, 0.3414336625418801, 0.1371674436803587, 0.23497316379755873, 0.14621150141230266, 0.13368052869681352, 0.11670854643787226, 0.47643177809732845, 0.3060187366738161, 0.35630033905333225, 0.19742920274571862, 0.25983983020308704, 0.15063228397381423, 0.08857196978970511, 0.02459512306710815, 0.04971748534098974, 0.2962060101657735, 0.3870950086248783, 0.4775748987981552, 0.003019697987298564, 0.27209284030494035, 0.3720324839311076, 0.06063471147047256, 0.3087805268370473, 0.2411862264442291, 0.3823891233639472, 0.4979052985952539, 0.05273796060967373, 0.4772202093905325, 0.15083245678472046, 0.19637169643551727, 0.11726985217873565, 0.2843638527777446, 0.37609028601514205, 0.22331550598014654, 0.31046876892505904, 0.12361498705749907, 0.004347739441635634, 0.26085067413140106, 0.2789087727146747, 0.09608904640866134, 0.49926996763398845, 0.05097408620568877, 0.14618665386514734, 0.40908390305851616, 0.22891157110472393, 0.33353892087692316, 0.4226694682913476, 0.1386296465360337, 0.28493449938077076, 0.3213553324450671, 0.24969913696474477, 0.07458704650491776, 0.4520931388090337, 0.037792790090740436, 0.4283589854818681, 0.22243047237875135, 0.12003050696005746, 0.453920426765277, 0.041677385455777316, 0.45004086292677437, 0.364009567264686, 0.4549240086604427, 0.0348778745018225, 0.07026564694360155, 0.314516289506046, 0.0006559589435125579, 0.2292529324054809, 0.07588109726957698, 0.1266408169185187, 0.18834321016342137, 0.2775337288213698, 0.36671211434705464, 0.02054335521034223, 0.4197494078529825, 0.35774765852671453, 0.19521014044187013, 0.12898358818529587, 0.4488375869905328, 0.029552394376501867, 0.44290009175171763, 0.41013496209150463, 0.20386631453168552, 0.028221862633940942, 0.3363298836508943, 0.23858365439837725, 0.01921873836606891, 0.4703263930785246, 0.050389838261420905, 0.278503373109518, 0.24332675518833718, 0.1093040600174019, 0.13636463608394245, 0.4467893771049005, 0.45321346141102314, 0.049810455677122556, 0.218363148770635, 0.24124765263092768, 0.20137902003604052, 0.06372904804055873, 0.07821405997652953, 0.48161013134641484, 0.026449832069809998, 0.41552633317373566, 0.2546945203399397, 0.07037408829014064, 0.46569485309539077, 0.16571234042366012, 0.47700400783044267, 0.43800912718530344, 0.344779532041748, 0.3470780127882843, 0.45254749351037366, 0.42154540460290374, 0.46472380958240544, 0.4432845614857753, 0.021771852613783393, 0.45457288686794645, 0.35157385179138584, 0.21034758610351817, 0.09440110214071529, 0.23734963735591452, 0.17710627742676727, 0.2566130188381103, 0.2632833153964512, 0.39020040795711686, 0.27729441894654827, 0.24205865787507785, 0.18084580775781767, 0.12080166030525391, 0.2774779056220008, 0.24246459630156786, 0.27909284280494057, 0.3394632821558114, 0.13887944037061234, 0.48667553588808, 0.25786111631814235, 0.3089959565491122, 0.035863449172339856, 0.2759774686003757, 0.4452054368162187, 0.1986973306456825, 0.09983399649980379, 0.07114829260529243, 0.35791826485263806, 0.24225370740344954, 0.3907131552210012, 0.3846966230105446, 0.2055528784344221, 0.37814892226611524, 0.028204888922334803, 0.10998488697474307, 0.19295064297508502, 0.41669395734562603, 0.18190831545740804, 0.2983345856995651, 0.1750339797933519, 0.20441489416414932, 0.24454232096174505, 0.43750277821622957, 0.20050911307800728, 0.13910300083468707, 0.4451453199627621, 0.21756313736618277, 0.003272967546572636, 0.299312083140545, 0.036791860223061246, 0.2930328962746835, 0.07887958514445148, 0.1544388106079317, 0.2582431856505667, 0.3899908979862065, 0.09280684658938276, 0.3750987869120615, 0.14896363212195296, 0.4325809835006669, 0.09781764315984132, 0.2885351007919555, 0.1735955904175806, 0.40574392603563475, 0.41917297457957375, 0.31801725214508225, 0.24893101906701404, 0.0004534655667816634, 0.4693424008531915, 0.4939634801217436, 0.36168400351427044, 0.4101291464189768, 0.11783543915329903, 0.3957611257105019, 0.4702752072611839, 0.07335606051807642, 0.3635390734462026, 0.35276909270178736, 0.2586365618001824, 0.07720583104495432, 0.020445744975614577, 0.18585816542272926, 0.12645373113650493, 0.08358391892233813, 0.26271869737213577, 0.22391773147559546, 0.4015151900154223, 0.18190413087394858, 0.44826118449764885, 0.4139853348181298, 0.21733587376036656, 0.058576999657120044, 0.009656810454054587, 0.16071645257908151, 0.3359882751029691, 0.2318501576250615, 0.2538878057059843, 0.18988402538114402, 0.32306277676679, 0.4547768198775389, 0.15734013171598316, 0.26266931112258035, 0.15062543738584278, 0.15705574212421852, 0.442662162169578, 0.4139823029264987, 0.19019190375054212, 0.0246751879869041, 0.0198779570045709, 0.32795433516711014, 0.03127979161172556, 0.46979652115857634, 0.2221178708197789, 0.2732194367212743, 0.4158445995319922, 0.025424376305232643, 0.22341835864428178, 0.47471660859846987, 0.42979010586924943, 0.3254208203056383, 0.1571621379750469, 0.2784215736272932, 0.375942485952076, 0.2475208351538586, 0.4004942308884269, 0.2181935367501368, 0.29915240800829995, 0.40415148754456603, 0.045027157762917214, 0.4674761579584435, 0.47229019159926877, 0.27809704656135575, 0.4632222036265257, 0.2594467634782289, 0.029233284021870032, 0.1747366168214129, 0.40843519506479, 0.46111112397164816, 0.4615767336287437, 0.33485381659117985, 0.25941745119329224, 0.1377988558503303, 0.17245321835678717, 0.0004145376515468646, 0.11495811398876593, 0.12651263374252208, 0.3290346598548419, 0.4899367528248453, 0.06807904114665692, 0.4746624467577054, 0.3422364546014481, 0.1842148940705181, 0.15112922492950787, 0.1454153627620534, 0.004099897252409113, 0.3302708282226196, 0.11197508394766953, 0.3274117574758821, 0.0026189258577354324, 0.2442051554828123, 0.1148056263323407, 0.225032061017031, 0.26698068311509743, 0.1347292180578331, 0.2548978324635327, 0.2960480770129477, 0.4215303233021638, 0.2222295306599122, 0.41346998896515486, 0.09542971471893558, 0.30847424286574887, 0.4478075285525501, 0.017392936591940633, 0.2792026883451539, 0.4191108951251098, 0.2318391140442535, 0.05441633455549755, 0.04517516130968857, 0.40168146286503215, 0.10632929347374853, 0.40402144620339187, 0.4767120170983614, 0.23778861699410192, 0.40572751735082035, 0.3329407663968661, 0.26037429655790967, 0.3456861363814059, 0.486652884726778, 0.08938597032057677, 0.07955647758775619, 0.1255241927661085, 0.1429403467025429, 0.05560009256824072, 0.08427448088917938, 0.044905449928503205, 0.30414085583653194, 0.3599740346757643, 0.3691885776823073, 0.4958296507446188, 0.25527941013536626, 0.13317170780232584, 0.09708592345827832, 0.478969851354647, 0.1384212767402329, 0.26477209433513305, 0.0790513880139943, 0.42675633350611075, 0.07629458977811865, 0.42819859291341533, 0.32680492651063076, 0.3447532227709416, 0.10087949605827118, 0.13979710449660326, 0.40819531023551187, 0.18993175562153441, 0.08713605923345369, 0.08920147344983309, 0.29761428577164184, 0.4278356082631619, 0.004917557768611913, 0.042515594187578276, 0.4956745921868907, 0.26227940654691656, 0.26820111751163894, 0.46176120802853027, 0.4990537041480458, 0.15716616364568564, 0.007778414897024688, 0.4013809133986374, 0.4155207632105013, 0.4647563496760541, 0.05709694835205592, 0.37496555467293563, 0.18023151996271208, 0.124736425580737, 0.07667976890034711, 0.29360188301573664, 0.38294904619534703, 0.06552461378358615, 0.4676618800092886, 0.4971723270024244, 0.007590681990645942, 0.38394856332322513, 0.32866727547382935, 0.1518508275351988, 0.32706332146885875, 0.024136729430369874, 0.05692243114643386, 0.25830780501353595, 0.29339468998000423, 0.4770541429047017, 0.49864412216129, 0.4734907594925477, 0.2067623455579099, 0.11734389089442149, 0.24500830607227908, 0.310372889892112, 0.16313591103095, 0.042899333840748954, 0.0512301218647957, 0.43463155467723735, 0.1998925967971718, 0.12911862885361008, 0.042638047137096624, 0.4531019721114127, 0.3581419959765415, 0.12060796940575291, 0.357706332690134, 0.011819744950356648, 0.17530031415883934, 0.08859327496439645, 0.2554203675447563, 0.3940829490409915, 0.32319433070701825, 0.008907662972784947, 0.37438652751183, 0.21118269667154033, 0.4016231899825289, 0.1094676027118292, 0.1262735517424335, 0.11616697885696942, 0.4199786216411445, 0.38430088742311175, 0.1388356976587624, 0.3280925621629372, 0.05723363676123572, 0.162493806389352, 0.3083606174393693, 0.3358470657123973, 0.2137171325331073, 0.14612556358718615, 0.31488548934332206, 0.027749062406876357, 0.44126202302505413, 0.3034618323659264, 0.14219863682748984, 0.49170362023443565, 0.47920827961579654, 0.45077452093701575, 0.05825484609237175, 0.15512942107796113, 0.22786518290648383, 0.38207490337767785, 0.48669847041384995, 0.2780077922139826, 0.3701901343025242, 0.0014119733535631895, 0.3908195876693565, 0.0888517505363009, 0.08786966658843681, 0.3691107220212811, 0.35830010223198416, 0.21141239978967974, 0.1254517927461613, 0.4874769371745128, 0.16290243890788547, 0.23541548718951583, 0.028638134317463204, 0.22756798847113735, 0.12063388726749441, 0.12828687045555842, 0.02651203984423478, 0.03304596509745045, 0.07001923723833059, 0.06139554653255941, 0.024173271641830585, 0.10619583866371007, 0.45636270521595645, 0.12683326205472234, 0.41652514015585007, 0.4419489866030297, 0.3694211125371278, 0.30747177642427675, 0.3464929037050683, 0.044940766719734515, 0.46998982271225287, 0.3058870717857858, 0.07787127947500078, 0.3916627362986897, 0.12766073771423292, 0.23010512764767987, 0.2945669493401115, 0.189088571918835, 0.45402338774759515, 0.35680040064896007, 0.4400956106633786, 0.13385299129865558, 0.045658760891441885, 0.12823630224181432, 0.318766193181428, 0.22301456659154123, 0.2843761852958067, 0.374012367215094, 0.0801679471631101, 0.32730447608557345, 0.3585836444611083, 0.45680056398225716, 0.09824774523710628, 0.024252446497871782, 0.240433977138704, 0.11792548903864358, 0.3776906111254206, 0.3662071449408345, 0.4408834506013168, 0.31385404447766996, 0.3848830110898533, 0.22291776538370817, 0.24209930685485226, 0.3552575610468207, 0.41311901128403783, 0.4232282796583072, 0.4564661309999561, 0.31610813545022626, 0.23866461608131084, 0.0762418363949044, 0.20296179268569087, 0.30909909848969397, 0.24876392807319853, 0.25283796781368806, 0.006341564868257821, 0.2769458419599896, 0.06921557708688736, 0.0859328011883243, 0.24618813107839832, 0.29300898291860733, 0.013164998534960337, 0.03938871020553153, 0.26025003645640993, 0.08036122437403709, 0.3845487561471564, 0.41807749546016365, 0.25770599856937265, 0.2153433333178647, 0.03789253244202062, 0.4105100171474466, 0.3628565886144903, 0.16017704846633168, 0.4425601140702389, 0.01147863408998484, 0.197669854561156, 0.3510912450211969, 0.2632145489842369, 0.3021515876394378, 0.25919777830680796, 0.20312320345574736, 0.15556819165696123, 0.036691092347733656, 0.08481002352114247, 0.045953125760921754, 0.16985554525061353, 0.40532967862595, 0.10150647522200806, 0.331197087552202, 0.2141688221702665, 0.45023332738453997, 0.27586605035369266, 0.44166757283520935, 0.0968694467244996, 0.0919334593473008, 0.3695430485598285, 0.19490668220757013, 0.04460022022815496, 0.10737623083290121, 0.10172066077315728, 0.2106046780855304, 0.009687930093663755, 0.43654481658560085, 0.1692534392345043, 0.4557985123471561, 0.1895892302379492, 0.3970005056913175, 0.3326269360561074, 0.4567389503729958, 0.43355429702660503, 0.15095207979366104, 0.13890183115370647, 0.3967540341760996, 0.48271998404497785, 0.1201990668627031, 0.02347869973801836, 0.25048321534067153, 0.23642257115840137, 0.37156522915738355, 0.4507547461171627, 0.10467126431079488, 0.16771189603733927, 0.20179782434050192, 0.495882113350459, 0.19184612577986826, 0.18296547839588173, 0.46654822808432667, 0.33745801444421086, 0.2749281502852837, 0.26638655403309164, 0.2683305807257143], "expected": [-3.6742516989474656, -1.9350924198995962, -4.04058235759961, -2.8714142634102915, -4.198125213574704, -3.105904341068214, -3.7150219493424856, -2.1199493222445662, -2.4078581417332137, -1.5507931249971456, -3.3946229391955134, -3.006107074647849, -3.381181473797737, -2.299543914513084, -3.6577675959478158, -1.9975018278123897, -2.9425874721292207, -4.115679144223066, -3.306770745697005, -2.5077839175927226, -2.2655877104688855, -1.6658390791894162, -3.639409954159895, -3.863436083259227, -1.9254862055090318, -1.4736090275857878, -4.223874831605889, -2.890545042009779, -1.5789163743839891, -3.5779049406477594, -3.904246141358128, -3.931637228478917, -3.0725930957985566, -1.5075717666297863, -2.749252933089143, -2.3343714518782757, -1.5381058902031302, -1.4509541825759633, -3.7900682849556806, -1.9180309762641736, -2.811070527131466, -5.02490072212682, -3.1217726016088174, -2.252001714611863, -3.684579002787705, -2.7042806104447745, -2.999113002485774, -3.5889367370761738, -1.6115804970402592, -4.202475252782786, -2.0981011646738774, -2.3331491008404863, -2.7403621869678774, -3.4769403623907675, -2.7028239622595196, -1.9405275003143807, -2.8863016409722073, -4.4240284018682505, -2.9314555877037702, -2.3764288219319547, -3.388213559812045, -3.688843250991114, -1.5545827590921373, -3.2143513026674504, -3.8695894838384643, -2.0334534915389133, -2.1279240907790276, -1.1893897307430799, -2.25015248072881, -4.189706431005382, -1.485510921539785, -3.331715236413591, -3.749516607137069, -1.8802144856307785, -7.037569871704127, -3.1860774865889, -1.4499475418804106, -3.1229445088651993, -1.9155561568969746, -2.7179763001693837, -1.631141058929476, -3.1854814434964793, -4.795129343758231, -4.4320106607584835, -3.2302984566280837, -3.7615982485821555, -3.5375194463308177, -2.515234580876606, -3.3355826552373378, -1.4807603005052015, -3.2632744921653973, -3.7211284169641647, -4.719711322780642, -2.249705949734049, -2.6057649614213565, -3.021577888522567, -2.594428632646993, -2.618585450062511, -1.683975836637522, -1.5724794932270723, -2.7125855088323565, -2.1806013535242172, -2.425019343238465, -3.5291680033709745, -2.21071584086559, -2.010622126674728, -4.1017243415615585, -2.2503955629690524, -2.063642553131604, -3.3335597177243645, -3.238939100616877, -2.517474040244258, -2.504641136879463, -2.7058637020059457, -1.5764813562233242, -2.76705759089763, -1.4583260759002836, -2.560772779996009, -3.542268301987486, -3.89847441198824, -4.602846969061484, -2.7378003896804444, -3.375952759415478, -2.8961639396080936, -3.1421071730454764, -3.0426019373688757, -3.734782572874959, -2.88375108655994, -2.2738625234707133, -3.2093866250207492, -1.9147770313293595, -1.8029971593012168, -3.1156995447005817, -4.35798481890799, -2.2579638222687763, -4.40584552463137, -3.81033458282169, -1.9433625305443216, -2.0135492697807846, -3.8375208517362283, -3.4364861407024163, -4.181081176708372, -1.7103341119152016, -4.410789531524842, -2.2582880993810295, -4.996565161069254, -3.1280379212731804, -3.567801583803887, -3.310745248430135, -3.047007239737592, -2.8377822121131087, -3.0084375122992206, -2.291888647905023, -2.279783875197071, -3.0685902638612754, -2.568899088058641, -2.226480579448987, -4.055537170785763, -3.161663938010521, -1.587921316990046, -1.4664338030866413, -3.1203674169171376, -1.92916521834144, -3.3790222372489596, -4.5473123342788275, -1.0479058715663336, -3.2000357279560427, -5.406501088788021, -4.271337177282281, -5.013386425464696, -4.371071150713442, -3.3981201237068537, -4.447829007623588, -3.551502082268868, -2.735574238888311, -3.0078764870179198, -3.1769860910204404, -10.998408123328353, -3.314696947588507, -2.6238192965810505, -2.5353433936695318, -1.0882634762722807, -3.7716832716291084, -2.464421122751583, -3.505312910468841, -4.219016313332622, -2.779749268730669, -2.706748002865748, -2.6348018798903765, -4.832975525087889, -3.262621844493293, -2.2634398891249603, -4.093501397940986, -4.225333057270919, -4.036320700832797, -1.9236738580415067, -2.1350542768624883, -2.5236366031761857, -2.961467203093259, -3.3649986167491215, -2.4330900655669905, -3.1978811367814415, -3.4488159595055006, -2.9286935437930577, -3.2005828084366916, -2.3592490514743925, -3.3212986106493934, -3.3410172529798623, -3.285749070345157, -5.3654231665771, -2.5330424339971542, -3.837419848850182, -2.7036831897359437, -2.714844789549872, -1.4637792405269217, -2.8790809690987325, -1.6757082409011197, -2.735571850254878, -1.9796073042400142, -2.3278051315787502, -3.926336561490506, -3.2483308175034393, -3.8395568369105026, -1.9404185777564837, -2.6704003466935413, -4.127477424011099, -3.7881203866168627, -3.1397289522064775, -2.8976889312841116, -4.9241048775342895, -1.9252264799070469, -3.0896362748700588, -2.371763650611083, -3.143893135339556, -3.2092588270477003, -1.9390684442661552, -2.9587181200145607, -3.0828541014612436, -2.5509608071645453, -3.281145525936378, -3.6041404220155626, -3.6270226464936033, -3.015130520760008, -2.6068539242259203, -2.2459167435310423, -3.2952045957613505, -1.6714195745394094, -3.986540919846343, -1.453535935760543, -5.194076335231492, -3.1850737625709464, -3.4535633255179095, -3.0639349417032467, -3.387441272143464, -1.4821663869219852, -4.602597848087839, -3.562997206954389, -3.3092221154251376, -3.0754718392599196, -4.191726071866926, -2.382061312434976, -2.7041682746870768, -2.5321433810199516, -3.083966222757946, -2.2493408186182795, -3.024716365127922, -4.164877395890164, -1.6443997285787104, -2.5042010127666763, -2.5695823290704842, -2.3137459009556114, -3.2750655011349297, -2.3002628383770003, -2.7485791402342374, -2.387587370873875, -2.7547110242794486, -4.159178778879074, -3.8390534696199086, -1.4553081428174925, -2.916713193520384, -1.9113184742793399, -1.6205083674920442, -3.082883458194118, -3.522258237623075, -1.043883484430282, -1.6381197633363536, -4.817543121375706, -2.304847646435424, -3.277295690801403, -3.377319557326922, -1.4907033904721334, -3.1398990117528265, -2.2791118202317437, -5.224867759751048, -1.5719346538823904, -3.1337692846945298, -3.216138848212967, -3.714559601960962, -2.5035193732572294, -2.5114879531386456, -3.2636130883344387, -4.627355974457178, -2.2826150355109815, -3.70889606308621, -3.6690378003415187, -1.2437567014534918, -5.440755885226041, -3.5148007385326965, -3.723091879064399, -2.542623652421236, -2.595307534600053, -4.7426654193559665, -2.7999299061556555, -2.3567875111343075, -2.1764599415408394, -2.6213674927096697, -3.2507317114499656, -2.8730086909314565, -5.179133253563633, -4.2445479091559495, -2.313985517044531, -2.8852926455175463, -2.3218323541893517, -1.7659375472170327, -2.102578558493036, -0.9340423408292022, -2.8161530291391337, -2.873208327351614, -3.0492702722596445, -2.733247790122376, -2.2695681111412753, -2.8725707694582048, -5.426223923567018, -1.5803215287471553, -1.9114772687352901, -4.095651008012397, -2.6485984191655327, -3.6879153340594133, -7.104759985182549, -1.4626620203981133, -2.990549351828683, -6.236898918689209, -0.9434255383582406, -4.447019284681032, -3.635225990372386, -3.328839446692559, -2.905857087097572, -2.9493374970309634, -3.2008778696289526, -5.0221001271376355, -4.523487057282046, -5.728920733380293, -2.747275120750935, -2.8045363556910403, -3.4216365933344655, -2.0196173304387983, -3.806814662116313, -3.6827350074231435, -4.040768610107133, -5.359257219786556, -3.866709435605413, -2.5360084144135224, -3.0703695395991586, -3.084409323513474, -2.8759886131858377, -2.274405300174236, -3.464384523648027, -1.9644755372736817, -3.3564065776594516, -4.060221240984324, -2.1096481816278274, -4.388849743820371, -4.399147294104838, -2.2272967737575917, -2.2157659043460565, -4.488920451348438, -1.9966744326873926, -2.546691691893018, -3.3894135788020168, -2.252420138871241, -2.1443164724895754, -3.193648292077734, -3.792548134995612, -3.043912628264693, -3.029061948655042, -3.3114181519644967, -3.2537337823757957, -2.253257749200535, -3.084153237314974, -1.7749663923508285, -3.245285186189233, -1.1894083611072872, -1.9117583169613268, -2.424493508428008, -2.3445931177809705, -5.583266545338887, -2.753886713894144, -1.0440003175830992, -3.116010828370671, -1.9307092453861334, -1.5625305409333383, -1.8846436212552944, -3.4218007245379565, -4.466004147888162, -4.194336573912534, -3.8506116686746332, -3.2941785754235964, -2.4064735180929673, -3.663452818162628, -4.534430946722099, -4.3748551588537925, -2.704072096980241, -3.9138420784699917, -2.8976740356393913, -3.2527550338782514, -4.297893276518717, -6.03632940607401, -3.3734529322433024, -2.2536126547156763, -2.506992114548183, -3.0294192880643327, -2.9939686628670676, -5.204920990784519, -3.0683396838600094, -2.509614310854847, -3.0606443831887598, -4.3935655619003615, -3.581093888108876, -3.9085853935272565, -2.5750684842004983, -3.2890680158894434, -2.740189991446419, -1.7984442550552424, -2.433550737505613, -2.212078740170525, -2.322570855308787, -5.25809265518163, -1.3332193790488704, -4.411550479981501, -2.3117538674162903, -3.81335664613731, -2.1179168020270076, -2.9107588199551726, -3.938835569263664, -3.473611710039712, -2.8421800615282167, -1.910586975534262, -3.356210974837194, -5.831285207740588, -3.883411058694035, -3.029192397799622, -3.014956057846446, -3.1782283741896173, -2.7462875561989484, -2.2935933196738216, -1.9318003161452073, -3.1268867451958635, -3.8322374143073468, -2.8710488300668233, -2.902555804657256, -3.374038075468034, -1.6806794523742123, -3.0405360502554273, -2.502012413222566, -1.9418308236486679, -2.6462143152377515, -5.462011016856433, -3.5582043730345307, -3.6443559424651393, -3.062763115641361, -4.928038256212975, -3.0527907557635636, -3.1645672999681054, -1.5004976534788557, -2.2734275993923077, -2.927828728531343, -1.4877363288514351, -2.8762413883617883, -3.3891241634272244, -1.6129416235873615, -3.507344648218019, -2.6328501590455113, -3.7239707462370064, -3.2944738163524105, -5.337929212264601, -1.6122953238953783, -2.6595463921112072, -1.4621435444395667, -3.5736594001843605, -3.7152576682672036, -2.279093739948599, -5.100794632732306, -3.652313866936426, -2.9011963168280137, -2.2534081275101037, -7.333676072292092, -3.648643321661719, -2.919812708448466, -2.508975115530053, -2.5155562284144013, -1.9724398136575, -2.647785708161478, -4.018731962125477, -3.5891380615839643, -4.778950854849709, -2.3153268612035407, -2.7567867385982407, -4.158996161759043, -3.7136446848212166, -1.9135012557620716, -4.370417195210959, -3.3214233656863397, -3.8357328395436427, -2.262108590555707, -1.5499564725154111, -4.095994667115156, -4.7429026893140485, -3.3657837379046063, -4.199380773320996, -2.5058546855234667, -3.3608166111975524, -3.1507475554284703, -4.595073954406565, -3.728735713132223, -3.0741426708901796, -2.5022439710407203, -2.5051218628213188, -2.9098409460821197, -3.3583715446146827, -2.7435861221308846, -4.33305043226689, -3.751500564415532, -2.3253675233493705, -3.2751978861234767, -2.90003311048284, -2.8508314743116854, -3.370625187750215, -4.3082978218440235, -4.978621147108596, -3.990527984846694, -3.6562765307675, -1.4631650184547391, -4.018025065291133, -2.848586615004795, -5.016572513715975, -3.9033190416245294, -4.643671472370455, -2.9738467905715917, -3.3451055180058344, -2.9734384068282695, -1.5545495960854578, -2.349570658540446, -2.5122024209472227, -3.0429795440687846, -5.031863103810746, -3.6364762229873357, -2.02128168015725, -3.0650917140884224, -2.1733981100254165, -3.6373701391419235, -1.535683525962744, -1.4125137741515337, -1.9242508266758833, -2.876061903416559, -2.413672532119248, -3.028662422640766, -4.105913564645591, -3.453505112590521, -4.182028002373978, -3.2496042867019046, -3.303255388762524, -2.852918238164195, -2.7495004796726756, -3.7065055737073047, -2.263213609191877, -2.6916381784920214, -4.603759440814079, -2.916385792033623, -3.0463351511271117, -3.638739026059592, -3.1417798757117645, -1.7402454131983163, -3.5766896602413967, -2.7033698186117423, -2.5483395536329456, -2.354117871433876, -2.301315230634442, -2.0172322300104657, -1.4749637113811656, -3.5100575539404937, -3.154110008923232, -5.029992187571158, -2.067202566332763, -5.736786106624082, -3.44737907819659, -3.3944018973504293, -2.8355760435848802, -3.2100500656553774, -2.098621916211775, -2.5131707050775853, -5.030207115990661, -3.165734206158177, -4.538148727487788, -3.0203559042213017, -4.507139277769936, -2.9600663513225633, -2.5378800365405914, -3.398929659167437, -4.344006294208238, -4.844304482839, -1.6184651124649385, -2.0103263885577607, -7.699271408788034, -1.9206170745746234, -5.387800681751329, -4.085853688028874, -1.4994781152727614, -3.1394889614184933, -2.7013519107429644, -1.4506519940820486, -3.1623764041114493, -1.9152155370790476, -2.6242225969694446, -3.28932000162468, -3.2172815051701456, -4.063751902294668, -2.145977972895731, -3.0156155990186764, -2.8577406922327633, -2.5160313217204737, -3.397689023258405, -1.909589620842768, -2.7033698708710676, -4.155979653608244, -3.1517132474719727, -2.502355402666828, -3.0422896902825523, -4.731827679752762, -3.0324110159271465, -2.5979269984027993, -3.8938518751597977, -3.7801126223818544, -3.083970096455742, -4.194660043080737, -2.825841398056549, -2.2416644183987224, -1.465320918139124, -3.3229555705013984, -2.556877770920399, -4.12676334592399, -5.221615514695098, -2.1336947035815803, -3.7636196758997844, -4.047334106105851, -3.5700610072927406, -3.5742215286064183, -3.330157134297864, -2.2799047995590427, -3.0702979112419526, -1.9098602205068154, -3.761005252041497, -1.6083394376824776, -3.346606357283808, -4.489989381002612, -3.884304516254229, -3.342488639021171, -3.3635528076635315, -1.536350894643237, -2.5075528048404157, -3.511594177145282, -1.8476802341685976, -3.1475666985032804, -3.1220021556766184, -3.258000042130718, -1.4525321109540204, -4.283061237310409, -3.6403896925718895, -0.9922348360087392, -1.4761240084874425, -3.6054949577009854, -2.7042549980228516, -3.134874424042146, -1.9180503586493072, -3.764494233575636, -2.5962357815264836, -1.7356404228834845, -2.3256662996658712, -3.567149205578633, -7.790212163726182, -3.254738946339352, -3.015591052710719, -1.9296719051554523, -3.398149458824616, -2.857090374528945, -2.8717622544099717, -4.318624225037053, -2.7034206536816465, -3.022137713512567, -2.727064643426437, -5.523441997733109, -1.9289785134225856, -3.0287696472303813, -2.258015235076528, -5.964632681387488, -1.7735707328324262, -3.2546191164052516, -2.277015520577498, -1.9850624957771836, -3.2836596611687034, -3.7857161394239642, -2.2497524958898993, -5.28253923051703, -2.7242500256671356, -3.5636121677995893, -2.682989853024883, -2.5602893145319894, -5.049221719828365, -4.060374961738342, -3.0873887718342448, -5.262975895983527, -2.734588194055715, -3.482339037776603, -3.52628687249163, -2.712948651271287, -2.506566656112915, -4.333677449668279, -3.8300197558809326, -3.4552215413326444, -5.155362850176532, -4.258113491913097, -1.9937476343502902, -3.6498958866608535, -2.9002935965184937, -2.9954674594146105, -2.889028544640664, -2.7649834008805216, -2.5877082658030917, -3.3620423958831407, -2.5155175110574364, -3.39499751748323, -4.379892060432348, -3.3561611987125604, -4.4980664642764125, -5.4016818174860495, -2.2561607004921846, -2.3483063800165507, -2.7686528336114438, -3.839881027908314, -2.1842872044097104, -2.7822130568970023, -3.051230812364556, -4.8981503542987666, -2.6873526108517503, -4.908426709405611, -2.911372829990905, -1.577108861465259, -3.150880307214459, -3.15502438068184, -2.7259553861229446, -2.1344172066061167, -2.657808288606821, -2.7287313624723932, -4.035604814719033, -1.9109900661404582, -5.356741493647458, -3.6042227727383533, -3.4178295466102444, -2.7780170132807984, -2.519927804804156, -2.380003039448734, -2.431373707831764, -2.399504233882381, -4.88362463344389, -1.508211976654788, -3.987444678325529, -5.6371998699381685, -3.4052897848086343, -3.412345766831583, -2.34297024357858, -2.5174816378268337, -2.9896111244600343, -3.1303536321982355, -1.1452248950054336, -3.3476343665263046, -4.726039436053804, -1.9314713477352383, -4.922580187951995, -2.294931830635278, -2.258547945501728, -2.111672285594922, -3.5661232599516954, -3.905021752513932, -2.8943920074543663, -4.06305673754924, -1.9561391207958376, -3.8315126079521753, -4.9239987923387645, -1.4485350157959622, -3.3318845279560385, -2.3180885861835834, -2.9965171949148903, -1.9419024702424514, -3.1987182166208425, -3.213171301924996, -3.458004407138624, -4.085134596692562, -2.1080422416037963, -2.240007082596674, -3.517355950707177, -2.8220573118971926, -4.065693997423177, -2.6573397562482657, -3.3478083555267406, -4.467527386324885, -2.002925068905434, -3.1764151541576107, -3.277780508664598, -4.668519340624919, -1.6099444978925281, -4.743109215852536, -1.538212897333659, -2.925861622170216, -3.11445664140734, -3.0326344111683436, -2.6368713754560646, -3.023416772707387, -4.010052652543372, -4.216740938879899, -2.7372574027009904, -2.586394857908049, -3.0035611067463694, -2.0597561674796387, -1.9434280953705434, -4.612798264951508, -2.075492378570087, -1.9954622473507608, -2.568402972826012, -3.82038817339505, -4.119481712577084, -1.643858078338881, -2.7317804735902813, -5.862713521233299, -3.8409236587686766, -1.0137229995074506, -3.163188251655787, -2.250316575415537, -3.1858274958472244, -4.203700117229373, -1.9270062822670198, -3.639954094354, -4.50484128080834, -6.570532781878393, -2.6918412989500218, -2.820289978408278, -3.2663407655458565, -4.49754013052547, -3.7082917236079376, -3.3490883429227543, -2.5142593199958037, -1.927322768055088, -3.198169049953601, -3.9159577909071293, -3.653215379288858, -1.591933359948693, -2.7778751430808004, -2.1169441465172754, -3.7494312078834815, -3.5585171467952064, -2.9738675540163078, -3.312123070081996, -3.7587432936017406, -2.9322734521937175, -1.9167113654276122, -2.888627967340601, -3.5760034093374045, -1.9133082026442216, -4.130217637124102, -2.559058951974717, -3.6535923246937645, -3.439381550199135, -2.390821732461232, -3.168909672683622, -3.0586087439648613, -2.301790249835309, -2.249191166533959, -2.272381735081332, -3.427888296535077, -2.70403755805653, -1.462067303771056, -1.9172809344942143, -4.993614392880878, -2.3448992248297933, -3.474572381625482, -2.8867314746610924, -1.6172164221439913, -2.725026850717473, -2.818159032621698, -2.6607002944014115, -3.2849592302038184, -2.257970390361355, -2.633867864500626, -1.9168304166290793, -2.8602234164107987, -3.8040968354914635, -1.543119210927184, -2.6677876363903037, -1.5342791157394942, -1.1820781201454151, -4.558398039280188, -2.2532153988074954, -1.5259756875260975, -2.2790948624456697, -2.747512487761255, -2.2730605478711396, -5.214668131217406, -1.064005402052079, -4.6555361907364325, -2.886105614878491, -3.458972988188351, -2.6879654984892025, -2.912273376913253, -3.79745792113872, -1.7618196539430593, -2.510115084973035, -5.082823517738773, -3.911725055413302, -2.981799827633685, -3.2702436146549796, -3.491734305114419, -1.663490781261755, -4.349933873580229, -3.6084041499308492, -3.5554172456805837, -2.641496273812972, -3.0645488553392317, -4.836552387026178, -3.8013772179449115, -2.5026351734814827, -3.5950279191384698, -3.9621683078834535, -3.003978801956498, -1.910495246697736, -3.2411120680421455, -4.4959589721492055, -1.9160342956399057, -2.621488955796974, -1.9899370952701338, -3.459162256300032, -3.2913494767377194, -2.9125248571266122, -2.404151591766117, -3.543657276414493, -2.594256897008955, -3.2868344876279707, -3.21537723940333, -1.5042128812943452, -3.0485019730777476, -3.2532564102022943, -2.5028399375624817, -1.9151406138122777, -3.0778002717928215, -2.796587100294615, -2.6730432241200917, -2.800038666737926, -2.283205085825817, -2.1209187350997714, -3.221434151576364, -2.7141291184134233, -3.3531606888675793, -2.5036461032929265, -4.651402473000213, -1.9122983760259686, -3.044565512415788, -5.5629473977221915, -3.2729067288441964, -1.5127600283911018, -2.2603222201089546, -3.743769411114083, -1.4782498598782343, -3.1729362645953048, -2.4593404793620026, -3.100035615139161, -5.304468061350532, -2.658899901141348, -3.8103354437104433, -3.260374602497286, -1.7944404752715353, -3.7710241395955113, -2.816776706380237, -2.518152355553711, -3.0421752011077836, -1.9014894992485116, -3.418543797722446, -2.5128361535836556, -2.520407979681591, -1.9197113771626122, -2.262676810347813, -2.525274749462333, -2.5185913125775534, -3.5933472284387658]} diff --git a/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/test/test.factory.js b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/test/test.factory.js new file mode 100644 index 000000000000..9253795ea9f8 --- /dev/null +++ b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/test/test.factory.js @@ -0,0 +1,182 @@ +/** +* @license Apache-2.0 +* +* Copyright (c) 2024 The Stdlib Authors. +* +* Licensed under the Apache License, Version 2.0 (the "License"); +* you may not use this file except in compliance with the License. +* You may obtain a copy of the License at +* +* http://www.apache.org/licenses/LICENSE-2.0 +* +* Unless required by applicable law or agreed to in writing, software +* distributed under the License is distributed on an "AS IS" BASIS, +* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +* See the License for the specific language governing permissions and +* limitations under the License. +*/ + +'use strict'; + +// MODULES // + +var tape = require( 'tape' ); +var isnan = require( '@stdlib/math/base/assert/is-nan' ); +var abs = require( '@stdlib/math/base/special/abs' ); +var PINF = require( '@stdlib/constants/float64/pinf' ); +var NINF = require( '@stdlib/constants/float64/ninf' ); +var EPS = require( '@stdlib/constants/float64/eps' ); +var factory = require( './../lib/factory.js' ); + + +// FIXTURES // + +var smallLambda = require( './fixtures/python/small_lambda.json' ); +var largeLambda = require( './fixtures/python/large_lambda.json' ); + + +// TESTS // + +tape( 'main export is a function', function test( t ) { + t.ok( true, __filename ); + t.strictEqual( typeof factory, 'function', 'main export is a function' ); + t.end(); +}); + +tape( 'the function returns a function', function test( t ) { + var logpmf = factory( 0.5 ); + t.equal( typeof logpmf, 'function', 'returns a function' ); + t.end(); +}); + +tape( 'if provided `NaN` for any parameter, the created function returns `NaN`', function test( t ) { + var logpmf; + var y; + + logpmf = factory( 0.5 ); + y = logpmf( NaN ); + t.equal( isnan( y ), true, 'returns NaN' ); + + logpmf = factory( NaN ); + y = logpmf( 0.0 ); + t.equal( isnan( y ), true, 'returns NaN' ); + + t.end(); +}); + +tape( 'if provided a finite `lambda`, the function returns a function which returns `-Infinity` when provided `+infinity` for `x`', function test( t ) { + var logpmf; + var y; + + logpmf = factory( 1.0 ); + y = logpmf( PINF ); + t.equal( y, NINF, 'returns -Infinity' ); + + t.end(); +}); + +tape( 'if provided a finite `lambda`, the function returns a function which returns `-Infinity` when provided a negative integer for `x`', function test( t ) { + var logpmf; + var y; + + logpmf = factory( 0.4 ); + y = logpmf( -4.0 ); + t.equal( y, NINF, 'returns -Infinity' ); + + y = logpmf( -1.0 ); + t.equal( y, NINF, 'returns -Infinity' ); + + t.end(); +}); + +tape( 'if provided a finite `lambda`, the function returns a function which returns `-Infinity` when provided a non-integer for `x`', function test( t ) { + var logpmf; + var y; + + logpmf = factory( 0.4 ); + y = logpmf( 1.3 ); + t.equal( y, NINF, 'returns -Infinity' ); + + y = logpmf( 1.4 ); + t.equal( y, NINF, 'returns -Infinity' ); + + y = logpmf( 3.2 ); + t.equal( y, NINF, 'returns -Infinity' ); + + y = logpmf( 4.8 ); + t.equal( y, NINF, 'returns -Infinity' ); + + y = logpmf( -1.2 ); + t.equal( y, NINF, 'returns -Infinity' ); + + t.end(); +}); + +tape( 'if provided a `lambda` which is negative, the created function always returns `NaN`', function test( t ) { + var logpmf; + var y; + + logpmf = factory( -1.5 ); + + y = logpmf( 2.0 ); + t.equal( isnan( y ), true, 'returns NaN' ); + + y = logpmf( 0.0 ); + t.equal( isnan( y ), true, 'returns NaN' ); + + t.end(); +}); + +tape( 'the created function evaluates the logpmf for `x` given small `lambda`', function test( t ) { + var expected; + var logpmf; + var lambda; + var delta; + var tol; + var i; + var x; + var y; + + expected = smallLambda.expected; + x = smallLambda.x; + lambda = smallLambda.lambda; + for ( i = 0; i < x.length; i++ ) { + logpmf = factory( lambda[ i ] ); + y = logpmf( x[ i ] ); + if ( y === expected[ i ] ) { + t.equal( y, expected[i], 'x: '+x[ i ]+'. lambda: '+lambda[ i ]+', y: '+y+', expected: '+expected[ i ] ); + } else { + delta = abs( y - expected[ i ] ); + tol = 2.0 * EPS * abs( expected[ i ] ); + t.ok( delta <= tol, 'within tolerance. x: '+x[ i ]+'. lambda: '+lambda[ i ]+'. y: '+y+'. E: '+expected[ i ]+'. Δ: '+delta+'. tol: '+tol+'.' ); + } + } + t.end(); +}); + +tape( 'the created function evaluates the logpmf for `x` given large `lambda`', function test( t ) { + var expected; + var logpmf; + var lambda; + var delta; + var tol; + var i; + var x; + var y; + + expected = largeLambda.expected; + x = largeLambda.x; + lambda = largeLambda.lambda; + for ( i = 0; i < x.length; i++ ) { + logpmf = factory( lambda[ i ] ); + y = logpmf( x[ i ] ); + if ( y === expected[ i ] ) { + t.equal( y, expected[i], 'x: '+x[ i ]+'. lambda: '+lambda[ i ]+', y: '+y+', expected: '+expected[ i ] ); + } else { + delta = abs( y - expected[ i ] ); + tol = 2.0 * EPS * abs( expected[ i ] ); + t.ok( delta <= tol, 'within tolerance. x: '+x[ i ]+'. lambda: '+lambda[ i ]+'. y: '+y+'. E: '+expected[ i ]+'. Δ: '+delta+'. tol: '+tol+'.' ); + } + } + t.end(); +}); diff --git a/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/test/test.js b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/test/test.js new file mode 100644 index 000000000000..0b7ebf6a2ffe --- /dev/null +++ b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/test/test.js @@ -0,0 +1,38 @@ +/** +* @license Apache-2.0 +* +* Copyright (c) 2024 The Stdlib Authors. +* +* Licensed under the Apache License, Version 2.0 (the "License"); +* you may not use this file except in compliance with the License. +* You may obtain a copy of the License at +* +* http://www.apache.org/licenses/LICENSE-2.0 +* +* Unless required by applicable law or agreed to in writing, software +* distributed under the License is distributed on an "AS IS" BASIS, +* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +* See the License for the specific language governing permissions and +* limitations under the License. +*/ + +'use strict'; + +// MODULES // + +var tape = require( 'tape' ); +var logpmf = require( './../lib' ); + + +// TESTS // + +tape( 'main export is a function', function test( t ) { + t.ok( true, __filename ); + t.strictEqual( typeof logpmf, 'function', 'main export is a function' ); + t.end(); +}); + +tape( 'attached to the main export is a factory method for generating `logpmf` functions', function test( t ) { + t.equal( typeof logpmf.factory, 'function', 'exports a factory method' ); + t.end(); +}); diff --git a/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/test/test.logpmf.js b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/test/test.logpmf.js new file mode 100644 index 000000000000..8376fcfc0268 --- /dev/null +++ b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/test/test.logpmf.js @@ -0,0 +1,140 @@ +/** +* @license Apache-2.0 +* +* Copyright (c) 2024 The Stdlib Authors. +* +* Licensed under the Apache License, Version 2.0 (the "License"); +* you may not use this file except in compliance with the License. +* You may obtain a copy of the License at +* +* http://www.apache.org/licenses/LICENSE-2.0 +* +* Unless required by applicable law or agreed to in writing, software +* distributed under the License is distributed on an "AS IS" BASIS, +* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +* See the License for the specific language governing permissions and +* limitations under the License. +*/ + +'use strict'; + +// MODULES // + +var tape = require( 'tape' ); +var isnan = require( '@stdlib/math/base/assert/is-nan' ); +var abs = require( '@stdlib/math/base/special/abs' ); +var PINF = require( '@stdlib/constants/float64/pinf' ); +var NINF = require( '@stdlib/constants/float64/ninf' ); +var EPS = require( '@stdlib/constants/float64/eps' ); +var logpmf = require( './../lib' ); + + +// FIXTURES // + +var smallLambda = require( './fixtures/python/small_lambda.json' ); +var largeLambda = require( './fixtures/python/large_lambda.json' ); + + +// TESTS // + +tape( 'main export is a function', function test( t ) { + t.ok( true, __filename ); + t.strictEqual( typeof logpmf, 'function', 'main export is a function' ); + t.end(); +}); + +tape( 'if provided `NaN` for any parameter, the function returns `NaN`', function test( t ) { + var y = logpmf( NaN, 1.0 ); + t.equal( isnan( y ), true, 'returns NaN' ); + y = logpmf( 0.0, NaN ); + t.equal( isnan( y ), true, 'returns NaN' ); + t.end(); +}); + +tape( 'if provided `+infinity` for `x` and a valid `lambda`, the function returns `-Infinity`', function test( t ) { + var y = logpmf( PINF, 0.01 ); + t.equal( y, NINF, 'returns -Infinity' ); + t.end(); +}); + +tape( 'if provided a negative integer for `x` and a valid `lambda`, the function returns `-Infinity`', function test( t ) { + var y = logpmf( -20.0, 0.5 ); + t.equal( y, NINF, 'returns -Infinity' ); + + y = logpmf( -4.0, 0.5 ); + t.equal( y, NINF, 'returns -Infinity' ); + + t.end(); +}); + +tape( 'if provided a non-integer for `x` and a valid `lambda`, the function returns `-Infinity`', function test( t ) { + var y = logpmf( -1.3, 0.5 ); + t.equal( y, NINF, 'returns -Infinity' ); + + y = logpmf( 2.4, 0.5 ); + t.equal( y, NINF, 'returns -Infinity' ); + + t.end(); +}); + +tape( 'if provided a shape parameter `lambda` which is negative, the function always returns `NaN`', function test( t ) { + var y; + + y = logpmf( 2.0, -1.0 ); + t.equal( isnan( y ), true, 'returns NaN' ); + + y = logpmf( 0.0, -1.5 ); + t.equal( isnan( y ), true, 'returns NaN' ); + + t.end(); +}); + +tape( 'the function evaluates the logpmf for `x` given small parameter `lambda`', function test( t ) { + var expected; + var lambda; + var delta; + var tol; + var x; + var y; + var i; + + expected = smallLambda.expected; + x = smallLambda.x; + lambda = smallLambda.lambda; + for ( i = 0; i < x.length; i++ ) { + y = logpmf( x[ i ], lambda[ i ] ); + if ( y === expected[ i ] ) { + t.equal( y, expected[ i ], 'x: '+x[ i ]+'. lambda:'+lambda[ i ]+', y: '+y+', expected: '+expected[ i ] ); + } else { + delta = abs( y - expected[ i ] ); + tol = 2.0 * EPS * abs( expected[ i ] ); + t.ok( delta <= tol, 'within tolerance. x: '+x[ i ]+'. lambda: '+lambda[ i ]+'. y: '+y+'. E: '+expected[ i ]+'. Δ: '+delta+'. tol: '+tol+'.' ); + } + } + t.end(); +}); + +tape( 'the function evaluates the logpmf for `x` given large parameter `lambda`', function test( t ) { + var expected; + var lambda; + var delta; + var tol; + var x; + var y; + var i; + + expected = largeLambda.expected; + x = largeLambda.x; + lambda = largeLambda.lambda; + for ( i = 0; i < x.length; i++ ) { + y = logpmf( x[ i ], lambda[ i ] ); + if ( y === expected[ i ] ) { + t.equal( y, expected[ i ], 'x: '+x[ i ]+'. lambda:'+lambda[ i ]+', y: '+y+', expected: '+expected[ i ] ); + } else { + delta = abs( y - expected[ i ] ); + tol = 2.0 * EPS * abs( expected[ i ] ); + t.ok( delta <= tol, 'within tolerance. x: '+x[ i ]+'. lambda: '+lambda[ i ]+'. y: '+y+'. E: '+expected[ i ]+'. Δ: '+delta+'. tol: '+tol+'.' ); + } + } + t.end(); +}); From 2557d85acb2461a4ab4ca1becabf9a3e80b1766a Mon Sep 17 00:00:00 2001 From: Jaysukh-409 Date: Wed, 25 Dec 2024 17:52:30 +0530 Subject: [PATCH 2/5] chore: clean-up --- type: pre_commit_static_analysis_report description: Results of running static analysis checks when committing changes. report: - task: lint_filenames status: passed - task: lint_editorconfig status: passed - task: lint_markdown status: passed - task: lint_package_json status: na - task: lint_repl_help status: passed - task: lint_javascript_src status: passed - task: lint_javascript_cli status: na - task: lint_javascript_examples status: passed - task: lint_javascript_tests status: passed - task: lint_javascript_benchmarks status: passed - task: lint_python status: passed - task: lint_r status: na - task: lint_c_src status: na - task: lint_c_examples status: na - task: lint_c_benchmarks status: na - task: lint_c_tests_fixtures status: na - task: lint_shell status: na - task: lint_typescript_declarations status: passed - task: lint_typescript_tests status: na - task: lint_license_headers status: passed --- --- type: pre_push_report description: Results of running various checks prior to pushing changes. report: - task: run_javascript_examples status: passed - task: run_c_examples status: na - task: run_cpp_examples status: na - task: run_javascript_readme_examples status: passed - task: run_c_benchmarks status: na - task: run_cpp_benchmarks status: na - task: run_fortran_benchmarks status: na - task: run_javascript_benchmarks status: passed - task: run_julia_benchmarks status: na - task: run_python_benchmarks status: na - task: run_r_benchmarks status: na - task: run_javascript_tests status: passed --- --- .../stats/base/dists/planck/logpmf/README.md | 21 +++++++-------- .../planck/logpmf/benchmark/benchmark.js | 2 +- .../base/dists/planck/logpmf/docs/repl.txt | 14 +++++----- .../dists/planck/logpmf/docs/types/index.d.ts | 2 +- .../dists/planck/logpmf/examples/index.js | 18 ++++--------- .../base/dists/planck/logpmf/lib/factory.js | 4 +-- .../base/dists/planck/logpmf/lib/main.js | 4 +-- .../logpmf/test/fixtures/python/runner.py | 2 +- .../dists/planck/logpmf/test/test.factory.js | 26 +++++++++---------- .../dists/planck/logpmf/test/test.logpmf.js | 18 ++++++------- 10 files changed, 50 insertions(+), 61 deletions(-) diff --git a/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/README.md b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/README.md index 616d684092b6..a5de034fe932 100644 --- a/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/README.md +++ b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/README.md @@ -34,7 +34,7 @@ The [probability mass function][pmf] (PMF) for a Planck random variable is defin -where `lambda > 0` is the shape parameter. The random variable `X` denotes the count of events in a quantized system. +where `λ` is the shape parameter. The random variable `X` denotes the count of events in a quantized system. @@ -50,7 +50,7 @@ var logpmf = require( '@stdlib/stats/base/dists/planck/logpmf' ); #### logpmf( x, lambda ) -Evaluates the logarithm of the [probability mass function][pmf] (PMF) of a Planck distribution with shape parameter `lambda`. +Evaluates the logarithm of the [probability mass function][pmf] (PMF) of a Planck distribution with shape parameter `λ`. ```javascript var y = logpmf( 4.0, 0.3 ); @@ -73,7 +73,7 @@ y = logpmf( 0.0, NaN ); // returns NaN ``` -If provided a shape parameter `lambda` which is negative number, the function returns `NaN`. +If provided a shape parameter `λ` which is nonpositive number, the function returns `NaN`. ```javascript var y = logpmf( 2.0, -1.0 ); @@ -82,7 +82,7 @@ var y = logpmf( 2.0, -1.0 ); #### logpmf.factory( lambda ) -Returns a function for evaluating the logarithm of the [probability mass function][pmf] (PMF) of a Planck distribution with shape parameter `lambda`. +Returns a function for evaluating the logarithm of the [probability mass function][pmf] (PMF) of a Planck distribution with shape parameter `λ`. ```javascript var mylogpmf = logpmf.factory( 0.5 ); @@ -118,17 +118,14 @@ var discreteUniform = require( '@stdlib/random/array/discrete-uniform' ); var uniform = require( '@stdlib/random/array/uniform' ); var logpmf = require( '@stdlib/stats/base/dists/planck/logpmf' ); -var lambda; -var x; +var lambda = uniform( 10, 0.1, 5.0 ); +var x = discreteUniform( 10, 0, 5 ); + var y; var i; - -x = discreteUniform( 10, 0, 5 ); -lambda = uniform( 10, 0.0, 5.0 ); - -for ( i = 0; i < 10; i++ ) { +for ( i = 0; i < lambda.length; i++ ) { y = logpmf( x[ i ], lambda[ i ] ); - console.log( 'x: %d, lambda: %d, ln( P( X = x; lambda ) ): %d', x[ i ], lambda[ i ].toFixed( 4 ), y.toFixed( 4 ) ); + console.log( 'x: %d, λ: %d, ln( P( X = x; λ ) ): %d', x[ i ], lambda[ i ].toFixed( 4 ), y.toFixed( 4 ) ); } ``` diff --git a/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/benchmark/benchmark.js b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/benchmark/benchmark.js index 0d2c33428b13..b2d161e5cca0 100644 --- a/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/benchmark/benchmark.js +++ b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/benchmark/benchmark.js @@ -37,7 +37,7 @@ bench( pkg, function benchmark( b ) { var i; x = discreteUniform( 100, 0, 40 ); - lambda = uniform( 100, 0.0, 10.0 ); + lambda = uniform( 100, 0.1, 10.0 ); b.tic(); for ( i = 0; i < b.iterations; i++ ) { diff --git a/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/docs/repl.txt b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/docs/repl.txt index 508c6d6dbd91..905574350098 100644 --- a/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/docs/repl.txt +++ b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/docs/repl.txt @@ -1,18 +1,18 @@ -{{alias}}( x, lambda ) +{{alias}}( x, λ ) Evaluates the logarithm of the probability mass function (PMF) for a - Planck distribution with shape parameter `lambda` at a value `x`. + Planck distribution with shape parameter `λ` at a value `x`. If provided `NaN` as any argument, the function returns `NaN`. - If `lambda < 0`, the function returns `NaN`. + If `λ <= 0`, the function returns `NaN`. Parameters ---------- x: number Input value. - lambda: number + λ: number Shape parameter. Returns @@ -37,13 +37,13 @@ NaN -{{alias}}.factory( lambda ) +{{alias}}.factory( λ ) Returns a function for evaluating the logarithm of the probability mass - function (PMF) of a Planck distribution with shape parameter `lambda`. + function (PMF) of a Planck distribution with shape parameter `λ`. Parameters ---------- - lambda: number + λ: number Shape parameter. Returns diff --git a/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/docs/types/index.d.ts b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/docs/types/index.d.ts index f092565169b2..b8e81981ac43 100644 --- a/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/docs/types/index.d.ts +++ b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/docs/types/index.d.ts @@ -35,7 +35,7 @@ interface LogPMF { * * ## Notes * - * - If `lambda < 0`, the function returns `NaN`. + * - If `lambda <= 0`, the function returns `NaN`. * * @param x - input value * @param lambda - shape parameter diff --git a/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/examples/index.js b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/examples/index.js index b95b9aa5e787..caae57cbe996 100644 --- a/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/examples/index.js +++ b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/examples/index.js @@ -22,20 +22,12 @@ var discreteUniform = require( '@stdlib/random/array/discrete-uniform' ); var uniform = require( '@stdlib/random/array/uniform' ); var logpmf = require( './../lib' ); -var lambda; -var x; +var lambda = uniform( 10, 0.1, 5.0 ); +var x = discreteUniform( 10, 0, 5 ); + var y; var i; - -x = discreteUniform( 10, 0, 5 ); -lambda = uniform( 10, 0.0, 5.0 ); - -for ( i = 0; i < 10; i++ ) { +for ( i = 0; i < lambda.length; i++ ) { y = logpmf( x[ i ], lambda[ i ] ); - console.log( 'x: %d, lambda: %d, ln( P( X = x; lambda ) ): %d', x[ i ], lambda[ i ].toFixed( 4 ), y.toFixed( 4 ) ); + console.log( 'x: %d, λ: %d, ln( P( X = x; λ ) ): %d', x[ i ], lambda[ i ].toFixed( 4 ), y.toFixed( 4 ) ); } - -console.log( logpmf(4.0, 0.3) ); -console.log( logpmf(2.0, 1.7) ); -console.log( logpmf(3.0, 0.5) ); -console.log( logpmf(1.0, 0.5) ); diff --git a/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/lib/factory.js b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/lib/factory.js index c5ae979a4dc9..e215504fa8f1 100644 --- a/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/lib/factory.js +++ b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/lib/factory.js @@ -33,7 +33,7 @@ var NINF = require( '@stdlib/constants/float64/ninf' ); /** * Returns a function for evaluating the logarithm of the probability mass function (PMF) for a Planck distribution with shape parameter `lambda`. * -* @param {NonNegativeNumber} lambda - shape parameter +* @param {PositiveNumber} lambda - shape parameter * @returns {Function} logPMF * * @example @@ -45,7 +45,7 @@ var NINF = require( '@stdlib/constants/float64/ninf' ); * // returns ~-1.4328 */ function factory( lambda ) { - if ( isnan( lambda ) || lambda < 0.0 ) { + if ( isnan( lambda ) || lambda <= 0.0 ) { return constantFunction( NaN ); } return logpmf; diff --git a/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/lib/main.js b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/lib/main.js index ac110102cbce..d278a5dea538 100644 --- a/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/lib/main.js +++ b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/lib/main.js @@ -33,7 +33,7 @@ var NINF = require( '@stdlib/constants/float64/ninf' ); * Evaluates the logarithm of the probability mass function (PMF) for a Planck distribution with shape parameter `lambda` at a value `x`. * * @param {number} x - input value -* @param {NonNegativeNumber} lambda - shape parameter +* @param {PositiveNumber} lambda - shape parameter * @returns {NonPositiveNumber} logarithm of PMF * * @example @@ -62,7 +62,7 @@ var NINF = require( '@stdlib/constants/float64/ninf' ); * // returns NaN */ function logpmf( x, lambda ) { - if ( isnan( x ) || isnan( lambda ) || lambda < 0.0 ) { + if ( isnan( x ) || isnan( lambda ) || lambda <= 0.0 ) { return NaN; } if ( isNonNegativeInteger( x ) ) { diff --git a/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/test/fixtures/python/runner.py b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/test/fixtures/python/runner.py index c2e03300d034..616300c199bf 100644 --- a/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/test/fixtures/python/runner.py +++ b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/test/fixtures/python/runner.py @@ -65,7 +65,7 @@ def gen(x, lam, name): with open(filepath, "w", encoding='utf-8') as outfile: json.dump(data, outfile) - # Include trailing newline + # Include trailing newline: with open(filepath, "a", encoding='utf-8') as outfile: outfile.write("\n") diff --git a/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/test/test.factory.js b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/test/test.factory.js index 9253795ea9f8..f7384708cb50 100644 --- a/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/test/test.factory.js +++ b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/test/test.factory.js @@ -55,11 +55,11 @@ tape( 'if provided `NaN` for any parameter, the created function returns `NaN`', logpmf = factory( 0.5 ); y = logpmf( NaN ); - t.equal( isnan( y ), true, 'returns NaN' ); + t.equal( isnan( y ), true, 'returns expected value' ); logpmf = factory( NaN ); y = logpmf( 0.0 ); - t.equal( isnan( y ), true, 'returns NaN' ); + t.equal( isnan( y ), true, 'returns expected value' ); t.end(); }); @@ -70,7 +70,7 @@ tape( 'if provided a finite `lambda`, the function returns a function which retu logpmf = factory( 1.0 ); y = logpmf( PINF ); - t.equal( y, NINF, 'returns -Infinity' ); + t.equal( y, NINF, 'returns expected value' ); t.end(); }); @@ -81,10 +81,10 @@ tape( 'if provided a finite `lambda`, the function returns a function which retu logpmf = factory( 0.4 ); y = logpmf( -4.0 ); - t.equal( y, NINF, 'returns -Infinity' ); + t.equal( y, NINF, 'returns expected value' ); y = logpmf( -1.0 ); - t.equal( y, NINF, 'returns -Infinity' ); + t.equal( y, NINF, 'returns expected value' ); t.end(); }); @@ -95,34 +95,34 @@ tape( 'if provided a finite `lambda`, the function returns a function which retu logpmf = factory( 0.4 ); y = logpmf( 1.3 ); - t.equal( y, NINF, 'returns -Infinity' ); + t.equal( y, NINF, 'returns expected value' ); y = logpmf( 1.4 ); - t.equal( y, NINF, 'returns -Infinity' ); + t.equal( y, NINF, 'returns expected value' ); y = logpmf( 3.2 ); - t.equal( y, NINF, 'returns -Infinity' ); + t.equal( y, NINF, 'returns expected value' ); y = logpmf( 4.8 ); - t.equal( y, NINF, 'returns -Infinity' ); + t.equal( y, NINF, 'returns expected value' ); y = logpmf( -1.2 ); - t.equal( y, NINF, 'returns -Infinity' ); + t.equal( y, NINF, 'returns expected value' ); t.end(); }); -tape( 'if provided a `lambda` which is negative, the created function always returns `NaN`', function test( t ) { +tape( 'if provided a `lambda` which is nonpositive, the created function always returns `NaN`', function test( t ) { var logpmf; var y; logpmf = factory( -1.5 ); y = logpmf( 2.0 ); - t.equal( isnan( y ), true, 'returns NaN' ); + t.equal( isnan( y ), true, 'returns expected value' ); y = logpmf( 0.0 ); - t.equal( isnan( y ), true, 'returns NaN' ); + t.equal( isnan( y ), true, 'returns expected value' ); t.end(); }); diff --git a/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/test/test.logpmf.js b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/test/test.logpmf.js index 8376fcfc0268..6cb9612a43bf 100644 --- a/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/test/test.logpmf.js +++ b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/test/test.logpmf.js @@ -45,9 +45,9 @@ tape( 'main export is a function', function test( t ) { tape( 'if provided `NaN` for any parameter, the function returns `NaN`', function test( t ) { var y = logpmf( NaN, 1.0 ); - t.equal( isnan( y ), true, 'returns NaN' ); + t.equal( isnan( y ), true, 'returns expected value' ); y = logpmf( 0.0, NaN ); - t.equal( isnan( y ), true, 'returns NaN' ); + t.equal( isnan( y ), true, 'returns expected value' ); t.end(); }); @@ -59,32 +59,32 @@ tape( 'if provided `+infinity` for `x` and a valid `lambda`, the function return tape( 'if provided a negative integer for `x` and a valid `lambda`, the function returns `-Infinity`', function test( t ) { var y = logpmf( -20.0, 0.5 ); - t.equal( y, NINF, 'returns -Infinity' ); + t.equal( y, NINF, 'returns expected value' ); y = logpmf( -4.0, 0.5 ); - t.equal( y, NINF, 'returns -Infinity' ); + t.equal( y, NINF, 'returns expected value' ); t.end(); }); tape( 'if provided a non-integer for `x` and a valid `lambda`, the function returns `-Infinity`', function test( t ) { var y = logpmf( -1.3, 0.5 ); - t.equal( y, NINF, 'returns -Infinity' ); + t.equal( y, NINF, 'returns expected value' ); y = logpmf( 2.4, 0.5 ); - t.equal( y, NINF, 'returns -Infinity' ); + t.equal( y, NINF, 'returns expected value' ); t.end(); }); -tape( 'if provided a shape parameter `lambda` which is negative, the function always returns `NaN`', function test( t ) { +tape( 'if provided a shape parameter `lambda` which is nonpositive, the function always returns `NaN`', function test( t ) { var y; y = logpmf( 2.0, -1.0 ); - t.equal( isnan( y ), true, 'returns NaN' ); + t.equal( isnan( y ), true, 'returns expected value' ); y = logpmf( 0.0, -1.5 ); - t.equal( isnan( y ), true, 'returns NaN' ); + t.equal( isnan( y ), true, 'returns expected value' ); t.end(); }); From 99853a2e36d0f9f41a00af92c602da4c92095a72 Mon Sep 17 00:00:00 2001 From: Jaysukh-409 Date: Sat, 28 Dec 2024 21:54:57 +0530 Subject: [PATCH 3/5] chore: clean-up --- type: pre_commit_static_analysis_report description: Results of running static analysis checks when committing changes. report: - task: lint_filenames status: passed - task: lint_editorconfig status: passed - task: lint_markdown status: passed - task: lint_package_json status: passed - task: lint_repl_help status: na - task: lint_javascript_src status: na - task: lint_javascript_cli status: na - task: lint_javascript_examples status: passed - task: lint_javascript_tests status: passed - task: lint_javascript_benchmarks status: na - task: lint_python status: passed - task: lint_r status: na - task: lint_c_src status: na - task: lint_c_examples status: na - task: lint_c_benchmarks status: na - task: lint_c_tests_fixtures status: na - task: lint_shell status: na - task: lint_typescript_declarations status: na - task: lint_typescript_tests status: na - task: lint_license_headers status: passed --- --- type: pre_push_report description: Results of running various checks prior to pushing changes. report: - task: run_javascript_examples status: passed - task: run_c_examples status: na - task: run_cpp_examples status: na - task: run_javascript_readme_examples status: passed - task: run_c_benchmarks status: na - task: run_cpp_benchmarks status: na - task: run_fortran_benchmarks status: na - task: run_javascript_benchmarks status: na - task: run_julia_benchmarks status: na - task: run_python_benchmarks status: na - task: run_r_benchmarks status: na - task: run_javascript_tests status: passed --- --- .../@stdlib/stats/base/dists/planck/logpmf/README.md | 12 ++++++------ .../stats/base/dists/planck/logpmf/examples/index.js | 2 +- .../stats/base/dists/planck/logpmf/package.json | 2 +- .../planck/logpmf/test/fixtures/python/runner.py | 2 +- .../base/dists/planck/logpmf/test/test.factory.js | 12 ++++++++++-- .../base/dists/planck/logpmf/test/test.logpmf.js | 6 +++--- 6 files changed, 22 insertions(+), 14 deletions(-) diff --git a/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/README.md b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/README.md index a5de034fe932..c05895dba0f7 100644 --- a/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/README.md +++ b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/README.md @@ -20,7 +20,7 @@ limitations under the License. # Logarithm of Probability Mass Function -> Planck distribution logarithm of [probability mass function][pmf] (PMF). +> Planck (discrete exponential) distribution logarithm of [probability mass function][pmf] (PMF).
@@ -34,7 +34,7 @@ The [probability mass function][pmf] (PMF) for a Planck random variable is defin -where `λ` is the shape parameter. The random variable `X` denotes the count of events in a quantized system. +where `λ` is the shape parameter and `x` denotes the count of events in a quantized system.
@@ -50,7 +50,7 @@ var logpmf = require( '@stdlib/stats/base/dists/planck/logpmf' ); #### logpmf( x, lambda ) -Evaluates the logarithm of the [probability mass function][pmf] (PMF) of a Planck distribution with shape parameter `λ`. +Evaluates the logarithm of the [probability mass function][pmf] (PMF) of a Planck (discrete exponential) distribution with shape parameter `lambda`. ```javascript var y = logpmf( 4.0, 0.3 ); @@ -73,7 +73,7 @@ y = logpmf( 0.0, NaN ); // returns NaN ``` -If provided a shape parameter `λ` which is nonpositive number, the function returns `NaN`. +If provided a shape parameter `lambda` which is nonpositive number, the function returns `NaN`. ```javascript var y = logpmf( 2.0, -1.0 ); @@ -82,7 +82,7 @@ var y = logpmf( 2.0, -1.0 ); #### logpmf.factory( lambda ) -Returns a function for evaluating the logarithm of the [probability mass function][pmf] (PMF) of a Planck distribution with shape parameter `λ`. +Returns a function for evaluating the logarithm of the [probability mass function][pmf] (PMF) of a Planck (discrete exponential) distribution with shape parameter `lambda`. ```javascript var mylogpmf = logpmf.factory( 0.5 ); @@ -118,8 +118,8 @@ var discreteUniform = require( '@stdlib/random/array/discrete-uniform' ); var uniform = require( '@stdlib/random/array/uniform' ); var logpmf = require( '@stdlib/stats/base/dists/planck/logpmf' ); -var lambda = uniform( 10, 0.1, 5.0 ); var x = discreteUniform( 10, 0, 5 ); +var lambda = uniform( 10, 0.1, 5.0 ); var y; var i; diff --git a/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/examples/index.js b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/examples/index.js index caae57cbe996..55ce046775f6 100644 --- a/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/examples/index.js +++ b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/examples/index.js @@ -22,8 +22,8 @@ var discreteUniform = require( '@stdlib/random/array/discrete-uniform' ); var uniform = require( '@stdlib/random/array/uniform' ); var logpmf = require( './../lib' ); -var lambda = uniform( 10, 0.1, 5.0 ); var x = discreteUniform( 10, 0, 5 ); +var lambda = uniform( 10, 0.1, 5.0 ); var y; var i; diff --git a/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/package.json b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/package.json index 5403559719e0..7de8fef1251d 100644 --- a/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/package.json +++ b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/package.json @@ -1,7 +1,7 @@ { "name": "@stdlib/stats/base/dists/planck/logpmf", "version": "0.0.0", - "description": "Planck distribution logarithm of probability mass function (PMF).", + "description": "Planck (discrete exponential) distribution logarithm of probability mass function (PMF).", "license": "Apache-2.0", "author": { "name": "The Stdlib Authors", diff --git a/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/test/fixtures/python/runner.py b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/test/fixtures/python/runner.py index 616300c199bf..fde4c274eae4 100644 --- a/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/test/fixtures/python/runner.py +++ b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/test/fixtures/python/runner.py @@ -74,7 +74,7 @@ def main(): """Generate fixture data.""" # Large shape paramter: x = np.round(np.random.rand(1000) * 10.0) - lam = (np.random.rand(1000) * 10) + 10 + lam = (np.random.rand(1000) * 10.0) + 10.0 gen(x, lam, "large_lambda.json") # Small shape parameter: diff --git a/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/test/test.factory.js b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/test/test.factory.js index f7384708cb50..fc1999fa1f00 100644 --- a/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/test/test.factory.js +++ b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/test/test.factory.js @@ -116,6 +116,14 @@ tape( 'if provided a `lambda` which is nonpositive, the created function always var logpmf; var y; + logpmf = factory( 0.0 ); + + y = logpmf( 2.0 ); + t.equal( isnan( y ), true, 'returns expected value' ); + + y = logpmf( 0.0 ); + t.equal( isnan( y ), true, 'returns expected value' ); + logpmf = factory( -1.5 ); y = logpmf( 2.0 ); @@ -147,7 +155,7 @@ tape( 'the created function evaluates the logpmf for `x` given small `lambda`', t.equal( y, expected[i], 'x: '+x[ i ]+'. lambda: '+lambda[ i ]+', y: '+y+', expected: '+expected[ i ] ); } else { delta = abs( y - expected[ i ] ); - tol = 2.0 * EPS * abs( expected[ i ] ); + tol = 1.0 * EPS * abs( expected[ i ] ); t.ok( delta <= tol, 'within tolerance. x: '+x[ i ]+'. lambda: '+lambda[ i ]+'. y: '+y+'. E: '+expected[ i ]+'. Δ: '+delta+'. tol: '+tol+'.' ); } } @@ -174,7 +182,7 @@ tape( 'the created function evaluates the logpmf for `x` given large `lambda`', t.equal( y, expected[i], 'x: '+x[ i ]+'. lambda: '+lambda[ i ]+', y: '+y+', expected: '+expected[ i ] ); } else { delta = abs( y - expected[ i ] ); - tol = 2.0 * EPS * abs( expected[ i ] ); + tol = 1.0 * EPS * abs( expected[ i ] ); t.ok( delta <= tol, 'within tolerance. x: '+x[ i ]+'. lambda: '+lambda[ i ]+'. y: '+y+'. E: '+expected[ i ]+'. Δ: '+delta+'. tol: '+tol+'.' ); } } diff --git a/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/test/test.logpmf.js b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/test/test.logpmf.js index 6cb9612a43bf..6fba5b92bb76 100644 --- a/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/test/test.logpmf.js +++ b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/test/test.logpmf.js @@ -80,7 +80,7 @@ tape( 'if provided a non-integer for `x` and a valid `lambda`, the function retu tape( 'if provided a shape parameter `lambda` which is nonpositive, the function always returns `NaN`', function test( t ) { var y; - y = logpmf( 2.0, -1.0 ); + y = logpmf( 2.0, 0.0 ); t.equal( isnan( y ), true, 'returns expected value' ); y = logpmf( 0.0, -1.5 ); @@ -107,7 +107,7 @@ tape( 'the function evaluates the logpmf for `x` given small parameter `lambda`' t.equal( y, expected[ i ], 'x: '+x[ i ]+'. lambda:'+lambda[ i ]+', y: '+y+', expected: '+expected[ i ] ); } else { delta = abs( y - expected[ i ] ); - tol = 2.0 * EPS * abs( expected[ i ] ); + tol = 1.0 * EPS * abs( expected[ i ] ); t.ok( delta <= tol, 'within tolerance. x: '+x[ i ]+'. lambda: '+lambda[ i ]+'. y: '+y+'. E: '+expected[ i ]+'. Δ: '+delta+'. tol: '+tol+'.' ); } } @@ -132,7 +132,7 @@ tape( 'the function evaluates the logpmf for `x` given large parameter `lambda`' t.equal( y, expected[ i ], 'x: '+x[ i ]+'. lambda:'+lambda[ i ]+', y: '+y+', expected: '+expected[ i ] ); } else { delta = abs( y - expected[ i ] ); - tol = 2.0 * EPS * abs( expected[ i ] ); + tol = 1.0 * EPS * abs( expected[ i ] ); t.ok( delta <= tol, 'within tolerance. x: '+x[ i ]+'. lambda: '+lambda[ i ]+'. y: '+y+'. E: '+expected[ i ]+'. Δ: '+delta+'. tol: '+tol+'.' ); } } From 5a34c1c735cd6daea99a77d777bd903cb8b46333 Mon Sep 17 00:00:00 2001 From: stdlib-bot <82920195+stdlib-bot@users.noreply.github.com> Date: Thu, 2 Jan 2025 06:55:55 +0000 Subject: [PATCH 4/5] chore: update copyright years --- .../@stdlib/stats/base/dists/planck/logpmf/README.md | 2 +- .../stats/base/dists/planck/logpmf/benchmark/benchmark.js | 2 +- .../stats/base/dists/planck/logpmf/docs/types/index.d.ts | 2 +- .../@stdlib/stats/base/dists/planck/logpmf/docs/types/test.ts | 2 +- .../@stdlib/stats/base/dists/planck/logpmf/examples/index.js | 2 +- .../@stdlib/stats/base/dists/planck/logpmf/lib/factory.js | 2 +- .../@stdlib/stats/base/dists/planck/logpmf/lib/index.js | 2 +- .../@stdlib/stats/base/dists/planck/logpmf/lib/main.js | 2 +- .../base/dists/planck/logpmf/test/fixtures/python/runner.py | 2 +- .../@stdlib/stats/base/dists/planck/logpmf/test/test.factory.js | 2 +- .../@stdlib/stats/base/dists/planck/logpmf/test/test.js | 2 +- .../@stdlib/stats/base/dists/planck/logpmf/test/test.logpmf.js | 2 +- 12 files changed, 12 insertions(+), 12 deletions(-) diff --git a/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/README.md b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/README.md index c05895dba0f7..6ddc43f5ef11 100644 --- a/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/README.md +++ b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/README.md @@ -2,7 +2,7 @@ @license Apache-2.0 -Copyright (c) 2024 The Stdlib Authors. +Copyright (c) 2025 The Stdlib Authors. Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. diff --git a/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/benchmark/benchmark.js b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/benchmark/benchmark.js index b2d161e5cca0..2d48249bfa8f 100644 --- a/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/benchmark/benchmark.js +++ b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/benchmark/benchmark.js @@ -1,7 +1,7 @@ /** * @license Apache-2.0 * -* Copyright (c) 2024 The Stdlib Authors. +* Copyright (c) 2025 The Stdlib Authors. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/docs/types/index.d.ts b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/docs/types/index.d.ts index b8e81981ac43..eb176c4abb50 100644 --- a/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/docs/types/index.d.ts +++ b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/docs/types/index.d.ts @@ -1,7 +1,7 @@ /* * @license Apache-2.0 * -* Copyright (c) 2024 The Stdlib Authors. +* Copyright (c) 2025 The Stdlib Authors. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/docs/types/test.ts b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/docs/types/test.ts index 7052a140ebc7..81f242369484 100644 --- a/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/docs/types/test.ts +++ b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/docs/types/test.ts @@ -1,7 +1,7 @@ /* * @license Apache-2.0 * -* Copyright (c) 2024 The Stdlib Authors. +* Copyright (c) 2025 The Stdlib Authors. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/examples/index.js b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/examples/index.js index 55ce046775f6..5f47a89e33a2 100644 --- a/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/examples/index.js +++ b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/examples/index.js @@ -1,7 +1,7 @@ /** * @license Apache-2.0 * -* Copyright (c) 2024 The Stdlib Authors. +* Copyright (c) 2025 The Stdlib Authors. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/lib/factory.js b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/lib/factory.js index e215504fa8f1..9a02a76317c8 100644 --- a/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/lib/factory.js +++ b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/lib/factory.js @@ -1,7 +1,7 @@ /** * @license Apache-2.0 * -* Copyright (c) 2024 The Stdlib Authors. +* Copyright (c) 2025 The Stdlib Authors. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/lib/index.js b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/lib/index.js index 3f602ad63d6e..79cd172ad66b 100644 --- a/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/lib/index.js +++ b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/lib/index.js @@ -1,7 +1,7 @@ /** * @license Apache-2.0 * -* Copyright (c) 2024 The Stdlib Authors. +* Copyright (c) 2025 The Stdlib Authors. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/lib/main.js b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/lib/main.js index d278a5dea538..be92ba4b2b82 100644 --- a/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/lib/main.js +++ b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/lib/main.js @@ -1,7 +1,7 @@ /** * @license Apache-2.0 * -* Copyright (c) 2024 The Stdlib Authors. +* Copyright (c) 2025 The Stdlib Authors. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/test/fixtures/python/runner.py b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/test/fixtures/python/runner.py index fde4c274eae4..ef5e8160f45f 100644 --- a/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/test/fixtures/python/runner.py +++ b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/test/fixtures/python/runner.py @@ -2,7 +2,7 @@ # # @license Apache-2.0 # -# Copyright (c) 2024 The Stdlib Authors. +# Copyright (c) 2025 The Stdlib Authors. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. diff --git a/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/test/test.factory.js b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/test/test.factory.js index fc1999fa1f00..f7c4851c79db 100644 --- a/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/test/test.factory.js +++ b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/test/test.factory.js @@ -1,7 +1,7 @@ /** * @license Apache-2.0 * -* Copyright (c) 2024 The Stdlib Authors. +* Copyright (c) 2025 The Stdlib Authors. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/test/test.js b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/test/test.js index 0b7ebf6a2ffe..5d2d6e2f6a68 100644 --- a/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/test/test.js +++ b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/test/test.js @@ -1,7 +1,7 @@ /** * @license Apache-2.0 * -* Copyright (c) 2024 The Stdlib Authors. +* Copyright (c) 2025 The Stdlib Authors. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/test/test.logpmf.js b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/test/test.logpmf.js index 6fba5b92bb76..42721405ea14 100644 --- a/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/test/test.logpmf.js +++ b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/test/test.logpmf.js @@ -1,7 +1,7 @@ /** * @license Apache-2.0 * -* Copyright (c) 2024 The Stdlib Authors. +* Copyright (c) 2025 The Stdlib Authors. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. From 3745a55a92b29bab17b9963a7a7f0dcfe5695e41 Mon Sep 17 00:00:00 2001 From: Athan Reines Date: Thu, 2 Jan 2025 00:28:03 -0800 Subject: [PATCH 5/5] chore: clean-up --- type: pre_commit_static_analysis_report description: Results of running static analysis checks when committing changes. report: - task: lint_filenames status: passed - task: lint_editorconfig status: passed - task: lint_markdown status: passed - task: lint_package_json status: passed - task: lint_repl_help status: passed - task: lint_javascript_src status: passed - task: lint_javascript_cli status: na - task: lint_javascript_examples status: na - task: lint_javascript_tests status: passed - task: lint_javascript_benchmarks status: na - task: lint_python status: missing_dependencies - task: lint_r status: na - task: lint_c_src status: na - task: lint_c_examples status: na - task: lint_c_benchmarks status: na - task: lint_c_tests_fixtures status: na - task: lint_shell status: na - task: lint_typescript_declarations status: passed - task: lint_typescript_tests status: passed - task: lint_license_headers status: passed --- --- type: pre_push_report description: Results of running various checks prior to pushing changes. report: - task: run_javascript_examples status: na - task: run_c_examples status: na - task: run_cpp_examples status: na - task: run_javascript_readme_examples status: na - task: run_c_benchmarks status: na - task: run_cpp_benchmarks status: na - task: run_fortran_benchmarks status: na - task: run_javascript_benchmarks status: na - task: run_julia_benchmarks status: na - task: run_python_benchmarks status: na - task: run_r_benchmarks status: na - task: run_javascript_tests status: na --- --- .../stats/base/dists/planck/logpmf/README.md | 2 +- .../base/dists/planck/logpmf/docs/repl.txt | 6 ++-- .../dists/planck/logpmf/docs/types/index.d.ts | 2 +- .../dists/planck/logpmf/docs/types/test.ts | 30 +++++++++---------- .../base/dists/planck/logpmf/lib/index.js | 2 +- .../base/dists/planck/logpmf/package.json | 2 +- .../logpmf/test/fixtures/python/runner.py | 4 +-- .../dists/planck/logpmf/test/test.factory.js | 8 ++--- 8 files changed, 28 insertions(+), 28 deletions(-) diff --git a/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/README.md b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/README.md index 6ddc43f5ef11..bd177c1db4d7 100644 --- a/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/README.md +++ b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/README.md @@ -20,7 +20,7 @@ limitations under the License. # Logarithm of Probability Mass Function -> Planck (discrete exponential) distribution logarithm of [probability mass function][pmf] (PMF). +> Evaluate the logarithm of the [probability mass function][pmf] (PMF) for a Planck (discrete exponential) distribution.
diff --git a/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/docs/repl.txt b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/docs/repl.txt index 905574350098..1ae67dfc813e 100644 --- a/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/docs/repl.txt +++ b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/docs/repl.txt @@ -1,7 +1,7 @@ {{alias}}( x, λ ) - Evaluates the logarithm of the probability mass function (PMF) for a - Planck distribution with shape parameter `λ` at a value `x`. + Evaluates the logarithm of the probability mass function (PMF) for a Planck + distribution with shape parameter `λ` at a value `x`. If provided `NaN` as any argument, the function returns `NaN`. @@ -49,7 +49,7 @@ Returns ------- logpmf: Function - Logarithm of probability mass function (PMF). + Logarithm of the probability mass function (PMF). Examples -------- diff --git a/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/docs/types/index.d.ts b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/docs/types/index.d.ts index eb176c4abb50..387dba3e316d 100644 --- a/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/docs/types/index.d.ts +++ b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/docs/types/index.d.ts @@ -86,7 +86,7 @@ interface LogPMF { } /** -* Planck distribution natural logarithm of probability mass function (PMF). +* Evaluates the natural logarithm of the probability mass function (PMF) for a Planck distribution. * * @param x - input value * @param lambda - shape parameter diff --git a/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/docs/types/test.ts b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/docs/types/test.ts index 81f242369484..344fadf696c9 100644 --- a/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/docs/types/test.ts +++ b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/docs/types/test.ts @@ -23,8 +23,8 @@ import logpmf = require( './index' ); // The function returns a number... { - logpmf( 2, 0.4 ); // $ExpectType number - logpmf( 1, 0.2 ); // $ExpectType number + logpmf( 2.0, 0.4 ); // $ExpectType number + logpmf( 1.0, 0.2 ); // $ExpectType number } // The compiler throws an error if the function is provided values other than two numbers... @@ -36,19 +36,19 @@ import logpmf = require( './index' ); logpmf( {}, 0.4 ); // $ExpectError logpmf( ( x: number ): number => x, 0.2 ); // $ExpectError - logpmf( 0, true ); // $ExpectError - logpmf( 1, false ); // $ExpectError - logpmf( 0, '5' ); // $ExpectError - logpmf( 1, [] ); // $ExpectError - logpmf( 2, {} ); // $ExpectError - logpmf( 3, ( x: number ): number => x ); // $ExpectError + logpmf( 0.0, true ); // $ExpectError + logpmf( 1.0, false ); // $ExpectError + logpmf( 0.0, '5' ); // $ExpectError + logpmf( 1.0, [] ); // $ExpectError + logpmf( 2.0, {} ); // $ExpectError + logpmf( 3.0, ( x: number ): number => x ); // $ExpectError } // The compiler throws an error if the function is provided an unsupported number of arguments... { logpmf(); // $ExpectError - logpmf( 0 ); // $ExpectError - logpmf( 1, 0.3, 4 ); // $ExpectError + logpmf( 0.0 ); // $ExpectError + logpmf( 1.0, 0.3, 4.0 ); // $ExpectError } // Attached to main export is a `factory` method which returns a function... @@ -59,7 +59,7 @@ import logpmf = require( './index' ); // The `factory` method returns a function which returns a number... { const fcn = logpmf.factory( 0.4 ); - fcn( 2 ); // $ExpectType number + fcn( 2.0 ); // $ExpectType number } // The compiler throws an error if the function returned by the `factory` method is provided an invalid argument... @@ -77,8 +77,8 @@ import logpmf = require( './index' ); { const fcn = logpmf.factory( 0.4 ); fcn(); // $ExpectError - fcn( 2, 0 ); // $ExpectError - fcn( 2, 0, 1 ); // $ExpectError + fcn( 2.0, 0.0 ); // $ExpectError + fcn( 2.0, 0.0, 1.0 ); // $ExpectError } // The compiler throws an error if the `factory` method is provided a value other than a number... @@ -93,6 +93,6 @@ import logpmf = require( './index' ); // The compiler throws an error if the `factory` method is provided an unsupported number of arguments... { - logpmf.factory( 0, 0.2 ); // $ExpectError - logpmf.factory( 0, 0.4, 8 ); // $ExpectError + logpmf.factory( 0.0, 0.2 ); // $ExpectError + logpmf.factory( 0.0, 0.4, 8.0 ); // $ExpectError } diff --git a/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/lib/index.js b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/lib/index.js index 79cd172ad66b..1084bd9a8c43 100644 --- a/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/lib/index.js +++ b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/lib/index.js @@ -19,7 +19,7 @@ 'use strict'; /** -* Planck distribution logarithm of probability mass function (PMF). +* Evaluate the logarithm of the probability mass function (PMF) for a Planck distribution. * * @module @stdlib/stats/base/dists/planck/logpmf * diff --git a/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/package.json b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/package.json index 7de8fef1251d..e13245ee25e9 100644 --- a/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/package.json +++ b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/package.json @@ -1,7 +1,7 @@ { "name": "@stdlib/stats/base/dists/planck/logpmf", "version": "0.0.0", - "description": "Planck (discrete exponential) distribution logarithm of probability mass function (PMF).", + "description": "Evaluate the logarithm of the probability mass function (PMF) for a Planck (discrete exponential) distribution.", "license": "Apache-2.0", "author": { "name": "The Stdlib Authors", diff --git a/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/test/fixtures/python/runner.py b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/test/fixtures/python/runner.py index ef5e8160f45f..1ccc2449f54e 100644 --- a/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/test/fixtures/python/runner.py +++ b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/test/fixtures/python/runner.py @@ -43,7 +43,7 @@ def gen(x, lam, name): # Examples ```python - python> x = np.random.rand(1000) * 10 + python> x = np.random.rand(1000) * 10.0 python> lam = np.random.rand(1000) python> gen(x, lam, "data.json") ``` @@ -72,7 +72,7 @@ def gen(x, lam, name): def main(): """Generate fixture data.""" - # Large shape paramter: + # Large shape parameter: x = np.round(np.random.rand(1000) * 10.0) lam = (np.random.rand(1000) * 10.0) + 10.0 gen(x, lam, "large_lambda.json") diff --git a/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/test/test.factory.js b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/test/test.factory.js index f7c4851c79db..c697773630ab 100644 --- a/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/test/test.factory.js +++ b/lib/node_modules/@stdlib/stats/base/dists/planck/logpmf/test/test.factory.js @@ -49,7 +49,7 @@ tape( 'the function returns a function', function test( t ) { t.end(); }); -tape( 'if provided `NaN` for any parameter, the created function returns `NaN`', function test( t ) { +tape( 'if provided `NaN` for any parameter, the returned function returns `NaN`', function test( t ) { var logpmf; var y; @@ -112,7 +112,7 @@ tape( 'if provided a finite `lambda`, the function returns a function which retu t.end(); }); -tape( 'if provided a `lambda` which is nonpositive, the created function always returns `NaN`', function test( t ) { +tape( 'if provided a `lambda` which is nonpositive, the returned function always returns `NaN`', function test( t ) { var logpmf; var y; @@ -135,7 +135,7 @@ tape( 'if provided a `lambda` which is nonpositive, the created function always t.end(); }); -tape( 'the created function evaluates the logpmf for `x` given small `lambda`', function test( t ) { +tape( 'the returned function evaluates the logpmf for `x` given small `lambda`', function test( t ) { var expected; var logpmf; var lambda; @@ -162,7 +162,7 @@ tape( 'the created function evaluates the logpmf for `x` given small `lambda`', t.end(); }); -tape( 'the created function evaluates the logpmf for `x` given large `lambda`', function test( t ) { +tape( 'the returned function evaluates the logpmf for `x` given large `lambda`', function test( t ) { var expected; var logpmf; var lambda;