UNPKG

@stdlib/constants-float32-two-pi

Version:
53 lines (42 loc) 1.25 kB
/** * @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'; /** * The mathematical constant `π` times `2`. * * @module @stdlib/constants-float32-two-pi * @type {number} * * @example * var FLOAT32_TWO_PI = require( '@stdlib/constants-float32-two-pi' ); * // returns 6.2831854820251465 */ // MODULES // var float64ToFloat32 = require( '@stdlib/number-float64-base-to-float32' ); // MAIN // /** * The mathematical constant `π` times `2`. * * @constant * @type {number} * @default 6.2831854820251465 * @see [Wikipedia]{@link https://en.wikipedia.org/wiki/Pi} */ var FLOAT32_TWO_PI = float64ToFloat32( 6.283185307179586 ); // EXPORTS // module.exports = FLOAT32_TWO_PI;