Progressive notation of the introduction to algorithms notes

Source: Internet
Author: User

Progressive notation

Θ (theta): Progressive tightening of the boundary. F (N) =θ (g (n)) indicates:? c1>0,c2>0,n0>0,s.t. N>N0,0≤C1G (n) ≤f (n) ≤c2g (n) was established. The limit is expressed as limn->∞f (n)/g (n) = c.

O (Greater Europe): progressive Upper bound. F (n) = O (g (n)) indicates: C>0,N0>0,S.T. Right? N>n0,0≤f (n) ≤CG (n) was established.

Omega (large Omega): progressive lower bound. F (N) =ω (g (n)) indicates:? c>0,n0>0,s.t. N>N0,0≤CG (n) ≤f (n) was established.

O (Small Europe): non-progressive tightening upper bound. F (n) = O (g (n)) means: right? c>0,?n0>0,s.t. N>n0,0≤f (n) <CG (n) was established. The main difference between f (n) = O (g (n)) and f (n) = O (g (n)) is that the former is set for any c>0,0≤f (n) ≤CG (n), and the latter is for a c>0,0≤f (n) <CG (n). In other words, f (n) = O (g (n)) can be expressed as when n->∞, LIMF (n)/g (n) = 0.

Omega (small Omega): non-progressive tight bound. F (N) =ω (g (n)) means: right? c>0,?n0>0,s.t. N>N0,0≤CG (n) <f (n) was established. The available limits are expressed as: when N->∞, LIMF (n)/g (n) =∞.

We remember f (n) = O (g (n)) to indicate that the function f (n) is a member of the Set O (g (n)), i.e. f (n) ∈o (g (n)). Note that f (n) =θ (g (n)) implies f (n) = O (g (n)), i.e. O (g (n)). Θ (g (n)). In the same way, Ω (g (n))? Θ (g (n)). Thus, the following important theorems can be derived:

For any two functions f (n) and g (n), we have f (n) =θ (g (n)), when and only if f (n) = O (g (n)) and f (n) =ω (g (n)).

The nature of progressive notation transitivity:

F (N) =θ (g (n)) and g (n) =θ (h (N)), then f (n) =θ (h (n))

F (n) = O (g (n)) and g (n) = O (h (n)), f (n) = O (h (n))

F (N) =ω (g (n)) and g (n) =ω (h (N)), then f (n) =ω (h (n))

F (n) = O (g (n)) and g (n) = O (h (n)), f (n) = O (h (n))

F (N) =ω (g (n)) and g (n) =ω (h (N)), then f (n) =ω (h (n))

Reflexive nature:

F (N) =θ (f (n))

F (n) = O (f (n))

F (N) =ω (f (n))

Symmetry:

F (N) =θ (g (n)) if and only if G (n) =θ (f (n))

Transpose Sex:

F (n) = O (g (n)) if and only if G (n) =ω (f (n))

F (n) = O (g (n)) if and only if G (n) =ω (f (n))

Since these properties are set for progressive notation, it is possible to compare the asymptotic comparison of two functions f and G with the comparison between Real and B:

F (N) =θ (g (n)) similar to a = b

F (n) = O (g (n)) similar to A≤b

F (N) =ω (g (n)) similar to A≥b

F (n) = O (g (n)) similar to a <b

F (N) =ω (g (n)) similar to a >b

However, the following properties of a real number cannot be carried to progressive notation:

Three-point: for any two real numbers a and B, the following three cases must be established: A<b,a>b or a=b.

Although two real numbers can be compared to each other, not all functions can be progressively compared. That is, for two functions f (n) and g (n) maybe f (n) = O (g (n)) and f (n) =ω (g (n)) are not true. For example, we cannot use progressive notation to compare N and N1+sin N

Progressive notation of the introduction to algorithms notes

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.