Class: Numeric

Inherits:
Object
  • Object
show all
Defined in:
lib/rcad.rb

Instance Method Summary collapse

Instance Method Details

#cmObject



10
11
12
# File 'lib/rcad.rb', line 10

def cm
  self * 10.0
end

#deg_to_radObject



22
23
24
# File 'lib/rcad.rb', line 22

def deg_to_rad
  self * Math::PI / 180
end

#inObject



18
19
20
# File 'lib/rcad.rb', line 18

def in
  self * 25.4
end

#mmObject



6
7
8
# File 'lib/rcad.rb', line 6

def mm
  self
end

#rad_to_degObject



26
27
28
# File 'lib/rcad.rb', line 26

def rad_to_deg
  self * 180 / Math::PI
end

#umObject



14
15
16
# File 'lib/rcad.rb', line 14

def um
  self / 1000.0
end