

BINDIR = ./bin
SRCDIR = ./src
RESDIR = ./Fig
OBJDIR = ./obj

resdir = ./fig

R = ${RESDIR}
B = ${BINDIR}
S = ${SRCDIR}
O = ${OBJDIR}

r = ${resdir}

CC = icc
F90LD = ifort -openmp -I$(SRCDIR) #-Mbounds

UF90LIBS  = -lsep2df90  -lsepgeef90 -lsep3df90 -lsepfftf90 -lsepfft
UF90FLAGS = -O3 -axP

${R}/%.ps: ${R}/%.v
	pstexpen ${R}/$*.v ${R}/$*.ps color=n fat=1 fatmult=1.5 invras=n force=  invras=y

${R}/%.pdf: ${R}/%.ps
	ps2pdf \
	-dDownsampleColorImages=false \
	-dDownsampleGrayImages=false \
	-dDownsampleMonoImages=false \
	-dColorImageFilter=/FlateEncode \
	-dGrayImageFilter=/FlateEncode \
	-dMonoImageFilter=/CCITTFaxEncode \
	-dAutoFilterColorImages=false \
	-dAutoFilterGrayImages=false \
	-dAutoFilterMonoImages=false \
	-dEPSCrop ${R}/$*.ps $@


${r}/%.ps: ${r}/%.v
	pstexpen ${r}/$*.v ${r}/$*.ps color=n fat=1 fatmult=1.5 invras=n force=  invras=y

${r}/%.pdf: ${r}/%.ps
	ps2pdf \
	-dDownsampleColorImages=false \
	-dDownsampleGrayImages=false \
	-dDownsampleMonoImages=false \
	-dColorImageFilter=/FlateEncode \
	-dGrayImageFilter=/FlateEncode \
	-dMonoImageFilter=/CCITTFaxEncode \
	-dAutoFilterColorImages=false \
	-dAutoFilterGrayImages=false \
	-dAutoFilterMonoImages=false \
	-dEPSCrop ${r}/$*.ps $@

pdf_synthetic:${r}/2d-synthetic-model.pdf ${r}/2d-synthetic-data.pdf ${r}/result-rho-0.pdf ${r}/result-rho-7.pdf ${r}/wiggle-local-rho-0.pdf ${r}/wiggle-local-rho-7.pdf ${r}/2d-field-data.pdf ${r}/result-0.pdf ${r}/result-8.pdf ${r}/wavelet-0.pdf ${r}/wavelet-8.pdf ${r}/2d-synthetic-model-local.pdf ${r}/2d-synthetic-data-local.pdf ${r}/result-local-rho-0.pdf ${r}/result-local-rho-7.pdf ${r}/freq-domain-9-99-a-freq.pdf ${r}/freq-domain-9-99-a.pdf ${r}/freq-domain-9-99-result-freq.pdf ${r}/freq-domain-9-99-result.pdf ${r}/freq-domain-a-freq.pdf ${r}/freq-domain-a.pdf ${r}/freq-domain-result-freq.pdf ${r}/freq-domain-result.pdf ${r}/freq-domain-result-freq.pdf ${r}/ricker-with-rho-freq.pdf ${r}/ricker-with-rho.pdf ${r}/half-ricker-freq.pdf ${r}/half-ricker-freq.pdf ${r}/half-ricker.pdf ${r}/half-ricker-with-rho-freq.pdf ${r}/half-ricker-with-rho.pdf ${r}/ricker.pdf ${r}/ricker-freq.pdf 




pdf: pdf_synthetic

all: pdf

default: all

