Assigning equation output to second row of a matrix
    5 visualizaciones (últimos 30 días)
  
       Mostrar comentarios más antiguos
    
    Martin
 el 21 de Mzo. de 2023
  
    
    
    
    
    Respondida: Steven Lord
    
      
 el 21 de Mzo. de 2023
            I have a 3x1 Matrix containing 3 values for my velocity and I'm trying to divide these 3 values by 5 different values for thrust. To create 1 matrix that is 3x5 with each row equaling my velocity1/thrust1, velocity1/thrust2. The next row would equal velocity2/thrust1, velocity2/thrust2. etc. Ultimately I 'm trying to plot the results in each row on the same plot. If there is a better way of doing this please let me know. I have attached a picture to help explain. Thank you in advance
Edit: for the graph I'm plotting the row on the y axis and the thrust on the x axis

0 comentarios
Respuesta aceptada
  Steven Lord
    
      
 el 21 de Mzo. de 2023
        Implicit expansion.
velocity = (1:3).'; % column vector
thrust = 10:14; % row vector
A = velocity./thrust % Dividing results in a matrix
If you prefer seeing them in rational form:
format rat
A
0 comentarios
Más respuestas (0)
Ver también
Categorías
				Más información sobre 2-D and 3-D Plots en Help Center y File Exchange.
			
	Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!

