Advertisement
If you have a new account but are having problems posting or verifying your account, please email us on hello@boards.ie for help. Thanks :)
Hello all! Please ensure that you are posting a new thread or question in the appropriate forum. The Feedback forum is overwhelmed with questions that are having to be moved elsewhere. If you need help to verify your account contact hello@boards.ie
Hi there,
There is an issue with role permissions that is being worked on at the moment.
If you are having trouble with access or permissions on regional forums please post here to get access: https://www.boards.ie/discussion/2058365403/you-do-not-have-permission-for-that#latest

Log2b Binary Search Cost

  • 06-01-2015 11:37pm
    #1
    Registered Users, Registered Users 2 Posts: 8


    Not sure if this is maths or computing but anyways, I am studying advanced databases and I am doing a question on indexes. Can someone please tell me how this log thing works on a calculator?
    I missed the class and now I have an exam on this.

    I am looking at the solution and it says Log2b = Log23000 = 12
    how do I get this?

    When I put in log23000 in calculator I get 4.3617...

    Please help explain how I do this on calculator?

    Thank You


Comments

  • Registered Users, Registered Users 2 Posts: 6,163 ✭✭✭ZENER


    log base 2 of 3000 is 11.55. Does that make sense ? It's as close to 12 as I can find.

    Ken


  • Registered Users, Registered Users 2 Posts: 8 mardigra_xo


    Ye thats what it would be but how do you do it on the calculator?

    Thanks


  • Registered Users, Registered Users 2 Posts: 6,163 ✭✭✭ZENER


    Math's isn't my thing but in logs 11.55 is a long way from 12 using log base 2. log base2 of 4000 is closer to 12. Is there anyone else on your coarse who could help you ?

    What model is your calculator ?

    Ken


  • Registered Users, Registered Users 2 Posts: 772 ✭✭✭maki


    You need to divide the log10 of the required value by log10 of the required base.

    In your case: log10(3000) / log10(2)


  • Registered Users, Registered Users 2 Posts: 8 mardigra_xo


    I just saw a video on youtube there he does this

    log2 3000 = x (the 2 is log to the power of 2)
    2x = 3000 (the x is 2 to the power of x)

    so closest I could get was 11.55 = 2998

    so thats where the 12 is coming from he wants it rounded to nearest whole number.

    I have a sharp el-w531 but might be easier to do it that way than the calculator lol

    Im not the best at maths myself especially when I miss the classes but once explained to me its all good


  • Advertisement
Advertisement