tests/testthat/test-solve.R

context("solve")

test_that("solving polynomial", {
    p <- S(~ x^2 - 2*x + 1)
    ans <- solve(p)
    
    expect_true(is(ans, "VecBasic"))
    expect_true(length(ans) == 1)
    expect_true(ans[[1]] == S(1L))
})

## TODO...

Try the symengine package in your browser

Any scripts or data that you put into this service are public.

symengine documentation built on Oct. 23, 2022, 5:06 p.m.