Skip to content

Commit a1b964b

Browse files
committed
macos
1 parent 75e02b5 commit a1b964b

File tree

4 files changed

+74
-22
lines changed

4 files changed

+74
-22
lines changed

api/c/lapack.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,9 +5,9 @@
55

66
/* #define __VECLIB__ */
77

8-
#include <Accelerate/Accelerate.h>
8+
/* #include <Accelerate/Accelerate.h> */
99

10-
/* #include <vecLib/clapack.h> */
10+
#include <vecLib/clapack.h>
1111

1212
#define MKL_Complex8 __CLPK_complex
1313
#define MKL_Complex16 __CLPK_doublecomplex

user/fomels/Mcausinv.c

Lines changed: 52 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,52 @@
1+
/* Smooth derivative by regularized causint inversion */
2+
/*
3+
Copyright (C) 2004 University of Texas at Austin
4+
5+
This program is free software; you can redistribute it and/or modify
6+
it under the terms of the GNU General Public License as published by
7+
the Free Software Foundation; either version 2 of the License, or
8+
(at your option) any later version.
9+
10+
This program is distributed in the hope that it will be useful,
11+
but WITHOUT ANY WARRANTY; without even the implied warranty of
12+
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13+
GNU General Public License for more details.
14+
15+
You should have received a copy of the GNU General Public License
16+
along with this program; if not, write to the Free Software
17+
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
18+
*/
19+
#include <rsf.h>
20+
21+
int main(int argc, char* argv[])
22+
{
23+
int n1, niter;
24+
float eps;
25+
bool verb;
26+
float *x, *y, **xmov;
27+
sf_file in, out, mov;
28+
29+
sf_init(argc,argv);
30+
in = sf_input("in");
31+
out = sf_output("out");
32+
33+
mov = sf_output("mov");
34+
35+
if (!sf_histint(in, "n1", &n1)) sf_error("No n1= in input");
36+
if (!sf_getint("niter", &niter)) niter=1;
37+
if (!sf_getfloat("eps", &eps)) eps=0.0;
38+
if (!sf_getbool("verb", &verb)) verb=false;
39+
40+
x = sf_floatalloc(n1);
41+
y = sf_floatalloc(n1);
42+
xmov = sf_floatalloc2(n1,niter);
43+
44+
sf_floatread(y, n1, in);
45+
46+
sf_solver_reg (sf_causint_lop, sf_cgstep, sf_igrad1_lop, n1, n1, n1, x, y, niter, eps, "verb", verb, "xmov", xmov, "end");
47+
48+
sf_floatwrite(x, n1, out);
49+
sf_floatwrite(xmov[0], n1*niter, mov);
50+
51+
exit(0);
52+
}

user/fomels/SConstruct

Lines changed: 19 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -4,25 +4,25 @@ import bldutil
44

55
progs = '''
66
abalance analytical angle angle2 approx arrival bdix beamform1 bil1
7-
bilat2 blur boxcascade cbeamform1 ccausint cchebyshevp cfftexpa-dev
8-
cfftwave1 cdivn cflow chain2dfft chebvc chebyshev chebyshevp clpf
9-
cltft cltftfft constperm constpermh constpermh1 cosftwave1 cpef cr
10-
ctf2dprec deblur diphase distance divn dix donut dpeiko eikonal
11-
eikonalvti eno2 erf exgr fedchain fedchain1 fedchain2 fedchain21 fft2
12-
fftexp0 fftexp1 fftexp3 fftexpa fftexp0a fftone ffttest fftwave1
13-
fftwave2 fftwave3 findmin2 focus fpow freqest gaussmooth gbeamform
14-
imray interf interp2 interpt iphase kdsort kdtree kron label legacy
15-
lfftexp0 llpf localskew locov lpf lrmig0 lsfit max2 median mffit mig3
16-
miss3 morph nconv nnint nnshape nnshapet nsmooth nsmooth1 ocparcel
17-
octentwt ofilp ofsemb ortho patch pchain pchain1 phaserot pick pick2
18-
pick3 plane poly polyfit psmig2 regr rdiv rect1 reshape riesz rsin sc
19-
seislet1 semblance semblancew shape shapeagc shapefill shearer shift1
20-
sh1 sh2 similarity similarity2 simenv slschain2d smoothderw smoothreg
21-
smspray stfchain stfchain2 stcontrib stltft stpf stphase stream
22-
streamiss sttimefreq taupfit tfchain tf2dprec thin timecont timefreq
23-
tomo tree trace2 tricascade tristack tristack2 twofreq2 upgrad var2
24-
velcon velinv vipmig0 vofzperm warp1 warpadd warpscan zero zmarch
25-
ztrace
7+
bilat2 blur boxcascade cbeamform1 causinv ccausint cchebyshevp
8+
cfftexpa-dev cfftwave1 cdivn cflow chain2dfft chebvc chebyshev
9+
chebyshevp clpf cltft cltftfft constperm constpermh constpermh1
10+
cosftwave1 cpef cr ctf2dprec deblur diphase distance divn dix donut
11+
dpeiko eikonal eikonalvti eno2 erf exgr fedchain fedchain1 fedchain2
12+
fedchain21 fft2 fftexp0 fftexp1 fftexp3 fftexpa fftexp0a fftone
13+
ffttest fftwave1 fftwave2 fftwave3 findmin2 focus fpow freqest
14+
gaussmooth gbeamform imray interf interp2 interpt iphase kdsort kdtree
15+
kron label legacy lfftexp0 llpf localskew locov lpf lrmig0 lsfit max2
16+
median mffit mig3 miss3 morph nconv nnint nnshape nnshapet nsmooth
17+
nsmooth1 ocparcel octentwt ofilp ofsemb ortho patch pchain pchain1
18+
phaserot pick pick2 pick3 plane poly polyfit psmig2 regr rdiv rect1
19+
reshape riesz rsin sc seislet1 semblance semblancew shape shapeagc
20+
shapefill shearer shift1 sh1 sh2 similarity similarity2 simenv
21+
slschain2d smoothderw smoothreg smspray stfchain stfchain2 stcontrib
22+
stltft stpf stphase stream streamiss sttimefreq taupfit tfchain
23+
tf2dprec thin timecont timefreq tomo tree trace2 tricascade tristack
24+
tristack2 twofreq2 upgrad var2 velcon velinv vipmig0 vofzperm warp1
25+
warpadd warpscan zero zmarch ztrace
2626
'''
2727

2828
ccprogs = 'anisolr2 isolr2 isolr3 lrvc0 permlr1 permlr2 permlr3'

user/fomels/cfft2w.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -202,7 +202,7 @@ void icfft2(sf_complex *out /* [n1*n2] */,
202202
}
203203
}
204204

205-
void cfft2_finalize()
205+
void cfft2_finalize(void)
206206
/*< clean up fftw >*/
207207
{
208208
/* make sure everything is back to its pristine state */

0 commit comments

Comments
 (0)