Пример #1
0
#sf.sol(plot=True)

#eq.plotb()
#

'''
sf.plot_coils(next(Color),coils=sf.coil,label=True,plasma=False,current=True) 

#sf.plot_coils(next(Color),coils=eq.coil,label=False,plasma=False) 

rb.FWfill(dt=conf.tfw,loop=True,alpha=0.7,color=next(Color))
rb.fill(dt=conf.BB[::-1],alpha=0.7,ref_o=0.3,dref=0.2,
        referance='length',color=next(Color))
rb.fill(dt=conf.tBBsupport,alpha=0.7,color=next(Color))
rb.BBsheild_fill(dt=conf.sheild,ref_o=0.35*np.pi,dref=0.2*np.pi,
                 offset=1/10*np.pi,alpha=0.7,color=next(Color))
rb.VVfill(dt=conf.VV,ref_o=0.25*np.pi,dref=0.25*np.pi,offset=0.5/10*np.pi,
          alpha=0.7,loop=True,color=next(Color))  # ref_o=0.385

conf.TFopp = 'L'
rb.set_TFbound()  # TF boundary conditions
rb.TFbound['ro_min'] -= 0.5
#rb.plot_TFbounds()          
rb.TFopp(False,objF=conf.TFopp)  # L==length, V==volume
rb.TFfill()
'''

'''
Rfw,Zfw = [],[]
with open('../Data/X_bdry.txt') as f:
    for i in range(10):
Пример #2
0
    pl.tight_layout()
    #pl.xlim([4,14]),pl.ylim([-13,8])
    pl.xlim([3, 17]), pl.ylim([-12, 10])

    conf = Config(config, inside=False)
    sf = SF(conf)
    sf.contour()
    sf.plot_coils(Color)
    conf.TF(sf)
    rb = RB(conf, sf, Np=200)
    rb.divertor_outline(True)
    rb.fill(dt=conf.tfw, alpha=0.7, color=next(Color))
    rb.fill(dt=conf.BB, alpha=0.7, color=next(Color))
    rb.fill(dt=conf.tBBsupport, alpha=0.7, color=next(Color))
    rb.BBsheild_fill(dt=conf.sheild,
                     ref_o=2 / 8 * np.pi,
                     alpha=0.7,
                     color=next(Color))
    rb.fill(dt=conf.VV, alpha=0.7, color=next(Color), loop=True)
    rb.set_TFbound()  # TF boundary conditions
    #rb.TFbound['ro_min'] -= 0.25
    #rb.plot_TFbounds()
    rb.TFopp(False, objF='L')  # L==length, V==volume
    rb.TFfill()

    pl.text(16, 9.5, config, fontsize=36, ha='right', va='top')
    '''
    Color = cycle(sns.color_palette('Set2'))
    for leg in conf.targets.keys():
        R,Z = rb.sol.legs(leg)
        pl.plot(R,Z,color=next(Color))
    pl.tight_layout()