Math.cosh()
Baseline
Widely available
This feature is well established and works across many devices and browser versions. Itโs been available across browsers since โจ2015๋ 7์โฉ.
Math.cosh()
์ ์ ๋ฉ์๋๋ ์ซ์์ ์๊ณก ์ฝ์ฌ์ธ์ ๋ฐํํฉ๋๋ค. ์ด๋ ์๋์ ๊ฐ์ต๋๋ค.
์๋ํด ๋ณด๊ธฐ
console.log(Math.cosh(0));
// Expected output: 1
console.log(Math.cosh(1));
// Expected output: 1.543080634815244 (approximately)
console.log(Math.cosh(-1));
// Expected output: 1.543080634815244 (approximately)
console.log(Math.cosh(2));
// Expected output: 3.7621956910836314
๊ตฌ๋ฌธ
js
Math.cosh(x)
๋งค๊ฐ ๋ณ์
x
-
์ซ์.
๋ฐํ ๊ฐ
x
์ ์๊ณก ์ฝ์ฌ์ธ.
์ค๋ช
Math
์ ์ ์ ๋ฉ์๋์ด๊ธฐ ๋๋ฌธ์ cosh()
๋ ์์ฑํ Math
๊ฐ์ฒด(Math
๋ ์์ฑ์๊ฐ ์๋๋๋ค)์ ๋ฉ์๋๋ฅผ ์ฌ์ฉํ๊ธฐ๋ณด๋ค๋ ์ธ์ ๋ Math.cosh()
๋ฅผ ์ฌ์ฉํ์ธ์.
์์
Math.cosh() ์ฌ์ฉํ๊ธฐ
js
Math.cosh(-Infinity); // Infinity
Math.cosh(-1); // 1.5430806348152437
Math.cosh(-0); // 1
Math.cosh(0); // 1
Math.cosh(1); // 1.5430806348152437
Math.cosh(Infinity); // Infinity
๋ช ์ธ์
Specification |
---|
ECMAScriptยฎ 2026 Language Specification # sec-math.cosh |
๋ธ๋ผ์ฐ์ ํธํ์ฑ
Loadingโฆ