Update example

This commit is contained in:
Iaroslav Postovalov 2020-10-30 16:40:58 +07:00
parent bc4eb95ae7
commit ef7066b8c9
No known key found for this signature in database
GPG Key ID: 46E15E4A31B3BCD7

View File

@ -5,6 +5,7 @@ import kscience.kmath.expressions.invoke
import kscience.kmath.expressions.symbol
import kscience.kmath.kotlingrad.DifferentiableMstExpression
import kscience.kmath.kotlingrad.derivative
import kscience.kmath.kotlingrad.differentiable
import kscience.kmath.operations.RealField
/**
@ -14,7 +15,8 @@ import kscience.kmath.operations.RealField
fun main() {
val x by symbol
val actualDerivative = DifferentiableMstExpression(RealField, "x^2-4*x-44".parseMath())
val actualDerivative = MstExpression(RealField, "x^2-4*x-44".parseMath())
.differentiable()
.derivative(x)
.compile()