# Math Help - Forming an equation (possibly curves)

1. ## Forming an equation (possibly curves)

Please check the new table in the post 8 further below.. thanks

Hello,

I have attached an image which lists the results that I need to achieve. All the values in the image cannot be changed, and I need to form an equation for each of the variable so that I can get each result of the particular row.

For example the column A,B,C and D have fixed time durations of .25 (i.e. 15 sec), .5, .5 and 1 (60 secs)

Each item costs a particular amount for A,B,C and D and is related with time. I do understand that the increases are not in a straight line, most probable some form of curves. I want to form an equation where I can just increase the time and it gives me a total.

Can a co-relation can be formed within these variables?

2. Sure you can write an equation to create all those values. The question is, should you or have you the wherewithal to pull it off? It is common to create such a complicated structure that it just isn't useful.

1) You will need to provide some intellectual review. In other words, what do you think it should look like? Are the results anywhere near your professional expectation?

2) Are you sure you have enough data to define the structure? What if Time = 0.35 is REALLY interesting? You have missed it.

3) How will it be used? This single consideration may define the maximum complexity.

4) What methods are available to you? What is your background in this sort of thing? It is not a trivial assignment.

Plenty to think about.

3. This is for practical use. I am making a custom order form through programming language and I need to form an equation where the user can just select what items he/she requires and for what duration.

The equation should calculate a result taking all these variables into consideration.

I have some maths background, but I have been relatively out of touch for a few years.

4. You sort of answered #3, and mentioned #4. You have not addressed issues #1 and #2.

5. Originally Posted by TKHunny
Sure you can write an equation to create all those values. The question is, should you or have you the wherewithal to pull it off? It is common to create such a complicated structure that it just isn't useful.

1) You will need to provide some intellectual review. In other words, what do you think it should look like? Are the results anywhere near your professional expectation?

2) Are you sure you have enough data to define the structure? What if Time = 0.35 is REALLY interesting? You have missed it.

3) How will it be used? This single consideration may define the maximum complexity.

4) What methods are available to you? What is your background in this sort of thing? It is not a trivial assignment.

Plenty to think about.
1. The numbers in the table are all values that are static and I need to form an equation out of them. Each row should have an equation which is dependent on the values from the time ratio. For example item 2 costs $50 if time is .25 (or 15 sec) and it costs 150 if the time is 0.5. 2. I can add more data if necessary, though I am hoping that the equation will fill in that void. 3. It will be used in a professional environment so the logic behind it should be accurate. 6. Originally Posted by math2me 1. The numbers in the table are all values that are static and I need to form an equation out of them. Each row should have an equation which is dependent on the values from the time ratio. For example item 2 costs$50 if time is .25 (or 15 sec) and it costs 150 if the time is 0.5.

2. I can add more data if necessary, though I am hoping that the equation will fill in that void.

3. It will be used in a professional environment so the logic behind it should be accurate.
it costs 150 if the time is 0.5.
It looks as if it could also cost 200 if the time is 0.5

The time for column B and for column C are both listed as 0.5
How can you be distingush between the two times?

It really looks as if column C should be 0.75

.

7. Originally Posted by aidan
It looks as if it could also cost 200 if the time is 0.5

The time for column B and for column C are both listed as 0.5
How can you be distingush between the two times?

It really looks as if column C should be 0.75

.
yeah I was a bit concerned with that one that it might not work. I will go back to the drawing board and get some new values up.

8. Ok I have made some adjustments to the table... and I require an equation for each of the item. the main variable is time.... the values of each item at time 2, 3, 5 and 8 is given. Now I need to compute values in between like what will be the value of item 1 at time 3.5 for example.

thanks

9. do i need to form an equation for a curve? and how will I chose the gradient?

10. To find the equation of a curve for item 2 I tried using

y = ax^2 + bx + c

and after putting in the x and y values to get the values of a, b and c. Once I got those, i tried testing it to find more values of x and y... but i got a wrong answer....

the curve plotting through excel (XY scatter graph) is attached below

11. I would really appreciate if someone can point me in the right direction. Is it realistically possible to derive an equation by looking at the curve I posted above, or are the points too random?

12. Originally Posted by math2me
To find the equation of a curve for item 2 I tried using
y = ax^2 + bx + c
and after putting in the x and y values to get the values of a, b and c. Once I got those, i tried testing it to find more values of x and y... but i got a wrong answer....
the curve plotting through excel (XY scatter graph) is attached below
There are 4 points given, so this is what I used:
y = ax^3 + bx^2 + cx + d
for each of the 5 items & the overhead.

Is it realistically possible to derive an equation by looking at the curve I posted above, or are the points too random?
Not from the curve, but if you furnish the grid points an equation can be constructed. I use several different routines to build the function: linear regression, log, loglog, exponential, least squares, curve fitting, & some others. If you have 14 points, this will generate a polynomial of degree 13 that will FIT EXACTLY (except for errors in rounding) ALL of the points given.

Code:

item1: 0*x^3 + 0*x^2 + 100*x + 200
:x,0,0.5,1,1.5,2,2.5,3,3.5,4,4.5,5,5.5,6,6.5,7,7.5,8,8.5,9,9.5,10,:
:y,200,250,300,350,400,450,500,550,600,650,700,750,800,850,900,950,1000,1050,1100,1150,1200,:
'
'
item2: 36.1*x^3 -562.667*x^2 +2627.433*x -3093
:x,     0,         0.5,        1,        1.5,       2,       2.5,       3,       3.5,      4,       4.5,      5,       5.5,       6,       6.5,       7,       7.5,       8,       8.5,       9,        9.5,      10,:
:y, -3093, -1915.43775, -992.134, -296.01375, 199.998, 522.97625, 699.996, 758.13225, 724.46, 626.05425, 489.99, 343.34225, 213.186, 126.59625, 110.648, 192.41625, 398.976, 757.40225, 1294.77, 2038.15425, 3014.63,:
'
'
item3: 5.555*x^3 -72.222*x^2 +555.555*x -166.667
:x,0,0.5,1,1.5,2,2.5,3,3.5,4,4.5,5,5.5,6,6.5,7,7.5,8,8.5,9,9.5,10,:
:y,-166.667,93.749375,322.221,522.914125,699.995,857.629875,999.985,1131.226625,1255.521,1377.034375,1499.933,1628.383125,1766.551,1918.602875,2088.705,2281.023625,2499.725,2748.975375,3032.941,3355.788125,3721.683,:
'
'
item4:-1.111*x^3 +11.111*x^2 +15.555*x +133.333
:x,0,0.5,1,1.5,2,2.5,3,3.5,4,4.5,5,5.5,6,6.5,7,7.5,8,8.5,9,9.5,10,:
:y,133.333,143.749375,158.888,177.915625,199.999,224.304875,250,276.251125,302.225,327.088375,350.008,370.150625,386.683,398.771875,405.584,406.286125,400.045,386.027375,363.4,331.329625,288.983,:
'
'
item5:-1.778*x^3 + 24.444*x^2 -88.444*x +153.333
:x,0,0.5,1,1.5,2,2.5,3,3.5,4,4.5,5,5.5,6,6.5,7,7.5,8,8.5,9,9.5,10,:
:y,153.333,114.99975,87.555,69.66525,59.997,57.21675,59.991,66.98625,76.869,88.30575,99.963,110.50725,118.605,122.92275,122.127,114.88425,99.861,75.72375,41.139,-5.22675,-64.707,:
'
'
OvrHd: 7.344*x^3 -136.777*x^2 +744.344*x -961.333
:x,0,0.5,1,1.5,2,2.5,3,3.5,4,4.5,5,5.5,6,6.5,7,7.5,8,8.5,9,9.5,10,:
:y,-961.333,-622.43725,-346.422,-127.77925,38.999,159.42075,238.994,283.22675,297.627,287.70275,258.962,216.91275,167.063,114.92075,65.994,25.79075,-0.181,-6.41325,12.602,62.37275,148.407,:
The coefficients are listed for each item:
the x values from 0 to 10 in 0.5 steps
and the resulting y values.

I tried to edit item 2 to make it easier to read.
Best to load the text file into a spread sheet for viewing.

Is that more in line with what you were seeking.

.

13. thank you for the clarification. That table worked out perfectly. However, when I try to utilize the same concept on a table with three points, I am having trouble.

I am using y = ax^2+bx+c as there are only three points. After I find the equation and check the answers for the particular item, I get the answer right for usually two of them, but one is wrong. e.g. in item 2 I derived the equation to be:

y = -311.1 x^2 + 633.325 x - 38.886

With this I get the correct values at time = 0.25 and 0.5, but wrong on 1 (I am getting 283 instead of 50.)

where am i going wrong?

14. Originally Posted by math2me
when I try to utilize the same concept on a table with three points, I am having trouble.

I am using y = ax^2+bx+c as there are only three points.
...
After I find the equation and check the answers for the particular item, I get the answer right for usually two of them, but one is wrong. e.g. in item 2 I derived the equation to be:

y = -311.1 x^2 + 633.325 x - 38.886

With this I get the correct values at time = 0.25 and 0.5, but wrong on 1 (I am getting 283 instead of 50.)

where am i going wrong?
Not sure of what you did.
Using the three values supplied I get this:
$y = -933.333x^2 +1100x -116.667$

with this result:
Code:
x=        0   ,   0.25,  0.5  ,   0.75,  1   ,   1.25
Item2: -116.67, 100.00, 200.00, 183.33, 50.00, -200.00
The coefficients found for the items listed (There was no Item3)

Code:
a,b,c coefficients for
y= ax^2 + bx + c
.         a         b      c
Item1,-266.666,  1000, -233.333
Item2,-933.333,  1100, -116.667
Item4, 533.333,  -200,   66.667
Item5,-333.333,   550, -116.667
Item6,  40.000,   -30,   20.000
OvrHd, 960.000, -1020,  329.000
Not sure if that answered your question.

.

15. Thanks... that is exactly what i wanted....

though i have started to seriously doubt my math skills... I used to be pretty good at this...