You can write TeX in Ruby!
Add this line to your application's Gemfile:
gem 'ratex'
And then execute:
$ bundle
Or install it yourself as:
$ gem install ratex
puts Ratex.generate{ f(x, y, t) == 2 * sin(pi / 4 * sqrt(x ** 2 + y ** 2) - pi / 2 * t) }
puts Ratex.generate{ f[n] == f[n - 2] + f[n - 1] }
puts Ratex.generate{ f(x, y) == sum(i == -1, h, a_i(x, y) * g_i(x, y)) }