Proving $f(n)+c=O(g(n))$ with $\lim_{n \to +\infty}f(n)=+\infty$

  • MHB
  • Thread starter evinda
  • Start date
In summary: However, the statement is still true for all $c>0$.In summary, the conversation discusses the implications of $f(n)=O(g(n))$ and $\lim_{n \to +\infty} f(n)=+\infty$ on the relationship between $f(n)+c$ and $g(n)$. It is concluded that for all $c>0$, $f(n)+c=O(g(n))$ holds. However, it is noted that this does not necessarily mean that $f(n)=\Theta(g(n))$.
  • #1
evinda
Gold Member
MHB
3,836
0
Hi! (Smile)

I want to show that $f(n)=O(g(n))$ and $\lim_{n \to +\infty} f(n)=+\infty$ implies that $f(n)+c=O(g(n))$.

$f(n)=O(g(n))$ means that $\exists c_1>0, n_1 \in \mathbb{N}_0$ such that $\forall n \geq n_1$: $f(n) \leq c_1g(n)$.

$\lim_{n \to +\infty} f(n)=+\infty$ means that $\forall M>0 \exists n_2 \in \mathbb{N}_0$ such that $\forall n \geq n_2$: $f(n)>M$.

We want to show that $\exists c_2>0, n_0 \in \mathbb{N}_0$ such that $\forall n \geq n_0$: $f(n)+c<c_2 g(n)$

That's what I have tried:$$M<f(n) \leq c_1 g(n) \Rightarrow M+c < f(n)+c \leq c_1g(n)+c \Rightarrow \frac{M+c}{g(n)} < \frac{f(n)+c}{g(n)} \leq \frac{ c_1g(n)+c}{g(n)} \Rightarrow \lim_{n \to +\infty} \frac{M+c}{g(n)}< \lim_{n \to +\infty} \frac{f(n)+c}{g(n)} \leq \lim_{n \to +\infty} \frac{ c_1g(n)+c}{g(n)} \overset{\star}{\Rightarrow} 0<\lim_{n \to +\infty} \frac{f(n)+c}{g(n)} \leq c_1 \\ \Rightarrow \lim_{n \to +\infty} \frac{f(n)+c}{g(n)}=a \in (0,c_1] \Rightarrow f(n)+c=\Theta(g(n)) \Rightarrow f(n)+c=O(g(n)) $$$$ \star: f(n) \leq c_1 g(n) \wedge \lim_{n \to +\infty} f(n)=+\infty \Rightarrow \lim_{n \to +\infty} c_1 g(n)=+\infty \Rightarrow \lim_{n \to +\infty}g(n)=+\infty $$
 
Physics news on Phys.org
  • #2
I think you proved too much. Take $c=0$. The fact that $f(n)=O(g(n))$ and $\lim_{n \to +\infty} f(n)=+\infty$ does not imply that $f(n)=\Theta(g(n))$.
 
  • #3
Evgeny.Makarov said:
I think you proved too much. Take $c=0$. The fact that $f(n)=O(g(n))$ and $\lim_{n \to +\infty} f(n)=+\infty$ does not imply that $f(n)=\Theta(g(n))$.

I see (Nod) But it holds for all $c>0$.. Or am I wrong? (Thinking)
 
  • #4
evinda said:
I see (Nod) But it holds for all $c>0$.
What do you see and what holds for all $c>0$?
 
  • #5
For $c=0$ we don't have to show anything since $f(n)=O(g(n))$ and $\lim_{n \to +\infty} f(n)=+\infty$ trivially implies that $f(n)+c=O(g(n))$.

For $c>0$ that what I wrote holds, or not? (Thinking)
 
  • #6
evinda said:
For $c=0$ we don't have to show anything since $f(n)=O(g(n))$ and $\lim_{n \to +\infty} f(n)=+\infty$ trivially implies that $f(n)+c=O(g(n))$.
Slowly exhales. Let's try this again.

Evgeny.Makarov said:
The fact that $f(n)=O(g(n))$ and $\lim_{n \to +\infty} f(n)=+\infty$ does not imply that $f(n)=\Theta(g(n))$.
I said this because you deduced $f(n)+c=O(g(n))$ from $f(n)+c=\Theta(g(n))$.
 

1. What does it mean for a function to be in the form of $f(n)+c=O(g(n))$?

When a function is in the form of $f(n)+c=O(g(n))$, it means that the function can be upper-bounded by a multiple of another function $g(n)$ as $n$ approaches infinity. The constant $c$ represents any additional terms in the function $f(n)$.

2. How is the Big O notation used to prove $f(n)+c=O(g(n))$?

The Big O notation is used to provide an upper bound for the growth rate of a function. In this case, we use it to show that the function $f(n)+c$ grows at a rate that is at most proportional to the function $g(n)$ as $n$ approaches infinity.

3. What is the significance of $\lim_{n \to +\infty}f(n)=+\infty$ in this proof?

The statement $\lim_{n \to +\infty}f(n)=+\infty$ means that as $n$ approaches infinity, the function $f(n)$ also approaches infinity. This is important because it allows us to show that the function $f(n)+c$ also approaches infinity, and therefore can be upper-bounded by a multiple of $g(n)$.

4. Can $c$ be any constant in the equation $f(n)+c=O(g(n))$?

Yes, $c$ can be any constant because it represents any additional terms in the function $f(n)$. As long as the growth rate of $f(n)$ is still upper-bounded by a multiple of $g(n)$, the equation holds.

5. Are there any limitations to using this method of proof?

Yes, the main limitation is that it only works for functions that have a limit of positive infinity as $n$ approaches infinity. This method cannot be used for functions with a limit of negative infinity or oscillating functions, as the Big O notation is not defined for them.

Similar threads

  • Set Theory, Logic, Probability, Statistics
Replies
2
Views
1K
  • Set Theory, Logic, Probability, Statistics
Replies
1
Views
749
  • Set Theory, Logic, Probability, Statistics
Replies
2
Views
1K
  • Set Theory, Logic, Probability, Statistics
Replies
8
Views
1K
Replies
2
Views
1K
  • Set Theory, Logic, Probability, Statistics
Replies
3
Views
2K
  • Set Theory, Logic, Probability, Statistics
Replies
1
Views
1K
  • Set Theory, Logic, Probability, Statistics
Replies
9
Views
2K
  • Set Theory, Logic, Probability, Statistics
Replies
27
Views
3K
  • Set Theory, Logic, Probability, Statistics
Replies
6
Views
946
Back
Top