I have to produce a list of combinations which are indicators to fields as I am trying to produce some conditions to interrogate data.I have some code for the combinations from here.
In the example of Power/Torque/Cylinders with a combination of 1,2,4:
I need to work out the combinations of those 3 fields, so the output would be:

So essentially all combinations but not from the same 'bucket' if that makes sense?
Edit: The number of combinations (ie 3 in the example) will change as per the link I provided. The combinations from the link determine which field to look at or use. Eg combination 123 would be the first 3 fields in the image. Combination 1,2 would be tge first 2 and 1,3 would be first and last. I have the code for that.
Now we have the combination buckets, need to work through the combinations across thise fields.
Also I am looking for guidance on how to approach the algo and not necessarily someone to do it for me 😊
As another example, if 1,2,3 were the column combination, the expected output would be:
20-0.5-200
20-0.5-300
20-0.5-400
etc



