$R$


In [1]:
from numpy import matlib as ml
from phys_const import *
from plot_conf import *
#from tm import ttf
execfile("tm.py")
r,M,tB,E=np.genfromtxt('model_fun.dat',unpack=True)
R = np.genfromtxt('R.dat')
rr=ml.repmat(r,R.shape[0],1)
t,t1=np.genfromtxt('t.dat',unpack=True)
t=t*Gyr_per_Gpc
S = R / rr
clf()
rc('text', usetex=True)
rc('font', family='serif',size=font_size)
xlim([-9,9])
plot(r[1:-1],R[0,1:-1],'b-',label=ttf(t[0]))
plot(r[1:-1],R[1,1:-1],'r-',label=ttf(t[1]))
plot(r[1:-1],R[2,1:-1],'c-',label=ttf(t[2]))
plot(r[1:-1],R[3,1:-1],'g-',label=ttf(t[3]))
plot(r[1:-1],R[4,1:-1],'y-',label=ttf(t[4]))
gca().set_yscale('log')
xlabel(r'$r [Gpc]$',size=label_size)
ylabel(r'$R(t,r) \left[ h^{-1}Gpc\right]$',size=label_size)
legend(loc='lower right',prop={'size':legend_size})
plt.savefig('R_hl87.png', bbox_inches='tight')

$\rho$


In [2]:
from numpy import matlib as ml
from phys_const import *
from tm import ttf
from plot_conf import *
r,M,tB,E=np.genfromtxt('model_fun.dat',unpack=True)
rho = np.genfromtxt('rho.dat')
t,t1=np.genfromtxt('t.dat',unpack=True)
t=t*Gyr_per_Gpc
clf()
rc('text', usetex=True)
rc('font', family='serif',size=font_size)
#xlim([-9,9])
plot(r[1:-1],rho[0,1:-1],'b-',label=ttf(t[0]))
plot(r[1:-1],rho[1,1:-1],'r-',label=ttf(t[1]))
plot(r[1:-1],rho[2,1:-1],'c-',label=ttf(t[2]))
plot(r[1:-1],rho[3,1:-1],'g-',label=ttf(t[3]))
plot(r[1:-1],rho[4,1:-1],'y-',label=ttf(t[4]))
gca().set_yscale('log')
xlabel(r'$r [Gpc]$',size=label_size)
ylabel(r'$\rho(t,r) [10^{10}M_\odot Gpc^{-3}h^3$]',size=label_size)
legend(loc='upper right',prop={'size':legend_size})
plt.savefig('ro_hl87.png', bbox_inches='tight')

$H$


In [3]:
from numpy import matlib as ml
from phys_const import *
from tm import ttf
from plot_conf import *
r,M,tB,E=np.genfromtxt('model_fun.dat',unpack=True)
H = np.genfromtxt('exp.dat')
H = np.abs(H)
t,t1=np.genfromtxt('t.dat',unpack=True)
t=t*Gyr_per_Gpc
clf()
rc('text', usetex=True)
rc('font', family='serif',size=font_size)
xlim([-9,9])
plot(r[1:-1],H[0,1:-1],'b-',label=ttf(t[0]))
plot(r[1:-1],H[1,1:-1],'r-',label=ttf(t[1]))
plot(r[1:-1],H[2,1:-1],'c-',label=ttf(t[2]))
plot(r[1:-1],H[3,1:-1],'g-',label=ttf(t[3]))
plot(r[1:-1],H[4,1:-1],'y-',label=ttf(t[4])+r'$(H < 0)$')
gca().set_yscale('log')
xlabel(r'$r [Gpc]$',size=label_size)
ylabel(r'$\left |H(t,r)\right | \left [ h\,Gyr^{-1}\right] $',size=label_size)
legend(loc='upper right',prop={'size':legend_size})
plt.savefig('H_hl87.png', bbox_inches='tight')

$M,\;\;t_B\;\; i\;\; E$


In [4]:
from pylab import figure, show
from plot_conf import *
from phys_const import * 
r,M,tB,E=np.genfromtxt('model_fun.dat',unpack=True)

class FixedOrderFormatter(ScalarFormatter):
    """Formats axis ticks using scientific notation with a constant order of 
    magnitude"""
    def __init__(self, order_of_mag=0, useOffset=True, useMathText=False):
        self._order_of_mag = order_of_mag
        ScalarFormatter.__init__(self, useOffset=useOffset, 
                                 useMathText=useMathText)
    def _set_orderOfMagnitude(self, range):
        """Over-riding this to avoid having orderOfMagnitude reset elsewhere"""
        self.orderOfMagnitude = self._order_of_mag

# Create a figure and add three subplots.
fig = figure()
ax1 = fig.add_subplot(311)
ax2 = fig.add_subplot(312, sharex=ax1)  # share ax1's xaxis
ax3 = fig.add_subplot(313, sharex=ax1)  # share ax1's xaxis

ax1.label_outer

# Plot
ax1.plot(r,M)
ax1.set_ylabel(r'$M(r) [10^{10}M_{\odot}]$',size=label_size);
ax1.locator_params(nbins=4)

ax2.plot(r,tB*Gyr_per_Gpc,)
ax2.set_ylabel(r'$t_{\mathrm{B}}(r) [h^{-1}Gyr]$',size=label_size);
ax2.locator_params(nbins=4)

ax3.plot(r,E)
ax3.set_ylabel(r'$E(r)$',size=label_size);
ax3.set_xlabel(r'$r [Gpc]$',size=label_size);
ax3.yaxis.set_major_formatter(FixedOrderFormatter(-6))
# Show the figure.
subplots_adjust(left=None, bottom=None, right=None, top=None, wspace=None, hspace=0.5)
show()
plt.savefig('fun_hl87.png', bbox_inches='tight')

In [2]:
from numpy import matlib as ml
from phys_const import *
from tm import ttf
from plot_conf import *
r,M,tB,E=np.genfromtxt('model_fun.dat',unpack=True)
gr = np.genfromtxt('grr.dat')
t,t1=np.genfromtxt('t.dat',unpack=True)
t=t*Gyr_per_Gpc
clf()
rc('text', usetex=True)
rc('font', family='serif',size=font_size)
xlim([-9,9])
plot(r[1:-1],gr[0,1:-1],'b-',label=ttf(t[0]))
plot(r[1:-1],gr[1,1:-1],'r-',label=ttf(t[1]))
plot(r[1:-1],gr[2,1:-1],'c-',label=ttf(t[2]))
plot(r[1:-1],gr[3,1:-1],'g-',label=ttf(t[3]))
plot(r[1:-1],gr[4,1:-1],'y-',label=ttf(t[4])+r'$(H < 0)$')
gca().set_yscale('log')
xlabel(r'$r [Gpc]$',size=label_size)
ylabel(r'$\left |H(t,r)\right | \left [ h\,Gyr^{-1}\right] $',size=label_size)
legend(loc='upper right',prop={'size':legend_size})
plt.savefig('H_hl87.png', bbox_inches='tight')

In [4]:
from numpy import matlib as ml
from phys_const import *
from tm import ttf
from plot_conf import *
r,M,tB,E=np.genfromtxt('model_fun.dat',unpack=True)
gr = np.genfromtxt('integr.dat')
t,t1=np.genfromtxt('t.dat',unpack=True)
t=t*Gyr_per_Gpc
clf()
rc('text', usetex=True)
rc('font', family='serif',size=font_size)
xlim([-9,9])
plot(r[1:-1],gr[0,1:-1],'b-',label=ttf(t[0]))
plot(r[1:-1],gr[1,1:-1],'r-',label=ttf(t[1]))
plot(r[1:-1],gr[2,1:-1],'c-',label=ttf(t[2]))
plot(r[1:-1],gr[3,1:-1],'g-',label=ttf(t[3]))
plot(r[1:-1],gr[4,1:-1],'y-',label=ttf(t[4])+r'$(H < 0)$')
gca().set_yscale('log')
xlabel(r'$r [Gpc]$',size=label_size)
ylabel(r'$\left |H(t,r)\right | \left [ h\,Gyr^{-1}\right] $',size=label_size)
legend(loc='upper right',prop={'size':legend_size})
plt.savefig('H_hl87.png', bbox_inches='tight')

In [ ]: