You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+21Lines changed: 21 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -16,10 +16,31 @@ SymbolicUtils.jl provides various utilities for symbolic computing.
16
16
17
17
[Symbols in SymbolicUtils](https://juliasymbolics.github.io/SymbolicUtils.jl/#creating_symbolic_expressions) carry type information. Operations on them propagate this information. [A rule-based rewriting language](https://juliasymbolics.github.io/SymbolicUtils.jl/#rule-based_rewriting) can be used to find subexpressions that satisfy arbitrary conditions and apply arbitrary transformations on the matches. The library also contains a set of useful [simplification](https://juliasymbolics.github.io/SymbolicUtils.jl/#simplification) rules for expressions of numeric symbols and numbers. These can be remixed and extended for special purposes.
18
18
19
+
19
20
If you are a Julia package develper in need of a rule rewriting system for your own types, have a look at the [interfacing guide](https://juliasymbolics.github.io/SymbolicUtils.jl/interface/).
20
21
21
22
[**Go to the manual**](https://juliasymbolics.github.io/SymbolicUtils.jl/)
22
23
24
+
## "I don't want to read your manual, just show me some cool code"
25
+
```julia
26
+
julia>using SymbolicUtils
27
+
28
+
julia>@syms x::Real y::Real z::Complex
29
+
(x, y, z)
30
+
31
+
julia>2x^2- y + x^2
32
+
(3* (x ^2)) + (-1* y)
33
+
34
+
julia> r =@rulesinh(im *~x) =>sin(~x)
35
+
sinh(im *~x) =>sin(~x)
36
+
37
+
julia>r(sinh(im * y))
38
+
sin(y)
39
+
40
+
julia>simplify(cos(y)^2+sinh(im*y)^2, [r])
41
+
1
42
+
```
43
+
23
44
# Citations
24
45
25
46
- The pattern matcher is an adaption of the one by Gerald Jay Sussman (as seen in [6.945](https://groups.csail.mit.edu/mac/users/gjs/6.945/) at MIT), his use of symbolic programming in the book [SICM](https://groups.csail.mit.edu/mac/users/gjs/6946/sicm-html/book.html) inspired this package.
0 commit comments