How to convert user-friendly infix math code to Clojure code?

Viewed 1765

I want user to be able to input like this:

5+6*t+sin(2*t)

, so it will get converted to this:

(+ 5 (* 6 t) (sin (* 2 t)))

, so I can eval it to some function that will be JITted and executed efficiently later.

Are there already available libraries (with operator priorities) that works in up-to-date Clojure already?

1 Answers
Related