Equation Format

Comments

4 comments

  • Rainer Grabowski

    Hi Stuart,

    var X = @turnover;
    
    ((-4.5799*10^-11)*(X^2))+(0.0000044233*X)+36.322
    

    Take care that you use the minus sign: - , not −

    Rainer

    0
    Comment actions Permalink
  • Stuart Frodsham

    Hi Rainer

    That is how I thought it should look but it gives a very different answer ( Expecting 33 and It gives 11,400,114)

    I have doubled checked the "-"

    0
    Comment actions Permalink
  • Rainer Grabowski

    Hi Stuart,

    if I remember right, ^ means in your example: X to the power of 2 (X²).
    In Javascript 10^2 = 8
    For "to the power of" you have to use Math.pow(X,2)

    var X = @turnover;
    var y= Math.pow(10,-11);
    var z = Math.pow(X,2);
    
    ((-4.5799*y)*(z))+(0.0000044233*X)+36.322
    

    Take care that you use the right minus sign: - , not −
    Rainer

    0
    Comment actions Permalink
  • Stuart Frodsham

    Yes that it .. THANK YOU !!!!

    0
    Comment actions Permalink

Please sign in to leave a comment.

Powered by Zendesk