Sha256: 7a42c68399513fcd2f7a90ba8645a9557b312a8cf3d53a2d2d49837fd3845c0d
Contents?: true
Size: 647 Bytes
Versions: 3
Compression:
Stored size: 647 Bytes
Contents
require 'qlang/api/matrix_api' require 'qlang/api/vector_api' require 'qlang/api/list_api' require 'qlang/api/func_api' require 'qlang/api/integral_api' module Qlang module Api # TODO: class ::String def rm(str_or_rgx) gsub!(str_or_rgx, '') end def rms(*str_or_rgxs) str_or_rgxs.each do |str_or_rgx| rm(str_or_rgx) end self end end class ::Matrix def to_q q_rows = rows.map { |row| row.join(' ') }.join('; ') "(#{q_rows})" end end class ::Vector def to_q "(#{elements.join(' ')})" end end end end
Version data entries
3 entries across 3 versions & 1 rubygems
Version | Path |
---|---|
qlang-0.0.14142 | lib/qlang/api.rb |
qlang-0.0.1414 | lib/qlang/api.rb |
qlang-0.0.141 | lib/qlang/api.rb |