Class: Plurimath::Math::Function::Tr
Instance Attribute Summary
#parameter_one
Instance Method Summary
collapse
#==, #class_name, #initialize, #value_to_asciimath
Instance Method Details
#to_asciimath ⇒ Object
9
10
11
|
# File 'lib/plurimath/math/function/tr.rb', line 9
def to_asciimath
"[#{parameter_one.map(&:to_asciimath).join(',')}]"
end
|
#to_html ⇒ Object
23
24
25
26
|
# File 'lib/plurimath/math/function/tr.rb', line 23
def to_html
first_value = parameter_one.map(&:to_html).join
"<tr>#{first_value}</tr>"
end
|
#to_latex ⇒ Object
17
18
19
20
21
|
# File 'lib/plurimath/math/function/tr.rb', line 17
def to_latex
parameter_one.reject do |td|
td if td.is_a?(Math::Symbol) && td.value == "|"
end.map(&:to_latex).join("&")
end
|
#to_mathml_without_math_tag ⇒ Object
13
14
15
|
# File 'lib/plurimath/math/function/tr.rb', line 13
def to_mathml_without_math_tag
"<mtr>#{parameter_one.map(&:to_mathml_without_math_tag).join}</mtr>"
end
|