Take the 2-minute tour ×
Mathematics Stack Exchange is a question and answer site for people studying math at any level and professionals in related fields. It's 100% free, no registration required.

In a straight line equation ' y = mx + b ' if i have 'm' and 'x' how can i get 'b' (where the line cross the Y axis)? I search on the internet they said to get it by drawing it and see where it cross the Y axis, and this not possible since the numbers am dealing with is very large.

share|improve this question
1  
How is that calculus? –  user824294 Oct 30 '12 at 7:40
2  
Will you please share more information on the set-up of the problem? Typically $x$ is not a constant, so you do not "have" it. It is a variable. You may be given a particular pair $(x,y)$ that satisfies the equation in addition to $m$. Is that what you mean? –  Jonas Meyer Oct 30 '12 at 7:41
1  
@Swaiss: Could you please give an example of what information you are given? –  Jonas Meyer Oct 30 '12 at 7:46
1  
this is two points on the line am working on it: point 1 = (419445.4712 , 1683997.1179) point 2 = (419438.9394 , 1683999.5773) –  RASHOMON Oct 30 '12 at 7:55
2  
@Swaiss: Your problem with two points is not what you described previously. Just knowing $m$ and a value of $x$ would not tell you much: Every value of $x$ will be part of a solution to an equation with a given $m$. But with two points, we're getting somewhere. If you know how to find $m$, and you also know a particular solution $(x,y)$, which can be given by either of your two points, plug in those three numbers into the equation $y=mx+b$ to leave $b$ as the only unknown, then solve. See also purplemath.com/modules/strtlneq.htm –  Jonas Meyer Oct 30 '12 at 7:58
show 3 more comments

1 Answer 1

up vote 2 down vote accepted

It looks like you have two points $(x_1,y_1)$ and $(x_2,y_2)$ so you can set up two simultaneous equations

$$y_1=mx_1+b$$$$y_2=mx_2+b$$Multiply the first by $x_2$ and the second by $x_1$

$$y_1x_2=mx_1x_2+bx_2$$$$y_2x_1=mx_1x_2+bx_1$$subtract:$$y_1x_2-y_2x_1=b(x_2-x_1)$$ and go from there.

You might also like to investigate the form:$$y=y_1\frac{(x-x_2)}{(x_1-x_2)}+y_2\frac{(x-x_1)}{(x_2-x_1)}$$ which is a direct way of writing the equation of a line through two points. The form can be developed to give the equation of a quadratic through three points, and generally the lowest degree curve through $n$ points.

share|improve this answer
    
Thank you very much. –  RASHOMON Oct 30 '12 at 8:16
1  
You could also get the slope $m$ from $m = \frac{\text{rise}}{\text{run}} = \frac{y_2 - y_1}{x_2 - x_1}$, and then use either equation to get $b$. –  littleO Oct 30 '12 at 8:41
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.