
Computer Science Computer Science Forum 
 LinkBack  Thread Tools  Display Modes 
April 5th, 2017, 11:53 PM  #1 
Banned Camp Joined: Aug 2011 Posts: 534 Thanks: 2  Random Number Generator program.
Do Random number generator program also generate Negative and Decimal numbers? Thanks & Regards, Prashant S Akerkar 
April 6th, 2017, 12:02 AM  #2 
Senior Member Joined: Feb 2016 From: Australia Posts: 1,830 Thanks: 648 Math Focus: Yet to find out. 
You name it, they got it.

April 6th, 2017, 04:33 AM  #3 
Senior Member Joined: Apr 2014 From: UK Posts: 937 Thanks: 335 
At least it was maths related 
April 6th, 2017, 07:18 AM  #4 
Math Team Joined: Oct 2011 From: Ottawa Ontario, Canada Posts: 14,597 Thanks: 1038 
Well, pick at random 2 integers; assume 372 and 5923 are picked: put 'em, side by side, with decimal point in between: 372.5923 You can be real audacious and add an "or" to get 5923.372 50% of time. DO NOT stop there: add a random "+ or " to get negatives 50% of time... I am tremendously proud of myself for "inventing?" the above. Are you jealous, Dave and Joppy? 
April 6th, 2017, 08:47 AM  #5 
Math Team Joined: Oct 2011 From: Ottawa Ontario, Canada Posts: 14,597 Thanks: 1038 
Ahhh...I see yer ain't jealous Benit; you get my benitiction! 
April 6th, 2017, 08:48 AM  #6  
Senior Member Joined: Apr 2014 From: Glasgow Posts: 2,156 Thanks: 731 Math Focus: Physics, mathematical modelling, numerical and computational solutions  Quote:
Is it possible for computers, which are deterministic machines, to be able to generate nondeterministic numbers? Have fun  
April 7th, 2017, 03:45 AM  #7 
Senior Member Joined: Apr 2014 From: UK Posts: 937 Thanks: 335 
Depends how good the RNG is, it might be more efficient to pick 3725923 and divide by 10000 

Tags 
decimal, generator, negative, number, program, random 
Thread Tools  
Display Modes  

Similar Threads  
Thread  Thread Starter  Forum  Replies  Last Post 
Largest and Smallest Decimal Number Computer program.  prashantakerkar  Applied Math  5  March 31st, 2017 06:46 AM 
I'm Looking For A Random Number Generator With Variable Probabilities  EvanJ  Probability and Statistics  7  October 16th, 2016 07:16 AM 
Random Number Generation  PrayForStan  Number Theory  1  November 28th, 2012 05:08 AM 
Random number generator of different distributions.  oldjack  Advanced Statistics  0  July 11th, 2009 06:30 PM 
Random number generator  grbradt  Advanced Statistics  6  August 7th, 2007 02:21 PM 