Function Repository Resource:

# ResistorColorCode

Generate an illustration of resistor color codes from a specified resistance

Contributed by: Jeff Bryant
 ResourceFunction["ResistorColorCode"][resistance,"ColorList"] generates a list of resistor color codes used to represent the specified resistance. ResourceFunction["ResistorColorCode"][resistance,"Graphics"] generates a resistor color code illustration used to represent the specified resistance found in analog electronics. ResourceFunction["ResistorColorCode"][<|"Resistance"→resistance,"Tolerance"→tolerance|>,prop] uses the specified resistance and tolerance.

## Details and Options

Depending on the value provided, ResourceFunction["ResistorColorCode"] may return a pair of illustrations when there are equivalent representations.
ResourceFunction["ResistorColorCode"] takes the same options as Graphics.
Values for tolerance must be one of: 0.05%, .1%, .25%, .5%, 1%, 2%, 5%, 10%.
Since FromResistorColorCode returns a resistance and/or tolerance, this can result in alternate forms for the diagram that do not necessarily match the provided color list. A specified color list may result in a unique resistance and/or tolerance, but this can be represented graphically in multiple ways.

## Examples

### Basic Examples

Generate a list of colors corresponding to a resistor color code for a given resistance:

 In[1]:=
 Out[1]=

Display a graphical representation of the resistor:

 In[2]:=
 Out[2]=

Generate a pair of images when there are two equivalent color code representations:

 In[3]:=
 Out[3]=

Generate a pair of color lists instead of graphics:

 In[4]:=
 Out[4]=

The final stripe represents the tolerance value:

 In[5]:=
 Out[5]=
 In[6]:=
 Out[6]=

Generate color lists including an entry for the tolerance:

 In[7]:=
 Out[7]=

### Options

When "Graphics" is specified, ResistorColorCode accepts the same options as Graphics:

 In[8]:=
 Out[8]=

### Properties and Relations

ResistorColorCode can accept the results of FromResistorColorCode as an argument:

 In[9]:=
 Out[9]=