예제 #1
0
f=g.DC1dRhoModelling( thk, ab2, mn2 )

inv = g.RInversion( rhoa, f, True )
model = g.RVector( nlay, P.median( rhoa ) )
inv.setModel( model )
inv.setTransData( transRhoa )
inv.setTransModel( transRho )
inv.setRelativeError( errPerc / 100.0 )
inv.setLambda( lam )
model = inv.run()

model2 = g.RVector( nlay, P.median( rhoa ) )
inv.setModel( model2 )
inv.setBlockyModel( True )
model2 = inv.run()

fig = P.figure(1)
fig.clf()
ax1=fig.add_subplot(121)
P.loglog( rhoa, ab2, 'rx-', inv.response(), ab2, 'b-' )
P.axis('tight')
P.ylim((max(ab2),min(ab2)))
P.grid(which='both')
P.xlabel(r"\rho_a in \Omegam");
P.ylabel("AB/2 in m");
P.legend(("measured", "fitted"),loc="upper left");
ax2=fig.add_subplot(122)
draw1dmodel(model,thk,r'\rho in \Omega m')
draw1dmodel(model2,thk,r'\rho in \Omega m')
draw1dmodel([100, 500, 20, 1000],[0.5,3.5,6])
P.show()
예제 #2
0
paraDepth = max(ab2) / 3
f.region(0).setStartValue(max(ab2) / 3. / nlay / 2.)
f.region(1).setStartValue(P.median(rhoa))

model = f.createStartVector()
model[nlay] *= 1.5

inv = g.RInversion(rhoa, f, True)
inv.setModel(model)
inv.setTransData(transRhoa)
inv.setRelativeError(errPerc / 100.0)
inv.setLambda(lam)
inv.setMarquardtScheme(0.9)
model = inv.run()

fig = P.figure(1)
fig.clf()
ax1 = fig.add_subplot(121)
P.loglog(rhoa, ab2, 'rx-', inv.response(), ab2, 'b-')
P.axis('tight')
P.ylim((max(ab2), min(ab2)))
P.grid(which='both')
P.xlabel(r"\rho_a in \Omegam")
P.ylabel("AB/2 in m")
P.legend(("measured", "fitted"), loc="upper left")
ax2 = fig.add_subplot(122)
res, thk = model(nlay - 1, nlay * 2 - 1), model(0, nlay - 1)
draw1dmodel(res, thk, r'\rho in \Omega m')
draw1dmodel([100., 500., 20., 1000.], [0.5, 3.5, 6.])
P.grid(which='both')
P.show()
예제 #3
0
invDCEM.setLambda( lamDCEM )
invDCEM.setMarquardtScheme( 0.9 )
modelDCEM = invDCEM.run()
respDCEM = invDCEM.response()

# comparison
invDC.echoStatus()
invEM.echoStatus()
invDCEM.echoStatus()
[invDC.chi2(), invEM.chi2(), invDCEM.chi2()]

# plot results
fig=P.figure(1)
fig.clf()
ax1=fig.add_subplot(131)
draw1dmodel( res, thk )
draw1dmodel( modelEM( nlay-1, nlay*2-1 ), modelEM(0,nlay-1) )
draw1dmodel( modelDC( nlay-1, nlay*2-1 ), modelDC(0,nlay-1) )
draw1dmodel( modelDCEM( nlay-1, nlay*2-1 ), modelDCEM(0,nlay-1) )
P.legend(('Syn','EM','DC','JI'))
P.xlim((10.,1000.))
P.ylim((40.,0.))
P.grid(which='both')
ax2=fig.add_subplot(132)
P.semilogy( dataEM( 0, nf ), freq, 'bx', dataEM(nf,nf*2), freq, 'bo')
P.semilogy( respEM( 0, nf ), freq, 'g-', respEM(nf,nf*2), freq, 'g-')
P.semilogy( respDCEM( na, na+nf ), freq, 'c-', respDCEM(na+nf, na+nf*2),freq,'c-')
P.ylim((min(freq),max(freq)))
P.grid(which='both')
P.legend(("syn","","EM","","DCEM",""),loc="lower left")
ax3=fig.add_subplot(133)
예제 #4
0
paraDepth = max( ab2 ) / 3
f.region( 0 ).setStartValue( max(ab2) / 3. / nlay / 2. )
f.region( 1 ).setStartValue( P.median( rhoa ) )

model = f.createStartVector()
model[ nlay ] *= 1.5

inv = g.RInversion( rhoa, f, True )
inv.setModel( model )
inv.setTransData( transRhoa )
inv.setRelativeError( errPerc / 100.0 )
inv.setLambda( lam )
inv.setMarquardtScheme( 0.9 )
model = inv.run()

fig = P.figure(1)
fig.clf()
ax1=fig.add_subplot(121)
P.loglog( rhoa, ab2, 'rx-', inv.response(), ab2, 'b-' )
P.axis('tight')
P.ylim((max(ab2),min(ab2)))
P.grid(which='both')
P.xlabel(r"\rho_a in \Omegam")
P.ylabel("AB/2 in m");
P.legend(("measured", "fitted"),loc="upper left")
ax2=fig.add_subplot(122)
res,thk = model(nlay-1,nlay*2-1),model(0,nlay-1)
draw1dmodel(res,thk,r'\rho in \Omega m')
draw1dmodel([100.,500.,20.,1000.],[0.5,3.5,6.])
P.grid(which='both')
P.show()
예제 #5
0
f = g.DC1dRhoModelling(thk, ab2, mn2)

inv = g.RInversion(rhoa, f, True)
model = g.RVector(nlay, P.median(rhoa))
inv.setModel(model)
inv.setTransData(transRhoa)
inv.setTransModel(transRho)
inv.setRelativeError(errPerc / 100.0)
inv.setLambda(lam)
model = inv.run()

model2 = g.RVector(nlay, P.median(rhoa))
inv.setModel(model2)
inv.setBlockyModel(True)
model2 = inv.run()

fig = P.figure(1)
fig.clf()
ax1 = fig.add_subplot(121)
P.loglog(rhoa, ab2, 'rx-', inv.response(), ab2, 'b-')
P.axis('tight')
P.ylim((max(ab2), min(ab2)))
P.grid(which='both')
P.xlabel(r"\rho_a in \Omegam")
P.ylabel("AB/2 in m")
P.legend(("measured", "fitted"), loc="upper left")
ax2 = fig.add_subplot(122)
draw1dmodel(model, thk, r'\rho in \Omega m')
draw1dmodel(model2, thk, r'\rho in \Omega m')
draw1dmodel([100, 500, 20, 1000], [0.5, 3.5, 6])
P.show()
예제 #6
0
파일: dcem.py 프로젝트: jchavezolalla/gimli
invDCEM.setLambda(lamDCEM)
invDCEM.setMarquardtScheme(0.9)
modelDCEM = invDCEM.run()
respDCEM = invDCEM.response()

# comparison
invDC.echoStatus()
invEM.echoStatus()
invDCEM.echoStatus()
[invDC.chi2(), invEM.chi2(), invDCEM.chi2()]

# plot results
fig = P.figure(1)
fig.clf()
ax1 = fig.add_subplot(131)
draw1dmodel(res, thk)
draw1dmodel(modelEM(nlay - 1, nlay * 2 - 1), modelEM(0, nlay - 1))
draw1dmodel(modelDC(nlay - 1, nlay * 2 - 1), modelDC(0, nlay - 1))
draw1dmodel(modelDCEM(nlay - 1, nlay * 2 - 1), modelDCEM(0, nlay - 1))
P.legend(('Syn', 'EM', 'DC', 'JI'))
P.xlim((10., 1000.))
P.ylim((40., 0.))
P.grid(which='both')
ax2 = fig.add_subplot(132)
P.semilogy(dataEM(0, nf), freq, 'bx', dataEM(nf, nf * 2), freq, 'bo')
P.semilogy(respEM(0, nf), freq, 'g-', respEM(nf, nf * 2), freq, 'g-')
P.semilogy(respDCEM(na, na + nf), freq, 'c-', respDCEM(na + nf, na + nf * 2),
           freq, 'c-')
P.ylim((min(freq), max(freq)))
P.grid(which='both')
P.legend(("syn", "", "EM", "", "DCEM", ""), loc="lower left")