-
Notifications
You must be signed in to change notification settings - Fork 1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Functor material properties #18395
Functor material properties #18395
Commits on Oct 1, 2021
-
Configuration menu - View commit details
-
Copy full SHA for a9902f7 - Browse repository at this point
Copy the full SHA a9902f7View commit details -
This check was immediately triggered because we add three material objects per material in the input file, e.g. volumetric, face, and neighbor face materials. Without the check we are vulnerable to user error such as defining two materials in the input file that define the same functor property on a given block. Maybe the best remedy in the future is to have distinct `FunctorMaterials` that don't get added in triplicate because there is no functional reason for that in a system where we are evaluating material properties on the fly as opposed to having references to triplicate storage
Configuration menu - View commit details
-
Copy full SHA for 23b8fd7 - Browse repository at this point
Copy the full SHA 23b8fd7View commit details -
Configuration menu - View commit details
-
Copy full SHA for d1e8c09 - Browse repository at this point
Copy the full SHA d1e8c09View commit details -
Configuration menu - View commit details
-
Copy full SHA for 797df91 - Browse repository at this point
Copy the full SHA 797df91View commit details -
Configuration menu - View commit details
-
Copy full SHA for 26fc5a9 - Browse repository at this point
Copy the full SHA 26fc5a9View commit details -
Configuration menu - View commit details
-
Copy full SHA for a049ee8 - Browse repository at this point
Copy the full SHA a049ee8View commit details -
Configuration menu - View commit details
-
Copy full SHA for f994f88 - Browse repository at this point
Copy the full SHA f994f88View commit details -
Create and define the FunctorInterface
GenericFunctors inherit from FunctorInterface and these are the building block for constant functors and material property functors. Variables also inherit from FunctorInterface. This commit also adds the FaceInfo operator() overload to the FunctorInterface. This overload takes FaceInfo, Limiter, and bool element_is_upwind arguments as a tuple to allow unambiguous creation of face values. Corresponding to this addition we have created a new getInternalFaceValue overload in MooseVariableFV that uses cell values, gradient, and the limiter to compute the face value
Configuration menu - View commit details
-
Copy full SHA for 8ca8366 - Browse repository at this point
Copy the full SHA 8ca8366View commit details -
Configuration menu - View commit details
-
Copy full SHA for 54ce2f8 - Browse repository at this point
Copy the full SHA 54ce2f8View commit details -
Configuration menu - View commit details
-
Copy full SHA for a688488 - Browse repository at this point
Copy the full SHA a688488View commit details -
Configuration menu - View commit details
-
Copy full SHA for e1570b4 - Browse repository at this point
Copy the full SHA e1570b4View commit details -
Configuration menu - View commit details
-
Copy full SHA for 2c59dc6 - Browse repository at this point
Copy the full SHA 2c59dc6View commit details -
Configuration menu - View commit details
-
Copy full SHA for d0ba4cf - Browse repository at this point
Copy the full SHA d0ba4cfView commit details -
Configuration menu - View commit details
-
Copy full SHA for bb61c49 - Browse repository at this point
Copy the full SHA bb61c49View commit details -
Configuration menu - View commit details
-
Copy full SHA for 6e089eb - Browse repository at this point
Copy the full SHA 6e089ebView commit details -
Configuration menu - View commit details
-
Copy full SHA for e6e49f8 - Browse repository at this point
Copy the full SHA e6e49f8View commit details -
Query cache in getExtrapolatedBoundaryFaceValue
With this query we avoid potentially unnecessary gradient computations for two term and we make the assertion in one term make sense
Configuration menu - View commit details
-
Copy full SHA for 8ae451c - Browse repository at this point
Copy the full SHA 8ae451cView commit details -
Configuration menu - View commit details
-
Copy full SHA for 49d10e1 - Browse repository at this point
Copy the full SHA 49d10e1View commit details -
Changes/additions to Limiter API
- Limiter now takes phi_upwind, phi_downwind, grad_phi_upwind, and dCD arguments. The gradient argument is a pointer which allows the user to not supply it when it's expensive and when the limiter is constant. non-constant Limiters now have to manually call Moose::FV::rF themselves - constant() is a new API that a user can call to determine whether they need to supply a gradient (and maybe there will be other uses as well)
Configuration menu - View commit details
-
Copy full SHA for d445330 - Browse repository at this point
Copy the full SHA d445330View commit details -
Adapt (P)INSFV to functor props
It's perhaps worth mentioning by now that the current functor implementation forces a paradigm in which 'interpolated' face quantities are formed by composing atomic interpolated face quantities, e.g. interp(u*v) becomes interp(u)*interp(v). I imagine we will have some debate about whether this is satisfactory. My current data point is that this change does not impact the order of approximation error has demonstrated by continued passing of ins and pins mms tests
Configuration menu - View commit details
-
Copy full SHA for df24c14 - Browse repository at this point
Copy the full SHA df24c14View commit details -
Configuration menu - View commit details
-
Copy full SHA for bf6034b - Browse repository at this point
Copy the full SHA bf6034bView commit details -
Create PINSFV and PWCNSFV analogs of PCNSFVStrongBC
But leverage functors to greatly simplify code
Configuration menu - View commit details
-
Copy full SHA for 1bf65cf - Browse repository at this point
Copy the full SHA 1bf65cfView commit details -
Make sure to query interpCoeffs for boundary faces
This prevents incorrectly adding to the Rhie-Chow element coefficient when doing upwind interpolation and when on a boundary face where the adjoining element is downwind with respect to the face velocity
Configuration menu - View commit details
-
Copy full SHA for b5a0439 - Browse repository at this point
Copy the full SHA b5a0439View commit details -
Add no-diffusion PINSFV 1D MMS tests
New tests: - Traditional INSFVInletVelocityBC and INSFVOutletPressureBC - new PINSFVStrongBC which is an FVFluxBC that leverages functors
Configuration menu - View commit details
-
Copy full SHA for 72165e1 - Browse repository at this point
Copy the full SHA 72165e1View commit details -
Working wcnsfv natural convection example
It was actually working before but when there are large variations in density then the velocity distribution is asymmetric which is unlike the Boussinesq benchmarks that I'm used to looking at (which kind of makes sense... Boussinesq is only supposed to be applied when density variations relatively small). So instead of generating Rayleigh numbers by varying delta T (and consequently delta rho), I generate Rayleigh numbers based on changing L (e.g. xmax and ymax)
Configuration menu - View commit details
-
Copy full SHA for 2e571e2 - Browse repository at this point
Copy the full SHA 2e571e2View commit details -
Restore aggregate interpolation in FVMatAdvection
This removes the previous exodiff. This also adds a new overload of operator() that combines an element, face, and subdomain ID. For variables we check whether we have dofs on the element, and if not we create a ghost value using the element across (using the face) and any Dirichlet information. We use the subdomain ID for ghosted material properties
Configuration menu - View commit details
-
Copy full SHA for a1faa73 - Browse repository at this point
Copy the full SHA a1faa73View commit details -
Allow functor property creation from getFunctorMaterialProperty
We don't want the ability to create functor materials to depend on material ordering in the input file. Consequently if a consumer material is before a producer, we must allow the consumer material to be able to create the functor property instance that will then be setup by the declarer
Configuration menu - View commit details
-
Copy full SHA for a896d93 - Browse repository at this point
Copy the full SHA a896d93View commit details -
Restore aggregate interpolations in NS objects
Includes - advection objects - PINSFVMomentumDiffusion This also required regolding the wcnsfv test since instead of using atomic interpolations, like was used when the gold file was initially produced, we now use the aggregated interpolations
Configuration menu - View commit details
-
Copy full SHA for 84562bd - Browse repository at this point
Copy the full SHA 84562bdView commit details -
Add two qp-based functor overloads
1. Just takes a single qp. For a variable this just returns the elemental moose variable data (element_data->adSln()) indexed at qp 2. The other overload takes a pair with the first of the pair corresponding to the element type (element, neighbor, or lower) and the second of the pair corresponding to the qp
Configuration menu - View commit details
-
Copy full SHA for bcdcd18 - Browse repository at this point
Copy the full SHA bcdcd18View commit details -
Adapt (P)INSFV to functor props, part 2
Some details for this commit: - Add makeElemAndFace method to FVFluxBC - Update NS postprocessors to use functor properties - Update inputs to use functor properties
Configuration menu - View commit details
-
Copy full SHA for 7c52535 - Browse repository at this point
Copy the full SHA 7c52535View commit details -
Configuration menu - View commit details
-
Copy full SHA for 79ae545 - Browse repository at this point
Copy the full SHA 79ae545View commit details -
Configuration menu - View commit details
-
Copy full SHA for d9e7765 - Browse repository at this point
Copy the full SHA d9e7765View commit details -
In brief trials, I have not been able to get the energy equation to converge at the correct rate. It's actually fully possible that I simply had not refined the mesh enough yet. But anyway this current feature branch is not about Euler/Navier-Stokes; it's about introducing functor properties and solving the mass and momentum equations in a weakly compressible context is enough of a physics demonstration of the usefulness of functor properties. Incorporating a weakly compressible energy equation can be a part of a feature branch more focused on the `navier_stokes` module
Configuration menu - View commit details
-
Copy full SHA for 6550f20 - Browse repository at this point
Copy the full SHA 6550f20View commit details -
Configuration menu - View commit details
-
Copy full SHA for e095777 - Browse repository at this point
Copy the full SHA e095777View commit details -
Apply suggestions from code review
Co-authored-by: Guillaume Giudicelli <guillaume.giudicelli@gmail.com>
Configuration menu - View commit details
-
Copy full SHA for 16a9bd5 - Browse repository at this point
Copy the full SHA 16a9bd5View commit details -
Configuration menu - View commit details
-
Copy full SHA for 59db6dd - Browse repository at this point
Copy the full SHA 59db6ddView commit details -
- Port all of its code back into FunctorMaterialProperty - Make MaterialPropertyInterface::getFunctorMaterialProperty return a FunctorInterface as opposed to a FunctorMaterialProperty. This allows returning a ConstantFunctor for default material properties
Configuration menu - View commit details
-
Copy full SHA for 257d146 - Browse repository at this point
Copy the full SHA 257d146View commit details -
Configuration menu - View commit details
-
Copy full SHA for 6bf472d - Browse repository at this point
Copy the full SHA 6bf472dView commit details -
Configuration menu - View commit details
-
Copy full SHA for fb693f9 - Browse repository at this point
Copy the full SHA fb693f9View commit details -
Add caching to functor properties
- Implemented for quadrature point evaluations on elements
Configuration menu - View commit details
-
Copy full SHA for 3ba76fc - Browse repository at this point
Copy the full SHA 3ba76fcView commit details -
No reason to link libmesh libs into gtest
In fact this can be quite disastrous. We do not build gtest with METHODS, so whatever METHOD is first used to build the gtest library will determine the libmesh library that gets linked. And then when linking our unit test executable and using any METHOD other than the METHOD initially used when linking gtest, you'll run into hideous errors like double frees
Configuration menu - View commit details
-
Copy full SHA for c8edc01 - Browse repository at this point
Copy the full SHA c8edc01View commit details -
Configuration menu - View commit details
-
Copy full SHA for 9040131 - Browse repository at this point
Copy the full SHA 9040131View commit details -
Address Guillaume navier-stokes portion review
Co-authored-by: Guillaume Giudicelli <guillaume.giudicelli@gmail.com> temp
Configuration menu - View commit details
-
Copy full SHA for 6a84446 - Browse repository at this point
Copy the full SHA 6a84446View commit details -
Configuration menu - View commit details
-
Copy full SHA for a253ebf - Browse repository at this point
Copy the full SHA a253ebfView commit details -
For now I chose to go with an unsigned int for the time argument. It corresponds to the solution state. This can be used to query for old and older variable values and can also be easily used to determine Real time values by querying `FEProblemBase` (e.g. `time()` or `timeOld()` methods)
Configuration menu - View commit details
-
Copy full SHA for aaa62bb - Browse repository at this point
Copy the full SHA aaa62bbView commit details -
This allows us to create physical quadrature point locations on-the-fly in `Function::evaluate(QpArg)` such that we can call `Function::value` with `Point` arguments. This could also allow us in the future to generate variable values at QpArg locations on-the-fly if we wanted to remove the pre-suppostion that the user has correctly init'd the variable before calls to `evaluate`
Configuration menu - View commit details
-
Copy full SHA for 6ace575 - Browse repository at this point
Copy the full SHA 6ace575View commit details -
Demonstrate use of Functions as functors
GenericFunctionFunctorMaterial takes an input of function names and then evalutes functor material properties by calling through to the same functor interfaces on the function objects. Another important change in this commit is that we moved inheritance of `FunctorInterface` down into `MooseVariableField` which allows use of `MooseVariableFE` as a functor. Moving this down required adding some more template syntax into the variable classes since we now have to support more than just the `Real` instantiation of `MooseVariableFields`. This commit also changed the coefficient in `FVDiffusion` to be a functor instead of a regular material property which necessitated some changes in navier_stokes, ray_tracing, and quite a few moose tests. Some of the more notable additional changes required to make all tests pass: - FVPropValPerSubdomainMaterial is now a FunctorMaterial. This actually greatly simplified the code since we've baked specificity into our residual object functor material property requests, e.g. it's always clear what subdomain ID we're requesting the material property for - Made our two framework level `FVInterfaceKernel` objects use functor material properties. This necessitated adding `elemFace` and `neighborFace` protected methods to `FVInterfaceKernel` There were also two tests that were `RunException` tests before with regular material properties that now fun fine with functor properties. These two tests now show that we allow the following two new concepts: - Neighboring subdomain materials can define properties of the same name even when the material block restriction doesn't match the physics block restriction. This should make production physics inputs like we run in Pronghorn much simpler - material properties using in finite volume calculations can depend on material properties that are computed in functor materials that couple in finite element variables. This is different because we cannot ghost regular materials that coupled in finite element variables. Now there is still this restriction: a ghosted material property evaluation cannot depend on a finite element variable (indeed we cannot even yet call a finite element variable with "finite volume-esque" geometric arguments) but this could potentially be changed in the future
Configuration menu - View commit details
-
Copy full SHA for c0df195 - Browse repository at this point
Copy the full SHA c0df195View commit details -
Apply suggestions from code review
Co-authored-by: Guillaume Giudicelli <guillaume.giudicelli@gmail.com>
Configuration menu - View commit details
-
Copy full SHA for 58eb930 - Browse repository at this point
Copy the full SHA 58eb930View commit details -
Elucidate meaning of ElemFromFaceArg
People should think of this geometric argument as corresponding to the location in space of the element centroid (created from the face info) or the neighbor centroid (created from the face info). People *should not* think of this argument as corresponding to the location of the face just with inifinitesimal positioning on the elem or neighbor side
Configuration menu - View commit details
-
Copy full SHA for c4c2550 - Browse repository at this point
Copy the full SHA c4c2550View commit details -
Overhaul FaceArg functor overload
A comment that Guillaume made really made me think about the design of this overload. It needed to be revamped to really take sidedness into account. So now the SubdomainID argument has been changed to be a std::pair<SubdomainID, SubdomainID>. This qualitative change now makes it conceptually sound in my mind to call the ElemFromFaceArg overload in FunctorMaterialProperty when the FaceArg overload is called. And then we can do a macroscopic interpolation between the results which is an ability that others clamored for in the beginning
Configuration menu - View commit details
-
Copy full SHA for 9ce8e6c - Browse repository at this point
Copy the full SHA 9ce8e6cView commit details -
Configuration menu - View commit details
-
Copy full SHA for 0691fe7 - Browse repository at this point
Copy the full SHA 0691fe7View commit details -
Configuration menu - View commit details
-
Copy full SHA for 83d4b4e - Browse repository at this point
Copy the full SHA 83d4b4eView commit details -
Resize qp cache all at once with qrule->n_points()
Do this instead of incrementally resizing by one
Configuration menu - View commit details
-
Copy full SHA for 40a83c6 - Browse repository at this point
Copy the full SHA 40a83c6View commit details -
Configuration menu - View commit details
-
Copy full SHA for a5b0280 - Browse repository at this point
Copy the full SHA a5b0280View commit details -
Configuration menu - View commit details
-
Copy full SHA for 226eb28 - Browse repository at this point
Copy the full SHA 226eb28View commit details -
Configuration menu - View commit details
-
Copy full SHA for ed7d970 - Browse repository at this point
Copy the full SHA ed7d970View commit details -
Configuration menu - View commit details
-
Copy full SHA for ec79f69 - Browse repository at this point
Copy the full SHA ec79f69View commit details -
Configuration menu - View commit details
-
Copy full SHA for f9d9e90 - Browse repository at this point
Copy the full SHA f9d9e90View commit details -
Configuration menu - View commit details
-
Copy full SHA for d54ef7a - Browse repository at this point
Copy the full SHA d54ef7aView commit details -
Configuration menu - View commit details
-
Copy full SHA for 9217f42 - Browse repository at this point
Copy the full SHA 9217f42View commit details -
Configuration menu - View commit details
-
Copy full SHA for 7bbd2a0 - Browse repository at this point
Copy the full SHA 7bbd2a0View commit details -
Configuration menu - View commit details
-
Copy full SHA for 543e805 - Browse repository at this point
Copy the full SHA 543e805View commit details -
Configuration menu - View commit details
-
Copy full SHA for 5095d90 - Browse repository at this point
Copy the full SHA 5095d90View commit details -
Configuration menu - View commit details
-
Copy full SHA for 422fad9 - Browse repository at this point
Copy the full SHA 422fad9View commit details -
Configuration menu - View commit details
-
Copy full SHA for 0050797 - Browse repository at this point
Copy the full SHA 0050797View commit details -
Configuration menu - View commit details
-
Copy full SHA for dd6fd5f - Browse repository at this point
Copy the full SHA dd6fd5fView commit details -
Configuration menu - View commit details
-
Copy full SHA for a762e32 - Browse repository at this point
Copy the full SHA a762e32View commit details -
Configuration menu - View commit details
-
Copy full SHA for 4df5341 - Browse repository at this point
Copy the full SHA 4df5341View commit details -
Configuration menu - View commit details
-
Copy full SHA for 060e2af - Browse repository at this point
Copy the full SHA 060e2afView commit details
Commits on Oct 4, 2021
-
Configuration menu - View commit details
-
Copy full SHA for 0bc54be - Browse repository at this point
Copy the full SHA 0bc54beView commit details -
Configuration menu - View commit details
-
Copy full SHA for 66557dd - Browse repository at this point
Copy the full SHA 66557ddView commit details -
Configuration menu - View commit details
-
Copy full SHA for 2778094 - Browse repository at this point
Copy the full SHA 2778094View commit details -
Configuration menu - View commit details
-
Copy full SHA for 433a4bc - Browse repository at this point
Copy the full SHA 433a4bcView commit details -
Configuration menu - View commit details
-
Copy full SHA for b9a921d - Browse repository at this point
Copy the full SHA b9a921dView commit details -
Apply suggestions from code review
Co-authored-by: Guillaume Giudicelli <guillaume.giudicelli@gmail.com>
Configuration menu - View commit details
-
Copy full SHA for eef4a49 - Browse repository at this point
Copy the full SHA eef4a49View commit details -
Configuration menu - View commit details
-
Copy full SHA for 6fe4847 - Browse repository at this point
Copy the full SHA 6fe4847View commit details -
Configuration menu - View commit details
-
Copy full SHA for d4d9c0f - Browse repository at this point
Copy the full SHA d4d9c0fView commit details -
Configuration menu - View commit details
-
Copy full SHA for 6bfd4e6 - Browse repository at this point
Copy the full SHA 6bfd4e6View commit details -
Configuration menu - View commit details
-
Copy full SHA for c7f3cab - Browse repository at this point
Copy the full SHA c7f3cabView commit details -
Configuration menu - View commit details
-
Copy full SHA for 9584906 - Browse repository at this point
Copy the full SHA 9584906View commit details -
Delete momentum_name code-path from incompressible friction object
Also clean-up documentation to reflect that fully compressible only works with a momentum parameter and incompressible only works with a density parameter and superficial velocity variable set
Configuration menu - View commit details
-
Copy full SHA for 2566c29 - Browse repository at this point
Copy the full SHA 2566c29View commit details
Commits on Oct 5, 2021
-
Further stratification of (P)INSFV and (P)CNSFV
Removing standalone NSFV and PNSFV for gravity and friction
Configuration menu - View commit details
-
Copy full SHA for e5c5bfe - Browse repository at this point
Copy the full SHA e5c5bfeView commit details -
Test swapping out of functor material property types
This revealed what should not have been a surprise: deleting an object makes any reference access to that object bad access. So now I use the letter and envelope idiom to allow changing out of the underlying functor material property type
Configuration menu - View commit details
-
Copy full SHA for 0653f11 - Browse repository at this point
Copy the full SHA 0653f11View commit details