Results 1 to 12 of 12
Like Tree4Thanks
  • 2 Post By DenisB
  • 2 Post By SlipEternal

Thread: Unable to solve equation -- please help!

  1. #1
    Newbie
    Joined
    Jul 2018
    From
    Amsterdam, Ohio
    Posts
    6

    Unable to solve equation -- please help!

    I'm trying to isolate ST, i.e. ST = ...

    PR = (1-((1-(1-(WR/100))^ST)^((TR*365*50)-(ST-1))))*100

    Can anyone help me?
    Follow Math Help Forum on Facebook and Google+

  2. #2
    MHF Contributor
    Joined
    Feb 2015
    From
    Ottawa Ontario
    Posts
    1,929
    Thanks
    359

    Re: Unable to solve equation -- please help!

    That monster looks to me like a financial formula, ST being the number of periods; yes?
    As far as I can tell, cannot be solved directly for ST; numeric method required.

    Anyhoooo: I suggest you simplify it as much as possible, a bit this way:
    p=PR, w=WR/100, t=TR*365*50, s=ST
    Thanks from joelray712 and topsquark
    Follow Math Help Forum on Facebook and Google+

  3. #3
    MHF Contributor
    Joined
    Nov 2010
    Posts
    3,631
    Thanks
    1457

    Re: Unable to solve equation -- please help!

    Quote Originally Posted by joelray712 View Post
    I'm trying to isolate ST, i.e. ST = ...

    $$PR = \left(1-\left[ \left(1-\left[1-\left( \dfrac{WR}{100} \right) \right]^{ST} \right)^{TR\cdot 365\cdot 50-ST+1} \right] \right)*100$$

    Can anyone help me?
    I reformatted this to make it easier to read. There is no easy way to isolate $ST$. You are likely to wind up with the Lambert W function in the solution. Let's give single letters to every double-letter variable. $ST = x, WR = y, TR = z, PR = w$. Then you have:

    $$w = \left(1-\left[ \left(1-\left[1-\left( \dfrac{y}{100} \right) \right]^{x} \right)^{18250z-x+1} \right] \right)*100$$

    Perhaps a computer algebra system would be able to chew through this and solve for $x$, but there is no easy way to do that. The problem is that you have $x$ in two separate exponents.
    Thanks from DenisB and joelray712
    Follow Math Help Forum on Facebook and Google+

  4. #4
    Newbie
    Joined
    Jul 2018
    From
    Amsterdam, Ohio
    Posts
    6

    Re: Unable to solve equation -- please help!

    Very astute of you; yes, it's a financial formula. PR = probability of x consecutive losing trades, WR = win-rate, TR = number of trades per day and ST = streak of consecutive losing trades.
    Follow Math Help Forum on Facebook and Google+

  5. #5
    Newbie
    Joined
    Jul 2018
    From
    Amsterdam, Ohio
    Posts
    6

    Re: Unable to solve equation -- please help!

    Thank you SlipEternal for the cleaned-up formula and assessment of the unfeasibility of isolating ST. The problem of ST existing in two separate exponents was what was holding me up.
    Follow Math Help Forum on Facebook and Google+

  6. #6
    MHF Contributor
    Joined
    Feb 2015
    From
    Ottawa Ontario
    Posts
    1,929
    Thanks
    359

    Re: Unable to solve equation -- please help!

    Quote Originally Posted by joelray712 View Post
    PR = (1-((1-(1-(WR/100))^ST)^((TR*365*50)-(ST-1))))*100
    which is really:
    PR/100 = 1-((1-(1-(WR/100))^ST)^((TR*365*50)-(ST-1)))
    right?
    PR = probability of x consecutive losing trades,
    WR = win-rate,
    TR = number of trades per day
    ST = streak of consecutive losing trades.
    Are these "reasonable" values:
    PR = 25 (25% probability)
    WR = 65 (win 65% of time)
    TR = dunno...perhaps >0 and <100?
    ST = calculated using above

    Can you supply a clear actual example, and ST's calculated value?
    I think can be solved not directly but from a very simple looper program.....
    Follow Math Help Forum on Facebook and Google+

  7. #7
    MHF Contributor
    Joined
    Feb 2015
    From
    Ottawa Ontario
    Posts
    1,929
    Thanks
    359

    Re: Unable to solve equation -- please help!

    ALSO: can you explain "TR*365*50"....makes no sense to me as a power...
    Follow Math Help Forum on Facebook and Google+

  8. #8
    Newbie
    Joined
    Jul 2018
    From
    Amsterdam, Ohio
    Posts
    6

    Re: Unable to solve equation -- please help!

    Ideally, the probability (PR) should be around 0.1%, since it is the probability of losing a certain number of trades in a row which would lead to a trading-account drawdown of a certain percentage (in my case 20%).

    Win-rate (WR) at 65% is good.

    Trades per day (TR) is usually around 0.5 or so, since the setups that I trade don't occur every day -- and also since there are only 5 trading days per week.

    The streak (ST) is calculated using the amount of risk per trade to find the number of losing trades that would lead to a maximum account drawdown of 20%. Depending on the strategy, the streak number is usually around 10-15.

    TR*365*50 is intended to return the total possible number of trades in 50 years.

    Thank you kindly for all your help!
    Follow Math Help Forum on Facebook and Google+

  9. #9
    MHF Contributor
    Joined
    Feb 2015
    From
    Ottawa Ontario
    Posts
    1,929
    Thanks
    359

    Re: Unable to solve equation -- please help!

    So, using WR = 65, TR = .5 and ST = 12, then PR = ~3.033

    PR = (1-((1-(1-(65/100))^12)^((.5*365*50)-(12-1))))*100 = ~3.033

    ...which means PRobability = approx. 3.033

    Relating that to your .1% then means 3.033/100 = .03% (approx.) : yes?

    What seems STRANGE to me is : ^((TR*365*50)-(ST-1))))
    WHY have -(ST - 1) in there: seems meaningless; here's why:

    PR = (1-((1-(1-(65/100))^12)^((.5*365*50)-(12-1))))*100 = 3.030328833
    remove the (ST - 1):
    PR = (1-((1-(1-(65/100))^12)^((.5*365*50)))*100 = 3.030364876
    ....a difference of .000036043

    Sooooo: remove the darn thing!!
    Get my drift?

    I hope SlipEternal checks this out...in case I goofed!!
    Follow Math Help Forum on Facebook and Google+

  10. #10
    Newbie
    Joined
    Jul 2018
    From
    Amsterdam, Ohio
    Posts
    6

    Re: Unable to solve equation -- please help!

    Hi DenisB,

    My apologies for my delayed response; I've been traveling around in Europe and the Middle East. Currently on a break in the Iceland airport.

    I tested out your hypothesis about simply removing -(ST - 1), and it does seem to make only a minimal difference, insignificant for my purposes.

    I'm still trying to isolate ST. I've got this far but am having a mental block.

    PR = (1-((1-(1-(WR/100))^ST)^(TR*365*50))*100
    PR/100 = 1-((1-(1-(WR/100))^ST)^(TR*365*50)
    -(PR/100 - 1) = (1-(1-(WR/100))^ST)^(TR*365*50)
    (TR*365*50) = ln(-(PR/100 - 1))/ln((1-(1-(WR/100))^ST))
    (TR*365*50)*ln((1-(1-(WR/100))^ST) = ln(-(PR/100 - 1))

    Do you know how to isolate ST?

    Any help is much appreciated!
    Follow Math Help Forum on Facebook and Google+

  11. #11
    MHF Contributor
    Joined
    Feb 2015
    From
    Ottawa Ontario
    Posts
    1,929
    Thanks
    359

    Re: Unable to solve equation -- please help!

    Quote Originally Posted by joelray712 View Post
    -(PR/100 - 1) = (1-(1-(WR/100))^ST)^(TR*365*50)
    Rearrange your equation this way: a = (b^c)^d
    You want to solve for c.
    c = log(a^(1/d)) / log(b)
    Follow Math Help Forum on Facebook and Google+

  12. #12
    Newbie
    Joined
    Jul 2018
    From
    Amsterdam, Ohio
    Posts
    6

    Re: Unable to solve equation -- please help!

    Thank you!
    Follow Math Help Forum on Facebook and Google+

Similar Math Help Forum Discussions

  1. Unable to Solve Problem
    Posted in the Geometry Forum
    Replies: 2
    Last Post: Jan 15th 2010, 10:58 PM
  2. Unable to solve this limit problem
    Posted in the Calculus Forum
    Replies: 1
    Last Post: Oct 27th 2009, 08:28 AM
  3. Unable to solve roots expression
    Posted in the Algebra Forum
    Replies: 16
    Last Post: Jun 13th 2009, 12:53 PM
  4. 3/5 - Written problem (unable to solve)
    Posted in the Algebra Forum
    Replies: 1
    Last Post: Oct 6th 2008, 01:03 PM
  5. Replies: 3
    Last Post: Sep 3rd 2008, 05:56 PM

/mathhelpforum @mathhelpforum