Main Program - SS 2-D Advective Diffusion
Finite-Volume Formulator
Matrix Solver

u velocity
w velocity
Steady 2-D advection-diffusion Power-Law scheme

The main program sets up geometry of solution domain for 2-D advective diffusion with uniform density rho and conductivity Gamma. Patankar's power-law scheme is used for advection.

  • The boundaries of this solution domain are on finite-volume faces, but additional nodes are added on the boundaries (Patankar's Practice B, p.69).
  • Boundary conditions can be either fixed phi or fixed phi gradient at each face on the boundary. For example, in bc_e, first column is numerical value of BC, second column specifies BC type - 1 for value, 2 for gradient.
  • u.m and w.m find velocities on appropriate volume boundaries
  • A.m and F_upwind.m implement power-law advection scheme

solve.m solves the resulting system of linear equations.