Sha256: 234e5966d53689792da9680b06c82a7fb849486fa1aab69a88a54a06c9d9f022

Contents?: true

Size: 340 Bytes

Versions: 17

Compression:

Stored size: 340 Bytes

Contents

# -*- encoding: utf-8 -*-
# -*- frozen_string_literal: true -*-
# -*- warn_indent: true -*-

UnitMeasurements::SoundLevel = UnitMeasurements.build do
  primitive "dB"

  system :metric do
    si_unit "B", aliases: ["bel", "bels"]

    unit "Np", value: [(20 / Math.log(10)), "dB"], aliases: ["neper", "nepers"] # (20 / ln(10)) dB
  end
end

Version data entries

17 entries across 17 versions & 2 rubygems

Version Path
unit_measurements_us_complete-5.17.0 lib/unit_measurements/unit_groups/sound_level.rb
unit_measurements-5.17.0 lib/unit_measurements/unit_groups/sound_level.rb
unit_measurements-5.16.0 lib/unit_measurements/unit_groups/sound_level.rb
unit_measurements-5.15.0 lib/unit_measurements/unit_groups/sound_level.rb
unit_measurements-5.14.0 lib/unit_measurements/unit_groups/sound_level.rb
unit_measurements-5.13.0 lib/unit_measurements/unit_groups/sound_level.rb
unit_measurements-5.12.0 lib/unit_measurements/unit_groups/sound_level.rb
unit_measurements-5.11.1 lib/unit_measurements/unit_groups/sound_level.rb
unit_measurements-5.11.0 lib/unit_measurements/unit_groups/sound_level.rb
unit_measurements-5.10.0 lib/unit_measurements/unit_groups/sound_level.rb
unit_measurements-5.9.0 lib/unit_measurements/unit_groups/sound_level.rb
unit_measurements-5.8.0 lib/unit_measurements/unit_groups/sound_level.rb
unit_measurements-5.7.0 lib/unit_measurements/unit_groups/sound_level.rb
unit_measurements-5.6.1 lib/unit_measurements/unit_groups/sound_level.rb
unit_measurements-5.6.0 lib/unit_measurements/unit_groups/sound_level.rb
unit_measurements-5.5.0 lib/unit_measurements/unit_groups/sound_level.rb
unit_measurements-5.4.1 lib/unit_measurements/unit_groups/sound_level.rb