Added calculation for intermediate pair of coils
This commit is contained in:
		
							parent
							
								
									7d4a895dc4
								
							
						
					
					
						commit
						37688201fe
					
				| @ -0,0 +1,87 @@ | |||||||
|  | import matplotlib.pyplot as plt | ||||||
|  | import numpy as np | ||||||
|  | import matplotlib | ||||||
|  | # matplotlib.use('Qt5Agg') | ||||||
|  | from src import coil_class as BC | ||||||
|  | 
 | ||||||
|  | scale = 10 | ||||||
|  | lim = 20 | ||||||
|  | nr_points = (2 * lim) * scale + 1 | ||||||
|  | x = np.linspace(-lim, lim, nr_points) | ||||||
|  | z = np.linspace(-lim, lim, nr_points) | ||||||
|  | 
 | ||||||
|  | 
 | ||||||
|  | def mu_it(x_pos): | ||||||
|  |     it = nr_points // 2 + x_pos | ||||||
|  |     return it | ||||||
|  | 
 | ||||||
|  | 
 | ||||||
|  | scale = 10 | ||||||
|  | # I_current = 0.94 | ||||||
|  | HH_Coil = BC.BCoil(HH=1, distance=79.968, radius=80.228, layers=8, windings=8, wire_height=0.5, | ||||||
|  |                    wire_width=0.5, insulation_thickness=0.046 / 2, is_round=True, | ||||||
|  |                    winding_scheme=2) | ||||||
|  | 
 | ||||||
|  | AHH_Coil = BC.BCoil(HH=-1, distance=100.336, radius=85.016, layers=10, windings=10, wire_height=1.18, | ||||||
|  |                     wire_width=1.18, insulation_thickness=0.06, is_round=True, | ||||||
|  |                     winding_scheme=2) | ||||||
|  | 
 | ||||||
|  | HH_Coil.print_basic_info() | ||||||
|  | AHH_Coil.print_basic_info() | ||||||
|  | 
 | ||||||
|  | I = 0.75 | ||||||
|  | #HH_Coil.B_quick_plot(I) | ||||||
|  | #HH_Coil.B_curv_quick_plot(I) | ||||||
|  | 
 | ||||||
|  | # Power | ||||||
|  | #HH_Coil.cooling(I, 23) | ||||||
|  | #AHH_Coil.cooling(I, 23) | ||||||
|  | print(f"resistance = {HH_Coil.resistance(23)} Ohm") | ||||||
|  | 
 | ||||||
|  | 
 | ||||||
|  | # rough Field | ||||||
|  | I_HH = 1 | ||||||
|  | HH_Coil.max_field(I_HH) | ||||||
|  | 
 | ||||||
|  | I_AHH = 3.6 | ||||||
|  | AHH_Coil.max_gradient(I_AHH) | ||||||
|  | 
 | ||||||
|  | # Quick plot | ||||||
|  | 
 | ||||||
|  | HH_Coil.B_quick_plot(I_HH) | ||||||
|  | HH_Coil.B_curv_quick_plot(I_HH) | ||||||
|  | AHH_Coil.B_quick_plot(I_AHH) | ||||||
|  | AHH_Coil.B_grad_quick_plot(I_AHH, nr_points = 200) | ||||||
|  | 
 | ||||||
|  | HH_Coil.plot_3d(I_HH, 50, 50) | ||||||
|  | AHH_Coil.plot_3d(I_AHH, 50, 50) | ||||||
|  | 
 | ||||||
|  | # Field calculation | ||||||
|  | 
 | ||||||
|  | Bz_HH, Bx_HH = HH_Coil.B_field(I_HH, x, z) | ||||||
|  | B_tot_z, B_tot_x = HH_Coil.B_tot_along_axis(I_HH, x, z) | ||||||
|  | 
 | ||||||
|  | Bz_grad = BC.BCoil.grad(Bz_HH, z) | ||||||
|  | 
 | ||||||
|  | 
 | ||||||
|  | 
 | ||||||
|  | 
 | ||||||
|  | # Position 2 | ||||||
|  | # AHH_Coil.set_R_inner(62) | ||||||
|  | # AHH_Coil.set_d_min(116) | ||||||
|  | # | ||||||
|  | # print(f"wire length = {AHH_Coil.get_wire_length()} m") | ||||||
|  | 
 | ||||||
|  | # AHH_Coil.print_info() | ||||||
|  | 
 | ||||||
|  | I = 1 | ||||||
|  | # print(f"current I = {I} A") | ||||||
|  | 
 | ||||||
|  | 
 | ||||||
|  | # AHH_Coil.B_quick_plot(I) | ||||||
|  | # AHH_Coil.B_grad_quick_plot(I, nr_points = 200) | ||||||
|  | # AHH_Coil.B_curv_quick_plot(I, nr_points = scale) | ||||||
|  | 
 | ||||||
|  | 
 | ||||||
|  | # HH_Coil.print_info() | ||||||
|  | # AHH_Coil.print_info() | ||||||
							
								
								
									
										23
									
								
								RF_coil/frequency_response.py
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										23
									
								
								RF_coil/frequency_response.py
									
									
									
									
									
										Normal file
									
								
							| @ -0,0 +1,23 @@ | |||||||
|  | import numpy as np | ||||||
|  | import matplotlib.pyplot as plt | ||||||
|  | import matplotlib as mpl | ||||||
|  | from src import coil_class as BC | ||||||
|  | 
 | ||||||
|  | 
 | ||||||
|  | RF_Coil = BC.BCoil(HH = 1, distance = 54, radius = 38.4, layers = 3, windings = 1, wire_height = 0.5, | ||||||
|  |                    wire_width = 0.5, insulation_thickness = (0.546-0.5)/2, is_round = True, | ||||||
|  |                    winding_scheme= 2) | ||||||
|  | 
 | ||||||
|  | R = RF_Coil.resistance(22.5)*2 | ||||||
|  | 
 | ||||||
|  | # R = 10 | ||||||
|  | 
 | ||||||
|  | L = RF_Coil.induct_perry() | ||||||
|  | 
 | ||||||
|  | L = 0.26e-6 | ||||||
|  | 
 | ||||||
|  | 
 | ||||||
|  | f = R/(2*np.pi* L) | ||||||
|  | print(R) | ||||||
|  | print(L) | ||||||
|  | print(f) | ||||||
| @ -13,6 +13,7 @@ Me = 9 | |||||||
| Mg = 8 | Mg = 8 | ||||||
| 
 | 
 | ||||||
| mu_eff = (ge*Me- gg*Mg) * cs.mu_B | mu_eff = (ge*Me- gg*Mg) * cs.mu_B | ||||||
|  | #print(mu_eff) | ||||||
| 
 | 
 | ||||||
| detuning = 2 * np.pi * 2.4e6 #Hz | detuning = 2 * np.pi * 2.4e6 #Hz | ||||||
| dG = 2.26e-4 #T/cm | dG = 2.26e-4 #T/cm | ||||||
|  | |||||||
| @ -624,7 +624,7 @@ class BCoil: | |||||||
|                 if B_tot[zz, xx] > 15: |                 if B_tot[zz, xx] > 15: | ||||||
|                     B[zz, xx, :] /= B_tot[zz, xx] / 15 |                     B[zz, xx, :] /= B_tot[zz, xx] / 15 | ||||||
| 
 | 
 | ||||||
|         plt.figure(33) |         plt.figure() | ||||||
|         plt.quiver(x_m, z_m, B[:, :, 0], B[:, :, 1]) |         plt.quiver(x_m, z_m, B[:, :, 0], B[:, :, 1]) | ||||||
|         plt.xlabel("x-axis [mm]") |         plt.xlabel("x-axis [mm]") | ||||||
|         plt.ylabel("z-axis [mm]") |         plt.ylabel("z-axis [mm]") | ||||||
|  | |||||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user