Sub Project_36_EN(ByVal VecType, m, n, m1, n1 As Integer) ' 36 Lorentz Force ' Updated: 4/01/25 ' Created by: Becerra Ariel, Cabrera Francisco, Ortiz Daniela, Jimenez Gabriel, Hernandez Aaron, Valderrama Sebastian, Gomez Fabian (20/12/24) ' Modified by: _________________ ' This is the code of your new project. ' Steps to embed the code to ScienSolar: ' Note 1: The number 36 in the name of this function must match the one in the list of the CONFIG sheet for this project. If not, please correct it. ' Note 2: This code will be integrated into the main code (into the VBA editor) to automate the download of the project. ' Note 3: The formulas and cell values generated here correspond only to the first 30 columns in the sheet. All your formulas and values are recommended to be written in these columns. ' Step 1. Go to the CONFIG sheet (at the end of column C) and add the number of your new project to the last row in the projects list, and a short name in the corresponding langage column. ' Step 2. Make sure that the list of projects in CONFIG sheet has the correct ascending numbering. ' Step 4. Open the VBA editor (Alt + F11 in Windows or Fn + Option + F11 in macOS). To avoid mistakes, make sure you only have one workbook open. ' Step 5. On the left, in the project explorer, select a non full module (or add a new one). ' Step 6. Select all the code in this file, copy and paste it at the end of the existing code in the module (or in the new one). ' Step 7. To load the project and to check it in a new sheet, go to the CONFIG sheet and click the New Sheet button, then select the project from the list and click the +Vector button. ' Step 8. Click any XYZ button to get the project in the coordinate system. Enjoy it! ' Visit www.sciensolar.com for news and updates of © ScienSolar. Cells(m1 -1, n1 + 2).FormulaR1C1 ="1" Cells(m1 - 1, n1 ).Value = "ENTIRE" Cells(m1 + 0, n1 + 0).FormulaR1C1 ="24" Cells(m1 + 0, n1 + 1).FormulaR1C1 ="77" Cells(m1 + 0, n1 + 2).FormulaR1C1 ="=CONFIG!R3C4" Cells(m1 + 0, n1 + 3).FormulaR1C1 ="850" Cells(m1 + 0, n1 + 6).FormulaR1C1 ="=CONFIG!R3C8" Cells(m1 + 0, n1 + 7).FormulaR1C1 ="0.000001" Cells(m1 + 0, n1 + 8).FormulaR1C1 ="Becerra Ariel, Cabrera Francisco, Ortiz Daniela, Jimenez Gabriel, Hernandez Aaron, Valderrama Sebastian, Gomez Fabian (20/12/24)" Cells(m1 + 1, n1 + 2).FormulaR1C1 ="=CONFIG!R4C4" Cells(m1 + 1, n1 + 3).FormulaR1C1 ="450" Cells(m1 + 1, n1 + 4).FormulaR1C1 ="=CONFIG!R4C6" Cells(m1 + 1, n1 + 5).FormulaR1C1 ="0" Cells(m1 + 1, n1 + 6).FormulaR1C1 ="=CONFIG!R4C8" Cells(m1 + 1, n1 + 7).FormulaR1C1 ="26" Cells(m1 + 2, n1 + 0).FormulaR1C1 ="t = 0,046875 s." Cells(m1 + 2, n1 + 2).FormulaR1C1 ="=CONFIG!R5C4" Cells(m1 + 2, n1 + 3).FormulaR1C1 ="200" Cells(m1 + 2, n1 + 4).FormulaR1C1 ="=CONFIG!R5C6" Cells(m1 + 2, n1 + 5).FormulaR1C1 ="15" Cells(m1 + 2, n1 + 6).FormulaR1C1 =" t =" Cells(m1 + 2, n1 + 7).FormulaR1C1 ="0" Cells(m1 + 3, n1 + 0).FormulaR1C1 ="B" Cells(m1 + 3, n1 + 2).FormulaR1C1 ="=CONFIG!R6C4" Cells(m1 + 3, n1 + 3).FormulaR1C1 ="200" Cells(m1 + 3, n1 + 4).FormulaR1C1 ="=CONFIG!R6C6" Cells(m1 + 3, n1 + 5).FormulaR1C1 ="15" Cells(m1, n1 + 9).FormulaR1C1 = "HELP" Dim HELPtxt as String HELPtxt = "MOVIMIENTO PARABîLICO" & Chr(10) & _ " (See english version at the end)" & Chr(10) & _ " A continuaci—n se escriben en las respectivas celdas las ecuaciones del movimiento parab—lico para las coordenadas x, y, z, que corresponden al vector r(x, y, z):" & Chr(10) & _ " A12 = x = x0 + v0x t + 1/2 ax t^2Ž" & Chr(10) & _ " B12 = y = y0 + v0y t + 1/2 ay t^2 " & Chr(10) & _ " C12 = z = z0 + v0z t + 1/2 az t^2,Ž" & Chr(10) & _ " en donde el tiempo estŽ dado por el valor de la celda I5. Las aceleraciones en cada eje se calculan por la segunda ley de Newton F = ma = qE. En el vector 6 se encuentran las ecuaciones para las respectivas componentes de estas aceleraciones: Ž" & Chr(10) & _ " A57 = ax = q Ex /mŽ" & Chr(10) & _ " B57 = ay = q Ey /mŽ" & Chr(10) & _ " C57 =az = q Ez /m." & Chr(10) & _ " Las ecuaciones para las componentes del vector velocidad se calculan por las f—rmulas A39 = Vx = Vox + ax t, B39 = Vy = Voy + ay t, C39 = Vz = Voz + az t. El tiempo tR en el que la part’cula alcanza el plano xy y es hallado resoviendo la ecuaci—n cuadr‡tica descrita al principio con respecto al tiempo t y para cada eje el resultado es plasmado en A56, B56 y C56. Por medio de la funci—n MIN() de Excel, es calculado el tiempo m’nimo entre los tres planos con el objeto de identificar a cu‡l plano cae primero la part’cula; este tiempo m’nimo se plasma en G49." & Chr(10) & _ " Oprima el bot—n B/W para ver el modelo en fondo blanco. Cambie los colores de los vectores a su gusto. En las celdas G12-G26 modifique los par‡metros iniciales para la posici—n, velocidad, campo elŽctrico, carga y masa de la part’cula y observe los resultados oprimiendo el bot—n Run. Si desea dibujar la trayectoria de la part’cula, coloque G28=2, y para quitarla G28=1, oprimiendo luego el bot—n Run. Oprima el bot—n Set to Zero para volver a iniciar la simulaci—n, y el bot—n 1 by 1 para ver la simulaci—n cada paso.Ž" & Chr(10) & _ " (ENGLISH)" & Chr(10) & _ " PARABOLIC MOVEMENT" & Chr(10) & _ " Next, the equations of parabolic motion are written in the respective cells for the coordinates x, y, z, which correspond to the vector r(x, y, z):" & Chr(10) & _ " A12 = x = x0 + v0x t + 1/2 ax t^2" & Chr(10) & _ " B12 = y = y0 + v0y t + 1/2 ay t^2 " & Chr(10) & _ " C12 = z = z0 + v0z t + 1/2 az t^2," & Chr(10) & _ " where the time is given by the value of cell I5. The accelerations in each axis are calculated by Newton's second law F = ma = qE. In vector 6 are the equations for these accelerations:" & Chr(10) & _ " A57 = ax = q Ex /m" & Chr(10) & _ " B57 = ay = q Ey /m" & Chr(10) & _ " C57 =az = q Ez /m." & Chr(10) & _ " The equations for the components of the velocity vector are calculated using the formulas A39 = Vx = Vox + ax t, B39 = Vy = Voy + ay t, C39 = Vz = Voz + az t. The time tR in which the particle reaches the xy plane is found by solving the quadratic equation described at the beginning with respect to time t and for each axis the result is recorded in A56, B56 and C56. Using Excel's MIN() function, the minimum time between the three planes is calculated to identify which plane the particle lands on first; this minimum time is reflected in I6." & Chr(10) & _ " Press the B/W button to see the model on a white background. Change the colors of the vectors to your liking. In cells G12-G26 modify the initial parameters of position, velocity, electric field, charge and mass of the particle and observe the results by pressing the Run button. If you want to draw the trajectory of the particle, set G28 = 2, and to remove it, G28 = 1, then press the Run button. Press the Set to Zero button to restart the simulation and the 1 by 1 button to view the simulation at each step." & Chr(10) & _ " " On Error Resume Next Cells(m1 , n1 + 9).Comment.Text Text:= HELPtxt If m = m1 + 0 Then ' vector 8 Cells(m + 3, n + -1).FormulaR1C1 ="1" Cells(m + 3, n + 0).FormulaR1C1 ="B" Cells(m + 3, n + 2).FormulaR1C1 ="=CONFIG!R6C4" Cells(m + 3, n + 3).FormulaR1C1 ="200" Cells(m + 3, n + 4).FormulaR1C1 ="=CONFIG!R6C6" Cells(m + 3, n + 5).FormulaR1C1 ="15" Cells(m + 3, n + 9).FormulaR1C1 ="Some vectors have been R E D U C E D! Set the scale in cell B8" Cells(m + 4, n + -1).FormulaR1C1 ="1" Cells(m + 4, n + 0).FormulaR1C1 ="183" Cells(m + 4, n + 2).FormulaR1C1 ="Lorentz force" Cells(m + 4, n + 12).FormulaR1C1 ="PARTICLE MOVEMENT IN ELECTRICAL AND MAGNETIC FIELDS" Cells(m + 4, n + 24).FormulaR1C1 ="INSTRUCTIONS" Cells(m + 5, n + -1).FormulaR1C1 ="1" Cells(m + 5, n + 0).FormulaR1C1 ="800*0,1" Cells(m + 5, n + 1).FormulaR1C1 ="=R[14]C[4]" Cells(m + 5, n + 12).FormulaR1C1 ="LORENTZ FORCE" Cells(m + 7, n + -1).FormulaR1C1 ="0" Cells(m + 7, n + 0).FormulaR1C1 ="=0.8*R6C5/R5C5" Cells(m + 7, n + 1).FormulaR1C1 ="=0.8*R6C5/R5C5" Cells(m + 7, n + 4).FormulaR1C1 ="Magnetic field (T):" Cells(m + 7, n + 21).FormulaR1C1 ="The objective of the model is to understand the behavior of charged particles moving in " Cells(m + 8, n + 2).FormulaR1C1 ="=IF(R[59]C[-1]>1,"" <-- Variable coordinates"","""")" Cells(m + 8, n + 4).FormulaR1C1 =" B_x =" Cells(m + 8, n + 5).FormulaR1C1 ="-0.05" Cells(m + 8, n + 21).FormulaR1C1 ="constant electric and magnetic fields. The model allows to add several particles and calculate " Cells(m + 9, n + -1).FormulaR1C1 ="=IF(R[-1]C[6]=0,1E-20,R[-1]C[6])" Cells(m + 9, n + 0).FormulaR1C1 ="=IF(RC[5]=0,1E-20,RC[5])" Cells(m + 9, n + 1).FormulaR1C1 ="=IF(R[1]C[4]=0,1E-20,R[1]C[4])" Cells(m + 9, n + 2).FormulaR1C1 ="=IF(R[58]C[-1]>1,"" <-- Field formulae"","""")" Cells(m + 9, n + 4).FormulaR1C1 =" B_y =" Cells(m + 9, n + 5).FormulaR1C1 ="0" Cells(m + 9, n + 21).FormulaR1C1 ="at any time their positions, velocities and accelerations, depending on the initial conditions. " Cells(m + 10, n + -1).FormulaR1C1 ="1" Cells(m + 10, n + 0).FormulaR1C1 ="0" Cells(m + 10, n + 1).FormulaR1C1 ="1" Cells(m + 10, n + 4).FormulaR1C1 =" B_z =" Cells(m + 10, n + 5).FormulaR1C1 ="0" Cells(m + 10, n + 21).FormulaR1C1 ="It can also explain the operation of the MASS SPECTROMETER and the VELOCITY SELECTOR." Cells(m + 11, n + -1).FormulaR1C1 ="3" Cells(m + 11, n + 0).FormulaR1C1 ="0" Cells(m + 11, n + 1).FormulaR1C1 ="1" Cells(m + 11, n + 2).FormulaR1C1 =" |B| =" Cells(m + 11, n + 3).FormulaR1C1 ="=SQRT(R[-2]C[-4]^2+R[-2]C[-3]^2+R[-2]C[-2]^2)" Cells(m + 3, n + 1).Interior.Color = "12874308" Cells(m + 3, n + 1).Font.Size = "12" Cells(m + 3, n + 1).Font.name = "Calibri" Cells(m + 4, n - 1).Value = 1 Cells(m1 + 1, n1 + 1).Value = "E" Call AddNewVector end if ' vector ends If m = m1 + 9 Then ' vector 7 Cells(m + 3, n + -1).FormulaR1C1 ="2" Cells(m + 3, n + 0).FormulaR1C1 ="E" Cells(m + 3, n + 1).FormulaR1C1 ="z" Cells(m + 3, n + 4).FormulaR1C1 ="Electric field (N/C):" Cells(m + 3, n + 21).FormulaR1C1 ="CONVENTIONS:" Cells(m + 4, n + -1).FormulaR1C1 ="1" Cells(m + 4, n + 0).FormulaR1C1 ="183" Cells(m + 4, n + 4).FormulaR1C1 =" E_x =" Cells(m + 4, n + 5).FormulaR1C1 ="0" Cells(m + 4, n + 21).FormulaR1C1 ="PARAMETER:" Cells(m + 4, n + 22).FormulaR1C1 ="CELL:" Cells(m + 4, n + 23).FormulaR1C1 ="VALUE (EXAMPLE):" Cells(m + 4, n + 25).FormulaR1C1 ="OBSERVATION:" Cells(m + 5, n + -1).FormulaR1C1 ="1" Cells(m + 5, n + 0).FormulaR1C1 ="100*1" Cells(m + 5, n + 1).FormulaR1C1 ="=R[4]C[4]" Cells(m + 5, n + 4).FormulaR1C1 =" E_y =" Cells(m + 5, n + 5).FormulaR1C1 ="0" Cells(m + 5, n + 21).FormulaR1C1 ="Scale:" Cells(m + 5, n + 22).FormulaR1C1 =" E5 = " Cells(m + 5, n + 23).FormulaR1C1 ="200" Cells(m + 5, n + 25).FormulaR1C1 ="Model scale" Cells(m + 6, n + 4).FormulaR1C1 =" E_z =" Cells(m + 6, n + 5).FormulaR1C1 ="0" Cells(m + 6, n + 21).FormulaR1C1 ="Step:" Cells(m + 6, n + 22).FormulaR1C1 =" I3 = " Cells(m + 6, n + 23).FormulaR1C1 ="0.000001" Cells(m + 6, n + 25).FormulaR1C1 ="Time scale in seconds" Cells(m + 7, n + -1).FormulaR1C1 ="0" Cells(m + 7, n + 0).FormulaR1C1 ="=0.8*R6C5/R5C5" Cells(m + 7, n + 1).FormulaR1C1 ="=0.8*R6C5/R5C5" Cells(m + 7, n + 2).FormulaR1C1 =" |E| =" Cells(m + 7, n + 3).FormulaR1C1 ="=SQRT(R[-3]C[2]^2+R[-2]C[2]^2+R[-1]C[2]^2)" Cells(m + 7, n + 21).FormulaR1C1 ="Number of steps:" Cells(m + 7, n + 22).FormulaR1C1 =" I4 = " Cells(m + 7, n + 23).FormulaR1C1 ="26" Cells(m + 7, n + 25).FormulaR1C1 ="Time units traveled" Cells(m + 8, n + -1).FormulaR1C1 ="0" Cells(m + 8, n + 0).FormulaR1C1 ="0" Cells(m + 8, n + 1).FormulaR1C1 ="0" Cells(m + 8, n + 2).FormulaR1C1 ="=IF(R[-4]C[-1]>1,"" <-- Variable coordinates"","""")" Cells(m + 8, n + 4).FormulaR1C1 ="Show (yes=0, no=1):" Cells(m + 8, n + 21).FormulaR1C1 =" B_x =" Cells(m + 8, n + 22).FormulaR1C1 =" G11 = " Cells(m + 8, n + 23).FormulaR1C1 ="-0.05" Cells(m + 8, n + 25).FormulaR1C1 ="X-component of magnetic field" Cells(m + 9, n + -1).FormulaR1C1 ="=R[-5]C[6]" Cells(m + 9, n + 0).FormulaR1C1 ="=R[-4]C[5]" Cells(m + 9, n + 1).FormulaR1C1 ="=R[-3]C[4]" Cells(m + 9, n + 2).FormulaR1C1 ="=IF(R[-5]C[-1]>1,"" <-- Field formulae"","""")" Cells(m + 9, n + 4).FormulaR1C1 =" E:" Cells(m + 9, n + 5).FormulaR1C1 ="0" Cells(m + 9, n + 21).FormulaR1C1 =" B_y =" Cells(m + 9, n + 22).FormulaR1C1 =" G12 = " Cells(m + 9, n + 23).FormulaR1C1 ="0" Cells(m + 9, n + 25).FormulaR1C1 ="Y-component of magnetic field" Cells(m + 10, n + -1).FormulaR1C1 ="1" Cells(m + 10, n + 0).FormulaR1C1 ="0" Cells(m + 10, n + 1).FormulaR1C1 ="1" Cells(m + 10, n + 4).FormulaR1C1 =" B:" Cells(m + 10, n + 5).FormulaR1C1 ="0" Cells(m + 10, n + 21).FormulaR1C1 =" B_z =" Cells(m + 10, n + 22).FormulaR1C1 =" G13 = " Cells(m + 10, n + 23).FormulaR1C1 ="0" Cells(m + 10, n + 25).FormulaR1C1 ="Z-component of magnetic field" Cells(m + 11, n + -1).FormulaR1C1 ="3" Cells(m + 11, n + 0).FormulaR1C1 ="0" Cells(m + 11, n + 1).FormulaR1C1 ="1" Cells(m + 11, n + 21).FormulaR1C1 =" E_x =" Cells(m + 11, n + 22).FormulaR1C1 =" G16 = " Cells(m + 11, n + 23).FormulaR1C1 ="0" Cells(m + 11, n + 25).FormulaR1C1 ="X-component of electric field" Cells(m + 3, n + 1).Interior.Color = "36799" Cells(m + 3, n + 1).Font.Size = "11" Cells(m + 3, n + 1).Font.name = "Calibri" Cells(m + 4, n - 1).Value = 1 Cells(m1 + 1, n1 + 1).Value = " + q1" Call AddNewVector end if ' vector ends If m = m1 + 18 Then ' vector 6 Cells(m + 3, n + -1).FormulaR1C1 ="=R[-9]C+1" Cells(m + 3, n + 0).FormulaR1C1 ="=IF(R[3]C[5]<0,"" - q"","" + q"")&R[1]C[5]" Cells(m + 3, n + 2).FormulaR1C1 ="%%%%%%%%%%%%%%%%%%%%%%%%%%%%%" Cells(m + 3, n + 21).FormulaR1C1 =" E_y =" Cells(m + 3, n + 22).FormulaR1C1 =" G17 = " Cells(m + 3, n + 23).FormulaR1C1 ="0" Cells(m + 3, n + 25).FormulaR1C1 ="Y-component of electric field" Cells(m + 4, n + -1).FormulaR1C1 ="1" Cells(m + 4, n + 0).FormulaR1C1 ="9" Cells(m + 4, n + 2).FormulaR1C1 ="To mark the path" Cells(m + 4, n + 4).FormulaR1C1 ="Particle No.:" Cells(m + 4, n + 5).FormulaR1C1 ="1" Cells(m + 4, n + 21).FormulaR1C1 =" E_z =" Cells(m + 4, n + 22).FormulaR1C1 =" G18 = " Cells(m + 4, n + 23).FormulaR1C1 ="0" Cells(m + 4, n + 25).FormulaR1C1 ="Z-component of electric field" Cells(m + 5, n + -1).FormulaR1C1 ="1" Cells(m + 5, n + 0).FormulaR1C1 ="1" Cells(m + 5, n + 1).FormulaR1C1 ="0" Cells(m + 5, n + 2).FormulaR1C1 ="=""pressr A""&ROW(R[-2]C[-3])&"" (left)""" Cells(m + 5, n + 4).FormulaR1C1 ="Charge of the particle (C):" Cells(m + 5, n + 21).FormulaR1C1 =" E:" Cells(m + 5, n + 22).FormulaR1C1 =" G21 = " Cells(m + 5, n + 23).FormulaR1C1 ="0" Cells(m + 5, n + 25).FormulaR1C1 ="Show or hide vector E" Cells(m + 6, n + 4).FormulaR1C1 ="q =" Cells(m + 6, n + 5).FormulaR1C1 ="1.6E-19" Cells(m + 6, n + 21).FormulaR1C1 =" B:" Cells(m + 6, n + 22).FormulaR1C1 =" G22 = " Cells(m + 6, n + 23).FormulaR1C1 ="0" Cells(m + 6, n + 25).FormulaR1C1 ="Show or hide vector B" Cells(m + 7, n + -1).FormulaR1C1 ="=R[47]C+R[4]C[6]" Cells(m + 7, n + 0).FormulaR1C1 ="=R[47]C+R[5]C[5]" Cells(m + 7, n + 1).FormulaR1C1 ="=R[47]C+R[6]C[4]" Cells(m + 7, n + 4).FormulaR1C1 ="Mass of the particle (kg):" Cells(m + 7, n + 21).FormulaR1C1 ="Particle No.:" Cells(m + 7, n + 22).FormulaR1C1 =" G25 = " Cells(m + 7, n + 23).FormulaR1C1 ="1" Cells(m + 7, n + 25).FormulaR1C1 ="Indicate the number of the first particle" Cells(m + 8, n + 2).FormulaR1C1 ="=IF(R[-4]C[-1]>1,"" <-- Variable coordinates"","""")" Cells(m + 8, n + 4).FormulaR1C1 ="m =" Cells(m + 8, n + 5).FormulaR1C1 ="6.64E-26" Cells(m + 8, n + 21).FormulaR1C1 =" q =" Cells(m + 8, n + 22).FormulaR1C1 =" G27 = " Cells(m + 8, n + 23).FormulaR1C1 ="1.6E-19" Cells(m + 8, n + 25).FormulaR1C1 ="Charge of the first particle" Cells(m + 9, n + -1).FormulaR1C1 ="2" Cells(m + 9, n + 0).FormulaR1C1 ="2" Cells(m + 9, n + 1).FormulaR1C1 ="0" Cells(m + 9, n + 2).FormulaR1C1 ="=IF(R[-5]C[-1]>1,"" <-- Field formulae"","""")" Cells(m + 9, n + 4).FormulaR1C1 ="////////////////////////////" Cells(m + 9, n + 21).FormulaR1C1 =" m =" Cells(m + 9, n + 22).FormulaR1C1 =" G29 = " Cells(m + 9, n + 23).FormulaR1C1 ="6.64E-26" Cells(m + 9, n + 25).FormulaR1C1 ="Mass of the first particle" Cells(m + 10, n + -1).FormulaR1C1 ="1" Cells(m + 10, n + 0).FormulaR1C1 ="0" Cells(m + 10, n + 1).FormulaR1C1 ="1" Cells(m + 10, n + 4).FormulaR1C1 ="Initial position (m):" Cells(m + 10, n + 21).FormulaR1C1 =" x_o =" Cells(m + 10, n + 22).FormulaR1C1 =" G32 = " Cells(m + 10, n + 23).FormulaR1C1 ="0" Cells(m + 10, n + 25).FormulaR1C1 ="X-position of the first particle" Cells(m + 11, n + -1).FormulaR1C1 ="3" Cells(m + 11, n + 0).FormulaR1C1 ="0" Cells(m + 11, n + 1).FormulaR1C1 ="2" Cells(m + 11, n + 2).FormulaR1C1 =" << -- Size " Cells(m + 11, n + 4).FormulaR1C1 ="x_o =" Cells(m + 11, n + 5).FormulaR1C1 ="0" Cells(m + 11, n + 21).FormulaR1C1 =" y_o =" Cells(m + 11, n + 22).FormulaR1C1 =" G33 = " Cells(m + 11, n + 23).FormulaR1C1 ="0" Cells(m + 11, n + 25).FormulaR1C1 ="Y-position of the first particle" Cells(m + 3, n + 1).Interior.Color = "255" Cells(m + 3, n + 1).Font.Size = "11" Cells(m + 3, n + 1).Font.name = "Calibri" Cells(m + 4, n - 1).Value = 1 Cells(m1 + 1, n1 + 1).Value = "Vo" Call AddNewVector end if ' vector ends If m = m1 + 27 Then ' vector 5 Cells(m + 3, n + -1).FormulaR1C1 ="=R[-9]C+1" Cells(m + 3, n + 0).FormulaR1C1 ="Vo" Cells(m + 3, n + 4).FormulaR1C1 ="y_o =" Cells(m + 3, n + 5).FormulaR1C1 ="0" Cells(m + 3, n + 21).FormulaR1C1 =" z_o =" Cells(m + 3, n + 22).FormulaR1C1 =" G34 = " Cells(m + 3, n + 23).FormulaR1C1 ="0" Cells(m + 3, n + 25).FormulaR1C1 ="Z-position of the first particle" Cells(m + 4, n + -1).FormulaR1C1 ="1" Cells(m + 4, n + 0).FormulaR1C1 ="183" Cells(m + 4, n + 4).FormulaR1C1 ="z_o =" Cells(m + 4, n + 5).FormulaR1C1 ="0" Cells(m + 4, n + 21).FormulaR1C1 =" V_ox=" Cells(m + 4, n + 22).FormulaR1C1 =" G36 = " Cells(m + 4, n + 23).FormulaR1C1 ="0" Cells(m + 4, n + 25).FormulaR1C1 ="X-velocity of the first particle" Cells(m + 5, n + -1).FormulaR1C1 ="1" Cells(m + 5, n + 0).FormulaR1C1 ="60*1" Cells(m + 5, n + 1).FormulaR1C1 ="=R[11]C[4]" Cells(m + 5, n + 4).FormulaR1C1 ="Initial velocity (m/s):" Cells(m + 5, n + 21).FormulaR1C1 =" V_oy=" Cells(m + 5, n + 22).FormulaR1C1 =" G37 = " Cells(m + 5, n + 23).FormulaR1C1 ="40000" Cells(m + 5, n + 25).FormulaR1C1 ="Y-velocity of the first particle" Cells(m + 6, n + 4).FormulaR1C1 =" V_ox=" Cells(m + 6, n + 5).FormulaR1C1 ="0" Cells(m + 6, n + 21).FormulaR1C1 =" V_oz=" Cells(m + 6, n + 22).FormulaR1C1 =" G38 = " Cells(m + 6, n + 23).FormulaR1C1 ="0" Cells(m + 6, n + 25).FormulaR1C1 ="Z-velocity of the first particle" Cells(m + 7, n + -1).FormulaR1C1 ="=R[-5]C[6]" Cells(m + 7, n + 0).FormulaR1C1 ="=R[-4]C[5]" Cells(m + 7, n + 1).FormulaR1C1 ="=R[-3]C[4]" Cells(m + 7, n + 4).FormulaR1C1 =" V_oy=" Cells(m + 7, n + 5).FormulaR1C1 ="40000" Cells(m + 7, n + 21).FormulaR1C1 =" |Vo| =" Cells(m + 7, n + 22).FormulaR1C1 =" G39 = " Cells(m + 7, n + 23).FormulaR1C1 ="=SQRT(R[-1]C[-18]^2+RC[-18]^2+R[1]C[-18]^2)" Cells(m + 7, n + 25).FormulaR1C1 ="Initial velocity modulus" Cells(m + 8, n + 2).FormulaR1C1 ="=IF(R[5]C[-1]>1,"" <-- Variable coordinates"","""")" Cells(m + 8, n + 4).FormulaR1C1 =" V_oz=" Cells(m + 8, n + 5).FormulaR1C1 ="0" Cells(m + 8, n + 21).FormulaR1C1 =" D:" Cells(m + 8, n + 22).FormulaR1C1 =" G44 = " Cells(m + 8, n + 23).FormulaR1C1 ="1" Cells(m + 8, n + 25).FormulaR1C1 ="Show/hide vector D" Cells(m + 9, n + -1).FormulaR1C1 ="=R[-3]C[6]" Cells(m + 9, n + 0).FormulaR1C1 ="=R[-2]C[5]" Cells(m + 9, n + 1).FormulaR1C1 ="=R[-1]C[4]" Cells(m + 9, n + 2).FormulaR1C1 ="=IF(R[4]C[-1]>1,"" <-- Field formulae"","""")" Cells(m + 9, n + 4).FormulaR1C1 =" |Vo| =" Cells(m + 9, n + 5).FormulaR1C1 ="=SQRT(R[-3]C^2+R[-2]C^2+R[-1]C^2)" Cells(m + 9, n + 21).FormulaR1C1 =" r:" Cells(m + 9, n + 22).FormulaR1C1 =" G45 = " Cells(m + 9, n + 23).FormulaR1C1 ="0" Cells(m + 9, n + 25).FormulaR1C1 ="Show/hide vector r" Cells(m + 10, n + -1).FormulaR1C1 ="1" Cells(m + 10, n + 0).FormulaR1C1 ="0" Cells(m + 10, n + 1).FormulaR1C1 ="1" Cells(m + 10, n + 2).FormulaR1C1 ="||||||||||||||||||||||||||||||||||||||||||||||" Cells(m + 10, n + 21).FormulaR1C1 =" Vo:" Cells(m + 10, n + 22).FormulaR1C1 =" G46 = " Cells(m + 10, n + 23).FormulaR1C1 ="1" Cells(m + 10, n + 25).FormulaR1C1 ="Show/hide vector Vo" Cells(m + 11, n + -1).FormulaR1C1 ="3" Cells(m + 11, n + 0).FormulaR1C1 ="0" Cells(m + 11, n + 1).FormulaR1C1 ="1" Cells(m + 11, n + 21).FormulaR1C1 =" V:" Cells(m + 11, n + 22).FormulaR1C1 =" G47 = " Cells(m + 11, n + 23).FormulaR1C1 ="1" Cells(m + 11, n + 25).FormulaR1C1 ="Show/hide vector V" Cells(m + 3, n + 1).Interior.Color = "11573124" Cells(m + 3, n + 1).Font.Size = "11" Cells(m + 3, n + 1).Font.name = "Calibri" Cells(m + 4, n - 1).Value = 1 Cells(m1 + 1, n1 + 1).Value = "V" Call AddNewVector end if ' vector ends If m = m1 + 36 Then ' vector 4 Cells(m + 3, n + -1).FormulaR1C1 ="=R[-9]C+1" Cells(m + 3, n + 0).FormulaR1C1 ="V" Cells(m + 3, n + 4).FormulaR1C1 ="DISPLAY:" Cells(m + 3, n + 21).FormulaR1C1 =" a:" Cells(m + 3, n + 22).FormulaR1C1 =" G48 = " Cells(m + 3, n + 23).FormulaR1C1 ="1" Cells(m + 3, n + 25).FormulaR1C1 ="Show/hide vector a" Cells(m + 4, n + -1).FormulaR1C1 ="1" Cells(m + 4, n + 0).FormulaR1C1 ="183" Cells(m + 4, n + 2).FormulaR1C1 =" " Cells(m + 4, n + 4).FormulaR1C1 ="Show (yes=0, no=1):" Cells(m + 4, n + 21).FormulaR1C1 =" rB =" Cells(m + 4, n + 22).FormulaR1C1 =" G55 = " Cells(m + 4, n + 23).FormulaR1C1 ="formula" Cells(m + 4, n + 25).FormulaR1C1 ="Radius of curvature due to B field" Cells(m + 5, n + -1).FormulaR1C1 ="1" Cells(m + 5, n + 0).FormulaR1C1 ="60*1" Cells(m + 5, n + 1).FormulaR1C1 ="=R[3]C[4]" Cells(m + 5, n + 3).FormulaR1C1 ="Distance" Cells(m + 5, n + 4).FormulaR1C1 =" D:" Cells(m + 5, n + 5).FormulaR1C1 ="1" Cells(m + 5, n + 21).FormulaR1C1 =" D =" Cells(m + 5, n + 22).FormulaR1C1 =" G57 = " Cells(m + 5, n + 23).FormulaR1C1 ="formula" Cells(m + 5, n + 25).FormulaR1C1 ="Distance from the starting point" Cells(m + 6, n + 3).FormulaR1C1 ="Radius vector" Cells(m + 6, n + 4).FormulaR1C1 =" r:" Cells(m + 6, n + 5).FormulaR1C1 ="1" Cells(m + 6, n + 21).FormulaR1C1 =" r =" Cells(m + 6, n + 22).FormulaR1C1 =" G59 = " Cells(m + 6, n + 23).FormulaR1C1 ="formula" Cells(m + 6, n + 25).FormulaR1C1 ="Radius vector of the particle" Cells(m + 7, n + -1).FormulaR1C1 ="=R[-18]C" Cells(m + 7, n + 0).FormulaR1C1 ="=R[-18]C" Cells(m + 7, n + 1).FormulaR1C1 ="=R[-18]C" Cells(m + 7, n + 3).FormulaR1C1 ="Initial speed" Cells(m + 7, n + 4).FormulaR1C1 =" Vo:" Cells(m + 7, n + 5).FormulaR1C1 ="1" Cells(m + 7, n + 21).FormulaR1C1 =" |V| =" Cells(m + 7, n + 22).FormulaR1C1 =" G61 = " Cells(m + 7, n + 23).FormulaR1C1 ="formula" Cells(m + 7, n + 25).FormulaR1C1 ="Module of the velocity" Cells(m + 8, n + 2).FormulaR1C1 ="=IF(R[-31]C[-1]>1,"" <-- Variable coordinates"","""")" Cells(m + 8, n + 3).FormulaR1C1 ="Velocity" Cells(m + 8, n + 4).FormulaR1C1 =" V:" Cells(m + 8, n + 5).FormulaR1C1 ="1" Cells(m + 9, n + -1).FormulaR1C1 ="=IF(R[-9]C[6]=R[-29]C[4]/R[-34]C[4],R[-9]C,R70C5*R12C1/R12C3+2*R71C5/(R12C1^2+R12C2^2)*(-R12C1*R12C3*COS(R76C5*R5C9)-R12C2*R14C5*SIN(R76C5*R5C9))+2*R72C5/(R12C1^2+R12C2^2)*(R12C2*R14C5*COS(R76C5*R5C9)-R12C1*R12C3*SIN(R76C5*R5C9))+R27C7*R16C7/R29C7*R5C9)" Cells(m + 9, n + 0).FormulaR1C1 ="=IF(R[-9]C[5]=R[-29]C[3]/R[-34]C[3],R[-9]C,R70C5*R12C2/R12C3+2*R71C5/(R12C1^2+R12C2^2)*(-R12C2*R12C3*COS(R76C5*R5C9)+R12C1*R14C5*SIN(R76C5*R5C9))+2*R72C5/(R12C1^2+R12C2^2)*(-R12C1*R14C5*COS(R76C5*R5C9)-R12C2*R12C3*SIN(R76C5*R5C9))+R27C7*R17C7/R29C7*R5C9)" Cells(m + 9, n + 1).FormulaR1C1 ="=IF(R[-9]C[4]=R[-29]C[2]/R[-34]C[2],R[-9]C,R70C5+2*R71C5*COS(R76C5*R5C9)+2*R72C5*SIN(R76C5*R5C9)+R27C7*R18C7/R29C7*R5C9)" Cells(m + 9, n + 2).FormulaR1C1 ="=IF(R[-32]C[-1]>1,"" <-- Field formulae"","""")" Cells(m + 9, n + 3).FormulaR1C1 ="Acceleration" Cells(m + 9, n + 4).FormulaR1C1 =" a:" Cells(m + 9, n + 5).FormulaR1C1 ="1" Cells(m + 9, n + 21).FormulaR1C1 ="ADDING MORE PARTICLES:" Cells(m + 10, n + -1).FormulaR1C1 ="1" Cells(m + 10, n + 0).FormulaR1C1 ="0" Cells(m + 10, n + 1).FormulaR1C1 ="1" Cells(m + 10, n + 21).FormulaR1C1 ="Several particles with their own parameters can be added to the model. To do this, press the " Cells(m + 11, n + -1).FormulaR1C1 ="3" Cells(m + 11, n + 0).FormulaR1C1 ="0" Cells(m + 11, n + 1).FormulaR1C1 ="1" Cells(m + 11, n + 21).FormulaR1C1 ="+OBJ button and to remove them, press the -OBJ button. The following values __must be present " Cells(m + 3, n + 1).Interior.Color = "11573124" Cells(m + 3, n + 1).Font.Size = "11" Cells(m + 3, n + 1).Font.name = "Calibri" Cells(m + 4, n - 1).Value = 1 Cells(m1 + 1, n1 + 1).Value = "r" Call AddNewVector end if ' vector ends If m = m1 + 45 Then ' vector 3 Cells(m + 3, n + -1).FormulaR1C1 ="=R[-9]C+1" Cells(m + 3, n + 0).FormulaR1C1 ="r" Cells(m + 3, n + 2).FormulaR1C1 ="||||||||||||||||||||||||||||||||||||||||||||||" Cells(m + 3, n + 21).FormulaR1C1 ="before pressing the buttons:" Cells(m + 4, n + -1).FormulaR1C1 ="1" Cells(m + 4, n + 0).FormulaR1C1 ="183" Cells(m + 4, n + 4).FormulaR1C1 ="RESULTS:" Cells(m + 4, n + 23).FormulaR1C1 =" B2 = " Cells(m + 4, n + 24).FormulaR1C1 ="ENTIRE" Cells(m + 5, n + -1).FormulaR1C1 ="1" Cells(m + 5, n + 0).FormulaR1C1 ="4" Cells(m + 5, n + 1).FormulaR1C1 ="=R[-8]C[4]" Cells(m + 5, n + 22).FormulaR1C1 ="First row:" Cells(m + 5, n + 23).FormulaR1C1 =" B3 = " Cells(m + 5, n + 24).FormulaR1C1 ="24" Cells(m + 6, n + 4).FormulaR1C1 ="Radius of curvature (m):" Cells(m + 6, n + 22).FormulaR1C1 ="Last row:" Cells(m + 6, n + 23).FormulaR1C1 =" C3 = " Cells(m + 6, n + 24).FormulaR1C1 ="77" Cells(m + 7, n + -1).FormulaR1C1 ="0" Cells(m + 7, n + 0).FormulaR1C1 ="0" Cells(m + 7, n + 1).FormulaR1C1 ="0" Cells(m + 7, n + 4).FormulaR1C1 ="rB =" Cells(m + 7, n + 5).FormulaR1C1 ="=R[-26]C*R[-16]C/ABS(R[-28]C*R[-41]C[-2])" Cells(m + 7, n + 21).FormulaR1C1 ="(Be sure to change the new particle number and its parameters.)" Cells(m + 8, n + 2).FormulaR1C1 ="=IF(R[-4]C[-1]>1,"" <-- Variable coordinates"","""")" Cells(m + 8, n + 4).FormulaR1C1 ="Distance (D = r - r_o):" Cells(m + 8, n + 21).FormulaR1C1 ="SET PARTICLE PATH" Cells(m + 9, n + -1).FormulaR1C1 ="=R[-25]C[6]+R[18]C" Cells(m + 9, n + 0).FormulaR1C1 ="=R[-24]C[5]+R[18]C" Cells(m + 9, n + 1).FormulaR1C1 ="=R[-23]C[4]+R[18]C" Cells(m + 9, n + 2).FormulaR1C1 ="=IF(R[-5]C[-1]>1,"" <-- Field formulae"","""")" Cells(m + 9, n + 4).FormulaR1C1 ="D =" Cells(m + 9, n + 5).FormulaR1C1 ="=SQRT(R[18]C[-6]^2+R[18]C[-5]^2+R[18]C[-4]^2)" Cells(m + 9, n + 21).FormulaR1C1 ="Use the button in A24 to set the particle path before pressing the run button located in " Cells(m + 10, n + -1).FormulaR1C1 ="1" Cells(m + 10, n + 0).FormulaR1C1 ="0" Cells(m + 10, n + 1).FormulaR1C1 ="1" Cells(m + 10, n + 4).FormulaR1C1 ="Position vector r:" Cells(m + 10, n + 21).FormulaR1C1 ="cell K5." Cells(m + 11, n + -1).FormulaR1C1 ="3" Cells(m + 11, n + 0).FormulaR1C1 ="0" Cells(m + 11, n + 1).FormulaR1C1 ="1" Cells(m + 11, n + 4).FormulaR1C1 ="r =" Cells(m + 11, n + 5).FormulaR1C1 ="=SQRT(R[-2]C[-6]^2+R[-2]C[-5]^2+R[-2]C[-4]^2)" Cells(m + 3, n + 1).Interior.Color = "16753236" Cells(m + 3, n + 1).Font.Size = "12" Cells(m + 3, n + 1).Font.name = "Calibri" Cells(m + 4, n - 1).Value = 1 Cells(m1 + 1, n1 + 1).Value = "a" Call AddNewVector end if ' vector ends If m = m1 + 54 Then ' vector 2 Cells(m + 3, n + -1).FormulaR1C1 ="=R[-9]C+1" Cells(m + 3, n + 0).FormulaR1C1 ="a" Cells(m + 3, n + 4).FormulaR1C1 ="Speed __(m/s):" Cells(m + 3, n + 24).FormulaR1C1 ="THEORY" Cells(m + 4, n + -1).FormulaR1C1 ="1" Cells(m + 4, n + 0).FormulaR1C1 ="183" Cells(m + 4, n + 4).FormulaR1C1 ="|V| =" Cells(m + 4, n + 5).FormulaR1C1 ="=SQRT(R[-13]C[-6]^2+R[-13]C[-5]^2+R[-13]C[-4]^2)" Cells(m + 5, n + -1).FormulaR1C1 ="1" Cells(m + 5, n + 0).FormulaR1C1 ="80*1" Cells(m + 5, n + 1).FormulaR1C1 ="=R[-14]C[4]" Cells(m + 5, n + 4).FormulaR1C1 ="Lorentz force (N):" Cells(m + 5, n + 21).FormulaR1C1 ="The motion of a charged particle in a magnetic field can be studied by means of the " Cells(m + 6, n + 4).FormulaR1C1 =" F_x =" Cells(m + 6, n + 5).FormulaR1C1 ="=R[-34]C*R[3]C[-6]" Cells(m + 6, n + 21).FormulaR1C1 ="expression" Cells(m + 7, n + -1).FormulaR1C1 ="=R[-36]C" Cells(m + 7, n + 0).FormulaR1C1 ="=R[-36]C" Cells(m + 7, n + 1).FormulaR1C1 ="=R[-36]C" Cells(m + 7, n + 4).FormulaR1C1 =" F_y =" Cells(m + 7, n + 5).FormulaR1C1 ="=R[-35]C*R[2]C[-5]" Cells(m + 8, n + -1).FormulaR1C1 ="=IF(R[1]C=0,10000,(-R[-29]C[6]-SQRT(ABS(POWER(R[-29]C[6],2)-2*R[1]C*R[-33]C[6])))/R[1]C)" Cells(m + 8, n + 0).FormulaR1C1 ="=IF(R[1]C=0,10000,(-R[-28]C[5]-SQRT(ABS(POWER(R[-28]C[5],2)-2*R[1]C*R[-32]C[5])))/R[1]C)" Cells(m + 8, n + 1).FormulaR1C1 ="=IF(R[1]C=0,100000,(-R[-27]C[4]-SQRT(ABS(POWER(R[-27]C[4],2)-2*R[1]C*R[-31]C[4])))/R[1]C)" Cells(m + 8, n + 2).FormulaR1C1 ="=IF(R[-58]C[-1]>1,"" <-- Variable coordinates"","""")" Cells(m + 8, n + 4).FormulaR1C1 =" F_z =" Cells(m + 8, n + 5).FormulaR1C1 ="=R[-36]C*R[1]C[-4]" Cells(m + 8, n + 27).FormulaR1C1 ="(Eq-35-1)" Cells(m + 9, n + -1).FormulaR1C1 ="=IF(R[-27]C[6]=R[-47]C[4]/R[-52]C[4],0,2*R[5]C[4]*R[10]C[4]/(R[-54]C^2+R[-54]C[1]^2)*(R[-54]C*R[-54]C[2]*SIN(R[10]C[4]*R[-61]C[8])-R[-54]C[1]*R[-52]C[4]*COS(R[10]C[4]*R[-61]C[8]))+2*R[6]C[4]*R[10]C[4]/(R[-54]C^2+R[-54]C[1]^2)*(-R[-54]C[1]*R[-52]C[4]*SIN(R[10]C[4]*R[-61]C[8])-R[-54]C*R[-54]C[2]*COS(R[10]C[4]*R[-61]C[8]))+R[-39]C[6]*R[-50]C[6]/R[-37]C[6])" Cells(m + 9, n + 0).FormulaR1C1 ="=IF(R[-27]C[5]=R[-47]C[3]/R[-52]C[3],0,2*R[5]C[3]*R[10]C[3]/(R[-54]C[-1]^2+R[-54]C^2)*(R[-54]C*R[-54]C[1]*SIN(R[10]C[3]*R[-61]C[7])+R[-54]C[-1]*R[-52]C[3]*COS(R[10]C[3]*R[-61]C[7]))+2*R[6]C[3]*R[10]C[3]/(R[-54]C[-1]^2+R[-54]C^2)*(R[-54]C[-1]*R[-52]C[3]*SIN(R[10]C[3]*R[-61]C[7])-R[-54]C*R[-54]C[1]*COS(R[10]C[3]*R[-61]C[7]))+R[-39]C[5]*R[-49]C[5]/R[-37]C[5])" Cells(m + 9, n + 1).FormulaR1C1 ="=IF(R[-27]C[4]=R[-47]C[2]/R[-52]C[2],0,-2*R[5]C[2]*R[10]C[2]*SIN(R[10]C[2]*R[-61]C[6])+2*R[6]C[2]*R[10]C[2]*COS(R[10]C[2]*R[-61]C[6])+R[-39]C[4]*R[-48]C[4]/R[-37]C[4])" Cells(m + 9, n + 2).FormulaR1C1 ="=IF(R[-59]C[-1]>1,"" <-- Field formulae"","""")" Cells(m + 9, n + 4).FormulaR1C1 =" |F| =" Cells(m + 9, n + 5).FormulaR1C1 ="=SQRT(R[-3]C^2+R[-2]C^2+R[1]C^2)" Cells(m + 10, n + -1).FormulaR1C1 ="1" Cells(m + 10, n + 0).FormulaR1C1 ="0" Cells(m + 10, n + 1).FormulaR1C1 ="1" Cells(m + 10, n + 2).FormulaR1C1 ="||||||||||||||||||||||||||||||||||||||||||||||" Cells(m + 10, n + 21).FormulaR1C1 ="where F is the magnetic force experienced by the particle with charge q, v is its speed and " Cells(m + 11, n + -1).FormulaR1C1 ="3" Cells(m + 11, n + 0).FormulaR1C1 ="0" Cells(m + 11, n + 1).FormulaR1C1 ="1" Cells(m + 11, n + 21).FormulaR1C1 ="B the magnetic field. Due to this expression, in a constant magnetic field the particle that " Cells(m + 3, n + 1).Interior.Color = "49407" Cells(m + 3, n + 1).Font.Size = "11" Cells(m + 3, n + 1).Font.name = "Calibri" Cells(m + 4, n - 1).Value = 1 Cells(m1 + 1, n1 + 1).Value = "D" Call AddNewVector end if ' vector ends If m = m1 + 63 Then ' vector 1 Cells(m + 3, n + -1).FormulaR1C1 ="=R[-9]C+1" Cells(m + 3, n + 0).FormulaR1C1 ="D" Cells(m + 3, n + 2).FormulaR1C1 ="CONSTANTS:" Cells(m + 3, n + 21).FormulaR1C1 ="enters perpendicular to the field describes a circular trajectory whose radius can be calculated " Cells(m + 4, n + -1).FormulaR1C1 ="1" Cells(m + 4, n + 0).FormulaR1C1 ="183" Cells(m + 4, n + 2).FormulaR1C1 ="C1" Cells(m + 4, n + 3).FormulaR1C1 ="=(R[-58]C[-4]*R[-58]C[-2]*R[-34]C[2]+R[-58]C[-3]*R[-58]C[-2]*R[-33]C[2]+R[-58]C[-2]^2*R[-32]C[2])/R[-56]C^2" Cells(m + 4, n + 21).FormulaR1C1 ="by referring to the equality of the magnetic (centripetal) force and the centrifugal mechanical force, " Cells(m + 5, n + -1).FormulaR1C1 ="1" Cells(m + 5, n + 0).FormulaR1C1 ="4" Cells(m + 5, n + 1).FormulaR1C1 ="=R[-27]C[4]" Cells(m + 5, n + 2).FormulaR1C1 ="C2" Cells(m + 5, n + 3).FormulaR1C1 ="=(-R[-59]C[-4]*R[-59]C[-2]*R[-35]C[2]-R[-59]C[-3]*R[-59]C[-2]*R[-34]C[2]+R[-59]C[-4]^2*R[-33]C[2]+R[-59]C[-3]^2*R[-33]C[2])/(2*R[-57]C^2)" Cells(m + 5, n + 21).FormulaR1C1 ="the latter given by:" Cells(m + 6, n + -1).FormulaR1C1 ="Initial position" Cells(m + 6, n + 0).FormulaR1C1 ="Aoy" Cells(m + 6, n + 1).FormulaR1C1 ="Aoz" Cells(m + 6, n + 2).FormulaR1C1 ="C3" Cells(m + 6, n + 3).FormulaR1C1 ="=(R[-60]C[-3]*R[-36]C[2]-R[-60]C[-4]*R[-35]C[2])/(2*R[-58]C)" Cells(m + 7, n + -1).FormulaR1C1 ="=R[-41]C[6]" Cells(m + 7, n + 0).FormulaR1C1 ="=R[-40]C[5]" Cells(m + 7, n + 1).FormulaR1C1 ="=R[-39]C[4]" Cells(m + 7, n + 2).FormulaR1C1 ="C4" Cells(m + 7, n + 3).FormulaR1C1 ="=-(2*R[-2]C*R[-61]C[-3]*R[-59]C+2*R[-1]C*R[-61]C[-4]*R[-61]C[-2])/(R[3]C*(R[-61]C[-4]^2+R[-61]C[-3]^2))" Cells(m + 7, n + 27).FormulaR1C1 ="(Eq-35-2)" Cells(m + 8, n + 2).FormulaR1C1 ="C5" Cells(m + 8, n + 3).FormulaR1C1 ="=(2*R[-3]C*R[-62]C[-4]*R[-60]C-2*R[-2]C*R[-62]C[-3]*R[-62]C[-2])/(R[2]C*(R[-62]C[-4]^2+R[-62]C[-3]^2))" Cells(m + 9, n + -1).FormulaR1C1 ="=IF(R[-36]C[6]=R[-56]C[4]/R[-61]C[4],R[-36]C*R[-70]C[8],R[-5]C[4]*R[-63]C/R[-63]C[2]*R[-70]C[8]-2*R[-4]C[4]*(R[-63]C*R[-63]C[2]*SIN(R[1]C[4]*R[-70]C[8])-R[-63]C[1]*R[-61]C[4]*COS(R[1]C[4]*R[-70]C[8]))/(R[1]C[4]*(R[-63]C^2+R[-63]C[1]^2))+2*R[-3]C[4]*(R[-63]C[1]*R[-61]C[4]*SIN(R[1]C[4]*R[-70]C[8])+R[-63]C*R[-63]C[2]*COS(R[1]C[4]*R[-70]C[8]))/(R[1]C[4]*(R[-63]C^2+R[-63]C[1]^2))+R[-48]C[6]*R[-54]C/R[-46]C[6]*R[-70]C[8]^2+R[-2]C[4])" Cells(m + 9, n + 0).FormulaR1C1 ="=IF(R[-36]C[5]=R[-56]C[3]/R[-61]C[3],R[-36]C*R[-70]C[7],R[-5]C[3]*R[-63]C/R[-63]C[1]*R[-70]C[7]+2*R[-4]C[3]*(-R[-63]C*R[-63]C[1]*SIN(R[1]C[3]*R[-70]C[7])-R[-63]C[-1]*R[-61]C[3]*COS(R[1]C[3]*R[-70]C[7]))/(R[1]C[3]*(R[-63]C[-1]^2+R[-63]C^2))+2*R[-3]C[3]*(-R[-63]C[-1]*R[-61]C[3]*SIN(R[1]C[3]*R[-70]C[7])+R[-63]C*R[-63]C[1]*COS(R[1]C[3]*R[-70]C[7]))/(R[1]C[3]*(R[-63]C[-1]^2+R[-63]C^2))+R[-48]C[5]*R[-54]C/R[-46]C[5]*R[-70]C[7]^2+R[-1]C[3])" Cells(m + 9, n + 1).FormulaR1C1 ="=IF(R[-36]C[4]=R[-56]C[2]/R[-61]C[2],R[-36]C*R[-70]C[6],R[-5]C[2]*R[-70]C[6]+2*R[-4]C[2]/R[1]C[2]*SIN(R[1]C[2]*R[-70]C[6])-2*R[-3]C[2]/R[1]C[2]*COS(R[1]C[2]*R[-70]C[6])+R[-48]C[4]*R[-54]C/R[-46]C[4]*R[-70]C[6]^2+RC[2])" Cells(m + 9, n + 2).FormulaR1C1 ="C6" Cells(m + 9, n + 3).FormulaR1C1 ="=2*R[-3]C/R[1]C" Cells(m + 10, n + -1).FormulaR1C1 ="1" Cells(m + 10, n + 0).FormulaR1C1 ="0" Cells(m + 10, n + 1).FormulaR1C1 ="1" Cells(m + 10, n + 2).FormulaR1C1 ="qB/m" Cells(m + 10, n + 3).FormulaR1C1 ="=R[-49]C[2]*R[-62]C/R[-47]C[2]" Cells(m + 10, n + 21).FormulaR1C1 ="Then, the expression for the radius becomes:" Cells(m + 11, n + -1).FormulaR1C1 ="8" Cells(m + 11, n + 0).FormulaR1C1 ="0" Cells(m + 11, n + 1).FormulaR1C1 ="1" Cells(m + 11, n + 2).FormulaR1C1 ="%%%%%%%%%%%%%%%%%%%%%%%%%%%%%" Cells(m + 3, n + 1).Interior.Color = "16711680" Cells(m + 3, n + 1).Font.Size = "11" Cells(m + 3, n + 1).Font.name = "Calibri" Cells(m + 4, n - 1).Value = 1 Cells(m1 + 1, n1 + 1).Value = "" Cells(m1 + 2, n1 - 1).Value = 8 end if ' vector ends If m = m1 + 63 Then Cells(m + 13, n + 27).FormulaR1C1 ="(Eq-35-3)" Cells(m + 16, n + 21).FormulaR1C1 ="When the particle moves under the simultaneous influence of a constant magnetic " Cells(m + 17, n + 21).FormulaR1C1 ="field and an electric field, the expression commonly called the Lorentz force is used:" Cells(m + 20, n + 27).FormulaR1C1 ="(Eq-35-4)" Cells(m + 23, n + 21).FormulaR1C1 ="The particle follows a straight line when the magnetic and electric forces are equal. " Cells(m + 24, n + 21).FormulaR1C1 ="A particular case is achieved for example when the magnetic field is directed in the negative " Cells(m + 25, n + 21).FormulaR1C1 ="direction of the x axis, the electric field in the negative direction of the z axis and the velocity of " Cells(m + 26, n + 21).FormulaR1C1 ="the particle has only a component in the y direction. In this case, the expression for the velocity " Cells(m + 27, n + 21).FormulaR1C1 ="(when the magnetic and electric forces cancel each other out) is:" Cells(m + 30, n + 27).FormulaR1C1 ="(Eq-35-5)" Cells(m + 32, n + 21).FormulaR1C1 ="For example, to get a constant speed (speed selector) set Ez = G18 = -3000, Bx = G11 = -0.05 " Cells(m + 33, n + 21).FormulaR1C1 ="and Voy = G37 = G18/G11 and press K5." Cells(m + 35, n + 21).FormulaR1C1 ="USING THE MODEL" Cells(m + 37, n + 21).FormulaR1C1 ="To use the model, modify the initial conditions in column G starting from row 10 for the " Cells(m + 38, n + 21).FormulaR1C1 ="electric field, magnetic field, initial velocity, charge, and mass of the particle as desired. " Cells(m + 39, n + 21).FormulaR1C1 ="Use the button at A24 (left) and then the K5 button to view the particle's trajectory. " Cells(m + 40, n + 21).FormulaR1C1 ="Press K5 several times for a longer path or modify the number of steps in cell I4. Use the +OBJ " Cells(m + 41, n + 21).FormulaR1C1 ="button to add more particles and -OBJ to remove them. Try to achieve different trajectories, " Cells(m + 42, n + 21).FormulaR1C1 ="such as circles, spirals, deformed spirals, by modifying the field components." Cells(m + 45, n + 21).FormulaR1C1 ="___________________________________________________________________________________" Cells(m + 46, n + 21).FormulaR1C1 ="Note: The model was built from the differential equation Eq-35-4, from which the expressions " Cells(m + 47, n + 21).FormulaR1C1 ="for the coordinates, velocities and acceleration were found. From there appear the constants " Cells(m + 48, n + 21).FormulaR1C1 ="found in cells D70-D75. These expressions are too extensive to explain in this model, however, " Cells(m + 49, n + 21).FormulaR1C1 ="if the reader wishes, the detailed analysis can be found in the books related to ScienSolar." Call BlackWhiteDesk Call PutEqBut end if ' actualizar hoja End Sub