You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@@ -106,7 +107,7 @@ var OVT = 8.0085662595372944372e-17;
106
107
* x^y = 2^n e^{y^\prime \cdot \mathrm{log2}}
107
108
* ```
108
109
*
109
-
* #### Special Cases
110
+
* ## Special Cases
110
111
*
111
112
* ```tex
112
113
* \begin{align*}
@@ -136,10 +137,10 @@ var OVT = 8.0085662595372944372e-17;
136
137
* ```
137
138
*
138
139
*
139
-
* #### Notes
140
+
* ## Notes
140
141
*
141
-
* - \\(\operatorname{pow}(x,y)\\) returns \\(x^y\\) nearly rounded. In particular, \\(\operatorname{pow}(<\mathrm{integer}>,<\mathrm{integer}>)\\) __always__ returns the correct integer, provided the value is representable.
142
-
* - The hexadecimal values shown in the source code are the intended values for used constants. Decimal values may be used, provided the compiler will accurately convert decimal to binary in order to produce the hexadecimal values.
142
+
* - \\(\operatorname{pow}(x,y)\\) returns \\(x^y\\) nearly rounded. In particular, \\(\operatorname{pow}(<\mathrm{integer}>,<\mathrm{integer}>)\\) __always__ returns the correct integer, provided the value is representable.
143
+
* - The hexadecimal values shown in the source code are the intended values for used constants. Decimal values may be used, provided the compiler will accurately convert decimal to binary in order to produce the hexadecimal values.
143
144
*
144
145
*
145
146
* @param {number} x - base
@@ -191,7 +192,6 @@ function pow( x, y ) {
191
192
vary1;
192
193
varhp;
193
194
varlp;
194
-
varw;
195
195
vart;
196
196
varz;// y prime
197
197
varj;
@@ -200,8 +200,9 @@ function pow( x, y ) {
200
200
returnNaN;
201
201
}
202
202
// Split `y` into high and low words:
203
-
hy=getHighWord(y);
204
-
ly=getLowWord(y);
203
+
toWords(WORDS,y);
204
+
hy=WORDS[0];
205
+
ly=WORDS[1];
205
206
206
207
// Special cases `y`...
207
208
if(ly===0){
@@ -235,8 +236,9 @@ function pow( x, y ) {
235
236
}
236
237
}
237
238
// Split `x` into high and low words:
238
-
hx=getHighWord(x);
239
-
lx=getLowWord(x);
239
+
toWords(WORDS,x);
240
+
hx=WORDS[0];
241
+
lx=WORDS[1];
240
242
241
243
// Special cases `x`...
242
244
if(lx===0){
@@ -328,9 +330,9 @@ function pow( x, y ) {
328
330
z=lp+hp;
329
331
330
332
// Note: *can* be more performant to use `getHighWord` and `getLowWord` directly, but using `toWords` looks cleaner.
0 commit comments