chordAreaInverse2 = {
const nodes = [
0.5, 0, 2.3584407814e-1, 2.0697979931e-2, 2.0894975402e-3, 1.1722274484e-1,
2.1236567413e-4, 4.6305986706e-1, 5.3748971858e-5, 8.1099031276e-3, 5.8743883731e-2],
values = [
1.5874010464, 1.4053918380, 1.4973407222, 1.4208001108, 1.4086435353, 1.4585411281,
1.4060959864, 1.5737389975, 1.4056733185, 1.4135101277, 1.4374270332],
weights = [
2.5236473233e-1, 3.2702933141e-6, 2.1134869853e-1, -4.5296987518e-2,
-1.8210616414e-3, -2.2914836584e-1, 2.1728601712e-4, -3.3969424647e-1,
-6.8763426681e-5, 1.3707998140e-2, 1.3854310301e-1];
return function chordAreaInverse(a) {
var s = (a <= 0.5) - (a > 0.5), b = (a > 0.5) + s * a, c = Math.cbrt(b);
return s * (reval(nodes, values, weights, b) * c * c - 1);
}
function reval(nodes, values, weights, x) {
var n = nodes.length, p = 0, q = 0, f, j, xj;
for (j = 0; j < n; j++) {
q += xj = weights[j] / (x - nodes[j]);
p += xj * values[j]; }
f = p / q;
if (f !== f) {
for (j = 0; j < n; j++) {
if (x - nodes[j] === 0) {
f = values[j]; break; }}}
return f;
};
}