Reduce.jl Library
Index
Reduce.RExpr
Base.parse
Reduce.ColCheck
Reduce.PrintLog
Reduce.Rational
Reduce.Reset
Reduce.SubCall
Reduce.SubFail
Reduce.SubHold
Reduce.load_package
Reduce.parsegen
Reduce.rcall
Reduce.squash
Reduce.unfoldgen
Reduce Interface
Reduce.Reset
— Function.Reduce.Reset()
Kills the REDUCE process and starts a new instance.
Examples
julia> Reduce.Reset()
Reduce (Free PSL version, revision 4015), 5-May-2017 ...
Reduce.RExpr
— Type.Reduce expression
Summary:
type RExpr <: Any
Fields:
str::Array{Compat.String,1}
Reduce.rcall
— Function.rcall(r::RExpr)
Evaluate a Reduce expression.
Examples
julia> R"int(sin(x), x)" |> RExpr |> rcall
- cos(x)
rcall{T}(e::T)
Evaluate a Julia expression or string using the Reduce interpretor and convert output back into the input type
Examples
julia> rcall("int(sin(y)^2, y)")
"( - cos(y)*sin(y) + y)/2"
julia> rcall(:(int(1/(1+x^2), x)))
:(atan(x))
Base.parse
— Function.Reduce.parse(r::RExpr)
Parse a Reduce expression into a Julia expression
Examples
julia> Reduce.parse(R"sin(i*x)")
:(sin(im * x))
Reduce.load_package
— Function.load_package(::Symbol)
Loads the specified package into REDUCE
Examples
julia> load_package(:rlfi)
Reduce.squash
— Function.squash(expr)
Reduces an entire program statement block using symbolic rewriting
Imported Operators
Reduce switch
modes callable as functions from Julia
expand, complex, factor, horner, expandlog, combinelog, precise, combineexpt, rounded, evallhseq, nat, latex
Reduce operators with multiple arguments
df, int, limit, sum, prod, +, -, ^, *, /, //
Unary operators
abs, conj, factorial, floor, max, min, round, sign, acos, acosh, acot, acoth, acsc, acsch, asec, asech, asin, asinh, atan, atanh, atan2, cos, cosh, cot, coth, csc, csch, exp, hypot, log, log10, sec, sech, sin, sinh, sqrt, tan, tanh, gamma, factorize
beta, besseli, besselj, besselk, bessely, polygamma, zeta
ibeta, igamma, ln, psi, bernoulli, continued_fraction, ci, dilog, ei, si, airy_ai, airy_aiprime, airy_bi, airy_biprime, hanekl1, hankel2, kummerm, kummeru, lommel1, lommel2, struveh, struvel, whittakerm, whittakeru, solidharmonicy, sphericalharmonicy
ceiling, fix, impart, repart, nextprime, euler, fibonacci, motzkin, random, random_new_seed
Tools & Options
Reduce.parsegen
— Function.parsegen(::Symbol,::Symbol)
Parser generator that outputs code to walk and manipulate REDUCE expressions
Reduce.unfoldgen
— Function.unfoldgen(::Symbol,::Symbol)
Parser generator that outputs code to walk and manipulate Julia expressions
Reduce.linefilter
Reduce.Rational
— Function.Reduce.Rational(::Bool)
Toggle whether to use '/' or '//' for division in julia expressions
Reduce.SubCall
— Function.Reduce.SubCall(::Bool)
Toggle whether to substitute additional expressions
Reduce.SubHold
— Function.Reduce.SubHold(::Real)
Sleep timer in case of clogged Reduce pipe on SubCall
Reduce.SubFail
— Function.Reduce.SubFail(::Integer)
Failure limit in case of clogged Reduce pipe on SubCall
Reduce.ColCheck
— Function.Reduce.ColCheck(::Bool)
Toggle whether to reset REPL linewidth on each show
Reduce.PrintLog
— Function.Reduce.PrintLog(::Bool)
Toggle whether to display the log of REDUCE commands