Methods
Attributes
| [R] | q | |
| [R] | r | |
| [R] | s | |
| [R] | t |
Class Public methods
new(q, r, s, t)
Link
Source: show
# File benchmark/bm_so_pidigits.rb, line 41 def initialize (q, r, s, t) @q,@r,@s,@t,@k = q,r,s,t,0 end
Instance Public methods
compose(a)
Link
Source: show
# File benchmark/bm_so_pidigits.rb, line 57 def compose(a) self.class.new( @q * a.q, @q * a.r + r * a.t, @s * a.q + t * a.s, @s * a.r + t * a.t ) end
extract(j)
Link
Source: show
# File benchmark/bm_so_pidigits.rb, line 53 def extract(j) (@q * j + @r) / (@s * j + @t) end