View Issue Details
ID | Project | Category | View Status | Date Submitted | Last Update |
---|---|---|---|---|---|
0004087 | OpenFOAM | Bug | public | 2024-05-29 10:50 | 2024-05-29 15:58 |
Reporter | cgoessni | Assigned To | will | ||
Priority | low | Severity | minor | Reproducibility | always |
Status | closed | Resolution | no change required | ||
Product Version | dev | ||||
Summary | 0004087: multiValveEngine: motion using wrong units | ||||
Description | If one uses e.g., a table for the motion specification of valves / piston, then the first unit is erroneously assumed to be unitNone instead of dimTime. | ||||
Steps To Reproduce | Run $ foamDictionary -entry mover/valves/iv/motion/units -set '([CAD] [m])' constant/dynamicMeshDict in engine2Valve2D tutorials, and try to run the simulation. | ||||
Additional Information | This change fixes it for us: diff --git a/src/fvMeshMovers/multiValveEngine/movingObject.C b/src/fvMeshMovers/multiValveEngine/movingObject.C index 5b0714e..39b2710 100644 --- a/src/fvMeshMovers/multiValveEngine/movingObject.C +++ b/src/fvMeshMovers/multiValveEngine/movingObject.C @@ -282,7 +282,7 @@ Foam::fvMeshMovers::multiValveEngine::movingObject::movingObject meshMover_(engine), name(objectName), axis(dict.lookup<vector>("axis", dimless)), - motion_(Function1<scalar>::New("motion", unitNone, dimLength, dict)), + motion_(Function1<scalar>::New("motion", dimTime, dimLength, dict)), maxMotionDistance_ ( dict.lookupOrDefault<scalar>("maxMotionDistance", dimLength, great) | ||||
Tags | No tags attached. | ||||
|
So the above diff does not work because multiValveEngine does the conversion from time to userTime (s -> CAD) internally, which breaks unitConversion. Please disregard this. |
|
Indeed. The mover does not support unit conversion of the time axis of the motion function. The error that you are seeing is reporting this lack of support. The time axis is hard-coded to be in units of user time. This is considered appropriate for the engine-specific context of this mover. |
Date Modified | Username | Field | Change |
---|---|---|---|
2024-05-29 10:50 | cgoessni | New Issue | |
2024-05-29 14:36 | cgoessni | Note Added: 0013251 | |
2024-05-29 15:58 | will | Assigned To | => will |
2024-05-29 15:58 | will | Status | new => closed |
2024-05-29 15:58 | will | Resolution | open => no change required |
2024-05-29 15:58 | will | Note Added: 0013252 |