Effacer les filtres
Effacer les filtres

Info

Cette question est clôturée. Rouvrir pour modifier ou répondre.

In regards to connecting points

2 vues (au cours des 30 derniers jours)
Harold
Harold le 3 Mar 2011
Clôturé : MATLAB Answer Bot le 20 Août 2021
After discussing the project more with my professor, I have learned that I did this wrong. What I was suppose to do was this:
Calculate the Mach number at each of the three altitudes for mdotfuel=.1, .2, .3, .4, .5, .6, .7 Note: In this code I change mdotfuel to mdotf The flight Mach number is M_0.
In case you forgot what I'm plotting it is Thrust vs. M_0 for 7 different mdotf values. I need to do this at 3 different altitudes.
I wrote the code to do just this. But again, I'm stuck at plotting out the three plots. I've tried using your code that you supplied to me on the first question but for some reason it doesn't work when I attempt to implement it in this new code. I thought I knew how your code worked but I was wrong when I tried to make adjustments. Could you explain to me how this works.
Note: The updated code now grabs data from an excel sheet because if I happen to make a change in the excel sheet, I won't have to change all the values that I'm using. You won't have to do anything with the Excel file. You can download zip file with the .m file and excel sheet at the link below. Thanks again for all the help you've given. I would really like to learn the 3 dimensional matrix tool.
Harold
  2 commentaires
Walter Roberson
Walter Roberson le 3 Mar 2011
The reference to "you" appears to be to Matt's solution in http://www.mathworks.com/matlabcentral/answers/2118-connecting-points-in-a-scatter-plot
Harold
Harold le 3 Mar 2011
Could you explain what you mean?

Réponses (1)

Walter Roberson
Walter Roberson le 3 Mar 2011
Your code does not contain any plot attempts, not even commented out. Please indicate what you want to plot against what.
You calculate a number of values within the double-nested loop, but you do not save any of the values in to an array. When you think of plotting, you should almost always be saving values in to an array to plot a line at a time (or to plot everything at the end.)
  1 commentaire
Harold
Harold le 3 Mar 2011
The reason why I don't have any plot attempts is because I deleted the code for it because it did not work. The code that I had was the following:
plot(M_0,Thrust)
hold on
How would I go about saving the arrays? According to the loop, I have 24 arrays...8 loops for mdotf X 3 loops of alt. I'm not entirely sure on were the saving should be put within the code.

Cette question est clôturée.

Tags

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by