class Units::ScaleFunction

Included Modules

Defined in:

units/scale_function.cr

Constructors

Instance Method Summary

Instance methods inherited from module Units::ScaleFunction::Functions

from_cel(x) from_cel, from_degf(x) from_degf, from_degre(x) from_degre, from_hpc(x) from_hpc, from_hpx(x) from_hpx, from_ld(x) from_ld, from_lg(x) from_lg, from_ln(x) from_ln, from_ph(x) from_ph, from_tan100(x) from_tan100, from_two_lg(x) from_two_lg, to_cel(x) to_cel, to_degf(x) to_degf, to_degre(x) to_degre, to_hpc(x) to_hpc, to_hpx(x) to_hpx, to_ld(x) to_ld, to_lg(x) to_lg, to_ln(x) to_ln, to_ph(x) to_ph, to_tan100(x) to_tan100, to_two_lg(x) to_two_lg

Instance methods inherited from class Units::Scale

atoms(*args, **options)
atoms(*args, **options, &)
atoms
, depth : Int32 depth, inspect(io : IO) : Nil inspect, magnitude(scalar = scalar()) magnitude, mode : Mode mode, root_terms : Array(Term) root_terms, scalar(magnitude = value) scalar, special?(*args, **options)
special?(*args, **options, &)
special?
, terms(*args, **options)
terms(*args, **options, &)
terms
, to_s(io, mode : Mode = @mode) : Nil to_s, unit : Unit unit, value : BigDecimal value

Constructor methods inherited from class Units::Scale

new(function_code : String | ScaleFunction::FunctionSelection, value : Number | String, unit : String, search : Mode = Mode::PrimaryCode)
new(value : BigDecimal, unit : Unit = Unit.new)
new(value : BigDecimal, unit : String, mode : Mode = Mode::PrimaryCode)
new(value : Number | String, unit : Unit = Unit.new)
new(value : Number | String, unit : String, mode : Mode = Mode::PrimaryCode)
new(function_code : String | ScaleFunction::FunctionSelection, value : Number | String, unit : Unit = Unit.new)
new

Instance methods inherited from module Units::Compatible

<=>(other) <=>, compatible_with?(other) compatible_with?, composition : Multiset(String) composition, composition_string : String composition_string, dimension dimension

Constructor Detail

def self.new(function_code : String, value, unit = Unit.new) #

[View source]
def self.new(function : FunctionSelection, value, unit = Unit.new) #

[View source]

Instance Method Detail

def function : FunctionSelection #

[View source]
def magnitude(scalar = scalar) #

Get the equivalent magnitude on this scale for a scalar value


[View source]
def scalar(magnitude = value) #

Get the equivalent scalar value of a magnitude on this scale


[View source]