Random Numbers Divisible By Random Numbers

omagoodness

Board Regular
Joined
Apr 17, 2016
Messages
64
I am trying to create math practice exercises for my granddaughter. I want to create 2 columns of random even numbers between 2 values. No problem, I can do that. My problem is that I want the random numbers in column B to evenly divide into the corresponding number in column A. I know how to use the MOD function to test the divisibility of the number but I cannot figure out the formula to change the random number if MOD =false. Is this even possible?
 

Excel Facts

Repeat Last Command
Pressing F4 adds dollar signs when editing a formula. When not editing, F4 repeats last command.
It's easier to go backwards i.e.generate the Quotient and Dividend then multiply them to get the Dividend.
Book2
ABC
1DividendDivisorQuotient
29434123
312163238
468409572
524844654
673479379
735885269
813491971
9477953
1015521697
111601016
Sheet5
Cell Formulas
RangeFormula
A2:A11A2=B2#*C2#
B2:C11B2=RANDARRAY(10,,1,100,1)
Dynamic array formulas.
 
Upvote 0
Solution
It's easier to go backwards i.e.generate the Quotient and Dividend then multiply them to get the Dividend.
Book2
ABC
1DividendDivisorQuotient
29434123
312163238
468409572
524844654
673479379
735885269
813491971
9477953
1015521697
111601016
Sheet5
Cell Formulas
RangeFormula
A2:A11A2=B2#*C2#
B2:C11B2=RANDARRAY(10,,1,100,1)
Dynamic array formulas.
I'm not sure I understand all this but I will give it a go and see what happens. Thanks.
 
Upvote 0
I'm saying randomly generate col B and C then multiply them to get A.
Great, I got it now. I just need to determine that upper limit for B & C to keep the value of A less than 50. My granddaughter is just leaning division and only working with small numbers. I can do that by trial and error. Thanks again for your help.
 
Upvote 0
Great, I got it now. I just need to determine that upper limit for B & C to keep the value of A less than 50. My granddaughter is just leaning division and only working with small numbers. I can do that by trial and error. Thanks again for your help.
Did you only want even numbers?
 
Upvote 0
@omagoodness
In future please mark the post as the solution that actually answered your question, instead of your feedback message as it will help future readers. No further action is required for this thread.
 
Upvote 0

Forum statistics

Threads
1,224,557
Messages
6,179,508
Members
452,918
Latest member
Davion615

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top