Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
I
INMOST
Project overview
Project overview
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Kirill Terekhov
INMOST
Commits
c1d6fa9f
Commit
c1d6fa9f
authored
Sep 26, 2018
by
Kirill Terekhov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Examples fixes
mpi.h included after stdio.h fixes in ADMFD
parent
653dd587
Pipeline
#134
passed with stages
in 10 minutes and 22 seconds
Changes
3
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
10 additions
and
8 deletions
+10
-8
Examples/ADMFD/main.cpp
Examples/ADMFD/main.cpp
+7
-6
Examples/ADVDIFF/main.cpp
Examples/ADVDIFF/main.cpp
+1
-1
Examples/Octree/main.cpp
Examples/Octree/main.cpp
+2
-1
No files found.
Examples/ADMFD/main.cpp
View file @
c1d6fa9f
#include "inmost.h"
#include <stdio.h>
#include <stdlib.h>
#include <math.h>
#include <string.h>
#include "inmost.h"
using
namespace
INMOST
;
#ifndef M_PI
...
...
@@ -97,7 +98,7 @@ int main(int argc,char ** argv)
Tag
tag_F
;
// Forcing term
Tag
tag_BC
;
// Boundary conditions
Tag
tag_W
;
// Gradient matrix acting on harmonic points on faces and returning gradient on faces
Tag
tag_DMP
;
// Indicates weather local W matrix satisfy DMP condition
if
(
m
->
GetProcessorsNumber
()
>
1
)
//skip for one processor job
{
// Exchange ghost cells
...
...
@@ -157,7 +158,7 @@ int main(int argc,char ** argv)
}
m
->
ExchangeData
(
tag_P
,
CELL
|
FACE
,
0
);
//Synchronize initial solution with boundary unknowns
tag_W
=
m
->
CreateTag
(
"nKGRAD"
,
DATA_REAL
,
CELL
,
NONE
);
tag_DMP
=
m
->
CreateTag
(
"isDMP"
,
DATA_BULK
,
CELL
,
NONE
);
ttt
=
Timer
();
//Assemble gradient matrix W on cells
#if defined(USE_OMP)
...
...
@@ -168,7 +169,6 @@ int main(int argc,char ** argv)
rMatrix
x
(
1
,
3
),
xf
(
1
,
3
),
n
(
1
,
3
);
double
area
;
//area of the face
double
volume
;
//volume of the cell
Areas
.
Zero
();
#if defined(USE_OMP)
#pragma omp for
#endif
...
...
@@ -184,8 +184,9 @@ int main(int argc,char ** argv)
//get permeability for the cell
rMatrix
K
=
rMatrix
::
FromTensor
(
cell
->
RealArrayDF
(
tag_K
).
data
(),
cell
->
RealArrayDF
(
tag_K
).
size
());
NK
.
Resize
(
NF
,
3
);
R
.
Resize
(
NF
,
3
),
Areas
(
NF
,
NF
);
//big gradient matrix, co-normals, directions
NK
.
Resize
(
NF
,
3
);
//co-normals
R
.
Resize
(
NF
,
3
);
//directions
Areas
.
Resize
(
NF
,
NF
);
//areas
Areas
.
Zero
();
for
(
int
k
=
0
;
k
<
NF
;
++
k
)
//loop over faces
{
...
...
Examples/ADVDIFF/main.cpp
View file @
c1d6fa9f
#include "inmost.h"
#include <stdio.h>
#include <stdlib.h>
#include <math.h>
#include <string.h>
#include "inmost.h"
#include "checks.h"
#include "save_mesh.h"
#include "conv_diff.h"
...
...
Examples/Octree/main.cpp
View file @
c1d6fa9f
#include "inmost.h"
#include "octgrid.h"
#include "my_glut.h"
#include "rotate.h"
#include <math.h>
#include "inmost.h"
#include <iomanip>
#include <iostream>
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a 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