Expiring Today—Celebrate National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

calculation of semilog line

Posted on 2010-09-17
17
Medium Priority
?
513 Views
Last Modified: 2012-05-10
Hi could someone tell me how to calculate the Y I'm asking.

Thx ORDINATE axis is scaled SEMILOG
0
Comment
Question by:cilerler
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 8
  • 6
  • 3
17 Comments
 
LVL 84

Expert Comment

by:ozo
ID: 33704997
Semi-log generally refers to the axes of the graph, and on the log axis, 0 would be infinitely far away, so the the graph you have drawn  is not semi-log

And labeling only two points is not enough to determine the equation of the red curve, since there are an infinite number of curves that match those two points.
0
 

Author Comment

by:cilerler
ID: 33705127
thx for quick reply,  my graph will never go to 0 so it is not the case here but thx for the heads up.

you are right, I realized after your post when I drew that graphic, I didn't use logarithm on Y axis.
and if I use it won't help me on what I need to do.

So what is the way of doing this? what I need?  I mean on linear grahic, how to calculate semilog line (it is semilog confirmed) :) based on given points.

Thx
0
 
LVL 27

Expert Comment

by:aburr
ID: 33705172
Your x axis does not appear to be linear. If it were your question could be answered.
I find it hard to understand a curve labeled linear plotted on a graph with no linear scale
You can get an approximation if you assume the x axis between the last two labeled points on the linear scale is linear.
y = 3.6
0
What does it mean to be "Always On"?

Is your cloud always on? With an Always On cloud you won't have to worry about downtime for maintenance or software application code updates, ensuring that your bottom line isn't affected.

 

Author Comment

by:cilerler
ID: 33705220
dear abur,
thank you for the reply.

X is linear it start from 0 ...  ends at 10000 and increases 1 on each point
and ~3.62376 is the number i  should get (it is estimated like yours) so I'm sure the formula you used is the one i need, may i get the formula please?

thx
0
 
LVL 27

Expert Comment

by:aburr
ID: 33705306
Label the three known points 1, 2, 3.

then the required y is obtained by solving

y2 - y3 divided by a measurement off your graph of the vertical distance between points 2 and 3.
this number is set equal to the desired y divided by the measured distance on your graph of the vertical distance between the ? point and point 3.
-
I measured the required distances off my computer screen. the scale factor between your graph and my screen cancels out.
0
 
LVL 84

Expert Comment

by:ozo
ID: 33705324
a straight line on a semi-log graph would have the form log(y) = a+b*x
so solving for a and b given
 log(7.71695) = a+b*1
log(5.0999) = a+b*191
gives
log(y)=2.04559919918196 - 0.00217999092925162*x
so
log(3.62176818616628) = 2.04559919918196 - 0.00217999092925162*348
0
 

Author Comment

by:cilerler
ID: 33705404
@aburr => I'm sorry but having trouble to following you could you give me a direct formula?
@ozo => thx a lot last favor, could you show write me step by step how did you get the conclusion

log(7.71695) = a+b*1
log(5.0999) = a+b*191
gives
log(y) = 2.04559919918196 - 0.00217999092925162 * x

thx...
0
 
LVL 84

Expert Comment

by:ozo
ID: 33705459

log(5.0999) = a+b*191
-
log(7.71695) = a+b*1
log(5.0999)-log(7.71695) = (a-a) + b*(191-1)

(log(5.0999)-log(7.71695)) / (191-1) = b

log(7.71695) - b*1 = a
0
 
LVL 27

Expert Comment

by:aburr
ID: 33705489
There is no direct formula because my method required two measurements taken off you graph. I used physical measurements because there were difficulties with you graphing.
-
Ozo assumed that your points would form a straight line on a true semi-log plot. A straight line has an equation like z = bx + a, He solve two equations (from your two known points) and used the a and b to calculate the coords of the third point. His answer of 3.62176818616628 (the same as mine but with more decimals) shows that his assumption is likely correct. And that my assumption of linearity in the drawing was not too far off either.
0
 

Author Comment

by:cilerler
ID: 33705807
@ozo: so based on what I understood the below is the formula will be

log(y1)=a+b*x1
log(y2)=a+b*x2
log(y2)-log(y1)=(a-a)+b*(191-1)
b=(log(y2)-log(y1))/(x2-x1)
a=log(y1)-b*1
log(y3)=(log(y1)-((log(y2)-log(y1))/(x2-x1))*1)+((log(y2)-log(y1))/(x2-x1))*x3

final part, how can I leave y3 alone?  for example if it was base 10 then I should do this
y3=10^((log(y1)-((log(y2)-log(y1))/(x2-x1))*1)+((log(y2)-log(y1))/(x2-x1))*x3)
but what I should do if there is no base shown...

actually I tested on base 10 and it did give me correct answer I'm just trying to understand what is the default base value of Log so i can place it if there is no log base...

thx
0
 
LVL 84

Expert Comment

by:ozo
ID: 33705826
a=log(y1)-b*x1
base of the log doesn't matter, as long as you are consistent.
0
 

Author Comment

by:cilerler
ID: 33705859
I'm sorry that pushing it just have to put in a code and couldn't understand it.
so if we say log(y3)=t+z how do you write y3=...
0
 

Author Comment

by:cilerler
ID: 33705866
This might give you idea what I need
Dim b As Double = (Math.Log(y2) - Math.Log(y1)) / (x2 - x1)
Dim a As Double = Math.Log(y1) - b * x1
Dim logY3 As Double = a + b * x3
'Below is the final part of the puzzle :)
Dim y3 as Double = Math.Pow(10, logY3) '<= is this correct?

Open in new window

0
 
LVL 84

Expert Comment

by:ozo
ID: 33705885
it would be correct if Math.Log is base 10
do you have a corresponding Math.Exp?
0
 

Author Comment

by:cilerler
ID: 33705995
Math.Exp is available but when I used it calculation changed so I tried Log10 with Power based on 10 and it did work.  After that I tried another points and have a problem.  Any idea?

x1=1
y1=0.31398
x2=51
y2=0.324621
x3=1453
it calculates y3 as 0.82650432082886593 which should be ~3.54-3.55
based on calculation
a = -0.50338750739956328
b = 0.00028949252287212567
0
 
LVL 84

Accepted Solution

by:
ozo earned 2000 total points
ID: 33706038
I get 0.8265 too
Perhaps you do not have a straight line on a semi-log plot.
0
 

Author Closing Comment

by:cilerler
ID: 33706351
I believe the software I'm using has a problem.  OZO, you made my day.  thank you very much for all your help...

Also let me ask you one more question regarding to this one...

I can get slope with =(Y2-Y1) / (X2-X1) and linear value of the point with =( ( Y2 - Y1 ) / (X2 - X1 ))*( X3 - X1 ) + Y1

isn't there any formula to use these values to get semilog value?  the reason I'm asking is the software I'm using shows the slope and value on that semi log line and I assume they may use these values to calculate it... any idea?

thank you very much again
0

Featured Post

Concerto's Cloud Advisory Services

Want to avoid the missteps to gaining all the benefits of the cloud? Learn more about the different assessment options from our Cloud Advisory team.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Complex Numbers are funny things.  Many people have a basic understanding of them, some a more advanced.  The confusion usually arises when that pesky i (or j for Electrical Engineers) appears and understanding the meaning of a square root of a nega…
Lithium-ion batteries area cornerstone of today's portable electronic devices, and even though they are relied upon heavily, their chemistry and origin are not of common knowledge. This article is about a device on which every smartphone, laptop, an…
This is a video describing the growing solar energy use in Utah. This is a topic that greatly interests me and so I decided to produce a video about it.
Although Jacob Bernoulli (1654-1705) has been credited as the creator of "Binomial Distribution Table", Gottfried Leibniz (1646-1716) did his dissertation on the subject in 1666; Leibniz you may recall is the co-inventor of "Calculus" and beat Isaac…

718 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question