In recent years, there has been growing interest in making computational fluid dynamics (CFD) predictions with quantifiable uncertainty. Tangent-mode sensitivity analysis and uncertainty propagation are integral components of the uncertainty quantification process. Generalized polynomial chaos (gPC) is a viable candidate for uncertainty propagation, and involves representing the dependant variables in the governing partial differential equations (pdes) as expansions in an orthogonal polynomial basis in the random variables. Deterministic coupled non-linear pdes are derived for the coefficients of the expansion, which are then solved using standard techniques. A significant drawback of this approach is its intrusiveness. In this paper, we develop a unified approach to automatic code differentiation and Galerkin-based gPC in a new finite volume solver, MEMOSA-FVM, written in C++. We exploit templating and operator overloading to perform standard mathematical operations, which are overloaded either to perform code differentiation or to address operations on polynomial expansions. The resulting solver is capable of either performing sensitivity or uncertainty propagation, with the choice being made at compile time. It is easy to read, looks like a deterministic CFD code, and can address new classes of physics automatically, without extensive re-implementation of either sensitivity or gPC equations. We perform tangent (forward) mode sensitivity analysis and Galerkin gPC-based uncertainty propagation in a variety of problems, and demonstrate the effectiveness of this approach.

This content is only available via PDF.
You do not currently have access to this content.