(poly)
| 729 | return array |
| 730 | } |
| 731 | integrate(poly) { |
| 732 | if (poly.type != 'polynomial') { |
| 733 | throw "TheoremJS: Integrate: Not a polynomial" |
| 734 | } |
| 735 | let values = [] |
| 736 | for (let i in poly.values.reverse()) { |
| 737 | values.push(poly.values[i] / (parseInt(i)+1)) |
| 738 | } |
| 739 | values.reverse() |
| 740 | values.push(0) |
| 741 | const out = values.filter(a => !isNaN(a)) |
| 742 | |
| 743 | return this.polynomial(...out) |
| 744 | } |
| 745 | numeralSolve(f, end, from = -100, to = 100, step = 0.1) { |
| 746 | let buffer = [] |
| 747 | let index = [] |
no test coverage detected