Exemplo n.º 1
0
        private void InitialiseViewModel()
        {
            Sampler sampler = new Sampler();
            BasicStochasticEngine stochasticEngine = new BasicStochasticEngine(sampler);

            ViewModel   = new EquityOptionHedgingVM(stochasticEngine);
            DataContext = ViewModel;
        }
        private BasicStochasticEngine GetStochasticEngine(int?seed)
        {
            var randomGenerator  = new BasicRandomNumberGenerator(seed);
            var sampler          = new Sampler(randomGenerator);
            var stochasticEngine = new BasicStochasticEngine(sampler);

            return(stochasticEngine);
        }