STATISTICAL MODELING OF SYSTEMS ON COMPUTER, GENERAL CHARACTERISTIC...

STATISTICAL MODELING OF SYSTEMS ON COMPUTER

In the practice of modeling informatics systems, one often has to deal with objects that in the process of their functioning contain elements of stochasticity or are subjected to stochastic influences of the external environment. Therefore, the main method of obtaining results using simulation models of such stochastic systems is the method of statistical modeling on a computer using limit theorems of probability theory as a theoretical basis. The ability of a model user to obtain the results of statistical modeling of complex systems in conditions of limited machine resources depends on the efficiency of the procedures for generating pseudo-random sequences on the computer, which are the basis for simulating the effects on the elements of the modeled system.

GENERAL CHARACTERISTIC OF THE METHOD OF STATISTICAL MODELING

At the stage of research and design of systems in the construction and implementation of computer models (analytical and simulation), the method of statistical tests (Monte Carlo) is widely used, which is based on the use of random numbers, that is, the possible values ​​of some random variable with a given distribution probabilities. Statistical modeling is a method for obtaining statistical data on the processes occurring in a simulated system using a computer. To obtain interesting estimates of the characteristics of the simulated system I , taking into account the environmental influences & pound; , the statistical data is processed and classified using mathematical statistics methods [10, 13, 18].

The essence of the method of statistical modeling. Thus, the essence of the statistical modeling method is reduced to the construction of a modeling algorithm simulating the behavior and interaction of the elements of the system taking into account the random input influences and environmental influences & pound; and the implementation of this algorithm with the use of software and hardware.

There are two areas of application of the statistical modeling method: 1) to study stochastic systems; 2) for solving deterministic problems. The basic idea that is used to solve deterministic problems by the method of statistical modeling is the replacement of the deterministic problem by an equivalent circuit of some stochastic system, the output characteristics of the latter coincide with the result of solving the deterministic problem. Naturally, with such a replacement, instead of an exact solution of the problem, an approximate solution is obtained and the error decreases with increasing number of tests (realizations of the modeling algorithm) N.

As a result of statistical modeling of system 5, a series of particular values ​​of the unknown quantities or functions are obtained whose statistical processing allows obtaining information about the behavior of a real object or process at arbitrary instants of time. If the number of realizations of N is sufficiently large, then the obtained results of the system simulation acquire statistical stability and can be accepted with sufficient accuracy as estimates of the required characteristics of the process of the system functioning. 5

Theoretical basis of the method of statistical modeling of systems on a computer is limit theorems of probability theory [2, 13]. Sets of random phenomena (events, quantities) are subject to certain regularities that allow them not only to predict their behavior, but also to quantify certain average characteristics of them that exhibit a certain stability. The characteristic regularities are also observed in the distributions of random variables that are formed when multiple actions are combined. The expression of these regularities and the stability of the average indices are the so-called limit theorems of probability theory, some of which are given below in the formulation suitable for practical use in statistical modeling. The fundamental significance of the limit theorems is that they guarantee high quality statistical estimates for a very large number of trials (realizations) N Practically, quantitative estimates of the characteristics of systems that are acceptable for statistical modeling can be obtained already at comparatively small (with using computers) N.

Chebyshev's inequality. For a non-negative function & pound; (& pound;) of the random variable & pound; and any AG & gt; 0 the inequality

In particular, if ^ (0 = - ^) and K = ko (where x is the arithmetic mean;

o is the standard deviation), then

Bernoulli's theorem. If independent trials are carried out, in each of which an event A is carried out with probability p , then the relative frequency of the appearance of the event m/NT as N - »oo converges in probability to for any & pound; & gt; 0

where t is the number of positive test outcomes.

Poisson's theorem. If an independent test is carried out and the probability of the A event occurring in the/-th test is p then the relative frequency of occurrence of the event m/I converges in probability to the mean of the probabilities />>, as n -> oo, ie for any I & gt; About

Chebyshev's theorem. If the independent trials test the values ​​..., x " of a random variable, then for N- * 0o the arithmetic mean of the values ​​of the random variable converges in probability to its mathematical expectation a, ie for any e> 0

The generalized theorem of Chebyshev. If ... - independent random variables with mathematical expectations a 1 , ..., a " and variances a, o%, bounded above by the same pure, then for M -> cc the arithmetic mean of the values ​​of the random variable converges in probability to the average of their mathematical expectations:

Markov's theorem. The expression (4.6) is also valid for dependent random variables { 1e ..., if only

The set of theorems establishing the stability of average indicators is usually called the law of large numbers.

The central limit theorem. If - are independent identically distributed

the limiting random variables having a mathematical expectation a and the variance o, then, as N -> oo, the distribution law of the sum & pound; x, unlimitedly approaches the normal:

Here the probability integral

Laplace's theorem. If in each of the N independent trials the event A appears with probability p then

where t is the number of occurrences of the event A in N trials. The Laplace theorem is a particular case of the central limit theorem.

Examples of statistical modeling. Statistical modeling of systems on a computer requires the formation of values ​​of random variables, which is realized with the help of gauges (generators) of random numbers. Without stopping while on the ways of their implementation for the purposes of computer simulation, let us explain the essence of the statistical modeling method by the following examples.

Example 4.1. It is necessary to find, by the method of statistical modeling, the output characteristics of a certain stochastic system, which is described by the following relations: x = 1 -e "* - input action, e ~ is the effect of the environment, where H and

M [y] of the value y. The dependence of the latter on the input impact x and the external environment

V has the form y = x + r

Fig. 4.1. The structural scheme of the system

As an estimate of the mathematical expectation of A/[y], as follows from the above theorems of probability theory, the arithmetic mean, calculated from the formula

where yI is the random value of the quantity y; N is the number of implementations necessary for the statistical stability of the results.

The structural diagram of the 5 * system is shown in Fig. 4.1.

Here, the elements perform the following functions: computing B.:

squaring K,:

summation C:

square root extraction AND:

The scheme of the algorithm realizing the method of statistical modeling for estimating the M [y] system is shown in Fig. 4.2. Here bA and/7 of the distribution function of the random variables A and q> N - a given number of implementations; Isi - the number of the current implementation; LATsX ( t FI/i & lt; p,;

TYPE OF GENEM BPM [...] - procedures for input of initial data, generation of pseudo-random sequences and output of simulation results, respectively.

Thus, this model allows statistical estimation of the mathematical expectation of the output characteristic M y) of the considered stochastic system by statistical computer simulation. The accuracy and reliability of the interaction results will be determined mainly number of realizations N.

Example 4.2. You need to use the statistical modeling method to find an estimate of the area of ​​the figure (Figure 4.3), bounded by the coordinate axes, the ordinate a = 1 and the curve y -/(a) ; and for the sake of certainty it is assumed that 0 & lt;/() & lt ;! for all a, 0

Fig. 4.2. The scheme of the modeling algorithm of the system

Thus, this problem is purely deterministic and its analytical solution reduces to the calculation of a definite integral, i.e., the desired area of the figure

To solve this deterministic problem by the method of statistical modeling, it is necessary to first construct an adequate stochastic system for estimating the characteristics of the output characteristics that coincide with the ones sought in this deterministic problem. A variant of the structural diagram of such a system is shown in Fig. 4.4, where the elements perform the following functions:

Fig. 4.3. Geometric interpretation of the area estimation of a figure

Fig. 4.4. Structural diagram of the system 5 C

calculation In 2 : S = * h'IN.

The system S D functions as follows: a pair of independent random numbers of the interval (0, 1) is obtained, the coordinate of the point (x it x, + |) shown in Fig. 4.3, the ordinate y = f (x;) is computed and a comparison of the quantities yi is carried out, and where the point (x, x, subf + i) falls into the area of ​​the figure (including the curve f (x)), then the outcome of the test is considered positive 1 and, as a result, it is possible to obtain a statistical estimate of the area of ​​figure 5f for a given number of realizations <

The logic scheme of the modeling algorithm of the probabilistic system S D is shown in Fig. 4.5. Here Rau * f (c) is a given function (tabular curve); N is a given number of realizations;/a/- current implementation number; X & amp; and D7/ah, + 1 ; Hilum, 5 = 5; 5H = A & pound; A, is the summing cell.

Thus, the construction of a stochastic system Hp allows statistical modeling to obtain estimates for a deterministic problem.

Example 4.3. You need to solve the following problem using the statistical modeling method. 5 "10 independent shots are fired on the target, and the probability of hitting one shot is given and equal to p. It is required to estimate the probability that the number of hits on the target will be even, ie, 0, 2, 4, 6, 8, 10.

This problem is probabilistic, and there is its analytical solution:

Fig. 4.5. The scheme of the modeling algorithm of the system 5 0

Fig. 4.6. The structural scheme of the system r

As the object of statistical modeling, we can consider the following probabilistic system, the structure of which is shown in Fig. 4.6, where the elements perform such functions: analysis A.:

The output impact in this system is the event of an even number of hits in a target in a series of ten shots. As an estimate of the output characteristic, the number of tests (series of shots) equal to

find the probability of an even number of hits:

The logical scheme of the statistical simulation algorithm for estimating the sought characteristic of such a system is shown in Fig. 4.7. Here Рвр - the given probability of hit the target with one shot; N - a given number of implementations;

o Given the modeling algorithm, after entering the input data in the implementation of the loop operators, the random number generator is accessed, ie, the values ​​X/of the random variable uniformly distributed in the interval (0, 1) are obtained. The probability of a random variable falling into the interval (0, p), where 1, is equal to the length of this segment, that is, P (x/& lt; p} Therefore, for each shot simulation, the random number X/obtained is compared with a given probability p and X (& lt; p the "target hit" is logged and, otherwise, the "miss." Next, a series of ten trials is modeled, an even number of hits is counted , in each series there is a statistical estimate of the required characteristic P (y).

Thus, the approach using statistical modeling, regardless of the nature of the object of the study (whether it is deterministic or stochastic) is general, and in the statistical modeling of deterministic systems (the system 3n in Example 4.2) it is necessary to first build a stochastic system whose output characteristics allow us to estimate the unknowns.

Note that in all the examples considered, it is not necessary to memorize the entire set of generated random numbers used in the statistical simulation of the system 5. Only the cumulative sum of outcomes and the total number of re -

Fig. 4.7. The scheme of the modeling algorithm of the system of alizations.

This is an important circumstance in general is typical for the implementation of simulation models by statistical modeling on a computer.

thematic pictures

Also We Can Offer!

Other services that we offer

If you don’t see the necessary subject, paper type, or topic in our list of available services and examples, don’t worry! We have a number of other academic disciplines to suit the needs of anyone who visits this website looking for help.

How to ...

We made your life easier with putting together a big number of articles and guidelines on how to plan and write different types of assignments (Essay, Research Paper, Dissertation etc)