Value for which cell = x

SHUTTEHFACE

Board Regular
Joined
Aug 13, 2014
Messages
53
Hello!

I'm running into some circular logic that is making my eyes spin. I have cells A & B. Cell B contains a formula which uses A as an input. My question is: I want a cell that gives me the value B for which cell A = X (a certain value, let's say 100%).

Any thoughts?

Thanks!

M
 

Excel Facts

Whats the difference between CONCAT and CONCATENATE?
The newer CONCAT function can reference a range of cells. =CONCATENATE(A1,A2,A3,A4,A5) becomes =CONCAT(A1:A5)
It uses visual basic:
=ErlangCsrv(D3,H3,E3,G3), where D3 is the value I am trying to find that will make this formula = 100%

CODE:

Code:
' Returns the probability a call waits.
' m is the agent count
' u is the traffic intensity
' tt is the target wait time
' tc is the average call time
Public Function ErlangCsrv(ByVal m As Integer, ByVal u As Double, ByVal tc As Double, ByVal tt As Double) As Double
    ErlangCsrv = 1 - ErlangC(m, u) * Math.Exp(-(m - u) * (tt / tc))
End Function

' Returns the probability a call waits.
' m is the agent count
' u is the traffic intensity
Public Function ErlangC(ByVal m As Integer, ByVal u As Double) As Double
    d = PowerFact(m, u)
    s = 1
    For k = 1 To m - 1
        s = s + PowerFact(k, u)
    Next k
    ' ErlangC = s
    ErlangC = d / (d + (1 - u / m) * s)
End Function
 
Upvote 0
Entire Code:

Code:
' By Joannes Vermorel, 2008-05-04' Copyright (c) 2008, LOKAD SAS


' Returns the probability a call waits.
' m is the agent count
' u is the traffic intensity
Public Function ErlangC(ByVal m As Integer, ByVal u As Double) As Double
    d = PowerFact(m, u)
    s = 1
    For k = 1 To m - 1
        s = s + PowerFact(k, u)
    Next k
    ' ErlangC = s
    ErlangC = d / (d + (1 - u / m) * s)
End Function


' Return Power(u, k) / Factorial(k) in a numeric-safe manner.
Public Function PowerFact(ByVal m As Integer, ByVal x As Double) As Double
    s = 0
    For k = 1 To m
        s = s + Math.Log(x / k)
    Next k
    PowerFact = Math.Exp(s)
End Function


' Returns the probability a call waits.
' m is the agent count
' u is the traffic intensity
' tt is the target wait time
' tc is the average call time
Public Function ErlangCsrv(ByVal m As Integer, ByVal u As Double, ByVal tc As Double, ByVal tt As Double) As Double
    ErlangCsrv = 1 - ErlangC(m, u) * Math.Exp(-(m - u) * (tt / tc))
End Function


' Returns the average speed of answer (ASA)
' m is the agent counts.
' u is the traffic intensity
' tc is the average call time
Public Function ASA(ByVal m As Integer, ByVal u As Double, ByVal tc As Double) As Double
    ASA = ErlangC(m, u) * tc / (m - u)
End Function
 
Upvote 0

Forum statistics

Threads
1,214,885
Messages
6,122,090
Members
449,065
Latest member
Danger_SF

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top