Properties of Asymptotic Notations and common conjuctures

 

Properties of Asymptotic Notations


Introduction

Asymptotic notations are used to compare the growth rates of functions while ignoring constants and lower-order terms. They satisfy several useful mathematical properties that simplify the analysis of algorithms.

The major properties are

  1. Reflexivity
  2. Transitivity
  3. Symmetry
  4. Transpose Symmetry
  5. Empty Set Property
  6. Constant Multiplication
  7. Addition Rule
  8. Maximum Rule
  9. Composition Property
  10. Polynomial Property
  11. Logarithm Property

1. Reflexivity Property

Every function is asymptotically bounded by itself.

f(n)=O(f(n))f(n)=O(f(n))
f(n)=Ω(f(n))f(n)=\Omega(f(n))
f(n)=Θ(f(n))f(n)=\Theta(f(n))

Example

n2=O(n2)n^2=O(n^2)
nlog⁡n=Θ(nlog⁡n)n\log n=\Theta(n\log n)

2. Transitivity Property

If

f(n)=O(g(n))f(n)=O(g(n))

and

g(n)=O(h(n))g(n)=O(h(n))

then

f(n)=O(h(n))f(n)=O(h(n))

Similarly,

f(n)=Ω(g(n))f(n)=\Omega(g(n))

and

g(n)=Ω(h(n))g(n)=\Omega(h(n))

implies

f(n)=Ω(h(n))f(n)=\Omega(h(n))

Also,

f(n)=Θ(g(n))f(n)=\Theta(g(n))

and

g(n)=Θ(h(n))g(n)=\Theta(h(n))

implies

f(n)=Θ(h(n))f(n)=\Theta(h(n))

Example

n=O(n2)n=O(n^2)
n2=O(n3)n^2=O(n^3)

Therefore,

n=O(n3)n=O(n^3)

3. Symmetry Property

Theta notation is symmetric.

If

f(n)=Θ(g(n))f(n)=\Theta(g(n))

then

g(n)=Θ(f(n))g(n)=\Theta(f(n))

Example

3n2+5n=Θ(n2)3n^2+5n=\Theta(n^2)

Therefore,

n2=Θ(3n2+5n)n^2=\Theta(3n^2+5n)

4. Transpose Symmetry

Big-O and Big-Omega are transpose of each other.

If

f(n)=O(g(n))f(n)=O(g(n))

then

g(n)=Ω(f(n))g(n)=\Omega(f(n))

Similarly,

If

f(n)=Ω(g(n))f(n)=\Omega(g(n))

then

g(n)=O(f(n))g(n)=O(f(n))

Example

n=O(n2)n=O(n^2)

Hence,

n2=Ω(n)n^2=\Omega(n)

5. Empty Set Property

No function can simultaneously satisfy

f(n)=o(f(n))f(n)=o(f(n))

or

f(n)=ω(f(n))f(n)=\omega(f(n))

Hence,

o(f(n))∩ω(f(n))=∅o(f(n))\cap \omega(f(n))=\emptyset

6. Constant Multiplication Property

Multiplying by a positive constant does not change the asymptotic order.

If

f(n)=O(g(n))f(n)=O(g(n))

then

cf(n)=O(cg(n))cf(n)=O(cg(n))

where

c>0c>0

Example

n=O(n2)n=O(n^2)

Multiply by 5

5n=O(5n2)5n=O(5n^2)

7. Addition Rule

If

f(n)=O(h(n))f(n)=O(h(n))

and

g(n)=O(h(n))g(n)=O(h(n))

then

f(n)+g(n)=O(h(n))f(n)+g(n)=O(h(n))

Example

3n+n23n+n^2

Since

3n=O(n2)3n=O(n^2)

Therefore

3n+n2=O(n2)3n+n^2=O(n^2)

8. Maximum Rule

The larger-growing function dominates.

f(n)+g(n)=Θ(max⁡(f(n),g(n)))f(n)+g(n)=\Theta(\max(f(n),g(n)))

Example

n+n2n+n^2

Since

n2>nn^2>n

Therefore

n+n2=Θ(n2)n+n^2=\Theta(n^2)

Another example

nlog⁡n+nn\log n+n

Result

=Θ(nlog⁡n)=\Theta(n\log n)

9. Polynomial Property

If

f(n)=O(g(n))f(n)=O(g(n))

then

(f(n))k=O((g(n))k)(f(n))^k=O((g(n))^k)

for any positive constant

kk

Example

n=O(n2)n=O(n^2)

Squaring both sides

n2=O(n4)n^2=O(n^4)

10. Logarithm Property

If

f(n)=O(g(n))f(n)=O(g(n))

and both functions are at least 1 for sufficiently large nn,

then

log⁡f(n)=O(log⁡g(n))\log f(n)=O(\log g(n))

Example

n=O(n2)n=O(n^2)

Therefore

log⁡n=O(log⁡n2)\log n=O(\log n^2)

Since

log⁡n2=2log⁡n\log n^2=2\log n

11. Exponential Property

Unlike logarithms,

Big-O is not preserved under exponentiation.

Example

Suppose

n=O(n2)n=O(n^2)

Then

2n2^n

is not

O(2n2)O(2^{n^2})

by simply applying the definition mechanically; exponential growth changes much more rapidly, so this requires separate analysis. In general, exponentiation is not a property that can be freely applied.


Common Conjectures 

The following table summarizes the conjectures from the CLRS exercise you posted.

ConjectureTrue/FalseReason
f=O(g)⇒g=O(f)f=O(g)\Rightarrow g=O(f)
❌ FalseExample: n=O(n2)n=O(n^2), but n2≠O(n)n^2\not=O(n)
f+g=Θ(min⁡(f,g))f+g=\Theta(\min(f,g))
❌ FalseDominated by the larger function, not the smaller.
f=O(g)⇒log⁡f=O(log⁡g)f=O(g)\Rightarrow \log f=O(\log g)
✅ TrueLogarithm is monotonic.
f=O(g)⇒2f=O(2g)f=O(g)\Rightarrow 2^f=O(2^g)
✅ TrueSince f≤cg for some constant cc, exponential preserves order up to constant multiples in the exponent for asymptotically positive functions under the exercise's assumptions.
f=O(f2)f=O(f^2)
❌ FalseCounterexample: f(n)=1/n, then 1/n≠O(1/n2)1/n\not=O(1/n^2)
f=O(g)⇒g=Ω(f)f=O(g)\Rightarrow g=\Omega(f)✅ TrueThis is the transpose symmetry property.
f(n)=Θ(f(n/2))f(n)=\Theta(f(n/2))
❌ FalseCounterexample: f(n)=2nf(n)=2^n, then 2n2^n is not Θ(2n/2)
f+o(f)=Θ(f)f+o(f)=\Theta(f)
✅ TrueLower-order terms do not change the asymptotic order.

Summary of Important Properties

PropertyFormula
Reflexivity                f(n)=O(f(n))=Ω(f(n))=Θ(f(n))
Transitivityf=O(g),  g=O(h)⇒f=O(h)f=O(g),\;g=O(h)\Rightarrow f=O(h)
Symmetryf=Θ(g)  ⟺  g=Θ(f)f=\Theta(g)\iff g=\Theta(f)
Transpose Symmetryf=O(g)  ⟺  g=Ω(f)f=O(g)\iff g=\Omega(f)
Constant Multiplicationcf=Θ(f)cf=\Theta(f) for c>0c>0
Addition RuleIf f,g=O(h)f,g=O(h), then f+g=O(h)
Maximum Rulef+g=Θ(max⁡(f,g))
Polynomial Propertyf=O(g)⇒fk=O(gk)f=O(g)\Rightarrow f^k=O(g^k)
Logarithm Propertyf=O(g)⇒log⁡f=O(log⁡g)f=O(g)\Rightarrow \log f=O(\log g) (for sufficiently large positive functions)
Lower-order Termsf+o(f)=Θ(f)f+o(f)=\Theta(f)

Comments

Popular posts from this blog

Design and Analysis of Algorithms PCCST502 Semester 5 KTU CS 2024 Scheme - Dr Binu V P

Introduction to Algorithms

Criteria for Analyzing Algorithms- Time and Space Complexity