Skip to contents

solvify(f, symbol, domain) solves f = 0 with solveset() and returns the solutions as a list; for periodic equations it lists the solutions in one period, as SymPy's solvify(). It returns NULL when the solutions cannot be listed.

Usage

solvify(f, symbol, domain)

Arguments

f

An expression.

symbol

The variable.

domain

The domain, a set.

Value

A list of expressions, or NULL.

Examples

x <- Symbol("x")
solvify(x^2 - 9, x, Reals)
#> [[1]]
#> -3
#> 
#> [[2]]
#> 3
#> 
solvify(sin(x) + 1, x, Reals)
#> [[1]]
#> 3*pi/2
#>