Build an equation from the following statments

xikky

New member
Joined
Mar 14, 2014
Messages
2
Hi guys! I'm not sure if I'm posting in the right thread and sorry if I'm not. The thing is that I'm totally out of practice in math solving problems and forgot about what my problem is named in Mathematics. I'm a programmer and I'm building a game in which I need an equation for the following statments..

if:

2000 = 1
AND
500 = 2

1000 = ?

I'm not really interested in the result as the values are rounded and moreover, I need all the results for all values between 500 and 2000.

Can someone help me build an equation for this problem?

Thanks a lot for your time!
 
ֺ
Not sure what you're getting at, but 1000 is one-third of the way from 500 to 2000. One-third of the way going from 2 to 1 is 5/3. Am I close? :)

ֺ
 
Your absolutely right! that would be the answer :) but what about 1001, 1002, 1003 .. etc. I need to know all the results for all values between 500 and 2000.

This problem will be used in my game under development to smoothly change the size of an object (from 2 to 1 and vice versa) depending on the distance between two other objects (distance greater than 500 units and smaller than 2000 units).

Hopefully an equation can be developed as it's the only way to fit in my programming calculation.
 
?

Your absolutely right! that would be the answer :) but what about 1001, 1002, 1003 .. etc. I need to know all the results for all values between 500 and 2000.

This problem will be used in my game under development to smoothly change the size of an object (from 2 to 1 and vice versa) depending on the distance between two other objects (distance greater than 500 units and smaller than 2000 units).

Hopefully an equation can be developed as it's the only way to fit in my programming calculation.

Double check me programmer xikky, no pro here. ;)
2014_0314.Jpg
 
Your absolutely right! that would be the answer :) but what about 1001, 1002, 1003 .. etc. I need to know all the results for all values between 500 and 2000.
If you're assuming that the model is a straight line, then find the slope between the two points (after, of course, you've specified what the x-values are; I'm assuming 500 and 2000 are the y-value outputs), and then plug this slope and either one of the original points into one of the formulas to find the straight-line equations.

It should be noted, however, that a straight line is only one of infinitely-many such models. A non-linear equation may be a better fit to the (other, unposted) data points. ;)
 
I see your work is nearly correct. The concept is right.

What I found helpful was to consider the points (2000,1) and (500,2) as (x,y) coordinates.

But I took x to be in thousands. So the points would be (2,1) and (1/2,2)

Using the equation for the line y-y1=(x-x1)m where m is slope.

I got y= -2/3x + 7/3.

But remember x is in thousands so 1001 would be entered as 1.001

Someone please check my work.
 
Top