View Issue Details

IDProjectCategoryView StatusLast Update
0003481OpenFOAMBugpublic2020-04-15 15:10
ReporterDaveD Assigned Towill  
Status resolvedResolutionfixed 
PlatformGNU/LinuxOSUbuntuOS Version18.04
Fixed in Versiondev 
Summary0003481: Bug in wallHeatFlux field calculation for patches
DescriptionIn OpenFoam v7, one can give the wall patches for which the wallHeatFlux field shall be calculated, otherwise wallHeatFlux is calculated for all wall patches.

    type wallHeatFlux;
    libs ("");
    patches ("wall_heated");
    writeControl writeTime;

In postprocessing/wallHeatFlux/0/wallHeatFlux.dat, OpenFoam writes the min/max/integral values of the patch "wall_heated" as it should.
However, in the volScalarField that is created for each writeTime, wallHeatFlux is calculated for arbitrary patches, no matter which patches are being specified for calculation. In my case, wallHeatFlux was calculated for wall_heated and for inlet, the latter of which is purely non-sense.

Obviously, wallHeatFlux loops for the field creation over all boundaries and not the ones being specified (wallHeatFlux.C, line 87 f.):

    forAll(wallHeatFluxBf, patchi)
    { ...

In contrast, wallShearStress does what it should (wallShearStress.C, line 79 ff.):

    forAllConstIter(labelHashSet, patchSet_, iter)
        label patchi = iter.key();

See also
TagsNo tags attached.



2020-04-15 15:10

manager   ~0011291

Agreed. wallHeatFlux should output values on walls only, unless finer per-patch control is specified by the user. Resolved in dev by

Issue History

Date Modified Username Field Change
2020-04-15 09:56 DaveD New Issue
2020-04-15 10:20 henry Severity major => minor
2020-04-15 15:10 will Assigned To => will
2020-04-15 15:10 will Status new => resolved
2020-04-15 15:10 will Resolution open => fixed
2020-04-15 15:10 will Fixed in Version => dev
2020-04-15 15:10 will Note Added: 0011291