Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
O
OpenSource
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Jan Willem Thorbecke
OpenSource
Commits
8c81d1c8
Commit
8c81d1c8
authored
7 years ago
by
Jan Willem Thorbecke
Browse files
Options
Downloads
Patches
Plain Diff
solved bugs in new marchenko reci option
parent
9caf2cbc
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
marchenko/marchenko.c
+3
-7
3 additions, 7 deletions
marchenko/marchenko.c
marchenko/readShotData.c
+1
-1
1 addition, 1 deletion
marchenko/readShotData.c
with
4 additions
and
8 deletions
marchenko/marchenko.c
+
3
−
7
View file @
8c81d1c8
...
...
@@ -793,7 +793,7 @@ nw, int nw_low, int nw_high, int mode, int reci, int nshots, int *ixpos, int np
shared(iRN, dx, npe, nw, verbose) \
shared(Refl, Nfoc, reci, xrcv, xsrc, xsyn, fxsb, fxse, nxs, dxs) \
shared(nx, dxsrc, inx, k, nfreq, nw_low, nw_high) \
shared(Fop, size, nts, ntfft, scl, ixrcv, ixsrc
, stderr
) \
shared(Fop, size, nts, ntfft, scl, ixrcv, ixsrc) \
private(l, ix, j, m, i, sum, rtrace)
{
/* start of parallel region */
sum
=
(
complex
*
)
malloc
(
nfreq
*
sizeof
(
complex
));
...
...
@@ -842,14 +842,13 @@ nw, int nw_low, int nw_high, int mode, int reci, int nshots, int *ixpos, int np
if
(
isxcount
[
k
]
==
0
)
continue
;
ixsrc
=
k
;
inx
=
isxcount
[
ixsrc
];
/* number of traces per reciprocal shot */
// fprintf(stderr,"inx=%d for k=%d ixsrc=%d\n", inx, k, ixsrc);
#pragma omp parallel default(none) \
shared(iRN, dx, nw, verbose) \
shared(Refl, Nfoc, reci, xrcv, xsrc, xsyn, fxsb, fxse, nxs, dxs) \
shared(nx, dxsrc, inx, k, nfreq, nw_low, nw_high) \
shared(reci_xrcv, reci_xsrc, ixmask) \
shared(Fop, size, nts, ntfft, scl, ixrcv, ixsrc
, stderr
) \
shared(Fop, size, nts, ntfft, scl, ixrcv, ixsrc) \
private(l, ix, j, m, i, sum, rtrace, ik, il)
{
/* start of parallel region */
sum
=
(
complex
*
)
malloc
(
nfreq
*
sizeof
(
complex
));
...
...
@@ -866,9 +865,6 @@ nw, int nw_low, int nw_high, int mode, int reci, int nshots, int *ixpos, int np
il
=
reci_xrcv
[
ixsrc
*
nxs
+
i
];
ik
=
reci_xsrc
[
ixsrc
*
nxs
+
i
];
ix
=
NINT
((
xsrc
[
il
]
-
fxsb
)
/
dxs
);
//if (j==nw_low) {
// fprintf(stderr,"ixsrc=%d with il=%d and ik=%d and ix=%d mask=%f\n", ixsrc, il, ik, ix, ixmask[ixsrc]);
//}
sum
[
j
].
r
+=
Refl
[
il
*
nw
*
nx
+
m
*
nx
+
ik
].
r
*
Fop
[
l
*
nw
*
nxs
+
m
*
nxs
+
ix
].
r
-
Refl
[
il
*
nw
*
nx
+
m
*
nx
+
ik
].
i
*
Fop
[
l
*
nw
*
nxs
+
m
*
nxs
+
ix
].
i
;
sum
[
j
].
i
+=
Refl
[
il
*
nw
*
nx
+
m
*
nx
+
ik
].
i
*
Fop
[
l
*
nw
*
nxs
+
m
*
nxs
+
ix
].
r
+
...
...
@@ -980,7 +976,7 @@ float fxse, float fxsb, float dxs, float dxsrc, float dx, int nshots, int *ixpos
free
(
count
);
/* sort ixpos into increasing values */
//
qsort(ixpos, *npos, sizeof(int), compareInt);
qsort
(
ixpos
,
*
npos
,
sizeof
(
int
),
compareInt
);
return
;
...
...
This diff is collapsed.
Click to expand it.
marchenko/readShotData.c
+
1
−
1
View file @
8c81d1c8
...
...
@@ -142,9 +142,9 @@ int readShotData(char *filename, float *xrcv, float *xsrc, float *zsrc, int *xnx
/* if reci=1 or reci=2 source-receive reciprocity is used and traces are added */
if
(
reci
!=
0
)
{
for
(
k
=
0
;
k
<
nxs
;
k
++
)
ixmask
[
k
]
=
1
.
0
;
for
(
k
=
0
;
k
<
nshots
;
k
++
)
{
ixsrc
=
NINT
((
xsrc
[
k
]
-
fxsb
)
/
dxs
);
ixmask
[
ixsrc
]
=
1
.
0
;
nxrk
=
xnx
[
k
];
for
(
l
=
0
;
l
<
nxrk
;
l
++
)
{
samercv
=
0
;
...
...
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