Selected dynamic investment strategies are analyzed within a unifying theoretical framework. We suggest a Kolmogorov-type partial differential equation for a profit and loss (P&L) distribution of strategies contingent on the current value of the basic asset as well as on a balance of a trading account ?P&L-to-date. This gives a possibility to study much wider class of strategies than is usually done in the literature and practical applications. Using our equation we build dynamic efficient frontier and demonstrate that an attempt to minimize variance for a given expected profit leads to a contrarian trading strategy, also known as the St.Petersburg paradox. Similar analysis is performed for the Black-Jones-Perold constant proportion portfolio insurance (CPPI). It is shown that both, dynamic efficient frontier and CPPI, belong to a special class of power-option-replicating strategies. Despite its small Sharpe ratio CPPI has an advantage of controlled downside, as its PL distribution is far from gaussian. Conversely, Sharpe-optimal dynamic efficient frontier has an uncontrollable downside. We show how to blend the advantages of these two strategies. A special part is devoted to discrete analysis and risk capital considerations for non-replicating strategies when P&L-to-date is not a single-valued function of the current asset value and path-dependency is essential.