Big-O Notation

  • Thread starter TheLegace
  • Start date
  • #1
27
0

Homework Statement


Hi, I have been having huge problems with dealing with these kinds of problems, I would appreciate atleast some guidance in dealing with these sorts of problems, I think the major problem is just how I learned to solve them, I have been looking for resources on the net, but it just gets to complicated, and I need someone to help me start with simple stuff first.

A very simple problem I am starting with will be this one:

Is x^4 + 9x^3 + 4x + 7 O(x^4) ?


Homework Equations


Well obviously start with:

|x^4 + 9x^3 + 4x + 7| ≤ C|x^4|

The Attempt at a Solution



Now if I try working this out

|x^4 + 9x^3 + 4x + 7| ≤ C|x^4| for all x > k
x^4 + 9x^3 + 4x + 7 ≤ 1x^4 + 9x^4 4x^4 7x^4 for all x > 1
f(x) ≤ 21x^4 for all x > 1
so for C=21 and k=1 f(x) = O(x^4).

Now the solution in the textbook says the constants are C=4, k=9.
Am I wrong or do the constants matter, I know there are infinite amount of constants if the statement is true, but why choose those ones anyway then?

Any help would be appreciated.
Thank You.
 

Answers and Replies

  • #2
392
0
I like your way. Simple and direct. The actual constants don't matter.
 

Related Threads on Big-O Notation

  • Last Post
Replies
1
Views
2K
  • Last Post
Replies
1
Views
2K
  • Last Post
Replies
1
Views
4K
  • Last Post
Replies
3
Views
11K
  • Last Post
Replies
18
Views
35K
  • Last Post
Replies
5
Views
2K
  • Last Post
Replies
6
Views
1K
  • Last Post
Replies
3
Views
15K
Replies
8
Views
10K
  • Last Post
Replies
5
Views
2K
Top