Determining the value of a point on a graph

heywannalaugh

New member
Joined
Dec 18, 2018
Messages
7
Hey everyone... my first post! I am working on some mapping software, and I need to be able to calculate the latitude on a graph as the user moves the mouse cursor. I hope the picture explains it all, but if not, please let me know, thank you!


Pixel.jpg
 
First, please read a summary of our guidelines.

Because this appears to come from a course that is not a math course, we have no clue what your knowledge in math is so how can we know how to help you. Give us some brief information about your training in math and what course this problem came from.

Finally, what are your ideas on how to start?

EDIT: You posted this in arithmetic. Is that because you never studied any math past arithmetic?
 
Last edited:
You need a function that takes y (from 1 to 1000) and returns the corresponding value of L (from 10 to 1).
f(1) = 10, f(1000) = 1.
Any ideas? 1st step - how about making the ranges the same? (i.e. map 1-1000 to 1-10).
 
First, please read a summary of our guidelines.

Because this appears to come from a course that is not a math course, we have no clue what your knowledge in math is so how can we know how to help you. Give us some brief information about your training in math and what course this problem came from.

Finally, what are your ideas on how to start?

EDIT: You posted this in arithmetic. Is that because you never studied any math past arithmetic?
Sure, I would be happy to read your community guidelines, but for some reason I am unable to find them. Can you please post a link and I will read those asap?

Me personally, in college I completed all the way through Calculus 2, but my math is extremely rusty at this point.

I posted in arithmetic because I could not find the best place to create the thread.

Here is what I have so far.

Latitude = ((LatitudeBottom * FormBottom) / (LatitudeTop * FormTop)) / 2

It returns a value of 5, which is the answer I was looking for because it was between the 10 and 1 range , but I just did not know where to include the pixel location so that it would return the result for that actual pixel. Thank you!
 
You need a function that takes y (from 1 to 1000) and returns the corresponding value of L (from 10 to 1).
f(1) = 10, f(1000) = 1.
Any ideas? 1st step - how about making the ranges the same? (i.e. map 1-1000 to 1-10).
Sounds great, thank you! I am just not sure where to go from there ;).
 
Let's consider an easier case: how do you convert a value from the range 1-3 to 2-4?
Thank you for your response. I see that your 1-3 to 2-4 example is indeed less confusing so that we can differentiate the two variables that equal 1, but it does not tell me what function to use. I read the link you provided on functions and I am not able to figure out what function to use.
 
Thank you for your response. I see that your 1-3 to 2-4 example is indeed less confusing so that we can differentiate the two variables that equal 1, but it does not tell me what function to use. I read the link you provided on functions and I am not able to figure out what function to use.

The function link was added automatically.

Ok. We need to go from 1-3 to 2-4. In particular, 1 becomes 2 and 3 becomes 4. Can you think of a rule that does that?
 
Sure, I would be happy to read your community guidelines, but for some reason I am unable to find them. Can you please post a link and I will read those asap?
Oops, sorry.

https://www.freemathhelp.com/forum/threads/112086-Guidelines-Summary?p=433156&viewfull=1#post433156

Me personally, in college I completed all the way through Calculus 2, but my math is extremely rusty at this point.

I posted in arithmetic because I could not find the best place to create the thread.

Here is what I have so far.

Latitude = ((LatitudeBottom * FormBottom) / (LatitudeTop * FormTop)) / 2

It returns a value of 5, which is the answer I was looking for because it was between the 10 and 1 range , but I just did not know where to include the pixel location so that it would return the result for that actual pixel. Thank you!
If I understand your question, the formula you need is

\(\displaystyle v = 1000 - \dfrac{999(x - m)}{n - m}, \text { where}\)

\(\displaystyle v = \text { vertical pixel address;}\)

\(\displaystyle x = \text { actual latitude;}\)

\(\displaystyle m = \text { lowest latitude; and}\)

\(\displaystyle n = \text { highest latitude.}\)

Let's see how that works with your example, where m = 1 and n = 10.

\(\displaystyle \text {If } x = 1 \implies v = 1000 - \dfrac{999(1 - 1)}{10 - 9} = 1000 -\dfrac{999 * 0}{9} = 1000.\)

That is, I believe, what you want. (Of course, I may not understand the question.)

\(\displaystyle \text {If } x = 10 \implies v = 1000 - \dfrac{999(10 - 1)}{10 - 1} = 1000 - 999 = 1.\)

Again, I suspect this is what you want.

Half way between 1 and 10 is latitude 5.5.

\(\displaystyle \text {If } x = 5.5 \implies v = 1000 - \dfrac{999(5.5 - 1)}{10 - 1} = 1000 - \dfrac{999}{2} \approx 1000 - 500 = 500.\)

It is not exact because of grain size.
 
Last edited:
The function link was added automatically.

Ok. We need to go from 1-3 to 2-4. In particular, 1 becomes 2 and 3 becomes 4. Can you think of a rule that does that?
How funny, I noticed that the link was added automatically after I submitted my post with that word.

Thank you for your help, it looks like Jeff nailed it.
 
Oops, sorry.

https://www.freemathhelp.com/forum/threads/112086-Guidelines-Summary?p=433156&viewfull=1#post433156


If I understand your question, the formula you need is

\(\displaystyle v = 1000 - \dfrac{999(x - m)}{n - m}, \text { where}\)

\(\displaystyle v = \text { vertical pixel address;}\)

\(\displaystyle x = \text { actual latitude;}\)

\(\displaystyle m = \text { lowest latitude; and}\)

\(\displaystyle n = \text { highest latitude.}\)

Let's see how that works with your example, where m = 1 and n = 10.

\(\displaystyle \text {If } x = 1 \implies v = 1000 - \dfrac{999(1 - 1)}{10 - 9} = 1000 -\dfrac{999 * 0}{9} = 1000.\)

That is, I believe, what you want. (Of course, I may not understand the question.)

\(\displaystyle \text {If } x = 10 \implies v = 1000 - \dfrac{999(10 - 1)}{10 - 1} = 1000 - 999 = 1.\)

Again, I suspect this is what you want.

Half way between 1 and 10 is latitude 5.5.

\(\displaystyle \text {If } x = 5.5 \implies v = 1000 - \dfrac{999(5.5 - 1)}{10 - 1} = 1000 - \dfrac{999}{2} \approx 1000 - 500 = 500.\)

It is not exact because of grain size.
Thank you Jeff, I appreciate that! No wonder I was struggling so much, I never would have figured that out. But now that I see it, it makes perfect sense. I have not tested it yet, but it looks like it will work. Thank you guys for all of your help!
 
Thank you Jeff, I appreciate that! No wonder I was struggling so much, I never would have figured that out. But now that I see it, it makes perfect sense. I have not tested it yet, but it looks like it will work. Thank you guys for all of your help!
You are of course welcome.

This merely shows how poorly we teach mathematics. You took two semesters of college calculus, yet the derivation of that formula involves a simple technique taught in the first few months of high school algebra. We spend far too little time on teaching people how to use the math we teach them, and consequently, they forget it as irrelevant to their lives.

If you want to learn how to do these scaling problems, keep on working with lev.
 
You are of course welcome.

This merely shows how poorly we teach mathematics. You took two semesters of college calculus, yet the derivation of that formula involves a simple technique taught in the first few months of high school algebra. We spend far too little time on teaching people how to use the math we teach them, and consequently, they forget it as irrelevant to their lives.

If you want to learn how to do these scaling problems, keep on working with lev.
So true... I could not agree more ;). When I was in elementary and high school, the teachers told us that we had to learn this stuff because "It's not like you are going to have a calculator in your pocket wherever you go!" ;) In a way they were correct, only in that we actually all have a computer in our pocket ;). From what I hear, they are not even teaching cursive writing anymore. Usually change is good, but not in these two cases. Thanks again!
 
Top