Discrete mathematics in the exam at the ShAD

Hello! My name is Azat, I create courses for preparing for the exam in the SHAD. Recently, we launched a course on discrete mathematics, so our team is actively solving problems on the relevant topic. After examining the exam in the SHAD 2019, we saw a great interest of Habr users in entertaining tasks from the exam. Therefore, we post here 4 favorites in discrete mathematics. Enjoy it!



Problem 1 (May 26, 2018, No. 5)


Random value Xequal to the length of the cycle containing simultaneously elements 1 and 2, with a random permutation of the set {1,2,,n}. If there is no such cycle, thenX=0. Find the distribution of a random variableX and her mathematical expectation.


Decision

, , . , XP(X=k)k. — , k, , n!


. . (1 2), k2n2, Cn2k2. , , , (nk)!. , . , , . aa1=b, ab, 1 b( ). , , (k1)!. :


P(X=k)=Cn2k2(nk)!(k1)!n!=k1n(n1)


, k=0k=1. k=1, , (P(X=1)=0, .. , ). , k>n, P(X=k)=0( ). , P(X=0):


P(X=0)=1k=1nk1n(n1)=11n(n1)n(n1)2=112=12


X, :


E(X)=k=1nkk1n(n1)=1n(n1)(k=1nk2k=1nk)=


=1n(n1)(16n(n+1)(2n+1)12n(n+1))=n+13

Problem 2 (June 4, 2016, No. 3)


Random variables Xand Ytake two values ​​and cov(X,Y)=0. Prove that they are independent.


Decision

, , , .


: 0 1, P(X=1)=p, P(Y=1)=q, P(X=1,Y=1)=r. , r=pq. , E(X)=P(X=0)0+P(X=1)1=P(X=1)=p, E(Y)=P(Y=0)0+P(Y=1)1=P(Y=1)=q, E(XY)=P(X=1,Y=1)=r. cov(X,Y)=E(XY)E(X)E(Y)=0, E(XY)=E(X)E(Y)r=pq.


, XY: , ( , : P(X=1,Y=0)=P(X=1)P(X=1,Y=1)=pr, P(X=0,Y=1)=P(Y=1)P(X=1,Y=1)=qr, P(X=0,Y=0)=1P(X=1,Y=1)P(X=0,Y=1)P(X=1,Y=0)). , , .


P(X=a)=p, P(X=b)=1p, P(Y=c)=q, P(Y=d)=1q, a<bc<d. X=XabaY=Ycdc. , Xab, X0 1 , Y. , cov(X,Y)=0, .


E(X)=E(X)aba   E(Y)=E(Y)cdc


E(XY)=E(XabaYcdc)=E(XY)cE(X)aE(Y)+ac(ba)(dc)


cov(X,Y)=E(XY)E(X)E(Y)=E(XY)E(X)E(Y)(ba)(dc)=cov(X,Y)(ba)(dc)


cov(X,Y)=0, cov(X,Y)=0, ...


Problem 3 (May 26, 2018, No. 8)


The magical land of Lelandia has 100 cities, some of which are connected by airlines. It is known that more than 90 airlines depart from each city. Prove that there are 11 cities in pairs connected by airlines with each other.


Decision

, — , — . , 91 , 8 . , , , .


( , ). , , , , .., . . 1 9 , , 1009=11, .


Problem 4 (June 3, 2017, No. 4)


At Tyndex, each employee has at least 50 acquaintances. It turned out that there are two employees who are familiar with each other only after 9 handshakes (that is, the shortest connecting chain of pairwise familiar people contains 8 intermediate people). Prove that this company has at least 200 employees.


Decision

, 10 . Aii- , i |Ai|50.


, A1, A4, A7, A10. , . , |A1A4A7A10|=|A1|+|A4|+|A7|+|A10|200, ...


If you have other ideas for solving problems or any comments, feel free to write to me in telegrams @ Azatik1000. Always happy to answer!


Azat Kalmykov, curator at ShAD Helper


All Articles