Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
blaster
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Iterations
Wiki
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Aerospace and Mechanical Engineering
blaster
Commits
d4b9adaf
Verified
Commit
d4b9adaf
authored
2 months ago
by
Paul Dechamps
Browse files
Options
Downloads
Patches
Plain Diff
(refactor) Added reference to setters in BoundaryLayer
parent
2643ac97
No related branches found
Branches containing commit
No related tags found
1 merge request
!1
BLASTER v1.0
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
blast/src/DBoundaryLayer.cpp
+6
-6
6 additions, 6 deletions
blast/src/DBoundaryLayer.cpp
blast/src/DBoundaryLayer.h
+13
-23
13 additions, 23 deletions
blast/src/DBoundaryLayer.h
with
19 additions
and
29 deletions
blast/src/DBoundaryLayer.cpp
+
6
−
6
View file @
d4b9adaf
...
...
@@ -22,10 +22,10 @@ BoundaryLayer::BoundaryLayer(double _xtrF, std::string _name)
BoundaryLayer
::~
BoundaryLayer
()
{
delete
closSolver
;
}
void
BoundaryLayer
::
setMesh
(
std
::
vector
<
double
>
_x
,
std
::
vector
<
double
>
_y
,
std
::
vector
<
double
>
_z
,
double
_chord
,
double
_xMin
,
std
::
vector
<
int
>
const
_rows
,
std
::
vector
<
int
>
const
_no
)
void
BoundaryLayer
::
setMesh
(
const
std
::
vector
<
double
>
&
_x
,
const
std
::
vector
<
double
>
&
_y
,
const
std
::
vector
<
double
>
&
_z
,
const
double
&
_chord
,
const
double
&
_xMin
,
const
std
::
vector
<
int
>
&
_rows
,
const
std
::
vector
<
int
>
&
_no
)
{
if
(
_x
.
size
()
!=
_y
.
size
()
||
_x
.
size
()
!=
_z
.
size
())
throw
std
::
runtime_error
(
"Mesh coordinates are not consistent."
);
...
...
@@ -166,8 +166,8 @@ void BoundaryLayer::setStagnationBC(double Re)
* @param UpperCond Variables at the last point on the upper side.
* @param LowerCond Variables at the last point on the lower side.
*/
void
BoundaryLayer
::
setWakeBC
(
double
Re
,
std
::
vector
<
double
>
UpperCond
,
std
::
vector
<
double
>
LowerCond
)
void
BoundaryLayer
::
setWakeBC
(
double
Re
,
std
::
vector
<
double
>
&
UpperCond
,
std
::
vector
<
double
>
&
LowerCond
)
{
if
(
name
!=
"wake"
)
std
::
cout
<<
"Warning: Imposing wake boundary condition on "
<<
name
...
...
This diff is collapsed.
Click to expand it.
blast/src/DBoundaryLayer.h
+
13
−
23
View file @
d4b9adaf
...
...
@@ -88,72 +88,62 @@ public:
size_t
getnNodes
()
const
{
return
nNodes
;
};
size_t
getnElms
()
const
{
return
nElms
;
};
std
::
vector
<
double
>
getDeltaStar
()
const
{
return
deltaStar
;
};
std
::
vector
<
double
>
getUe
()
const
{
std
::
vector
<
double
>
ue
(
nNodes
,
0.
);
for
(
size_t
i
=
0
;
i
<
nNodes
;
++
i
)
ue
[
i
]
=
u
[
i
*
nVar
+
3
];
return
ue
;
};
std
::
vector
<
double
>
getBlowing
()
const
{
return
blowingVelocity
;
};
double
getMaxMach
()
const
{
return
*
std
::
max_element
(
Me
.
begin
(),
Me
.
end
());
};
// Setters
void
setMesh
(
std
::
vector
<
double
>
const
_x
,
std
::
vector
<
double
>
const
y
,
std
::
vector
<
double
>
const
z
,
double
const
_chord
,
double
const
_xMin
,
std
::
vector
<
int
>
const
_rows
=
std
::
vector
<
int
>
(
0
),
std
::
vector
<
int
>
const
_no
=
std
::
vector
<
int
>
(
0
));
void
setMesh
(
const
std
::
vector
<
double
>
&
_x
,
const
std
::
vector
<
double
>
&
y
,
const
std
::
vector
<
double
>
&
z
,
const
double
&
_chord
,
const
double
&
_xMin
,
const
std
::
vector
<
int
>
&
_rows
=
std
::
vector
<
int
>
(
0
),
const
std
::
vector
<
int
>
&
_no
=
std
::
vector
<
int
>
(
0
));
void
computeLocalCoordinates
();
void
setMe
(
std
::
vector
<
double
>
const
_Me
)
void
setMe
(
std
::
vector
<
double
>
const
&
_Me
)
{
if
(
_Me
.
size
()
!=
nNodes
)
throw
std
::
runtime_error
(
"Mach number vector is not consistent."
);
Me
=
_Me
;
};
void
setVt
(
std
::
vector
<
double
>
const
_vt
)
void
setVt
(
std
::
vector
<
double
>
const
&
_vt
)
{
if
(
_vt
.
size
()
!=
nNodes
)
throw
std
::
runtime_error
(
"Velocity vector is not consistent."
);
vt
=
_vt
;
};
void
setRhoe
(
std
::
vector
<
double
>
const
_rhoe
)
void
setRhoe
(
std
::
vector
<
double
>
const
&
_rhoe
)
{
if
(
_rhoe
.
size
()
!=
nNodes
)
throw
std
::
runtime_error
(
"Density vector is not consistent."
);
rhoe
=
_rhoe
;
};
void
setxxExt
(
std
::
vector
<
double
>
const
_xxExt
)
void
setxxExt
(
std
::
vector
<
double
>
const
&
_xxExt
)
{
if
(
_xxExt
.
size
()
!=
nNodes
)
throw
std
::
runtime_error
(
"External mesh vector is not consistent."
);
xxExt
=
_xxExt
;
};
void
setDeltaStarExt
(
std
::
vector
<
double
>
const
_deltaStarExt
)
void
setDeltaStarExt
(
std
::
vector
<
double
>
const
&
_deltaStarExt
)
{
if
(
_deltaStarExt
.
size
()
!=
nNodes
)
throw
std
::
runtime_error
(
"Displacement thickness vector is not consistent."
);
deltaStarExt
=
_deltaStarExt
;
};
void
setVtExt
(
std
::
vector
<
double
>
const
_vtExt
)
void
setVtExt
(
std
::
vector
<
double
>
const
&
_vtExt
)
{
if
(
_vtExt
.
size
()
!=
nNodes
)
throw
std
::
runtime_error
(
"Velocity vector is not consistent."
);
vtExt
=
_vtExt
;
};
void
setxtrF
(
double
const
_xtrF
)
{
xtrF
=
_xtrF
;
};
void
setnCrit
(
double
const
_nCrit
)
{
nCrit
=
_nCrit
;
};
// Boundary conditions.
void
setStagnationBC
(
double
Re
);
void
setWakeBC
(
double
Re
,
std
::
vector
<
double
>
upperConditions
,
std
::
vector
<
double
>
lowerConditions
);
void
setWakeBC
(
double
Re
,
std
::
vector
<
double
>
&
upperConditions
,
std
::
vector
<
double
>
&
lowerConditions
);
// Getters.
size_t
getnVar
()
const
{
return
nVar
;
};
double
getnCrit
()
const
{
return
nCrit
;
};
void
setnCrit
(
double
const
_nCrit
)
{
nCrit
=
_nCrit
;
};
// Others
void
printSolution
(
size_t
iPoint
)
const
;
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
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!
Save comment
Cancel
Please
register
or
sign in
to comment