Resistor Maker in MATLAB

A program that shows you how to arrange given resistors for a desired value!

Al momento, stai seguendo questo contributo

Example: Say you want a 26.5 Ohm resistor and have [1 20 2 3 1 6 3] Ohm resistors on hand...

>> rMaker(26.5,[1 20 2 3 1 6 3], 0)
The first element within tolerance
(((1||1)+6)+20) = 26.5

Where || is a parallel connection and + is a series connection.

You can even give a tolerance!

>> rMaker(16.432,[1 1 10 4 2 2 2], 0.02)
The first element within tolerance
((((((1+2)+2)||2)+1)+4)+10) = 16.4286

Not that fast, but was some fun.

This code also contains a handy function matCount that can tile every combination given to it to vector length n. You can use it to make truth tables, etc.
e.g

>> matCount([1 2], 3)

ans =

1 1 1
1 1 2
1 2 1
1 2 2
2 1 1
2 1 2
2 2 1
2 2 2

>> matCount([1 0], 3)

ans =

0 0 0
0 0 1
0 1 0
0 1 1
1 0 0
1 0 1
1 1 0
1 1 1

Cita come

Josip (2026). Resistor Maker in MATLAB (https://it.mathworks.com/matlabcentral/fileexchange/44283-resistor-maker-in-matlab), MATLAB Central File Exchange. Recuperato .

Informazioni generali

Compatibilità della release di MATLAB

  • Compatibile con qualsiasi release

Compatibilità della piattaforma

  • Windows
  • macOS
  • Linux
Versione Pubblicato Note della release Action
1.0.0.0