Wednesday 16 March 2011

Allowing everyone to verify the models


Using a relative heavy IDE (Integrated Development Environment) like the free Visual Studio Express version for running the Monte Carlo - type simulations discussed in this blog makes it possible for everyone with a (Windows) computer to verify these models.
A nice feature is the debugging possibility. This allows even those interested but with less programming experience to follow the code line by line while running, and inspecting the values in each calculation on the job. Of course this is essential in any attempt to prove Bell wrong by a simulation. With Visual Studio one just has to use the following steps:
  1. Download and install the free version of VS2010 C#  (Express)  from http://www.microsoft.com/express/Downloads/#2010-Visual-CS (first only a setup program of 3,5 MB is used, later for the real program  about 141 MB is downloaded)
  2. Download the model(s) discussed from SourceForce and unzip the zip-archive
  3. Start VS2010 C# express
  4. Use File, Open Project to open the solution file EPR_Bohm.sln
  5. Start the simulation by pressing F5
After a short compilation time the program will show the main window that can be used for running a simulation.



Debugging
For following the logic of the model, one just has to open a relevant file from the Project Explorer window, like Calc_Epr.cs, and click in the left (grey) margin to set a breakpoint. Whenever the line with the breakpoint is executed, the program halts at that point (1). Then, by right-clicking the objects used in that part of code, their current contents can be inspected . Even more, one can follow the execution of the program line by line by using the Step Into, Step Over and Step Out buttons (2).

No comments:

Post a Comment