Physics 5—Scientific  Computing

Instructor: Geoff Hagopian,
office: Math 12
email: ghagopian@colleGEOFthedesert.edu
phone: 776-7223

Meetings: TR: 5:15-7:45

[Syllabus]

[Calendar]
[Compilers]
[Exams]
[References]

[Grades]

babbage machine

Compiler/IDE Options:

To write and test computer programs you need to combine a variety of different software in what is called an "Integrated Development Environment" (an I.D.E.).  This can vary from using a common text editor such as Edit or Gedit or Emacs on a UNIX platform or Notepad on a Windows operating system to create .txt files which you can compile and link with other software such as cygwin.exe or gcc.exe...to a more comprehensive all-in-one sort of package which is specifically designed to combine all these tasks under one umbrella.

In this course you will need to use the Microsoft Visual Studio C++ IDE together with the MS Aug/2007 edition of DirectX 9.0 and the Dark GDK. These are available on the disk that comes with a new text from the bookstore or you can download and install these from the internet by following the instructions in Appendix A of the Games and Graphics in C++ text, which I repeat here:

  1. Download and install Visual C++ 2008 Express Edition from here. Don't forget to run the installer after downloading.
  2. Start the Visual C++ Express Edition at least once so it can create some initialization files: Windows start/all programs/click VC++/click MS VC++. Once it is open, you can close it.
  3. Download and install the August 2007 DirectX 9.0c SDK and the Dark GDK here. These are large and take some time. Once the DirectX file has downloaded, the WinZip dialog box will appear. Make sure the "Overwrite files without prompting" and "When done unzipping open: Setup.exe" boxes are checked, and then click the Unzip button. The program will begin unzipping files to your system, and then you will see a dialog box indicating that the files were unzipped successfully. Click OK to dismiss the dialog box.
  4. Keep pressing "next" until the installation begins and wait until you see the "InstallShield Wizard Completed" message.
  5. After the DirectX is installed, go back to the Dark GDK page and click the link to download the Dark GDK,. Click Run to install the Dark GDK. This is another large file, so be patient. When the "next" button appears again, click it and accept each of the default options on each of the screens that you see. When it is finished you should see the message, "Installation Complete."
  6. Finally, download the sample source code for the examples shown in the book, sample media files and game case studies here. Click on the image of the Games and Graphics in C++ cover and follow the links to gather these resources.

Other IDE's you might want to use include:

The IDE that comes on the disk that is bundled with the text, Starting Out With C++, by Gaddis is the Borland C++ Builder 6.  Detailed instructions for how to set this up are in Appendix L on the supplementary disc.

Here are some Deitel resources you may find handy. Deitel is an alternate text for this class.

http://www.deitel.com/ResourceCenters/Programming/C/CCompilersandDevelopmentTools/tabid/228/Default.aspx

http://www.deitel.com/ResourceCenters/Programming/CPlusPlus/tabid/224/Default.aspx

Various resources are available at http://www.deitel.com/books/downloads.html#cppHTP4.  To get a nice overview of what's in the book, you might look at the tour of the book.

There are also instructions (you'll need the free acrobat reader to read these .pdf files) for

  • how to set up the UNIX emulating cygwin environment on a Windows operating system (Dive Into GNU C++ with CygWin on Windows)
  • how to author and compile simple console applications in the relatively complex environment of MS Visual C++ environment (Dive Into Microsoft Visual C++ .NET)
  • how to set up and use the Borland 5.5 free C++ compiler with an editor

A favorite IDE is DevCpp, which is available for free download at http://www.bloodshed.net/devcpp.html. Go to the two links at the bottom of the page and follow either the Download from Sourceforge.net link or the Download from Simtel.net link.

While not as robust as the Visual C++ IDE's, DevCpp is attractive for several features:

  • it's small
  • it's free
  • it doesn't have a lot of features we'll never use in this class
  • the editor is robust and flexible
  • it's really easy to set up on most Windows platforms

Finally, a note of caution: many of these IDE's may want to be the default editor. It's possible to have several compilers and editors together on the same computer, but only one can be the "default."