Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Development
openfoam
Commits
08193a50
Commit
08193a50
authored
May 22, 2018
by
Andrew Heather
Browse files
ENH: Pair collision model - added ramp time to bleed-in force contributions
parent
885c4715
Changes
3
Hide whitespace changes
Inline
Side-by-side
src/lagrangian/intermediate/submodels/Kinematic/CollisionModel/PairCollision/PairModel/PairModel/PairModel.C
View file @
08193a50
...
...
@@ -3,7 +3,7 @@
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
\\ / A nd | Copyright (C) 2011 OpenFOAM Foundation
\\/ M anipulation |
\\/ M anipulation |
Copyright (C) 2018 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
...
...
@@ -37,7 +37,11 @@ Foam::PairModel<CloudType>::PairModel
:
dict_
(
dict
),
owner_
(
owner
),
coeffDict_
(
dict
.
subDict
(
type
+
"Coeffs"
))
coeffDict_
(
dict
.
subDict
(
type
+
"Coeffs"
)),
forceRampTime_
(
this
->
coeffDict
().
template
lookupOrDefault
<
scalar
>
(
"forceRampTime"
,
-
1
)
)
{}
...
...
@@ -66,13 +70,28 @@ const Foam::dictionary& Foam::PairModel<CloudType>::dict() const
template
<
class
CloudType
>
const
Foam
::
dictionary
&
Foam
::
PairModel
<
CloudType
>::
coeffDict
()
const
const
Foam
::
dictionary
&
Foam
::
PairModel
<
CloudType
>::
coeffDict
()
const
{
return
coeffDict_
;
}
template
<
class
CloudType
>
Foam
::
scalar
Foam
::
PairModel
<
CloudType
>::
forceCoeff
(
typename
CloudType
::
parcelType
&
pA
,
typename
CloudType
::
parcelType
&
pB
)
const
{
if
(
forceRampTime_
<
0
)
{
return
1
;
}
return
min
(
min
(
pA
.
age
(),
pB
.
age
())
/
forceRampTime_
,
1
);
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
#include
"PairModelNew.C"
...
...
src/lagrangian/intermediate/submodels/Kinematic/CollisionModel/PairCollision/PairModel/PairModel/PairModel.H
View file @
08193a50
...
...
@@ -3,7 +3,7 @@
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
\\ / A nd | Copyright (C) 2011-2016 OpenFOAM Foundation
\\/ M anipulation |
\\/ M anipulation |
Copyright (C) 2018 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
...
...
@@ -63,6 +63,21 @@ class PairModel
//- The coefficients dictionary
const
dictionary
coeffDict_
;
//- Time to bleed-in collision forces; default = 0 (no delay)
scalar
forceRampTime_
;
protected:
// Protected Member Functions
//- Return the force coefficient based on the forceRampTime_
scalar
forceCoeff
(
typename
CloudType
::
parcelType
&
pA
,
typename
CloudType
::
parcelType
&
pB
)
const
;
public:
...
...
src/lagrangian/intermediate/submodels/Kinematic/CollisionModel/PairCollision/PairModel/PairSpringSliderDashpot/PairSpringSliderDashpot.C
View file @
08193a50
...
...
@@ -3,7 +3,7 @@
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
\\ / A nd | Copyright (C) 2011-2017 OpenFOAM Foundation
\\/ M anipulation |
\\/ M anipulation |
Copyright (C) 2018 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
...
...
@@ -193,7 +193,10 @@ void Foam::PairSpringSliderDashpot<CloudType>::evaluatePair
if
(
normalOverlapMag
>
0
)
{
//Particles in collision
// Particles in collision
// Force coefficient
scalar
forceCoeff
=
this
->
forceCoeff
(
pA
,
pB
);
vector
rHat_AB
=
r_AB
/
(
r_AB_mag
+
VSMALL
);
...
...
@@ -224,6 +227,8 @@ void Foam::PairSpringSliderDashpot<CloudType>::evaluatePair
*
rHat_AB
;
}
fN_AB
*=
forceCoeff
;
pA
.
f
()
+=
fN_AB
;
pB
.
f
()
+=
-
fN_AB
;
...
...
@@ -278,6 +283,8 @@ void Foam::PairSpringSliderDashpot<CloudType>::evaluatePair
fT_AB
=
-
kT
*
tangentialOverlap_AB
-
etaT
*
USlip_AB
;
}
fT_AB
*=
forceCoeff
;
pA
.
f
()
+=
fT_AB
;
pB
.
f
()
+=
-
fT_AB
;
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment