Teaching

Computational Macroeconomics Course


Fortran Programming


Overview

Basics

Arrays

Functions, Subroutines, and Modules

Input/Output

External Libraries

More on Functions and Subroutines

Object-Oriented Programming

Optimization

Parallel Programming


Numerical Methods


Discretization and Error Assessment

Linear Interpolation and Splines

Nonlinear Equations, Numerical Error, and Differentiation

Optimization

Projection Methods

Quadrature

Linearization and Perturbation

Continuous Time


Homeworks

#1

#2

#3

#4


Minicourse on heterogeneous agent macro


Slides


Other Tools / Resources


Getting starting in Linux

Here


Gnuplot


Gnuplot examples

Data file for examples (I based much of this on http://people.duke.edu/~hpgavin/gnuplot.html)


Links to Fortran Programming Tools

gedit - free text editor with Fortran90 syntax highlighting, see the right column for links to binaries in Windows and Mac.

gnuplot - free plotting that works on all the major platform. There is a Windows binary at the link. With Linux, you can use apt-get. With Mac, you can use Macports or Homewbrew to install.


Other Links

Macports - a way to install development software in Mac, including gcc/gfortran and openmpi. Note: optimized versions of BLAS and LAPACK come with OS X. You just need to link with -framework Accelerate (if using gcc/gfortran).

NLopt - great collection of minimization routines, callable from Fortran, C, or even Matlab (I have not tried the last two though).

Surprising bugs