Dismiss Notice
Join Physics Forums Today!
The friendliest, high quality science and math community on the planet! Everyone who loves science is here!

Excel, proper equation format.

  1. Oct 20, 2008 #1
    Ok, so the teacher gave us an assignment to write a program that calculates the ratio below, tabulate it and plot it.. for given values of R and λ.

    T_b/T_a =([R^4-(R-λR)^4])/([4λR^2 (R-λR/2)^2])

    I figured that I would use Excel to do this.

    I think the above equation converts to the function below in excel but I keep getting zero for all values I try.

    And A4=λ


    Any help would be appreciated.
  2. jcsd
  3. Oct 21, 2008 #2


    User Avatar
    Staff Emeritus
    Science Advisor
    Gold Member

    I would break it up into manageable chunks putting them in a series of cells. Then combining the pieces into the final relationship.

    Also you can use simple operators like ^ for exponentiation, * for multiplication and / for divide. That may be easier to read and troubleshoot then the functions you are using.

    Is that ratio correct? Looks to me like R cancels out.
  4. Oct 21, 2008 #3
    Well... my excel does not understand "QUOTIENT" (I have an English speaking Excel 2003).
    And also, there seems a mistake in your formula: ([R^4-(R-λR)^4])/([4λR^2 (R-λR/2)^2]) - the underlined part, should I subtract one part from the other, or multiply? There's a symbol missing. I chose for subtracting.

    T_b/T_a =([R^4-(R-λR)^4])/([4λR^2 - (R-λR/2)^2])
    T_b = ([R^4-(R-λR)^4])
    T_a = ([4λR^2 - (R-λR/2)^2])

    And in Excel language:
    (For T_b)
    (For T_a)
  5. Oct 21, 2008 #4
    I'm sorry.. it supposed to be multiplied

    I'll try your suggestion. I have Excel 2007 though.
    I think Initially your method is what I had tried but I'll give it a go again.

  6. Oct 21, 2008 #5
    I would try that. They probably do cancel out but the arithmetic was taking me too long.

  7. Oct 21, 2008 #6


    User Avatar
    Staff Emeritus
    Science Advisor
    Gold Member

    If you are unable to do the simple algebra required to cancel out the R, how do you hope to get the formula entered correctly into Excel?

    Do the Algebra, it will simplify the spread sheet.

    Also note that double posting is strictly against fourm policy.
  8. Oct 21, 2008 #7
    I didn't bother to do any algebra... but indeed, if it is important, writing out an equation on paper before entering it into the computer generally makes life easier. Equations in a computer program can become a nightmare with all the brackets and pluses/minuses.

    I'd be surprised if Excel 2003 "language" does not work in 2007. If that would be true, it would be a very strong argument for Matlab or Octave (Octave is the GPL version of Matlab, with a lot less functionality, but more than adequate to plot this little equation).
  9. Oct 21, 2008 #8
    Hey Thanks. I used the simpler functions and they worked.
  10. Oct 21, 2008 #9
    I got it working.
    Thanks for all the help

Know someone interested in this topic? Share this thread via Reddit, Google+, Twitter, or Facebook