Thread: math.h

  1. #1
    Registered User
    Join Date
    Apr 2002
    Posts
    94

    math.h

    I am trying to write a fnct that will do the following

    Z = X * log2 Y

    but dont know how I can use log() for this or if I should be using something else for it Any feedback will be greatly appreciated.

    Thanx
    simple is always an understatement.....

  2. #2
    Registered User
    Join Date
    Nov 2002
    Posts
    1,109
    there is a log2() fxn in math.h

    edit: takes a double, returns a double
    Last edited by alpha; 05-04-2003 at 10:44 PM.

  3. #3
    Registered User
    Join Date
    Jan 2003
    Posts
    648
    New Headers:
    #include <cmath>

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. math.h
    By tsutharssan in forum C Programming
    Replies: 3
    Last Post: 07-03-2009, 02:24 PM
  2. Trig Functions without math.h
    By daltore in forum C Programming
    Replies: 13
    Last Post: 12-29-2008, 04:47 PM
  3. cosine series with out using math.h
    By indrajit_muk in forum C Programming
    Replies: 5
    Last Post: 12-16-2008, 08:17 PM
  4. undefined reference to `sqrt' when using math.h
    By Milhas in forum C Programming
    Replies: 4
    Last Post: 03-31-2008, 06:11 PM
  5. using round from math.h
    By axr0284 in forum C Programming
    Replies: 5
    Last Post: 05-02-2006, 11:23 AM