Unlock instant, AI-driven research and patent intelligence for your innovation.

Method for verifying quality of random numbers generated by different program languages

A programming language and random number technology, which is used in the field of testing the quality of random numbers generated by different programming languages, and can solve problems such as inability to obtain random numbers.

Inactive Publication Date: 2010-11-24
张会雄
View PDF0 Cites 1 Cited by
  • Summary
  • Abstract
  • Description
  • Claims
  • Application Information

AI Technical Summary

Problems solved by technology

No matter what kind of computer programming language, only "pseudo-random numbers" can be generated, but random numbers in the absolute sense cannot be obtained

Method used

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
View more

Image

Smart Image Click on the blue labels to locate them in the text.
Viewing Examples
Smart Image
  • Method for verifying quality of random numbers generated by different program languages
  • Method for verifying quality of random numbers generated by different program languages
  • Method for verifying quality of random numbers generated by different program languages

Examples

Experimental program
Comparison scheme
Effect test

Embodiment Construction

[0018] Here we take PHP, MATLAB, and JAVA as examples. Firstly, 20 groups of random numbers are generated by using the random number generation functions of the three programming languages, each group of random numbers is 100,000, and each number is randomly selected within 1-1000. Then use the entropy value calculation formula to calculate the entropy value corresponding to each group of random numbers, see Table 1. Perform a correlation test on the entropy value:

[0019] Table 1, the entropy value distribution table corresponding to the random numbers generated by the random number generation functions of the three programming languages

[0020] Number of groups\Program language

[0021] 4

[0022] ① Draw a scatter diagram of the entropy value, see figure 2 . It can be seen from the figure that the entropy sequence corresponding to the grouped random numbers generated by the three programming languages ​​basically satisfies that the entropy value of...

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to View More

PUM

No PUM Login to View More

Abstract

The invention discloses a method for verifying the quality of random numbers generated by own random number generation functions of different program languages, which belongs to the field of mathematics. In the method, based on the concept of comentropy, the randomness degrees of the random numbers generated by the different program languages are quantitatively measured, and entropies are analyzed and verified so as to conveniently and fast judge quality differences of the random numbers generated by own random number generation functions of the different program languages (such as MATLAB, JAVA, PHP and the like).

Description

technical field [0001] The invention relates to a method for checking the quality of random numbers generated by different programming languages, which belongs to the field of computer applications. Background technique [0002] In engineering and in the medical industry, we often need to write programs based on the Monte Carlo algorithm for simulation calculations. For example, there are two ways to calculate molecular simulations in chemical engineering: MC (Monte Carlo) and MD (Molecular Dynamics). Among them, MC is For the Monte Cano algorithm based on random numbers, another example is the calculation of radiation doses received by different body organs in interventional radiotherapy in the medical industry. There are several commonly used calculation programs (such as MCNP-A GeneralMonte Carlo N-Particle Transport Code ; MCNPX, a general-purpose Monte Carlo radiation transport code for modeling the interaction of radiation with everything, developed by the US LOS ALAMO...

Claims

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to View More

Application Information

Patent Timeline
no application Login to View More
Patent Type & Authority Applications(China)
IPC IPC(8): G06F7/58
Inventor 张会雄李世杰张永康
Owner 张会雄