Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7850413
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 2, 20262026-06-02T18:50:28+00:00 2026-06-02T18:50:28+00:00

If I need to determine the algorithmic complexity of a process with a cost

  • 0

If I need to determine the algorithmic complexity of a process with a cost set by a given function, is it just a question of giving O(n^2 log n) – or whatever the big O happens to be?

Also, isn’t big O just going to be the highest order of any term in the polynomial? If I’m asked to give a derivation I’m not sure what to provide because it seems a little trivial.

Last question, if I need to give the operation count for an algorithm and it’s really straightforward – roughly like

array1, array2, array3 of size n 
for i in n:
    array2[i] = sqrt(array1[i])
    array3[i] = array1[i]^2

For ‘operation count’ am I just counting up all my arithmetical operations and figuring out which ones (like sqrt) count as multiple operations, etc… Or can I just write that it’s O(n)?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-02T18:50:30+00:00Added an answer on June 2, 2026 at 6:50 pm

    The algorithmic cost of a process is the costs of all the components of the process. For example, using your example, we can decompose the costs of everything

    array1, array2, array3 of size n
    

    This takes n time for each array, so a total of 3n time, which is in O(n).

    for i in n:
    

    This means that everything in the loop is multiplies by n.

    array2[i] = sqrt(array1[i])
    

    This takes O(1) time. Why? Accessing an array element is constant time. Taking the sqrt is constant time. And setting the value of an array element is constant time. So the whole operation is constant time.

    array3[i] = array1[i] ^ 2
    

    This takes O(1) time, for the same reasons as the previous operation.

    So the whole running time is 3n + n * ( 1 + 1) (using rough math here, not exact), which is just in O(n) time. Does that help?

    As for an actual derivation, there are specific techniques for this. Did you learn the precise mathematical definition of big-Oh notation?

    This link describes the formal definition of big-Oh notation, and provides of an example of how to prove this stuff.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I need to determine if a given selection is in between a start line
Here's an obscure question: I need to be able to determine historical astrological periods
My winform application is launched by another application (the parent), I need determine the
I need to determine in 80% if a file is binary or text, is
I need to determine file type (i.e., MimeType) of stored data in the SQL
I need to determine whether or not two sets contains exactly the same elements.
I need to determine the clients .NET framework version in my web application. I'm
I need to determine whether a selected UIColor (picked by the user) is dark
We need to determine a quick way for our web application deployed in a
I need to Determine the serial port name connected to other machine using c#.

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.