Ejemplo n.º 1
0
            reliabFlag = 1
        icount = 0
        if bzd + 6 < bcf:
            #binBBT=0
            #binBB=bzd-1
            #binBBT=binBB-3
            dn = -0.1
            t1st = time.time()
            dt1 = 0
            dt2 = 0
            dnp = zeros((176), float)
            if binBB > 0:
                bbb = binBB + 2
                dn1d,dm1d,rrate1d,zkuc,zkasim,\
                    epst,piaku,piaka,\
                    dzdn,dpiadn = cmb.iter_profst(bst,bzd,binBB,binBBT,bbb,bcf,bsfc,\
                                                  zKu,zKa,dr,eps,imu,dn,dnCoeff,dnp)
                dn1d1,dm1d1,rrate1d1,zkuc,zkasim1,\
                    epst1,piaku1,piaka1,\
                    dzdn1,dpiadn1 = cmb.iter_profst(bst,bzd,binBB,binBBT,bbb,bcf,bsfc,\
                                                  zKu,zKa,dr,eps,imu,dn+0.1,dnCoeff,dnp)
                gradZS = 1
                gradZe = 0.
                for k in range(bbb + 3, bcf + 1):
                    if zKu[k] > 10.0 and zKa[k] > 10.0:
                        gradZS = gradZS + 0.125 * (
                            (zkasim1[k] - zkasim[k]) / 0.1)**2
                        gradZe = gradZe + 0.25 * (
                            zkasim1[k] - zkasim[k]) / 0.1 * 0.25 * (zKa[k] -
                                                                    zkasim[k])

                if reliabFlag == 1:
Ejemplo n.º 2
0
            zkuc,zkasim,epst,piaKu,piaKa =\
                cmb.iter_profcv(bst[i1,24],bzd[i1,24],bcf[i1,24],\
                                bsfc[i1,24],zKu1,zKa1,dr,eps,imu)
    if pType[i1, 24] == 1:
        if binBB[i1, j1] <= 1:
            dn1d,dm1d,rrate1d,\
                zkuc,zkasim,epst,piaKu,piaKa =\
                    cmb.iter_profcv(bst[i1,24],bzd[i1,24],bcf[i1,24],\
                                bsfc[i1,24],zKu1,zKa1,dr,eps,imu)
        else:
            bbb = binBB[i1, j1] + 2
            bbt = binBBT[i1, j1]
            bb = binBB[i1, j1]
            dn1d,dm1d,rrate1d,\
                zkuc,zkasim,epst,piaKu,piaKa =\
                    cmb.iter_profst(bst[i1,24],bzd[i1,24],bb,bbt,bbb,bcf[i1,24],\
                                    bsfc[i1,24],zKu1,zKa1,dr,eps,imu)

    rrate1dL.append(rrate1d)
    zKaSimL.append(zkasim)

rrate2d = array(rrate1dL)
rrate2d = ma.array(rrate2d, mask=rrate2d < 0.001)
plt.figure()
plt.pcolormesh(rrate2d[:, ::-1].T, cmap='jet')
plt.ylim(0, 60)
plt.xlim(75, 175)
plt.colorbar()

zKaSimL = array(zKaSimL)
zKaSimL = ma.array(zKaSimL, mask=zKaSimL < 0.001)
plt.figure()
Ejemplo n.º 3
0
 if bzd + 6 < bcf and pType == 1:
     #binBBT=0
     #binBB=bzd-1
     #binBBT=binBB-3
     dn = -0.1
     t1st = time.time()
     dt1 = 0
     dt2 = 0
     dnp = zeros((176), float)
     if binBB > 0:
         bbb = binBB + 2
         dn1d,dm1d,rrate1d,zkuc,zkasim,\
             epst,piaku,piaka,\
             dzdn,dpiadn,\
             piaKuS,piaKaS = cmb.iter_profst(bst,bzd,binBB,binBBT,\
                                         bbb,bcf,bsfc,\
                                         zKu,zKa,dr,eps,imu,dn,\
                                         dnCoeff,dnp)
         nc = bsfc - bcf
         wzku = 0.2
         wzka = 0.1
         wpia = 1
         nens = 60
         dpiaRet = piaka - piaku
         if bcf > bbb + 1:
             rrate_out,dn_out,zkusimE,zkasimE,\
                 zku_out,zka_out,rrEns,yEns,xEns,dy,pia_out = \
                 cmb.rainprofstg(zKu[bbb:bcf+1],zKa[bbb:bcf+1],\
                                 dsrtPIA,piaKuS,piaKaS,\
                                 reliabFlag,nc,dr,wzku,wzka,wpia,\
                                 rrate1d[bbb:bcf+1],dn1d[bbb:bcf+1],nens)
             xEns = xEns.T
Ejemplo n.º 4
0
         zkuc,zkasim,epst,piaKu,piaKa =\
             cmb.iter_profcv(bst[i1,j1],bzd[i1,j1],bcf[i1,j1],\
                             bsfc[i1,j1],zKu1,zKa1,dr,eps,imu,1,dnst)
     ibbL.append(0)
 else:
     bbb=binBB[i1,j1]+2
     bbt=binBBT[i1,j1]
     bb=binBB[i1,j1]
     dnst=0.0
     dnCoeff=array([ 0.01608098, -0.82884294])
     #dnCoeff=array([-0.00570364,  0.13319214])
     #dnst=-0.35
     dnp=random.randn(176)*0.025
     dn1d,dm1d,rrate1d,\
         zkuc,zkasim,epst,piaKu,piaKa =\
             cmb.iter_profst(bst[i1,j1],bzd[i1,j1],bb,bbt,bbb,bcf[i1,j1],\
                             bsfc[i1,j1],zKu1,zKa1,dr,eps,imu,dnst,dnCoeff,dnp)
     dn1d1,dm1d1,rrate1d1,\
         zkuc1,zkasim1,epst1,piaKu1,piaKa1 =\
             cmb.iter_profst(bst[i1,j1],bzd[i1,j1],bb,bbt,bbb,bcf[i1,j1],\
                             bsfc[i1,j1],zKu1,zKa1,dr,eps,imu,dnst-0.1,dnCoeff,dnp)
     
     ddpia=-((piaKa1-piaKu1)-(piaKa-piaKu))/0.1
     dpiaSRT=5*piaSRT[i1,j1]
     
     if reliabFlag[i1,j1]==1 or reliabFlag[i1,j1]==2:
         dnst=(dpiaSRT-(piaKa-piaKu))*ddpia/(ddpia**2+1)
         dn1d,dm1d,rrate1d,\
             zkuc,zkasim,epst,piaKu,piaKa =\
             cmb.iter_profst(bst[i1,j1],bzd[i1,j1],bb,bbt,bbb,bcf[i1,j1],\
                             bsfc[i1,j1],zKu1,zKa1,dr,eps,imu,dnst,dnCoeff,dnp)
         rd1L.append([rrate1d[bcf[i1,j1]],dprsfcRate[i1,j1],\