#! /usr/bin/env python3
# -*- coding:utf8 -*-
import matplotlib.pyplot as plt
import numpy as np
from math import *
plt.rcParams['font.sans-serif'] = 'DejaVu Sans'
plt.rc('mathtext', default='regular')
# data: https://doi.org/10.1063/1.555614 TABLE 2.
# T in K, rho in 1e-8 Ohm*m
T_rho_Cu = np.array([
[20, 0.000798], [25, 0.00249], [30,0.00628], [35, 0.0127], [40, 0.0219],
[45, 0.0338], [50, 0.0498], [55, 0.0707], [60, 0.0951], [70, 0.152],
[80, 0.213], [90, 0.279], [100, 0.346], [125, 0.520], [150, 0.697],
[175, 0.872], [200, 1.044], [225, 1.215], [250, 1.385], [273.15, 1.541],
[293, 1.676], [300, 1.723], [350, 2.061], [400, 2.400], [500, 3.088],
[600, 3.790], [700, 4.512], [800, 5.260], [900, 6.039], [1000, 6.856],
[1100, 7.715], [1200, 8.624], [1300, 9.590], [1357.6, 10.169]
])
# data: https://doi.org/10.1063/1.555614 TABLE 5.
# T in K, rho in 1e-8 Ohm*m
T_rho_Au = np.array([
[15, 0.00376], [20, 0.0126], [25, 0.0282], [30, 0.0505], [35, 0.0798],
[40, 0.119], [45, 0.159], [50, 0.199], [55, 0.248], [60, 0.286], [70, 0.373],
[80, 0.459], [90, 0.544], [100, 0.628], [125, 0.835], [150, 1.039],
[175, 1.240], [200, 1.440], [225, 1.640], [250, 1.842], [273.15, 2.029],
[293, 2.192], [300, 2.249], [350, 2.663], [400, 3.085], [500, 3.952],
[600, 4.853], [700, 5.794], [800, 6.786], [900, 7.840], [1000, 8.964],
[1100, 10.169], [1200, 11.464], [1300, 12.832], [1337.58, 13.366]
])
# data: https://doi.org/10.1063/1.555614 TABLE 11.
# T in K, rho in 1e-8 Ohm*m
T_rho_Ag = np.array([
[20, 0.00322], [25, 0.00855], [30, 0.0184], [35, 0.0331], [40, 0.0529],
[45, 0.0763], [50, 0.103], [55, 0.131], [60, 0.161], [70, 0.224], [80, 0.288],
[90, 0.353], [100, 0.417], [125, 0.572], [150, 0.725], [175, 0.877],
[200, 1.028], [225, 1.178], [250, 1.328], [273.15, 1.466], [293, 1.586],
[300, 1.628], [350, 1.931], [400, 2.240], [500, 2.874], [600, 3.530],
[700, 4.208], [800, 4.911], [900, 5.637], [1000, 6.395], [1100, 7.214],
[1200, 8.088], [1235.08, 8.414]
])
fig = plt.figure(figsize=(520 / 90.0, 340 / 90.0), dpi=72)
plt.plot(T_rho_Au[:,0], 10.*T_rho_Au[:,1], '-', color='#d39a00', lw=2.4, label='Au')
plt.plot(T_rho_Cu[:,0], 10.*T_rho_Cu[:,1], '-', color='#a05923', lw=2.4, label='Cu')
plt.plot(T_rho_Ag[:,0], 10.*T_rho_Ag[:,1], '-', color='#909090', lw=2.4, label='Ag')
plt.grid(True)
plt.xlim(0)
plt.ylim(0, 140)
plt.xlabel('T [K]')
plt.ylabel(r'$\rho$ [$10^{-9}\Omega m$]')
plt.legend(loc='upper left')
plt.plot([293, 293], [0, 2.192e1], color='k', lw=0.5)
plt.tight_layout()
plt.savefig('Resistivity_Cu-Ag-Au.svg')