Multiplication factors fo a number

Considering you like that comment: let me share that node:
Multiplication Factors.dyf (5.1 KB)

1 Like

The definition below generates all possible pairs.
The last step provides the pair of smallest numbers

Factors.dyn (13.3 KB)

1 Like

Seems a lot of people already gave a response. Here is a quick python script I made in case it is helpful.

factors.dyn (5.3 KB)

It allows you to put in a step size as an input. Also it should allow you to put the range in the wrong order if you do so on accident. Beware though that since it uses a while loop that could potentially never finish that you should always save first, including your Revit project. For example, if it is impossible to find a number using the step size to return factors within the range, it will go on forever since I never put in any hard stop.

1 Like

One more post. This version will stop itself so there is no infinite looping. It stops once the increasing has reached the point of being more than the max squared, meaning that there will never be a pair of factors within the range.

factors.dyn (5.4 KB)