Code covered by the BSD License  

Highlights from
Exercises in Advanced Risk and Portfolio Management

from Exercises in Advanced Risk and Portfolio Management by Attilio Meucci
text and comments on solutions available at http://symmys.com/node/170

[mu,sigma_square]=LognMomentsToParameters(e,v)
function [mu,sigma_square]=LognMomentsToParameters(e,v)

% this function inverts the formulas (1.98)-(1.99) in the book 
% "Risk and Asset Allocation" - Springer.

sigma_square=log(1+v/(e^2));
mu=log(e)-sigma_square/2;

Contact us at files@mathworks.com