Uniform Distribution

\dfrac{1}{b-a} \quad a<x<b\\ \;\;0\quad \quad \quad 其他 \end{cases}$$ $$F(x)=\begin{cases} \quad 0\quad \quad \quad \,x<a\\ \dfrac{x-a}{b-a}\quad a\leq x<b\\ \quad 1\quad \quad \quad \,x\geq b \end{cases}$$ <svg xmlns="http://www.w3.org/2000/svg" version="1.1" viewBox="0 0 698.2107444454932 222.6980271056109" width="698.2107444454932" height="222.6980271056109"> <!-- svg-source:excalidraw --> <defs> <style class="style-fonts"> @font-face { font-family: "Virgil"; src: url("https://excalidraw.com/Virgil.woff2"); } @font-face { font-family: "Cascadia"; src: url("https://excalidraw.com/Cascadia.woff2"); } @font-face { font-family: "Assistant"; src: url("https://excalidraw.com/Assistant-Regular.woff2"); } </style> </defs> <rect x="0" y="0" width="698.2107444454932" height="222.6980271056109" fill="#ffffff"></rect><g stroke-linecap="round"><g transform="translate(11.1558195754792 167.45685708326982) rotate(0 149.58841371639357 0.014718154306592623)"><path d="M0.2 1 C50.05 1.19, 249.54 0.16, 299.53 0.02 M-1.16 0.47 C48.54 0.97, 248.6 1.38, 298.77 1.55" stroke="#1e1e1e" stroke-width="1" fill="none"></path></g><g transform="translate(11.1558195754792 167.45685708326982) rotate(0 149.58841371639357 0.014718154306592623)"><path d="M275.26 10.03 C284.84 7.76, 291 5.93, 298.77 1.55 M275.26 10.03 C282.54 7.51, 290.11 5.61, 298.77 1.55" stroke="#1e1e1e" stroke-width="1" fill="none"></path></g><g transform="translate(11.1558195754792 167.45685708326982) rotate(0 149.58841371639357 0.014718154306592623)"><path d="M275.3 -7.07 C284.71 -3.64, 290.86 0.24, 298.77 1.55 M275.3 -7.07 C282.41 -4.32, 289.97 -0.95, 298.77 1.55" stroke="#1e1e1e" stroke-width="1" fill="none"></path></g></g><mask></mask><g stroke-linecap="round"><g transform="translate(120.18368291384309 201.28393681797843) rotate(0 -0.7727579715501633 -89.16394771406567)"><path d="M0.36 -0.01 C0.22 -29.88, -0.08 -148.36, -0.59 -178.23 M-0.92 -1.07 C-1.14 -30.2, -1.12 -147.08, -1.03 -176.64" stroke="#1e1e1e" stroke-width="1" fill="none"></path></g><g transform="translate(120.18368291384309 201.28393681797843) rotate(0 -0.7727579715501633 -89.16394771406567)"><path d="M7.49 -153.14 C4.57 -158.96, 2.06 -169.91, -1.03 -176.64 M7.49 -153.14 C5.86 -157.78, 4.46 -163.96, -1.03 -176.64" stroke="#1e1e1e" stroke-width="1" fill="none"></path></g><g transform="translate(120.18368291384309 201.28393681797843) rotate(0 -0.7727579715501633 -89.16394771406567)"><path d="M-9.61 -153.16 C-7.11 -159.02, -4.21 -169.97, -1.03 -176.64 M-9.61 -153.16 C-7.41 -157.78, -4.97 -163.96, -1.03 -176.64" stroke="#1e1e1e" stroke-width="1" fill="none"></path></g></g><mask></mask><g transform="translate(310.6005226194643 173.13895098013518) rotate(0 7 16.09999999999991)"><text x="0" y="25.760546874999996" font-family="Helvetica, Segoe UI Emoji" font-size="28px" fill="#1e1e1e" text-anchor="start" style="white-space: pre;" direction="ltr" dominant-baseline="alphabetic">x</text></g><g stroke-linecap="round"><g transform="translate(54.68459501502298 90.85371045300008) rotate(0 97.68378330221799 -0.6807290916394777)"><path d="M1.17 -1.19 C33.61 -1.33, 163.32 -0.39, 195.57 -0.53 M0.32 0.8 C32.54 0.29, 162.52 -1.91, 194.73 -2.22" stroke="#1e1e1e" stroke-width="1" fill="none"></path></g></g><mask></mask><g stroke-linecap="round"><g transform="translate(54.34424168717737 92.89585285602243) rotate(0 0.34036454581973885 38.29068047448891)"><path d="M1.04 -0.87 C1 12.13, 0.64 64.56, 0.53 77.46" stroke="#1e1e1e" stroke-width="1.5" fill="none" stroke-dasharray="8 9"></path></g></g><mask></mask><g stroke-linecap="round"><g transform="translate(250.05216161945918 89.49222983377285) rotate(0 0.3403757637936451 40.50303319535624)"><path d="M0.76 -1.01 C0.87 12.29, 1.26 66.88, 1.33 80.72" stroke="#1e1e1e" stroke-width="1.5" fill="none" stroke-dasharray="8 9"></path></g></g><mask></mask><g transform="translate(47.83656041745758 173.7521817312404) rotate(0 7.7861328125 16.09999999999991)"><text x="0" y="25.760546874999996" font-family="Helvetica, Segoe UI Emoji" font-size="28px" fill="#1e1e1e" text-anchor="start" style="white-space: pre;" direction="ltr" dominant-baseline="alphabetic">a</text></g><g transform="translate(246.33680717244056 176.45373033164196) rotate(0 7.7861328125 16.09999999999991)"><text x="0" y="25.760546874999996" font-family="Helvetica, Segoe UI Emoji" font-size="28px" fill="#1e1e1e" text-anchor="start" style="white-space: pre;" direction="ltr" dominant-baseline="alphabetic">b</text></g><g transform="translate(44.90882662695071 16.146602802132747) rotate(0 20.2138671875 16.09999999999991)"><text x="0" y="25.760546874999996" font-family="Helvetica, Segoe UI Emoji" font-size="28px" fill="#1e1e1e" text-anchor="start" style="white-space: pre;" direction="ltr" dominant-baseline="alphabetic">f(x)</text></g><g stroke-linecap="round"><g transform="translate(358.6190180369267 171.50115385723893) rotate(0 149.71399424654658 0.014730510300978494)"><path d="M-0.98 -1.11 C49.23 -1.15, 250.05 -1.04, 300.15 -0.73 M0.71 0.92 C50.92 1.06, 249.88 0.77, 299.59 0.4" stroke="#1e1e1e" stroke-width="1" fill="none"></path></g><g transform="translate(358.6190180369267 171.50115385723893) rotate(0 149.71399424654658 0.014730510300978494)"><path d="M276.13 9.05 C279.24 8.63, 284.76 5.94, 299.59 0.4 M276.13 9.05 C284.13 6.08, 293.8 2.46, 299.59 0.4" stroke="#1e1e1e" stroke-width="1" fill="none"></path></g><g transform="translate(358.6190180369267 171.50115385723893) rotate(0 149.71399424654658 0.014730510300978494)"><path d="M276.06 -8.06 C279.11 -4.88, 284.65 -3.97, 299.59 0.4 M276.06 -8.06 C283.96 -4.92, 293.66 -2.45, 299.59 0.4" stroke="#1e1e1e" stroke-width="1" fill="none"></path></g></g><mask></mask><g stroke-linecap="round"><g transform="translate(467.64688137529083 205.32823359194754) rotate(0 -0.7727579715501633 -89.16394771406567)"><path d="M0.72 -0.76 C0.66 -30.19, -0.82 -148.13, -1.34 -177.65 M-0.35 1.45 C-0.47 -28.22, -2.24 -149.17, -2.19 -179.42" stroke="#1e1e1e" stroke-width="1" fill="none"></path></g><g transform="translate(467.64688137529083 205.32823359194754) rotate(0 -0.7727579715501633 -89.16394771406567)"><path d="M6.54 -155.99 C3.58 -160.72, 4.07 -167.66, -2.19 -179.42 M6.54 -155.99 C4.61 -164.16, 1.6 -171.1, -2.19 -179.42" stroke="#1e1e1e" stroke-width="1" fill="none"></path></g><g transform="translate(467.64688137529083 205.32823359194754) rotate(0 -0.7727579715501633 -89.16394771406567)"><path d="M-10.56 -155.86 C-9.78 -160.73, -5.55 -167.69, -2.19 -179.42 M-10.56 -155.86 C-6.76 -164.11, -4.05 -171.09, -2.19 -179.42" stroke="#1e1e1e" stroke-width="1" fill="none"></path></g></g><mask></mask><g transform="translate(658.0637210809118 177.18324775410474) rotate(0 7 16.09999999999991)"><text x="0" y="25.760546874999996" font-family="Helvetica, Segoe UI Emoji" font-size="28px" fill="#1e1e1e" text-anchor="start" style="white-space: pre;" direction="ltr" dominant-baseline="alphabetic">x</text></g><g stroke-linecap="round"><g transform="translate(598.3739851708115 63.05560475822858) rotate(0 -0.08893678115873627 55.743494120113155)"><path d="M1.07 -0.41 C1.29 18.24, 0.9 93.65, 0.78 112.16" stroke="#1e1e1e" stroke-width="1.5" fill="none" stroke-dasharray="8 9"></path></g></g><mask></mask><g transform="translate(395.29975887890487 177.79647850520996) rotate(0 7.7861328125 16.09999999999991)"><text x="0" y="25.760546874999996" font-family="Helvetica, Segoe UI Emoji" font-size="28px" fill="#1e1e1e" text-anchor="start" style="white-space: pre;" direction="ltr" dominant-baseline="alphabetic">a</text></g><g transform="translate(593.8000056338878 180.49802710561107) rotate(0 7.7861328125 16.09999999999991)"><text x="0" y="25.760546874999996" font-family="Helvetica, Segoe UI Emoji" font-size="28px" fill="#1e1e1e" text-anchor="start" style="white-space: pre;" direction="ltr" dominant-baseline="alphabetic">b</text></g><g transform="translate(395.952612898036 10) rotate(0 24.8759765625 16.09999999999991)"><text x="0" y="25.760546874999996" font-family="Helvetica, Segoe UI Emoji" font-size="28px" fill="#1e1e1e" text-anchor="start" style="white-space: pre;" direction="ltr" dominant-baseline="alphabetic">F(x)</text></g><g stroke-linecap="round"><g transform="translate(402.16394715637944 171.16588568226052) rotate(0 98.3117238190265 -55.166191552697)"><path d="M0.47 -0.15 C33.36 -18.6, 164.82 -91.81, 197.64 -110.1 M-0.74 -1.28 C32.05 -20.16, 164.26 -93.65, 197.22 -112.1" stroke="#1e1e1e" stroke-width="1" fill="none"></path></g></g><mask></mask><g stroke-linecap="round"><g transform="translate(599.5853748005507 59.45507232518503) rotate(0 43.858440954547746 0.488536396150721)"><path d="M-0.03 -0.86 C14.48 -0.4, 72.04 1.56, 86.53 2.04 M-1.5 1.3 C13.4 1.51, 73.48 0.65, 88.63 0.47" stroke="#1e1e1e" stroke-width="1" fill="none"></path></g></g><mask></mask><g stroke-linecap="round"><g transform="translate(464.46987194933604 59.759764009316314) rotate(0 67.34253863877223 -0.5508638528115171)"><path d="M0.84 -0.19 C23.25 -0.2, 111.06 -0.65, 133.5 -0.91" stroke="#e03131" stroke-width="1.5" fill="none" stroke-dasharray="8 9"></path></g></g><mask></mask><g transform="translate(443.002765927959 48.5835393051716) rotate(0 5.071291390060765 10.486308588122029)"><text x="0" y="16.778449933542483" font-family="Helvetica, Segoe UI Emoji" font-size="18.237058414125364px" fill="#e03131" text-anchor="start" style="white-space: pre;" direction="ltr" dominant-baseline="alphabetic">1</text></g><g transform="translate(137.52059521763022 59.10491216406945) rotate(0 31.616679084150746 11.37543577436486)"><text x="0" y="18.20108363286186" font-family="Helvetica, Segoe UI Emoji" font-size="19.78336656411267px" fill="#1e1e1e" text-anchor="start" style="white-space: pre;" direction="ltr" dominant-baseline="alphabetic">1/(a+b)</text></g></svg> **期望:** $E(X)=\dfrac{a+b}{2}$ **方差:** $D(X)=\dfrac{(b-a)^{2}}{12}$ 均匀分布表示取值**等可能**或者完全随机的随机变量 通过均匀分布的随机数可以产生其他分布的随机数,是 [[蒙特卡洛方法\|蒙特卡洛方法]]模拟的基础 二维均匀分布 $(X,Y)\sim U(D)$ $$f(x,y)=\begin{cases} \dfrac{1}{A} \quad (x,y)\in D\\ \\ 0\quad \quad (x,y) \not\in D \end{cases}$$ $$\begin{align} P\left\{(X,Y) \in D_{1} \right\}=\iint \limits_{D_{1}} \dfrac{1}{A} d\sigma =\dfrac{S_{D_{1}}}{A} \end{align}$$