SlideShare a Scribd company logo
6
Most read
7
Most read
8
Most read
Welcome
Topic Name : Mid-Square Random Number Generation
Presented By
Md: Arman Hossain
OUTLINE
 Introduction
 Mid-square Method
 Example of Mid-square
 Departures of Mid-square Method
 Applications of Random Numbers
 References
INTRODUCTION
Mid-square method was invented by John von Neumann, and was described at a conference in 1949.
In mathematics, the mid-square method is a method of generating pseudorandom numbers. In practice it is
not a good method since its period is usually very short.
Mid-square Method
1. Starting with n digit number
2. Squaring it
3. For 8 digit : Remove two lower and higher order digit
4. For 7 digit : Remove one lower and two higher order digit
5. Taking n digits in the middle as the next number
6. Repeat from number no. 2.
Example of Mid-square
For an example, we are using 4 digit which is called seed number, we are showing generate 5 random number
here,
5673
1. (5673)2 = 32 1829 29 = 1829
2. (1829)2 = 3 3452 41 = 3452
3. (3452)2 = 11916304 = 9163
4. (9163)2 = 83960569 = 9605
5. (9605)2 = 92256025 = 2560
Remove two
higher order digit
Remove two
lower order digit
Next seed
number
Square seed
number
Remove one
higher order digit
Remove two
lower order digit
Departures of Mid-square Method
Converge on a constant :
 2500
(2500)2 = 6 2500 00 = 2500 This will repeated.
 2504
(2504)2 = 6 2700 16 = 2700
(2700)2 = 7 2900 00 = 2900
(2900)2 = 8 4100 00 = 4100
.
.
(2100)2 = 4 4100 00 = 4100 This will repeated also.
There more constant number like this.
seed
seed
Applications of Random Numbers
 Simulation : when a computer is being used to simulate natural phenomena, random numbers are
required to make things realistic. Simulation covers many fields, from the study of nuclear physics to
operations research.
 Sampling : It is often impractical to examine all possible cases, but a random sample will provide
insight into what constitutes “typical behavior”.
 Numerical analysis : Ingenious techniques for solving complicated numerical problems have been
devised using random numbers.
 Computer programming: Random values make a good source of data for testing the effectiveness of
computer algorithm.
 Decision making : There are reports that many executives make their decisions by flipping a coin or
by throwing darts, etc. It is also rumored that some college professors prepare their grades on such a
basis. Sometimes it is important to make a completely "unbiased decision; this ability is occasionally
useful in computer algorithms, for example in situations where a fixed decision made each time would
cause the algorithm to run more slowly. Randomness is also an essential part of optimal strategies in
the theory of games.
 Recreation : Rolling dice, shuffling decks of cards, spinning roulette wheels, etc., are fascinating
pastimes for just about everybody. These traditional uses of random numbers have suggested the name
"Monte Carlo method," a general term used to describe any algorithm that employs random numbers.
THANK YOU

More Related Content

PPTX
Unit 3 random number generation, random-variate generation
raksharao
 
PPTX
Discrete event simulation
ssusera970cc
 
PPT
Fuzzy relations
naugariya
 
PPTX
Polynomial regression
naveedaliabad
 
PPTX
Np hard
jesal_joshi
 
PPTX
Mid-Point Cirle Drawing Algorithm
Neha Kaurav
 
PPTX
Artificial Intelligence Approaches
Jincy Nelson
 
Unit 3 random number generation, random-variate generation
raksharao
 
Discrete event simulation
ssusera970cc
 
Fuzzy relations
naugariya
 
Polynomial regression
naveedaliabad
 
Np hard
jesal_joshi
 
Mid-Point Cirle Drawing Algorithm
Neha Kaurav
 
Artificial Intelligence Approaches
Jincy Nelson
 

What's hot (20)

PDF
Support Vector Machines ( SVM )
Mohammad Junaid Khan
 
PPTX
Flowshop scheduling
Kunal Goswami
 
PPT
Wavelet transform in image compression
jeevithaelangovan
 
PPTX
GMM
atulnitrkl
 
PPTX
Problem solving agents
Megha Sharma
 
PPTX
Bruteforce algorithm
Rezwan Siam
 
PPTX
Ensemble learning
Haris Jamil
 
PPTX
Halftoning in Computer Graphics
University of Potsdam
 
PPTX
Stochastic Gradient Decent (SGD).pptx
Shubham Jaybhaye
 
PPTX
Naïve Bayes Classifier Algorithm.pptx
Shubham Jaybhaye
 
PPTX
4. random number and it's generating techniques
MdFazleRabbi18
 
PPT
Fuzzy logic ppt
Priya_Srivastava
 
PDF
Working principle of Turing machine
Karan Thakkar
 
PPSX
Perceptron (neural network)
EdutechLearners
 
PPTX
Simulation & Modeling about Telephone System
Md. Taiseen Azam
 
PDF
Naive Bayes
CloudxLab
 
PDF
Bayesian learning
Vignesh Saravanan
 
PPTX
Pattern recognition UNIT 5
Dr. SURBHI SAROHA
 
PDF
Neural Network Toolbox MATLAB
ESCOM
 
Support Vector Machines ( SVM )
Mohammad Junaid Khan
 
Flowshop scheduling
Kunal Goswami
 
Wavelet transform in image compression
jeevithaelangovan
 
Problem solving agents
Megha Sharma
 
Bruteforce algorithm
Rezwan Siam
 
Ensemble learning
Haris Jamil
 
Halftoning in Computer Graphics
University of Potsdam
 
Stochastic Gradient Decent (SGD).pptx
Shubham Jaybhaye
 
Naïve Bayes Classifier Algorithm.pptx
Shubham Jaybhaye
 
4. random number and it's generating techniques
MdFazleRabbi18
 
Fuzzy logic ppt
Priya_Srivastava
 
Working principle of Turing machine
Karan Thakkar
 
Perceptron (neural network)
EdutechLearners
 
Simulation & Modeling about Telephone System
Md. Taiseen Azam
 
Naive Bayes
CloudxLab
 
Bayesian learning
Vignesh Saravanan
 
Pattern recognition UNIT 5
Dr. SURBHI SAROHA
 
Neural Network Toolbox MATLAB
ESCOM
 
Ad

Viewers also liked (20)

PDF
Pseudo Random Number Generators
Darshini Parikh
 
PPT
Random number generation
De La Salle University-Manila
 
PPTX
And or graph problem reduction using predicate logic
Mohanlal Sukhadia University (MLSU)
 
PPT
Simulation As a Method To Support Complex Organizational Transformations in H...
Jos van Hillegersberg
 
PDF
Applying the Scientific Method to Simulation Experiments
Frank Bergmann
 
PDF
EGLACOMM / MEVIA APP TEASER
Dr. Edwin Hernandez
 
PPTX
Eswaran Subrahmanian - Serious Games in Complex Design of Urban Systems and P...
SeriousGamesAssoc
 
PDF
A copula-based Simulation Method for Clustered Multi-State Survival Data
federicorotolo
 
PPTX
Urban simulation by ANN-CA
Davoud Karimzadeh
 
PDF
A368 afa1 b0f8-4b79-812f-980f7dc622bf
Shatabdi Mahanta
 
PDF
Brudaru, o. 2011: cellular genetic algorithm with communicating grids for a d...
ArchiLab 7
 
PDF
Simulation of Urban Mobility (Sumo) For Evaluating Qos Parameters For Vehicul...
iosrjce
 
PDF
Cfms project (asrc)
Michael Davies
 
PDF
A High-speed Verilog HDL Simulation Method using a Lightweight Translator
Ryohei Kobayashi
 
PPT
Games and Serious Games in Urban Planning: Study Cases
Beniamino Murgante
 
PPTX
charge simulation method
dharmendrawaghjipur007
 
PDF
Architecture and urban planning (3 d) representation
Maria Bostenaru
 
PPS
Parallel Simulation of Urban Dynamics on the GPU Ivan Blečić, Arnaldo Cecchi...
Beniamino Murgante
 
PPTX
Spatial Microsimulation for City Modelling, Social Forecasting and Urban Poli...
NeISSProject
 
Pseudo Random Number Generators
Darshini Parikh
 
Random number generation
De La Salle University-Manila
 
And or graph problem reduction using predicate logic
Mohanlal Sukhadia University (MLSU)
 
Simulation As a Method To Support Complex Organizational Transformations in H...
Jos van Hillegersberg
 
Applying the Scientific Method to Simulation Experiments
Frank Bergmann
 
EGLACOMM / MEVIA APP TEASER
Dr. Edwin Hernandez
 
Eswaran Subrahmanian - Serious Games in Complex Design of Urban Systems and P...
SeriousGamesAssoc
 
A copula-based Simulation Method for Clustered Multi-State Survival Data
federicorotolo
 
Urban simulation by ANN-CA
Davoud Karimzadeh
 
A368 afa1 b0f8-4b79-812f-980f7dc622bf
Shatabdi Mahanta
 
Brudaru, o. 2011: cellular genetic algorithm with communicating grids for a d...
ArchiLab 7
 
Simulation of Urban Mobility (Sumo) For Evaluating Qos Parameters For Vehicul...
iosrjce
 
Cfms project (asrc)
Michael Davies
 
A High-speed Verilog HDL Simulation Method using a Lightweight Translator
Ryohei Kobayashi
 
Games and Serious Games in Urban Planning: Study Cases
Beniamino Murgante
 
charge simulation method
dharmendrawaghjipur007
 
Architecture and urban planning (3 d) representation
Maria Bostenaru
 
Parallel Simulation of Urban Dynamics on the GPU Ivan Blečić, Arnaldo Cecchi...
Beniamino Murgante
 
Spatial Microsimulation for City Modelling, Social Forecasting and Urban Poli...
NeISSProject
 
Ad

Similar to Midsquare method- simulation system (20)

PPTX
Random number generation
Vinit Dantkale
 
PPTX
Pseudo Random Number
Hemant Chetwani
 
PPTX
Unit-3 of mathematical foundation of ai ml
nikutiwari70
 
PPTX
2. Modelling and Simulation in computer 2.pptx
waleedhayyakallah
 
PPTX
Ppt
Amit Agarwal
 
PPT
Random Number Generation Conceptual and Practice
htwtrainingonai
 
PDF
AN ALTERNATIVE APPROACH FOR SELECTION OF PSEUDO RANDOM NUMBERS FOR ONLINE EXA...
cscpconf
 
PDF
Fv2510671071
IJERA Editor
 
PPTX
Amanda Sopkin - Computational Randomness: Creating Chaos in an Ordered Machin...
Codemotion
 
PDF
J45015460
IJERA Editor
 
PPT
Lecture06-Random-Number-Genedawrators.ppt
snhskale
 
PPTX
Random_Number_Generation_Algorithms.pptx
gyanarashmi99
 
PPTX
Random number generation
vinay126me
 
PPTX
MT6702 Unit 2 Random Number Generation
Kannappan Subramaniam
 
PDF
Generating random primes
John-André Bjørkhaug
 
PDF
Random number generation (in C++) – past, present and potential future
Pattabi Raman
 
PPTX
Pseudorandom number generators powerpoint
David Roodman
 
PPTX
Teknik Simulasi
Rezzy Caraka
 
PDF
Random number generators
Bob Landstrom
 
PDF
Python Programming - IX. On Randomness
Ranel Padon
 
Random number generation
Vinit Dantkale
 
Pseudo Random Number
Hemant Chetwani
 
Unit-3 of mathematical foundation of ai ml
nikutiwari70
 
2. Modelling and Simulation in computer 2.pptx
waleedhayyakallah
 
Random Number Generation Conceptual and Practice
htwtrainingonai
 
AN ALTERNATIVE APPROACH FOR SELECTION OF PSEUDO RANDOM NUMBERS FOR ONLINE EXA...
cscpconf
 
Fv2510671071
IJERA Editor
 
Amanda Sopkin - Computational Randomness: Creating Chaos in an Ordered Machin...
Codemotion
 
J45015460
IJERA Editor
 
Lecture06-Random-Number-Genedawrators.ppt
snhskale
 
Random_Number_Generation_Algorithms.pptx
gyanarashmi99
 
Random number generation
vinay126me
 
MT6702 Unit 2 Random Number Generation
Kannappan Subramaniam
 
Generating random primes
John-André Bjørkhaug
 
Random number generation (in C++) – past, present and potential future
Pattabi Raman
 
Pseudorandom number generators powerpoint
David Roodman
 
Teknik Simulasi
Rezzy Caraka
 
Random number generators
Bob Landstrom
 
Python Programming - IX. On Randomness
Ranel Padon
 

Recently uploaded (20)

PPTX
Cleaning Validation Ppt Pharmaceutical validation
Ms. Ashatai Patil
 
PPTX
CARE OF UNCONSCIOUS PATIENTS .pptx
AneetaSharma15
 
PPTX
Gupta Art & Architecture Temple and Sculptures.pptx
Virag Sontakke
 
PPTX
Information Texts_Infographic on Forgetting Curve.pptx
Tata Sevilla
 
PPTX
HEALTH CARE DELIVERY SYSTEM - UNIT 2 - GNM 3RD YEAR.pptx
Priyanshu Anand
 
PDF
Review of Related Literature & Studies.pdf
Thelma Villaflores
 
PPTX
Python-Application-in-Drug-Design by R D Jawarkar.pptx
Rahul Jawarkar
 
PPTX
Continental Accounting in Odoo 18 - Odoo Slides
Celine George
 
PPTX
20250924 Navigating the Future: How to tell the difference between an emergen...
McGuinness Institute
 
DOCX
Modul Ajar Deep Learning Bahasa Inggris Kelas 11 Terbaru 2025
wahyurestu63
 
PDF
Module 2: Public Health History [Tutorial Slides]
JonathanHallett4
 
PPTX
Basics and rules of probability with real-life uses
ravatkaran694
 
PDF
What is CFA?? Complete Guide to the Chartered Financial Analyst Program
sp4989653
 
PDF
Health-The-Ultimate-Treasure (1).pdf/8th class science curiosity /samyans edu...
Sandeep Swamy
 
PPTX
How to Track Skills & Contracts Using Odoo 18 Employee
Celine George
 
DOCX
SAROCES Action-Plan FOR ARAL PROGRAM IN DEPED
Levenmartlacuna1
 
PPTX
Artificial Intelligence in Gastroentrology: Advancements and Future Presprec...
AyanHossain
 
PPTX
How to Close Subscription in Odoo 18 - Odoo Slides
Celine George
 
DOCX
pgdei-UNIT -V Neurological Disorders & developmental disabilities
JELLA VISHNU DURGA PRASAD
 
PPTX
Applications of matrices In Real Life_20250724_091307_0000.pptx
gehlotkrish03
 
Cleaning Validation Ppt Pharmaceutical validation
Ms. Ashatai Patil
 
CARE OF UNCONSCIOUS PATIENTS .pptx
AneetaSharma15
 
Gupta Art & Architecture Temple and Sculptures.pptx
Virag Sontakke
 
Information Texts_Infographic on Forgetting Curve.pptx
Tata Sevilla
 
HEALTH CARE DELIVERY SYSTEM - UNIT 2 - GNM 3RD YEAR.pptx
Priyanshu Anand
 
Review of Related Literature & Studies.pdf
Thelma Villaflores
 
Python-Application-in-Drug-Design by R D Jawarkar.pptx
Rahul Jawarkar
 
Continental Accounting in Odoo 18 - Odoo Slides
Celine George
 
20250924 Navigating the Future: How to tell the difference between an emergen...
McGuinness Institute
 
Modul Ajar Deep Learning Bahasa Inggris Kelas 11 Terbaru 2025
wahyurestu63
 
Module 2: Public Health History [Tutorial Slides]
JonathanHallett4
 
Basics and rules of probability with real-life uses
ravatkaran694
 
What is CFA?? Complete Guide to the Chartered Financial Analyst Program
sp4989653
 
Health-The-Ultimate-Treasure (1).pdf/8th class science curiosity /samyans edu...
Sandeep Swamy
 
How to Track Skills & Contracts Using Odoo 18 Employee
Celine George
 
SAROCES Action-Plan FOR ARAL PROGRAM IN DEPED
Levenmartlacuna1
 
Artificial Intelligence in Gastroentrology: Advancements and Future Presprec...
AyanHossain
 
How to Close Subscription in Odoo 18 - Odoo Slides
Celine George
 
pgdei-UNIT -V Neurological Disorders & developmental disabilities
JELLA VISHNU DURGA PRASAD
 
Applications of matrices In Real Life_20250724_091307_0000.pptx
gehlotkrish03
 

Midsquare method- simulation system

  • 2. Topic Name : Mid-Square Random Number Generation Presented By Md: Arman Hossain
  • 3. OUTLINE  Introduction  Mid-square Method  Example of Mid-square  Departures of Mid-square Method  Applications of Random Numbers  References
  • 4. INTRODUCTION Mid-square method was invented by John von Neumann, and was described at a conference in 1949. In mathematics, the mid-square method is a method of generating pseudorandom numbers. In practice it is not a good method since its period is usually very short.
  • 5. Mid-square Method 1. Starting with n digit number 2. Squaring it 3. For 8 digit : Remove two lower and higher order digit 4. For 7 digit : Remove one lower and two higher order digit 5. Taking n digits in the middle as the next number 6. Repeat from number no. 2.
  • 6. Example of Mid-square For an example, we are using 4 digit which is called seed number, we are showing generate 5 random number here, 5673 1. (5673)2 = 32 1829 29 = 1829 2. (1829)2 = 3 3452 41 = 3452 3. (3452)2 = 11916304 = 9163 4. (9163)2 = 83960569 = 9605 5. (9605)2 = 92256025 = 2560 Remove two higher order digit Remove two lower order digit Next seed number Square seed number Remove one higher order digit Remove two lower order digit
  • 7. Departures of Mid-square Method Converge on a constant :  2500 (2500)2 = 6 2500 00 = 2500 This will repeated.  2504 (2504)2 = 6 2700 16 = 2700 (2700)2 = 7 2900 00 = 2900 (2900)2 = 8 4100 00 = 4100 . . (2100)2 = 4 4100 00 = 4100 This will repeated also. There more constant number like this. seed seed
  • 8. Applications of Random Numbers  Simulation : when a computer is being used to simulate natural phenomena, random numbers are required to make things realistic. Simulation covers many fields, from the study of nuclear physics to operations research.  Sampling : It is often impractical to examine all possible cases, but a random sample will provide insight into what constitutes “typical behavior”.  Numerical analysis : Ingenious techniques for solving complicated numerical problems have been devised using random numbers.  Computer programming: Random values make a good source of data for testing the effectiveness of computer algorithm.  Decision making : There are reports that many executives make their decisions by flipping a coin or by throwing darts, etc. It is also rumored that some college professors prepare their grades on such a basis. Sometimes it is important to make a completely "unbiased decision; this ability is occasionally useful in computer algorithms, for example in situations where a fixed decision made each time would cause the algorithm to run more slowly. Randomness is also an essential part of optimal strategies in the theory of games.  Recreation : Rolling dice, shuffling decks of cards, spinning roulette wheels, etc., are fascinating pastimes for just about everybody. These traditional uses of random numbers have suggested the name "Monte Carlo method," a general term used to describe any algorithm that employs random numbers.