Computer Mathematical Foundation ③(Combinatorics and Probability)

Combinatorics and Probability

Ordered Choice

insert image description here
(Ordered selection and repetition) Suppose you want to select k objects out of n objects, and you care about the order in which the objects are selected. You can select the same objects repeatedly if you want. Then the selection is satisfied by the k-th power of n

Equivalent to Ank

insert image description here
The related concepts of factorial are defined here, which can be understood in combination with pictures.

insert image description here
(Ordered selection without repetition) Suppose you want to select k objects from n objects, you care about the order in which the objects are selected, but only one object can be selected at most once. Use the formula in the box above.

Equivalent to C nk

Unordered Choice

insert image description here
(No duplicates required) The binomial coefficient (nk) represents the number of ways to select k things from n options, provided that duplicate options are not allowed and the order of the options does not matter.

insert image description here
explains how quadratic coefficients are calculated

insert image description here
(No need to select repeatable) Number of ways to select k things from n options, where we don't consider the order of selection but allow selection to repeat, we can use the formula in the picture.

Guess you like

Origin blog.csdn.net/zyb18507175502/article/details/124250550