Skip to main content

Working with the E-series of preferred numbers used for electronic components, such as resistors and capacitors

Project description

The E-series is a system of preferred numbers used with electronic components such as resistors and capacitors. For example, the E6 series contains six values (10, 15, 22, 33, 47, 68) which cover a one-order of magnitude range of values (one decade) from 10 to 99. These base values repeat again to cover the next decade from 100 to 999, as 100, 220, 330, 470, and 680.

This eseries library is useful for selecting values from the standard E3, E6, E12, E24, E48, E96 and E192 decades.

Status

https://travis-ci.org/rob-smallshire/eseries.svg?branch=master

Installation

This package support Python 3 only. To install:

$ pip install eseries

Python Interface

For full help:

>>> import eseries
>>> help(eseries)

In the meantime, here are some highlights.

To find the nearest E24 value to 319 use:

>>> from eseries import find_nearest, E24
>>> find_nearest(E24, 319)
330

To find the next value greater-than or equal-to 184 in the E96 series use:

>>> from eseries import find_greater_than_or_equal, E96
>>> find_greater_than_or_equal(E96, 184)
187

To find a few values around the specified value, use:

>>> from eseries import find_nearest_few, E24
>>> find_nearest_few(E24, 5000)
(4700, 5100, 5600)

Command-Line Interface

There’s also a handy command-line interface. Run eseries --help to see a list of commands:

$ eseries --help
eseries

Usage: eseries [options] <command> [<args> ...]

Options:
  -h --help     Show this screen.
  -v --verbose  Use verbose logging

Available commands:
  ge
  gt
  help
  le
  lt
  nearby
  nearest
  range
  series
  tolerance

See 'eseries help <command>' for help on specific commands.

To find a nearby value, use:

$ eseries nearest E24 37726
39e3

If you prefer an SI exponent symbol, supply --symbol or -s:

$ eseries nearest E24 37726 -s
39 k

To show values around the given value, use the nearby command:

$ eseries nearby E48 52e6 -s
48.7 M
51.1 M
53.6 M

To show the smallest value greater than or equal to the given value, use the ge command:

$ eseries ge E48 52e3 -s
53.6 k

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

eseries-1.1.0.tar.gz (10.1 kB view details)

Uploaded Source

Built Distribution

eseries-1.1.0-py3-none-any.whl (11.5 kB view details)

Uploaded Python 3

File details

Details for the file eseries-1.1.0.tar.gz.

File metadata

  • Download URL: eseries-1.1.0.tar.gz
  • Upload date:
  • Size: 10.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No

File hashes

Hashes for eseries-1.1.0.tar.gz
Algorithm Hash digest
SHA256 45b70c19bc28b4fbc2354c6279f8e52bec7c6895f2a4e5b8f358984092b4fb77
MD5 bcdbbabb4bb7f495ce1959b6469bf6e3
BLAKE2b-256 effe6f986e09e88f489eca7685b08c7b5afd65b70df5888d486ed239dd6d9379

See more details on using hashes here.

File details

Details for the file eseries-1.1.0-py3-none-any.whl.

File metadata

File hashes

Hashes for eseries-1.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 a18c4ac330a546e616e12003d85f564fe40ed96bc0692f6a80e655fc927500c1
MD5 189996460d988e0b7f875715bdfa139f
BLAKE2b-256 c357b1b732ebc3d6d990e9cc148eda08f80590b5340ba7b7e81a84e159165261

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page