Hello all,
I'm very new to deal.II and I've made some small modifications to the step-22 tutorial in an effort to validate (for myself) how to simulate a simple channel-flow problem. I've run into an issue that might be a bug, but more likely I believe I'm missing something (hopefully obvious) about how boundary constraints are handled. Below I detail what I have changed from step-22, as well as include the code and a screenshot of the output which shows the issue. For a one-sentence summary: I'm trying to do channel flow (left-to-right) while prescribing velocity boundary conditions on the inflow (left) and walls (top,bottom), and homogeneous neumann on the outflow (right); the result is generally what is expected except for the solution near the outflow boundary.
From step-22, I have made two modifications: (1) boundary id's changed so that top, left, and bottom have boundaryid=1 and right boundary has boundaryid=0, and (2) implement exact solution function for simple 2D channel flow, to be implement on boundaryid=1. This should give flow from left to right. Nothing else about the program is changed.
As can be seen from the screenshot, there is error near the outflow where the flow has non-zero vertical component (it should be zero) and the pressure is not constant on the outflow boundary. The velocity values on the boundaries do satisfy the boundary conditions. I've tried (a) using a direct solver and (b) implementing boundary conditions after assembly and both of those changes (not included in attached code) gave the same solution.
I've tried looking through tutorials, as well as other similar questions relate to boundary conditions on this forum, but nothing has worked so far. Any help would be greatly appreciated!
Best,
Patrick