[1]:
%load_ext autoreload
%autoreload 2

plot vr vr using plons

[2]:
import math                     as math
import matplotlib.pyplot        as plt

# import necessary plons scripts
import plons.AccrDisk                     as ad

Examples:

[2]:
## Example for one circular model:
run    = '/STER/matse/Phantom/Pi1Gru/Pi1Gru/'
dump   = 101
dumpData,setup = ad.loadDataForSmoothing(run,dump)
r      = 0.75
zoom   = 100
smooth = ad.calcSmoothVtVrRho(zoom,dumpData,setup)
fig, axs = plt.subplots(nrows = 1, ncols= 3 , figsize=(28, 7))
ad.plot_vrvtRho(axs,smooth,zoom,r)
fig.savefig(run+f'plotsAnalysis/vrvtRho_op_wind_%05d'%(dump)+'_Z'+str(zoom)+'.png')
plt.show(fig)
../../_images/1_examples_2_accretion_disk_accrDisks_vrvrPlots_Plons_4_0.png
[2]:
## Example: all eccentric models, 4 different dumps, 4 zoom

%matplotlib inline
# models = ['v20e50']
# dumps  = [250,266,277,292]
# rs     = [0.44,0.37,0.5,0.41]
# zoomChoices = [20,12,8.5,2]
# for model in models:
#     run    = '/lhome/jolienm/Documents/TierModels/R_Aql/cooling/binariesInPaper/finalAccrDisks/'+str(model)+'_T3000_res8_racc01/'
#     i = 0
#     for dump in dumps:
#         dumpData,setup = loadDataForSmoothing(run,dump)
#         r = rs[i]
#         i = i+1
#         for zoom in zoomChoices:
#             smooth = calcSmoothVtVrRho(zoom,dumpData,setup)
#             plot_vrvtRho(smooth,zoom,run,dump,r)

models = ['v10e50']
dumps  = [245,263,277,292]
rs     = [0.48,0.58,0.59,0.63]
zoomChoices = [20,12,8.5,2]

for model in models:
    run    = '/lhome/jolienm/Documents/TierModels/R_Aql/cooling/binariesInPaper/finalAccrDisks/'+str(model)+'_T3000_res8_racc01/'
    i = 0
    for dump in dumps:
        dumpData,setup = ad.loadDataForSmoothing(run,dump)
        r = rs[i]
        i = i+1
        for zoom in zoomChoices:
            smooth = ad.calcSmoothVtVrRho(zoom,dumpData,setup)
            fig, axs = plt.subplots(nrows = 1, ncols= 3 , figsize=(28, 7))
            ad.plot_vrvtRho(axs,smooth,zoom,r)
            fig.savefig(run+f'plotsAnalysis/vrvtRho_op_wind_%05d'%(dump)+'_Z'+str(zoom)+'.png')


# models = ['v05e50']
# dumps  = [245,263,277,292]
# rs     = [0.62,0.70,0.64,0.59]
# zoomChoices = [20,12,8.5,2]
# for model in models:
#     run    = '/lhome/jolienm/Documents/TierModels/R_Aql/cooling/binariesInPaper/finalAccrDisks/'+str(model)+'_T3000_res8_racc01/'
#     i = 0
#     for dump in dumps:
#         dumpData,setup = ad.loadDataForSmoothing(run,dump)
#         r = rs[i]
#         i = i+1
#         for zoom in zoomChoices:
#             smooth = ad.calcSmoothVtVrRho(zoom,dumpData,setup)
#             fig, axs = plt.subplots(nrows = 1, ncols= 3 , figsize=(28, 7))
#             ad.plot_vrvtRho(axs,smooth,zoom,r)
#             fig.savefig(run+f'plotsAnalysis/vrvtRho_op_wind_%05d'%(dump)+'_Z'+str(zoom)+'.png')

../../_images/1_examples_2_accretion_disk_accrDisks_vrvrPlots_Plons_5_0.png
[3]:
## Example: all circular models, 1 dump, 4 different zoom

%matplotlib inline

# Load data and calculate smoothened data for sliceplots
dump = 292
models = ['v10e00','v05e00','v20e00']
# models = ['v05e00']
# zoomChoices = [20,12,8.5,2]
zoomChoices = [12]

for model in models:
    if model == 'v20e00':
        r = 0.36
    elif model == 'v10e00':
        r = 0.75
    elif model == 'v05e00':
        r = 0.94
    run    = '/lhome/jolienm/Documents/TierModels/R_Aql/cooling/binariesInPaper/finalAccrDisks/'+str(model)+'_T3000_res8_racc01/'
    dumpData,setup = ad.loadDataForSmoothing(run,dump)
    for zoom in zoomChoices:
        smooth = ad.calcSmoothVtVrRho(zoom,dumpData,setup)
        fig, axs = plt.subplots(nrows = 1, ncols= 2 , figsize=(19, 7))
        ad.plot_vrvt(axs,smooth,zoom,r)
        fig.savefig(run+f'plotsAnalysis/vrvt_op_wind_%05d'%(dump)+'_Z'+str(zoom)+'.png')
        # fig, axs = plt.subplots(nrows = 1, ncols= 3 , figsize=(28, 7))
        # ad.plot_vrvtRho(axs,smooth,zoom,r)
        # fig.savefig(run+f'plotsAnalysis/vrvtRho_op_wind_%05d'%(dump)+'_Z'+str(zoom)+'.png')


# zoom  = 20        # for v20e00                          ----> Z1
# zoom = 12         # for v05e00 and v10e00               ----> Z2
# zoom = 8.5        # correct for v05e00 and v10e00       ----> Z3
# zoom = 3                                              # ----> Z10
# zoom = 2                                              # ----> Z15
../../_images/1_examples_2_accretion_disk_accrDisks_vrvrPlots_Plons_6_0.png
../../_images/1_examples_2_accretion_disk_accrDisks_vrvrPlots_Plons_6_1.png
../../_images/1_examples_2_accretion_disk_accrDisks_vrvrPlots_Plons_6_2.png
[ ]: