Skip to content

genericsoma/SymMath

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

SymMath

Symbolic differentiation using Elixir macros

SymMath.dif macro differentiates an expression with respect to :x atom, which singifies the independent variable.

There is SymMath.simplify macro which tries to perform some simplifications.

Finally, SymMath.d_s macro applies simplification after differentiation.

Only some standard functions and basic differention rules are coded. See the test script for some working examples.

Running mix dif calls d_s on the input.

Examples

> mix dif
Enter an expression: pow(sin(:x), 2)
Differentiated: 2 * sin(:x) * cos(:x)

> mix dif
Enter an expression: pow(:x, 2) + 5 * :x
Differentiated: 2 * :x + 5

About

Symbolic math manipulations using Elixir macros

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages