Determination of the uniform distribution of continuous random variables. Uniform continuous distribution in Excel

Determination of the uniform distribution of continuous random variables. Uniform continuous distribution in Excel

Uniform distribution.Random value X.it makes sense of the coordinates of the point selected by the border on the segment

[A, b. Uniform distribution density of random variable X.(Fig. 10.5, but) You can define as:

Fig. 10.5. Uniform distribution of random variable: but - distribution density; b. - Distribution function

Random variable distribution function X. It has the form:

The graph of the uniform distribution function is shown in Fig. 10.5, b.

Laplace transformation of uniform distribution calculated software (10.3):

Mathematical expectation and dispersion are easily calculated directly from the corresponding definitions:

Similar formulas for mathematical expectation and dispersion can also be obtained using Laplace transforms using formulas (10.8), (10.9).

Consider an example of a system system that can be described by uniform distribution.

The movement of transport at the intersection is regulated by an automatic traffic light, in which the green light is lit and 0.5 min - red. Drivers drive up to the intersection at random moments of time with a uniform distribution that are not associated with the work of the traffic light. We find the likelihood that the car will drive the intersection without stopping.

The moment of the passage of the car through the intersection is distributed evenly in the range of 1 + 0.5 \u003d 1.5 minutes. The car will pass through the intersection, without stopping if the moment of travel the intersection falls at the time interval. For a uniformly distributed random variable in the range, the probability of entering the interval is 1 / 1.5 \u003d 2/3. Waiting time r ok eating mixed random value. With a probability of 2/3, it is zero, and with a probability of 0.5 / 1.5 takes any value between 0 and 0.5 min. Consequently, the average time and dispersion of expectations at the intersection

Exponential (indicative) distribution.For exponential distribution, the distribution density of the random variable can be written as:

where a call is called the distribution parameter.

The density schedule of the probability of exponential distribution is given in Fig. 10.6, but.

The distribution function of a random variable with exponential distribution has the form


Fig. 10.6. Exponential distribution of random variable: but - distribution density; b - Distribution function

The graph of the function of the exponential distribution is shown in Fig. 10.6, 6.

The transformation of the Laplace of the exponential distribution by calculating software (10.3):

We show that for a random variable X having an exponential distribution, mathematical expectation is equal to the standard deviation A and back the parameter A ::

Thus, for the exponential distribution we have: you can also show that

those. Exponential distribution is fully characterized by a medium value or parameter. X. .

Exponential distribution has near useful propertiesUsed when modeling service systems. For example, it has no memory. When T.

In other words, if the random value corresponds to the time, the distribution of the remaining duration does not depend on the time that has already passed. This property illustrates Fig. 10.7.


Fig. 10.7.

Consider an example of a system whose functioning parameters can be described by an exponential distribution.

When working some device at random moments of time, faults occur. Time of operation of the device T. From its inclusion, until the fault occurs, distributed by exponential law with the parameter X. When a malfunction is detected, the device immediately enters the repair, which continues the time / 0. We will find the density and function of the distribution of the time of the time g, between two adjacent faults, mathematical expectation and dispersion, as well as the likelihood that time T. H. there will be more 2T 0.

Since, then


Normal distribution.Normal is called the distribution of probabilities of a continuous random variable, which is described by density

From (10.48) it follows that the normal distribution is determined by two parameters - mathematical expectation t. and dispersion A 2. Chart of the probability of a random variable with a normal distribution with t \u003d.0, and 2 \u003d 1 is shown in Fig. 10.8, but.


Fig. 10.8. Normal law of the distribution of random variable when t. \u003d 0, Art 2 \u003d 1: but - probability density; 6 - Distribution function

The distribution function is described by the formula

The graph of the probability distribution function of a normally distributed random variable when t. \u003d 0, and 2 \u003d 1 is shown in Fig. 10.8, b.

We define the likelihood that X.this will take the value owned by the interval (A, P):

where - Laplace function, and the likelihood

that the absolute value of deviation is less than a positive number 6:

In particular, when t \u003d. 0 Equality is true:

As can be seen, a random variable with a normal distribution can take both positive values \u200b\u200band negative. Therefore, to calculate the moments, it is necessary to use the bilateral transformation of Laplace

However, this integral does not necessarily exist. If it exists, instead of (10.50), the expression is usually used

which is called characteristic function or the function of the moments.

Calculate by formula (10.51) the productive function of normal distribution moments:

After converting the numerator of the subexponential expression to the type we get

Integral

since it is an integral of the normal probability density with parameters t + SO 2 And 2. Hence,

Differentiating (10.52), we get

From these expressions you can find moments:

The normal distribution is widespread in practice, since, according to the central limit theorem, if the random value is the sum of a very large number of mutually independent random variables, the influence of each of which is nonstunuously small, it has a distribution close to normal.

Consider an example of a system whose parameters can be described by a normal distribution.

The company manufactures a detail of the specified size. The quality of the details is estimated by measuring its size. Random measurement errors are subordinated to a normal law with an average quadratic deviation. but - Yumkm. We find the likelihood that the measurement error will not exceed 15 μm.

According to (10.49) we find

For the convenience of using the discussed distributions, we will reduce the resulting formulas in Table. 10.1 and 10.2.

Table 10.1. The main characteristics of continuous distributions

Table 10.2. Performing continuous distribution functions

CONTROL QUESTIONS

  • 1. What are the distributions of probabilities relate to continuous?
  • 2. What is the transformation of Laplas Stilletes? What is it used for?
  • 3. How to calculate the moments of random variables using the Laplace-style transformation?
  • 4. What is the lapel transformation of the sum of independent random variables?
  • 5. How to calculate the average time and dispersion of the system transition from one state to another using signal graphs?
  • 6. Give the basic characteristics of the uniform distribution. Give examples of its use in the service tasks.
  • 7. Give the main characteristics of the exponential distribution. Give examples of its use in the service tasks.
  • 8. Give the basic characteristics of the normal distribution. Give examples of its use in the service tasks.

As mentioned earlier, examples of probability distributions continuous random variable X are:

  • uniform distribution of probabilities of a continuous random variable;
  • indicative distribution of probabilities of a continuous random variable;
  • normal distribution probabilities of a continuous random variable.

We will give the concept of uniform and indicative laws of distribution, probability formula and numerical characteristics of the functions under consideration.

IndicatorRanodern distribution lawIndicative distribution law
Definition Uniformly called The distribution of probabilities of a continuous random variable X, the density of which retains a constant value on the segment and has Indicative (exponential) called The distribution of probabilities of a continuous random variable x, which is described by the density having a view

where λ is a constant positive value
Distribution function
Probability hitting interval
Expected value
Dispersion
Average quadratic deviation

Examples of solving problems on the topic "Uniform and indicative laws of distribution"

Task 1.

Buses are strictly scheduled. Movement interval 7 min. Find: a) the likelihood that the passenger approached to the stop will expect another bus for less than two minutes; b) the likelihood that the passenger approached to the stop will expect another bus at least three minutes; c) mathematical expectation and the average quadratic deviation of the random variable x is the passenger waiting time.

Decision. 1. By the condition of the problem, the continuous random value x \u003d (passenger waiting time) uniformly distributed Between the arrival of two buses. The length of the distribution interval of the random variable x is equal to B - a \u003d 7, where a \u003d 0, b \u003d 7.

2. The waiting time will be less than two minutes if the random value x enters the interval (5; 7). The probability of entering the specified interval will find by the formula: P (x 1<Х<х 2)=(х 2 -х 1)/(b-a) .
P (5.< Х < 7) = (7-5)/(7-0) = 2/7 ≈ 0,286.

3. The waiting time will be at least three minutes (i.e. from three to seven min.) If the random value x falls into the interval (0; 4). The probability of entering the specified interval will find by the formula: P (x 1<Х<х 2)=(х 2 -х 1)/(b-a) .
P (0.< Х < 4) = (4-0)/(7-0) = 4/7 ≈ 0,571.

4. The mathematical expectation of a continuous, uniformly distributed random variable X - the passenger's waiting time, we will find by the formula: M (x) \u003d (a + b) / 2. M (x) \u003d (0 + 7) / 2 \u003d 7/2 \u003d 3.5.

5. Average quadratic deviation of a continuous, uniformly distributed random variable X - passenger waiting time, we will find by the formula: σ (x) \u003d √d \u003d (b-a) / 2√3. σ (x) \u003d (7-0) / 2√3 \u003d 7 / 2√3≈2.02.

Task 2.

The indicative distribution is set at x ≥ 0 density F (x) \u003d 5e - 5x. Required: a) write an expression for the distribution function; b) find the likelihood that as a result of test X enters the interval (1; 4); c) find the likelihood that as a result of the test x ≥ 2; d) Calculate m (x), d (x), σ (x).

Decision. 1. Since under the condition is set indicative distribution , from the formula for the density of the probability distribution of the random variable x we \u200b\u200bobtain λ \u003d 5. Then the distribution function will look:

2. The likelihood that as a result of testing X enters the interval (1; 4) will be found by the formula:
P (A.< X < b) = e −λa − e −λb .
P (1.< X < 4) = e −5*1 − e −5*4 = e −5 − e −20 .

3. The likelihood that as a result of the test x ≥ 2 will be found by the formula: P (a< X < b) = e −λa − e −λb при a=2, b=∞.
P (x≥2) \u003d P (1< X < 4) = e −λ*2 − e −λ*∞ = e −2λ − e −∞ = e −2λ - 0 = e −10 (т.к. предел e −х при х стремящемся к ∞ равен нулю).

4. Find for the indicative distribution:

  • mathematical expectation according to the formula m (x) \u003d 1 / λ \u003d 1/5 \u003d 0.2;
  • dispersion by formula D (x) \u003d 1 / λ 2 \u003d 1/25 \u003d 0.04;
  • the average quadratic deviation by the formula σ (x) \u003d 1 / λ \u003d 1/5 \u003d 1.2.

With which many real processes are simulated. And the most such common example is a schedule of public transport. Suppose some bus (Trolleybus / Tram) It goes with an interval of 10 minutes, and at random point of time came to the stop. What is the likelihood that the bus is suitable for 1 minute? Obviously, 1 / 10th. And the likelihood that you have to wait 4-5 minutes? Also . And the likelihood that the bus will have to wait for more than 9 minutes? One tenth!

Consider some finite The gap, even if it is a segment for definition. If a random value possessed permanent probability distribution density on this segment and zero density outside it, then they say that it is distributed evenly. In this case, the density function will be strictly defined:

And in fact, if the length of the segment (see drawing) Makes up, the value inevitably equals - in order to be the unit area of \u200b\u200bthe rectangle, and was observed famous property:


Check it formally:
, bt.p. From a probabilistic point of view, this means that a random value reliably It will take one of the values \u200b\u200bof the segment ..., Eh, we are slowly bored older \u003d)

The essence of uniformity is that whatever interior fixed length We have considered (We remember "Bus" minutes) - The likelihood that a random value will take a value from this gap will be the same. In the drawing, I raised the triethrower of such probabilities - once again focusing that they are determined by squares, not the values \u200b\u200bof the function!

Consider a typical task:

Example 1.

The continuous random value is set by its distribution density:

Find a constant, calculate and make a distribution function. Build graphics. To find

In other words, everything you could only dream :)

Decision: since on the interval (finite interval) , the random value has a uniform distribution, and the "CE" value can be found in a direct formula . But it is better in general - using the property:

... why is it better? So that there are no extra questions;)

Thus, the density function:

Perform a drawing. Values impossible and therefore the fat points are put at the bottom:


As an express check, calculate the area of \u200b\u200bthe rectangle:
, bt.p.

Find expected valueAnd, probably, you already guess what it is equal. Remember the "10-minute" bus: if randomly approach a lot of many days to boat, then average He will have to wait 5 minutes.

Yes, it is that way - the matchmaker must be exactly the contemporary of the "eventful" gap:
, as was supposed.

Dispersion calculated by formula . And here you need an eye yes eye when calculating the integral:

In this way, dispersion:

Make up distribution function . Nothing new here:

1) if, then ;

2) if, then and:

3) and finally , so:

As a result:

Perform a drawing:


On the "live" interval distribution function growing lineloAnd this is another sign that we have a uniformly distributed random value. Well, still, because derivative linear function - There is a constant.

The required probability can be calculated in two ways using the distribution function found:

either using a specific density integral:

Who likes how.

And here you can write answer: ,
The graphs are built along the solution.

... "You can", because for his absence usually do not punish. Usually;)

For calculation and uniform random variance there are special formulas that I suggest you withdraw yourself:

Example 2.

Continuous random value is defined by density .

Calculate the mathematical expectation and dispersion. The results are simplified as much as possible (formulas of abbreviated multiplication to help).

The resulting formulas are convenient to use to check, in particular, check the task that has just broken, substituting the specific values \u200b\u200bof "A" and "B" in them. Summary at the bottom of the page.

And in the conclusion of the lesson, we will analyze a couple of "text" tasks:

Example 3.

The division of the measuring instrument scale is 0.2. The testimony of the device is rounded to the nearest whole division. Considering that rounding errors are uniformly distributed, finding the likelihood that in the next dimension it does not exceed 0.04.

For better understanding solutions Imagine that this is some mechanical device with an arrow, for example, scales with a division of 0.2 kg, and we have to weigh a cat in a bag. But not in order to figure out his fatness - now it will be important where the arrow will stop between two adjacent divisions.

Consider a random amount - distance Arrows OT. nearest left division. Or from the nearest right, it is not fundamentally.

We will make a function of the probability distribution density:

1) Since the distance cannot be negative, then on the interval. Logical.

2) from the condition it follows that the arrow of the scales with equal to probabilitycan stay anywhere between divisions * , including the divisions themselves, and therefore at the interval:

* This is a substantial condition. So, for example, when weighing pieces of cotton wool or kilogram packs of salt, uniformity will be observed at much narrower intervals.

3) and since the distance from the nearest left division can not be greater than 0.2, then at either equal to zero.

In this way:

It should be noted that no one asked us about the density function, and its complete construction I brought exclusively in cognitive circuits. With the county design, only the 2nd point is enough.

Now answer the question of the task. When the rounding error to the nearest division does not exceed 0.04? This will happen when the arrow stops no further than 0.04 from the left division on right or No further than 0.04 on the right division left. In the drawing, I raised the corresponding area:

It remains to find these areas With the help of integrals. In principle, they can be calculated and "School" (as the area of \u200b\u200brectangles), but simplicity does not always find an understanding;)

By the theorem of the addition of probability of incomplete events:

- the likelihood that rounding error does not exceed 0.04 (40 grams for our example)

It is easy to understand that the maximum possible rounding error is 0.1 (100 grams) and therefore the likelihood that rounding error will not exceed 0.1 equal to one. And from this, by the way, follows another, more easily solution of solutions in which it is necessary to consider a random amount - the accuracy of rounding to the nearest division. But the first way I came to mind first :)

Answer: 0,4

And one more thing for the task. In the condition it can be about the errors not rounding, O. random Error measurements themselveswho are usually (but not always), Distributed according to the normal law. In this way, just one word can radically change the decision! Be alert and delve into the meaning of tasks!

And since everything comes in a circle soon, the legs bring us to the same stop:

Example 4.

Buses of some route are strictly on a schedule and intervals of 7 minutes. Create a function of the density of a random variable - the time of waiting for the next bus to the passenger who came to the stop. Find the likelihood that he will wait for the bus no more than three minutes. Find the distribution function and explain its meaningful meaning.

Examples of the laws of the distribution of continuous random variables.

Continuous random x has uniform distribution law On the segment, if its probability density is constant on this segment and is zero outside it.

The density of the probability distribution is a uniformly distributed random variable has the form:

Fig. one. Uniform distribution density schedule

The distribution function of a uniformly distributed random variable has the form:

It is dealing with the uniform distribution law when, according to the conditions of test or experience, the random amount x, which takes values \u200b\u200bin the final gap and all values \u200b\u200bfrom this gap are equal to possible, i.e. None of the values \u200b\u200bhave advantages over others.

For example:

Waiting time at the bus stop - a random X - is evenly distributed on the segment where t. - interval of movement between buses;

Rounding the numbers, when rounding to integer numbers, rounding error is the difference between the initial and rounded value, and this value is evenly distributed on the semi-interval.

Numeric characteristics of a uniformly distributed random variable:

2) Dispersion

Example 1:Bus traffic interval 20 minutes. What is the likelihood that the passenger at the stop will wait for the bus not more than 6 minutes?

Decision:Let a random value of X - the bus waiting time, it is evenly distributed on the segment.

By the condition of the problem of the parameters of the uniform distribution of the value of x:

By determining the uniform distribution in accordance with formula (2), the function of the distribution of the amount of X will look at:

The desired probability is calculated by the formula

Answer:The likelihood that the passenger will be the bus not more than 6 minutes is 0.3.

Example 2:The random value x has a uniform distribution on the segment. Write the density distribution of the value of H.

Decision:

By determining the uniform distribution in accordance with the formula (1), the density of the distribution of the amount of X will look at:

Answer:.

Example 3:The random value x has a uniform distribution on the segment. Record the function of the distribution of the value of H.

Decision:Since the random value X is evenly distributed on the segment, then under the condition of the problem of the distribution parameters x:

By determining the uniform distribution in accordance with formula (2), the density of the distribution of the amount of X will look at:

Example 4:The random value x has a uniform distribution on the segment. Find numerical characteristics of H.


Decision:Since the random value X is evenly distributed on the segment, then under the condition of the problem of the distribution parameters x:

By determining the uniform distribution in accordance with formulas (3), (4) and (5), the number characteristics of the value will be the following:

1) mathematical expectation

2) Dispersion

3) secondary quadratic deviation

Answer:, ,

The continuous random value of X has a uniform distribution on the segment [a, b], if on this segment the density of the distribution is constant, and outside it is equal to 0.

The uniform distribution curve is shown in Fig. 3.13.

Fig. 3.13.

Values \u200b\u200b/ (x) At least but and B plot B) Not specified, since the probability of entering any of these points for a continuous random variable X. equal to 0.

Mathematical expectation of a random variable X having a uniform distribution on the site [a, th], / "\u003d (a + B) / 2. Dispersion is calculated by the formula D \u003d ( a) 2/12, hence the art \u003d (B - a) / 3,464.

Modeling random variables. To simulate a random variable, it is necessary to know its distribution law. The most common method of obtaining a sequence of random numbers distributed according to an arbitrary law is a method based on their formation from the initial sequence of random numbers distributed in the interval (0; 1) according to a uniform law.

Uniformly distributed In the interval (0; 1) of the sequence of random numbers can be obtained in three ways:

  • according to specially prepared random numbers;
  • using physical generators of random numbers (for example, throwing coins);
  • Algorithmic method.

For such numbers, the magnitude of the mathematical expectation should be 0.5, and the dispersion is 1/12. If necessary, the random number X. was in the interval ( but; B) different from (0; 1), you need to use the formula X \u003d a + (l- a) g Where g. - Random number from the interval (0; 1).

Due to the fact that almost all models are implemented on a computer, almost always to obtain random numbers use an algorithmic generator built into the computer, although it is not necessary to use the tables previously translated into electronic form. It should be borne in mind that the algorithmic method we always get pseudo-random numbers, since each subsequent generated number depends on the previous one.

In practice, you always need to get random numbers distributed according to the specified distribution law. This uses a wide variety of methods. If an analytical expression is known for the distribution law F, That can be used the method of inverse functions.

It is enough to play a random number evenly distributed in the range from 0 to 1. Since the function F. also changes in this interval, then a random number X.you can determine the reverse function on schedule or analytically: x \u003d F. "(d). Here g. - the number generated by the amount of HSH in the range from 0 to 1; x T. - generated as a result of a random value. Graphically the essence of the method is depicted in fig. 3.14.


Fig. 3.14. Illustration of a feedback method for generating random events X., the values \u200b\u200bof which are distributed continuously. The figure shows the charts of probability density and integral probability density from h.

Consider as an example exponential distribution law. The distribution function of this law has the form f (x) \u003d 1 -EP (-EG). As g. and F. In this method are assumed similar and arranged in the same interval, then replacing F. on a random number g, we have g. \u003d 1 - EXP (-EG). Expressing the desired value h. From this expression (i.e., reversing the function of the EXR ()), we get x \u003d - / x? 1P (1. -G). Since in the statistical sense (1 - d) and g - This is the same thing. x \u003d -h. 1P (g).

Algorithms for modeling some common laws of distribution of continuous random variables are shown in Table. 3.10.

For example, you need to simulate the time of loading, which is distributed according to the normal law. It is known that the average loading duration is 35 minutes, and the mean square deviation of real-time from the average value is 10 minutes. That is, by the terms of the task t. H. = 35, with H. \u003d 10. Then the value of a random variable will be calculated by the formula R. \u003d? g, where g. - Random numbers from GSH in the range, n \u003d 12. The number 12 is chosen as quite large on the basis of the central limit theorem of the theory of probability (Lyapunov theorems): "For a large number N. random variables X.with any distribution law, their amount is a random number with the normal distribution law. " Then random meaning X. \u003d O (7? - L / 2) + t. H. = 10(7? -3) + 35.

Table 3.10

Random variance modeling algorithms

Modeling a random event. Random event implies that some event has several outcomes and which will occur once again, is determined only by its probability. That is, the outcome is chosen by chance, taking into account its probability. For example, we assume that we know the likelihood of issuing defective products. R \u003d 0.1. It is possible to simulate the loss of this event by playing a uniformly distributed random number from the range from 0 to 1 and setting, in which of the two intervals (from 0 to 0.1 or from 0.1 to 1) it fell (Fig. 3.15). If the number falls in the range (0; 0.1), the marriage is released, i.e. the event happened, otherwise the event did not happen (the conditioned condition). With a significant number of experiments, the frequency of numbers in the interval from 0 to 0.1 will approach the probability P \u003d. 0.1, and the frequency of entering numbers to the interval from 0.1 to 1 will be approached R. \u003d 0.9.


Fig. 3.15.

Events are called non-bedsif the probability of the appearance of these events is simultaneously equal to 0. From here it follows that the total probability of a group of incomplete events is equal to 1. Denote by a R. I, a N. events, and through P] 9 p 2, ..., P P. - The probabilities of the emergence of individual events. Since events are incomplete, then the sum of the probabilities of their loss is 1: P x + p 2 + ... + P n. \u003d 1. We again use for simulating the fallout of one of the events generator of random numbers, the value of which is also always in the range from 0 to 1. We will postpone on a single interval of segments P R P V ..., P p. It is clear that in the sum of the segments will make exactly a single interval. The point corresponding to the resulting number from the generator of random numbers at this interval will indicate one of the segments. Accordingly, in large segments, random numbers will fall more often (the probability of the appearance of these events is greater!), In smaller segments - less often (Fig. 3.16).

If necessary, modeling joint events They must be brought to incomplete. For example, to simulate the appearance of events for which the probabilities are given. P (a () = 0,7; P (A 2) \u003d 0.5 I. P (a] 9 a 2) \u003d 0.4, We define all possible incomprehensible outcomes of events a G A 2 And their simultaneous appearance:

  • 1. Simultaneous appearance of two events P (b () \u003d p (and l , a 2) \u003d 0,4.
  • 2. Event appearance a] p (b 2) \u003d p (and y) - p (A ( , a 2) \u003d 0,7 - 0,4 = 0,3.
  • 3. Event appearance a 2 p (b 3) = P (a 2) - p (a g a 2) \u003d 0,5 - 0,4 = 0,1.
  • 4. Impact not a single event P (B 4) \u003d 1 - (P (b) + P (b 2) + + P (b 3)) =0,2.

Now the likelihood of incomplete events b. It is necessary to represent on the numeric axis in the form of segments. Having obtained with the help of HSH numbers, we determine their belonging to this or that interval and get the implementation of joint events but.

Fig. 3.16.

Often in practice meet random Systems, i.e. such two (or more) various random variables X., W. (And others), which depend on each other. For example, if an event occurred X.and took some random meaning, then the event W. happens, though accidentally, but taking into account the fact that X. Already made some value.

For example, if as X. dropped a large number, then as W. There must also fall a sufficiently large number (if the correlation is positive, and vice versa, if negative). In transport, such dependencies occur quite often. A large delay duration is more likely on substantial length routes, etc.

If random variables are dependent, then

f (x) \u003d f (x l) f (x 2 x l) f (x 3 x 2, x l) - ... - / (xjx, r x, ..., x 2, x t),where x. | x._ V x ( - random dependent values: loss x. provided that they fell x._ (9 x._ (, ..., *,) - conditional density

probability of appearance x. \u003e. If you have fallen x._ (9. ..., x (F (x) - the likelihood of the loss of the vector x random dependent values.

Correlation coefficient q. shows how closely the events are related Hee u If the correlation coefficient is equal to one, then the dependence of events Hee u Mutually unambiguous: one value X.corresponds to one value W. (Fig. 3.17, but) . For q.Close to units, the picture appears, shown in Fig. 3.17, b, i.e. one meaning X.there are already several values \u200b\u200bof y (more precisely, one of several values \u200b\u200bof y, determined randomly); i.e. in this event X. and Y. Less correlated, less dependent on each other.


Fig. 3.17. The type of dependence of two random variables with a positive correlation coefficient: a. - Ply q \u003d. 1; b - at 0 q with q, close to O.

And finally, when the correlation coefficient is striving for zero, a situation in which any meaning arises X. may correspond to any value of y, i.e. events X. and Y. Does not depend or almost independent of each other, do not correlate with each other (Fig. 3.17, in).

For example, take a normal distribution as the most common. The mathematical expectation indicates the most likely events, here the number of events is larger and the graph of events is thicker. Positive correlation indicates that large random variables X. cause to generate big Y. Zero and close to zero correlation shows that the magnitude of the random variable X. Not related to a certain value of random variable Y. Easy to understand what is said, if you imagine the distribution first f (X)and / (y) separately, and then tie them into the system, as presented in Fig. 3.18.

In this example Chill U distributed according to a normal law with the corresponding values t x AI t y, but,. The correlation coefficient of two random events is set. q., i.e. random variables X. And it is dependent on each other, not quite by chance.

Then the possible algorithm for implementing the model will be as follows:

1. Place six random uniformly distributed numbers on the interval: B p b: , B I, B 4, B 5. , b 6; There are their sum S.:

S \u003d ъ. There is a normally distributed random number L: according to the following formula: x \u003d a (5 - 6) + t x.

  • 2. By Formula t! H. = t U. + qOJO X (X --T X) Located mathematical expectation t U1h (sign u / H. It means that it will take random meanings with the condition that * has already accepted some specific meanings).
  • 3. By formula \u003d a d / l - TS 2. There is a rms deviation a ..

4. 12 randomly uniformly distributed on the interval of numbers g; There are their sum to: K \u003d Zr. There is a normally distributed random number w. By the following formula: y \u003d ° JK-6) + M R / x.


Fig. 3.18.

Modeling event flow. When there are a lot of events and they follow each other, they form flow. Note that events should be homogeneous, that is, similar to each other. For example, the appearance of drivers on a gas station wishing to fix their car. That is, homogeneous events form a series. It is believed that the statistical characteristics of this 146

the phenomena (intensity of the flow of events) is set. The intensity of the flow of events indicates how much such events occurs per unit of time. But when it comes to each specific event, it is necessary to determine the methods of modeling. It is important that when we generate, for example, for 200 hours of 1000 events, their number will be approximately the magnitude of the average intensity of the events of 1000/200 \u003d 5 events per hour. This is a statistical value that characterizes this flow as a whole.

The stream intensity in a sense is the mathematical expectation of the number of events per unit of time. But it may actually be that in one hour 4 events will appear, in the other - 6, although there are 5 events per hour on average, therefore one value for the flow characteristics is not enough. The second value characterizing how large the scatter of events relative to the mathematical expectation is, as before, the dispersion. It is this value that determines the accident rate of the event, weak predictability of its appearance.

Random flows are:

  • ordinary - the probability of the simultaneous appearance of two or more events is zero;
  • Stationary - the frequency of events X. constant;
  • without amersion - the probability of the occurrence of a random event does not depend on the moment of the previous events.

When modeling the SMO in the overwhelming number of cases is considered poisson (simplest) stream - ordinary stream without amersion in which the probability of receipt during the period of time t. smooth t. Requirements are given by Poisson's formula:

Poisson flow can be stationary if a. (/) \u003d Const (/), or non-stationary otherwise.

In Poisson Stream, the likelihood that no event comes,

In fig. 3.19 shows addiction R from time. Obviously, the more observation time, the probability that no event will occur, less. In addition, the more important X More coaster there is a graph, that is, the probability is faster. This corresponds to the fact that if the intensity of the events appear is large, the likelihood that the event does not happen, it is rapidly reduced by observation time.

Fig. 3.19.

The probability of at least one event P \u003d. 1 - CHR (-d), since P + P \u003d. It is obvious that the probability of the appearance of at least one event seeks over time to one, i.e., with the corresponding long-term observation, the event will necessarily or later happen. Within the meaning of R equal to g, therefore, expressing / from the definition formula R, Finally, to determine the intervals between two random events we have

where g- evenly distributed from 0 to 1 by a random number, which is obtained by means of HSH; t. - The interval between random events (random value).

As an example, consider the flow of cars arriving at the terminal. Cars come random - on average 8 per day (flow intensity X. \u003d 8/24 aut. / H). It is necessary for CM - 148.

deliver this process for T. \u003d 100 h. The average time interval between cars / \u003d 1 / l. \u003d 24/8 \u003d 3 h.

In fig. 3.20 shows the result of modeling - the time of time when cars came to the terminal. As can be seen, just for the period T \u003d. 100 Terminal Processed N \u003d 33. car. If you start modeling again, then N. may be equal, for example, 34, 35 or 32. But on average TO Algorithm runs N. It will be equal to 33.333.

Fig. 3.20.

If it is known that the flow is not ordinary It is necessary to simulate in addition to the event of the event, the number of events that could appear at this moment is also. For example, cars on the terminal arrive at random moments of time (ordinary stream of cars). But at the same time in cars there may be different (random) amount of cargo. In this case, the flow of cargo is said to be about a thread of extraordinary events.

Consider the task. It is necessary to determine the time of idle of the 1-point equipment on the terminal, if the AUC-1,25 containers are delivered to the terminal. The stream of cars is subject to the law of Poisson, the average interval between cars is 0.5 CD \u003d 1 / 0.5 \u003d 2 aut. / H. The number of containers in the car varies according to a normal law with an average value. t. \u003d 6 I. a \u003d 2.In this case, it can be minimally 2, and the maximum - 10 containers. The unloading time of one container is 4 minutes and 6 minutes is necessary for technological operations. The algorithm for solving this task, built on the principle of consistent wiring of each application, is shown in Fig. 3.21.

After entering the source data, the modeling cycle is launched until the specified model time is reached. With HSH, we obtain a random number, then determine the time interval before the car arrives. We mark the resulting interval on the time axis and simulate the number of containers in the body of the arrived car.

Check the number received on the permissible interval. Next, the discharge time is calculated and is summarized in the total timing of loading equipment. Condition is checked: if the car arrival interval is more unloading time, then the difference between them is summing up in the metering time counter.

Fig. 3.21.

A typical example for the SMO may be the work of a loading point with several posts, as shown in Fig. 3.22.


Fig. 3.22.

For the clarity of the simulation process, we construct a temporary diagram of the SMO operation, reflecting on each line (axis of time /) the state of the individual element of the system (Fig. 3.23). Temporary lines is carried out as much as there are various objects in the SMO (streams). In our example, they are 7: the flow of applications, the waiting flux in the first place in the queue, the flow of expectation in second place in the queue, the service flow in the first channel, the service flow in the second channel, the flow of the applications served, the flow of refused applications. To demonstrate the reference process, we agree that only two cars can be in the load on the loading queue. If they are more, they are sent to another loading point.

Smalled random moments of receipt of car service applications are displayed on the first line. The first application is taken and, since at this moment the channels are free, it is set to maintain the first channel. Request 1 It is transferred to the first channel line. Channel service time is also random. We find in the chart the end of the service ending, postponement of the generated service time from the moment of starting service

and omit the application to the "served" line. The application was held in the SMO all the way. Now it is possible according to the principle of consistent posting of applications as soon as you simulate the path of the second application.


Fig. 3.23.

If at some point it turns out that both channels are busy, then you should establish an application queue. In fig. 3.23 This is an application 3. Note that, according to the terms of the task in the queue, in contrast to the channels, the applications are not random time, and expect when some of the channels are free. After the canal is released, the application rises to the line of the corresponding channel and its maintenance is organized there.

If the weight of the place in the queue at the time when another application comes, will be occupied, the application should be sent to the "refused" line. In fig. 3.23 This is an application 6.

The procedure for simulating applications continues for a while T.. The larger this time, the more accurately there will be simulation results in the future. Really for simple systems choose T., equal to 50-100 hours or more, although sometimes it is better to measure this amount of applications considered.

The analysis of the SMO will spend on the example already considered.

First you need to wait for the steady regime. We fold down the first four applications as uncharacteristic, flowing during the process of installing the system ("time warming time"). We measure the observation time, assume that in our example r \u003d 5 hours. We count the number of applications served in the diagram N. O6C, downtime and other values. As a result, we can calculate the indicators characterizing the quality of the work of the SMO:

  • 1. Probability of service P \u003d n, / n \u003d 5/7 \u003d 0.714. To calculate the probability of servicing the application in the system, it is enough to divide the number of applications that managed to serve during the time T. (see the "Served" line), l / o6c for the number of applications N, who entered the same time.
  • 2. system bandwidth A \u003d njt h \u003d 7/5 \u003d 1.4 aut. / H. To calculate the bandwidth of the system, it is enough to divide the number of serviced applications N O6C. for a while T, For which this service happened.
  • 3. Probability of refusal P \u003d n / n \u003d 3/7 \u003d 0.43. To calculate the worklessness of the reference in service, it is enough to divide the number of applications N. who refused during the time T. (see the "refused" line), the number of applications N, Who wanted to serve during the same time, i.e. they entered the system. Note that the amount P OP + R P (to In the theory should be equal to 1. In fact, it turned out that it was experimentally that P + R. \u003d 0.714 + 0.43 \u003d 1.144. This inaccuracy is explained by the fact that during the observation T. Insufficient statistics have accumulated for the exact response. The error of this indicator is now 14%.
  • 4. The probability of employment of one channel P \u003d T R JT H \u003d 0.05 / 5 \u003d 0.01, where T. - Employment time is only one channel (first or second). The measurements are subject to time segments on which certain events occur. For example, the diagram is searched for such segments when busy or first, or a second channel. In this example, there is one such segment at the end of a diagram with a length of 0.05 hours.
  • 5. The probability of employment of two channels P \u003d t / t \u003d 4.95 / 5 \u003d 0.99. The diagram is searched for such segments, during which the first and second channel are simultaneously occupied. In this example, there are four of these segments, their amount is 4.95 hours.
  • 6. The average number of busy channels: / V to - 0 P 0. + R x + 2P, \u003d \u003d 0.01 +2? 0.99 \u003d 1.99. To calculate how many channels are occupied in the system on average, it is enough to know the share (the probability of employing one channel) and multiply by the weight of this share (one channel), to know the share (the probability of employment of two channels) and multiply by the weight of this share (two channels) and etc. The resulting number 1.99 says that 1,99 channels are loaded on average of two possible channels. This is a high loading rate, 99.5%, the system uses the resources well.
  • 7. The probability of idle at least one channel P *, \u003d g is simple, / r \u003d 0.05 / 5 \u003d 0.01.
  • 8. The probability of downtime of two channels at the same time: P \u003d \u003d t jt \u003d 0.
  • 9. The probability of downtime of the entire system P * \u003d t / t \u003d 0.
  • 10. The average number of applications in the queue / V s \u003d 0 P (H. + 1 P and + 2r k \u003d \u003d 0.34 + 2 0.64 \u003d 1.62 auth. To determine the average number of applications in the queue, it is necessary to determine the probability that in the queue will be one application p, the likelihood of the queue will be two applications of p 2z, etc., and again with the corresponding weights to add them.
  • 11. The likelihood that there will be one application in the queue, P and \u003d. = TJT N \u003d 1.7 / 5 \u003d 0.34 (in total, four such segments in the diagram, in the amount of 1.7 h).
  • 12. The likelihood in the queue will stand at the same time two applications, R K \u003d G 2z / g \u003d 3.2 / 5 \u003d 0.64 (in total, three of these segments in the sum of 3.25 h).
  • 13. The average waiting time of the application in the queue r ore \u003d 1.7 / 4 \u003d 0.425 hours. You need to add all the time intervals, during which any application was in the queue, and divided by the number of applications. On a temporary diagram of such applications 4.
  • 14. Average application time of application 7 'Crowd \u003d 8/5 \u003d 1.6 h. Fold all time intervals during which any application was on service on any channel, and divided by the number of applications.
  • 15. The average time is the application in the system: T. = T. +

g g cf. Soot Wed. OK.

If accuracy is not satisfactory, then you should increase the experiment time and thereby improve the statistics. Can be done differently if you start experiment 154 several times

for a while T. And subsequently averaged the values \u200b\u200bof these experiments, and then again check the results on the accuracy criterion. This procedure should be repeated as long as the NA will be achieved required accuracy.

Analysis of modeling results

Table 3.11

Indicator

Value

indicator

The interests of the owner of the SMO

The interests of the client

Probability

service

The probability of maintenance is small, many customers leave the system without servicing Recommendation: increase the probability of service

The probability of service is small, every third client wants, but the recommendation cannot be served: increase the probability of service

The average number of applications in the queue

Almost always before serving the car stands in the queue Recommendation: increase the number of places in the queue, increase bandwidth

Increase bandwidth to increase the number of places in the queue not to lose potential customers

Customers are interested in a significant increase in bandwidth to reduce waiting time and reduce failures.

To make a decision on the performance of specific activities, it is necessary to analyze the sensitivity of the model. purpose sensitivity analysis model It is to determine the possible deviations of the output characteristics due to changes in the input parameters.

Methods for estimating the sensitivity of the simulation model are similar to the methods for determining the sensitivity of any system. If the output characteristic of the model R Depends on the parameters associated with variable values R =/(PG R 2, P), That changes these

parameters D. p. (/ \u003d 1, ..d) Change change Ar.

In this case, the sensitivity analysis of the model is reduced to the study of sensitivity functions. dr /dr.

As an example of an analysis of the sensitivity of the simulation model, we consider the impact of the change in the variable reliability parameters of the vehicle on the efficiency of operation. As a target function, we use the indicator of the current costs from IR. To analyze sensitivity, we use the operating data for the KAMAZ-5410 road train in urban conditions. Limits change parameters r. To determine the sensitivity of the model, it is sufficient to determine the expert route (Table 3.12).

To carry out the calculations on the model, a base point is selected in which varying parameters have values \u200b\u200bcorresponding to standards. The idle duration parameter when performing maintenance and repair in days is replaced by a specific indicator - simple in days per thousand kilometers N.

The calculation results are shown in Fig. 3.24. The base point is at the intersection of all curves. Shown in Fig. 3.24 dependences make it possible to establish the degree of influence of each of the parameters under consideration by the value of the value of the s. At the same time, the use of natural values \u200b\u200bof the analyzed values \u200b\u200bdoes not allow you to establish a comparative degree of influence of each parameter by 3, the gap as these parameters have different units of measurement. To overcome this, we choose the form of interpretation of the calculation results in relative units. To do this, the base point must be transferred to the beginning of the coordinates, and the values \u200b\u200bof the variable parameters and the relative change in the output characteristics of the model are expressed as a percentage. The results of the transformations are presented in Fig. 3.25.

Table 3.12

Values variable parameters

Fig. 3.24.


Fig. 3.25. The effect of the relative change of variable parameters to the degree of change

Changing the variable parameters relative to the base value is represented on one axis. As can be seen from fig. 3.25, an increase in the value of each parameter near the base point by 50% leads to an increase of 9% of the growth of C A, more than 1.5% of the R, less than 0.5% of N. and to a decrease of 3 almost 4% of the increase L. . Reduction by 25 % B and D RG leads to an increase in the s of more than 6%, respectively. Reduction on the same value of parameters Nt0, C TR and C A leads to a decrease of 0.2, 0.8 and 4.5%, respectively.

The dependences provide an idea of \u200b\u200bthe effect of the individual parameter and can be used when planning the operation of the transport system. By the intensity of influence on s. The considered parameters can be placed in the following order: D, II, L, with 9 N. .

'And 7 k.r 7 tr 7 so

During operation, the change in the value of one indicator entails the change in the values \u200b\u200bof other indicators, with the relative change in each of the variable parameters per and the same value in the general case has an unequal physical basis. It is necessary to replace the relative change in the values \u200b\u200bof the variable parameters in percents along the abscissa axis to be replaced by a parameter that can serve as a single measure to evaluate the degree of change of each parameter. It can be assumed that at each moment of operation of the vehicle, the value of each parameter has the same economic weight relative to the values \u200b\u200bof other variable parameters, i.e., from an economic point of view, the reliability of the vehicle at each moment of time has an equilibrium effect on all related parameters . Then the desired economic equivalent will be time or, more convenient, the year of operation.

In fig. 3.26 Presented dependencies constructed in accordance with the above requirements. For the basic value of occupation, the first year of operation of the vehicle is taken. The values \u200b\u200bof variable parameters for each operation were determined by observation results.


Fig. 3.26.

In the process of operation, an increase in s. For the first three years is primarily due to the growth of values. H. JO, and then, in the considered operating conditions, the main role in reducing the efficiency of the vehicle is plays an increase in values \u200b\u200bwith tr. To identify the influence of the magnitude L KP, In the calculations, its value was equal to the total mileage of the vehicle from the beginning of operation. View of the function 3. \u003d F (L) shows that the intensity of reduction 3 with increasing

etc J. V K.R " 7 NP. J.

1 to p is significantly reduced.

As a result of the analysis of the sensitivity of the model, you can understand which factors need to be influenced to change the target function. To change factors, it is required to make governing efforts, which is associated with the appropriate costs. The cost of costs cannot be infinite, like any resources, these costs in reality are limited. Consequently, it is necessary to understand what amount of funds will be allocated effectively. If in most cases the costs with increasing control exposure grow linearly, then the efficiency of the system is growing rapidly only to some limit, when even significant costs do not give the same return. For example, it is impossible to infinitely increase the power of the serving devices due to restrictions but the area or by the potential number of served cars, etc.

If you compare the increase in costs and the system efficiency indicator in one units, then, as a rule, it will look at the same way as presented in Fig. 3.27.


Fig. 3.27.

From fig. 3.27 It can be seen that when the price of C, per unit of cost Z and the price of C, per unit of indicator R These curves can be folded. Curves are folded if they are required to simultaneously minimize or maximize. If one curve is subject to maximization, and the other is minimized, then their difference should be found, for example, by points. Then the resulting curve (Fig. 3.28), which takes into account the effect of control, and the cost of this will have an extremum. The value of the parameter /?, Delivering the extremum function, is the solution of the synthesis problem.


Fig. 3.28.

to software.

Except management R. and indicator R There are indignation in systems. Disturbance D \u003d (d v d r ...) is an input impact that, unlike the control parameter, does not depend on the will of the owner of the system (Fig. 3.29). For example, low temperatures on the street, competition, unfortunately, reduce the stream of customers; Equipment breakdowns reduce system performance. Managing these values \u200b\u200bdirectly owner system cannot. Usually, the perturbation acts "called" the owner, reducing the effect R from managers efforts R. This is because, in general, the system is created to achieve goals unattainable by themselves in nature. Man, organizing the system, always hopes through it to achieve some goal R. It spends efforts R. In this context, it can be said that the system is an organization of accessible to the person studied by them natural components to achieve some new goal unattainable previously in other ways.

Fig. 3.29.

If we remove the dependence of the indicator R from management R. Once again, but in the face of the perturbation that appeared, the character of the curve will change. Most likely, the indicator will be with the same values \u200b\u200bof the controls below, since the indignation is negative, reducing the system performance. The system provided by herself, without the efforts of the managing nature, ceases to provide a goal to achieve which it was created. If, as before, construct the dependence of costs, relate it to the dependence of the indicator from the control parameter, then the extremum point found will shift (Fig. 3.30) compared with the case "perturbation \u003d 0" (see Fig. 3.28). If you increase the perturbation again, then the curves will change and, as a result, the position of the extremum point will change again.

Schedule in fig. 3.30 binds the R, control (resource) R. and indignation D. In complex systems, indicating how best to act a manager (organization) that makes a solution in the system. If the control action is less optimal, then the total effect will decrease, the situation will arise the situation. If the control exposure is more optimal, the effect will also decrease, as to pay for the que- 162

an increase in management efforts will have to be largely greater than the one you receive as a result of the use of the system.


Fig. 3.30.

The simulation model of the system for actual use must be implemented on the computer. This can be created using the following tools:

  • universal user program Type mathematical (MATLAB) or tabular processor (Excel) or DBMS (Access, FoxPro), which allows you to create only a relatively simple model and requires at least the initial programming skills;
  • universal Programming Language (C ++, Java, Basic, etc.), which allows you to create a model of any complexity; But this is a very time-consuming process that requires writing a large amount of software code and long debugging;
  • specialized Simulation Languagewhich has ready-made templates and visual programming tools designed to quickly create a model base. One of the most famous - UML (Unified Modeling Language);
  • simulation programs, Which are the most popular means of creating imitation models. They allow you to create a model visually, only in the most difficult cases resorting to writing manually program code for procedures and functions.

Programs of imitation modeling are divided into two types:

  • Universal Simulation Packages Designed to create various models and contain a set of functions with which you can simulate typical processes in various destination systems. Popular packages of this type are Arena (developer Rockwell Automation 1, United States), Extendsim (developer Imagine That Ink, USA), AnyLogic (developer XJ Technologies, Russia) and many others. Almost all universal packages have specialized versions for modeling specific classes. objects.
  • Subject-oriented simulation packages Serve for modeling specific types of objects and have a specialized toolkit in the form of templates, masters for visual design of the model from finished modules, etc.
  • Of course, two random numbers cannot uniquely depend on each other, rice. 3.17, apricients for clarity of the concept of correlation. 144.
  • Technical and economic analysis in the reliability of KAMAZ-5410 / Yu cars. Kotikov, I. M. Blankinstein, A. E. Gorez, A. N. Borisenko; Lisi. L .:, 1983. 12 S.-dep. In Tsbnti Manavtotrans RSFSR, No. 135AT-D83.
  • http://www.rockwellautomation.com.
  • http://www.cxtcndsiin.com.
  • http://www.xjtek.com.
Views

Save to classmates Save Vkontakte