Skip to Content
Financial Simulation Modeling in Excel
book

Financial Simulation Modeling in Excel

by Keith Allman, Josh Laurito, Michael Loh
October 2011
Beginner
216 pages
5h 47m
English
Wiley
Content preview from Financial Simulation Modeling in Excel

OTHER METHODS OF GENERATING NORMAL PSEUDORANDOM NUMBERS

Earlier in this chapter we discussed the merits of using different methods and algorithms to generate uniform pseudorandom numbers and found the RAND function to be suitable in many financial situations. Further transforming the uniform pseudorandom numbers can be done quite easily using the NORMSINV function, but as we get more advanced and possibly switch entirely to a code-based solution, we may want to explore more computationally efficient methods of transformation.

The Box-Muller transformation is a widely accepted method of taking uniform pseudorandom numbers and creating normal pseudorandom numbers. The Box-Muller transformation uses the trigonometric functions SIN and COS. If a simulation were being done in VBA, using this transformation would be more efficient than using NORMSINV, since NORMSINV would have to be called from the WorksheetFunction library, while SIN and COS are contained in the VBA library. Code that is written with references to the WorksheetFunction library is generally slower than code using the VBA library.

Implementing the Box-Muller transformation is relatively simple and can be done on the sheet as shown in the following Model Builder.

MODEL BUILDER 2.5: Creating Normal Pseudorandom Numbers Using the Box-Muller Transformation

  1. Insert a new sheet in the Model Builder 2 workbook that you have been working in. Name this sheet “Box-Muller”.
  2. Label the following cells:

    C5: “Uniform 1”

    D5: “Uniform ...

Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.

Read now

Unlock full access

More than 5,000 organizations count on O’Reilly

AirBnbBlueOriginElectronic ArtsHomeDepotNasdaqRakutenTata Consultancy Services

QuotationMarkO’Reilly covers everything we've got, with content to help us build a world-class technology community, upgrade the capabilities and competencies of our teams, and improve overall team performance as well as their engagement.
Julian F.
Head of Cybersecurity
QuotationMarkI wanted to learn C and C++, but it didn't click for me until I picked up an O'Reilly book. When I went on the O’Reilly platform, I was astonished to find all the books there, plus live events and sandboxes so you could play around with the technology.
Addison B.
Field Engineer
QuotationMarkI’ve been on the O’Reilly platform for more than eight years. I use a couple of learning platforms, but I'm on O'Reilly more than anybody else. When you're there, you start learning. I'm never disappointed.
Amir M.
Data Platform Tech Lead
QuotationMarkI'm always learning. So when I got on to O'Reilly, I was like a kid in a candy store. There are playlists. There are answers. There's on-demand training. It's worth its weight in gold, in terms of what it allows me to do.
Mark W.
Embedded Software Engineer

You might also like

Hands-On Financial Modeling with Microsoft Excel 2019

Hands-On Financial Modeling with Microsoft Excel 2019

Shmuel Oluwa

Publisher Resources

ISBN: 9780470931226Purchase book