Added plots, fixed python files
This commit is contained in:
@@ -14,13 +14,14 @@ sns.set()
|
||||
|
||||
# Intensity profile graphics
|
||||
rho = np.linspace(-r_max, r_max, 500)
|
||||
fig1 = plt.figure(1, figsize=(10, 6))
|
||||
plt.figure(1, figsize=(10, 6))
|
||||
I = gauss(rho)
|
||||
I0 = np.max(I)
|
||||
plt.plot(rho, I / I0)
|
||||
plt.fill_between(rho, I / I0, 0, alpha=0.3)
|
||||
plt.xlabel('r, m', fontsize=18)
|
||||
plt.ylabel('I(r)', fontsize=18)
|
||||
plt.title("Forces along Y axis")
|
||||
plt.xlabel('$r, m$', fontsize=18)
|
||||
plt.ylabel('$I(r)$', fontsize=18)
|
||||
|
||||
# Integration
|
||||
def q_res_g(z, func):
|
||||
@@ -47,11 +48,12 @@ axial = axial_g + axial_s
|
||||
z = -z[::-1]
|
||||
|
||||
# Graphics
|
||||
fig2 = plt.figure(2, figsize=(10, 6))
|
||||
plt.figure(2, figsize=(10, 6))
|
||||
plt.plot(z, axial_g, '-.', lw=1, label='$F_{g}$')
|
||||
plt.plot(z, axial_s, '--', lw=1, label='$F_{s}$')
|
||||
plt.plot(z, axial, lw=1, label='$F_{t}$')
|
||||
plt.xlabel('r, m', fontsize=18)
|
||||
plt.ylabel('F, N', fontsize=18)
|
||||
plt.xlabel('$r, m$', fontsize=18)
|
||||
plt.ylabel('$F, N$', fontsize=18)
|
||||
plt.legend(fontsize=18)
|
||||
|
||||
plt.show()
|
||||
|
||||
@@ -14,12 +14,11 @@ t_deg = t * 180 / np.pi
|
||||
pol = np.pi / 4
|
||||
|
||||
plt.figure(figsize=(13, 8))
|
||||
plt.plot(t_deg, q_s(t, pol), '--', label='Q_s')
|
||||
plt.plot(t_deg, -q_g(t, pol), '-.', label='Q_g')
|
||||
plt.plot(t_deg, q_mag(t, pol), label='Q_t')
|
||||
plt.grid()
|
||||
plt.plot(t_deg, q_s(t, pol), '--', label='$Q_s$')
|
||||
plt.plot(t_deg, -q_g(t, pol), '-.', label='$Q_g$')
|
||||
plt.plot(t_deg, q_mag(t, pol), label='$Q_t$')
|
||||
plt.xlabel(r'$\theta$, deg', fontsize=18)
|
||||
plt.ylabel('Q', fontsize=18)
|
||||
plt.ylabel('$Q$', fontsize=18)
|
||||
plt.legend(fontsize=18)
|
||||
plt.title('Beam efficiencies', fontsize=20)
|
||||
plt.title('Ray efficiencies', fontsize=20)
|
||||
plt.show()
|
||||
|
||||
@@ -13,13 +13,14 @@ sns.set()
|
||||
|
||||
# Intensity profile graphics
|
||||
rho = np.linspace(-r_max, r_max, 500)
|
||||
fig1 = plt.figure(1, figsize=(10, 6))
|
||||
plt.figure(1, figsize=(10, 6))
|
||||
I = gauss(rho)
|
||||
I0 = np.max(I)
|
||||
plt.plot(rho, I / I0)
|
||||
plt.fill_between(rho, I / I0, 0, alpha=0.3)
|
||||
plt.xlabel('r, m', fontsize=18)
|
||||
plt.ylabel('I(r)', fontsize=18)
|
||||
plt.title("Forces along Z axis")
|
||||
plt.xlabel('$r, m$', fontsize=18)
|
||||
plt.ylabel('$I(r)$', fontsize=18)
|
||||
|
||||
|
||||
# Integration
|
||||
@@ -46,11 +47,12 @@ transverse = transverse_g + transverse_s
|
||||
|
||||
|
||||
# Graphics
|
||||
fig2 = plt.figure(2, figsize=(10, 6))
|
||||
plt.figure(2, figsize=(10, 6))
|
||||
plt.plot(y, transverse_g, '-.', lw=1, label='$F_{g}$')
|
||||
plt.plot(y, transverse_s, '--', lw=1, label='$F_{s}$')
|
||||
plt.plot(y, transverse, lw=1, label='$F_{t}$')
|
||||
plt.xlabel('r, m', fontsize=18)
|
||||
plt.ylabel('F, m', fontsize=18)
|
||||
plt.xlabel('$r, m$', fontsize=18)
|
||||
plt.ylabel('$F, N$', fontsize=18)
|
||||
plt.legend()
|
||||
|
||||
plt.show()
|
||||
Reference in New Issue
Block a user