# Calculating maximum series/parallel configurations for unique resistors

Say I have 4 unique resistors. How would I calculate all the possible unique series and parallel configurations and thus, calculate all the possible total resistances?

And how can I expand this to accommodate a variable number of resistors?

I first started listing all the possible combinations for 4 resistors, but this was very time consuming and I ended up missing a few valid combinations. Is there some sort of algorithm that can do this?

• A spreadsheet can do this easily Commented Feb 6, 2021 at 15:11
• There's a lot more combinations of 4S, 3S, 3S1P, 2S, 2S+1P, 2S+2P, 1S, 1S+2P, 1S+3P, Commented Feb 6, 2021 at 15:47
• This sounds like a nightmare for a human but a joke for a computer. Rather than trying to make an algorithm to find all possible layouts I'd do that part by hand and then let the computer find all the permutations and weed out duplicate combinations. That said there may be someone around here that knows offhand how to generate the netlists(connection diagrams) too, that's more of a programming problem, so you could take a look at the programming stack exchange (or code golf if you don't mind an algo only one person alive understands lol)
– K H
Commented Feb 7, 2021 at 3:03
• Perhaps read this? The general subject is a very powerful topic area called "generating functions" and Donald Knuth (and a couple of others) have written a book that covers the topic: "Concrete Mathematics: A Foundation for Computer Science," 2nd edition.
– jonk
Commented Feb 7, 2021 at 4:12