+ Reply to Thread
Results 1 to 6 of 6

Polynomial Trendline Equation Trouble

  1. #1
    Registered User
    Join Date
    04-02-2009
    Location
    USA
    MS-Off Ver
    Excel 2002
    Posts
    12

    Polynomial Trendline Equation Trouble

    This is the polynomial trendline equation I generated from a series of data
    items. I've been trying for hours to write the equation properly in my
    cells, but I do not seem to be doing it right. I'm a newbie at excel.

    y = -3E-08x6 + 1E-06x5 - 4E-05x4 + 0.0005x3 + 3E-05x2 + 0.0101x - 0.0048
    R2 = 1


    Where x = percentage of job duration (B171/$D$165) (ex: .05)
    and y = percentage of allotted hours used (ex: .006)


    MY EQUATION:


    =(-0.00000003*((B171/$D$165)^6))+(0.000001*((B171/$D$165)^5))-(0.00004*((B171/$D$165)^4))+(0.0005*((B171/$D$165)^3))+(0.00003*((B171/$D$165)^2))+(0.0101*(B171/$D$165))-0.0048

    What am i doing wrong?... I'm getting negative numbers after plugging the
    equation into my spreadsheet, so obviously I am re-writing the equation
    wrong... Thoughts?

  2. #2
    Forum Expert shg's Avatar
    Join Date
    06-20-2007
    Location
    The Great State of Texas
    MS-Off Ver
    2010, 2019
    Posts
    40,689

    Re: Polynomial Trendline Equation Trouble

    1. You have more parens than you need:

    = -0.00000003 * (B171/$D$165)^6
    + 0.000001 * (B171/$D$165)^5
    - 0.00004 * (B171/$D$165)^4
    + 0.0005 * (B171/$D$165)^3
    + 0.00003 * (B171/$D$165)^2
    + 0.0101 * (B171/$D$165)
    - 0.0048


    2. If the coefficients m6, m5, ..., m1, b are in A1:A7, you can write the formula more compactly as

    =SERIESSUM(B171 / $D$165, 6, -1, $A$1:$A$6) + $A$7

    3. You don't have nearly enough precision in the coefficients for a sixth-order polynomial (you copied them from the trendline formula on the graph, right?). You should compute the coefficients separately using LINEST, and then use those with the formula in 2 above.

    I'm always suspect about polynomial fits. What makes you think the data has polynomial behavior?
    Entia non sunt multiplicanda sine necessitate

  3. #3
    Registered User
    Join Date
    04-02-2009
    Location
    USA
    MS-Off Ver
    Excel 2002
    Posts
    12

    Re: Polynomial Trendline Equation Trouble

    I may be getting too complicated here... and I think I am...

    But I am looking to be able to make a spreadsheet that allows me to determine the amount of manpower needed in the construction business at any given time during the construction process. I have a set of values for every five percent of the job completion based upon industry averages.

    For instance, at ten percent of the project completion, our company should have accumulated a set amount of hours (in this case, 1.85% of the total alotted hours)... At twenty percent of completion, we should have accumulated 6% of the total hours... I have "percentage of hours" values for every 5% of the projected timeframe. I want to be able to type in the length of the project (in weeks) and the total alloted hours for the project, and achieve a weekly hour value for each week of the project.

    I've tried the IF command, but due to extreme variations in project lengths (6 weeks to 3 years) it's practically impossible to write a formula with a seven-condition limit using the IF command.

    I figured that if I could graph my values, I could get an equation that would more accurately give me the results I am seeking. The graph that I get is not a straight line because, due to the industry averages our trade follows, the data shows that most of the hours used are in the middle of the project when things are going faster and more fluidly. The beginning and end of the project progress slower due to planning and completion tasks that occur. So I get somewhat of a nice fluid "S-curve".

    If that is confusing, I apologize... I'm pretty new at excel functions... Thanks in advance for any input, advice, etc.

    PERCENTAGE OF TIMEFRAME - ACUMULATIVE PERCENTAGE OF HOURS USED

    05% - 0.60%
    10% - 1.85%
    15% - 3.65%
    20% - 6.00%
    25% - 9.00%
    30% - 12.60%
    35% - 16.90%
    40% - 22.00%
    45% - 27.80%
    50% - 34.20%
    55% - 41.15%
    60% - 48.60%
    65% - 56.35%
    70% - 64.20%
    75% - 72.20%
    80% - 80.00%
    85% - 87.20%
    90% - 93.30%
    95% - 97.50%
    100% - 100%

  4. #4
    Forum Expert shg's Avatar
    Join Date
    06-20-2007
    Location
    The Great State of Texas
    MS-Off Ver
    2010, 2019
    Posts
    40,689

    Re: Polynomial Trendline Equation Trouble

    See attached; change hours or weeks as desired. You can copy formulas down as necessary.
    Attached Files Attached Files

  5. #5
    Registered User
    Join Date
    04-02-2009
    Location
    USA
    MS-Off Ver
    Excel 2002
    Posts
    12

    Re: Polynomial Trendline Equation Trouble

    Looks beautiful...!

    However, when I try to change the weeks or hours, I get a #NAME error in the allocated hours column... I am supposed to be able to change these two values on your spreadsheet, right?...

    Thanks again... The spreadsheet looks great!

  6. #6
    Forum Expert shg's Avatar
    Join Date
    06-20-2007
    Location
    The Great State of Texas
    MS-Off Ver
    2010, 2019
    Posts
    40,689

    Re: Polynomial Trendline Equation Trouble

    Try loading the Analysis ToolPak Add-In.

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1