why file name is coming on display window after running?

30 views (last 30 days)
T = 273;
I =(293-T)/T;
while I >= 0.6
R1 =1/(6.5965*10^(-9)*(T+293)*(T^2+293^2));
q =(197.4)/(2.3968+((1.0028*R1)/(1.0028+R1)));
T = T + 0.1;
disp(R1)
end
THIS IS MY CODE I DONT KNOW WHY I M GETTING THE
>> Untitled5
>> Untitled7
>> Untitled7
IN COMMAND WINDOW PLS HWLP ME OUT

Answers (2)

Star Strider
Star Strider on 11 Feb 2016
Those are likely the names of the scripts you are using to run your code. They are the Command History, and will appear if you run one of them and then hit the ‘Up Arrow’ key on your keyboard (or if you have ‘NumLock’ off and hit ‘8’ on your keypad), or run your script by clicking on the green right arrow in the Editor toolbar.
  4 Comments
Josiah David McClintic
Josiah David McClintic on 6 Mar 2022
But what to do when that occurs? I have been running my code from the Editor only to have the name of my file continue to appear in the Command Window.
Walter Roberson
Walter Roberson on 6 Mar 2022
The way that the green Run button works is that it sends the name of the file to the command window for execution. The green Run button itself does not directly start execution of the code: instead it pushes a command to the command line that tells the command line to execute the code, since executing code is what the command line is designed for. And the way to run a file in MATLAB is by invoking its file name
There is no way to configure the green Run button to not put the name of the file into the command window (as the command to be executed.)

Sign in to comment.


Boluwatife Ekundayo
Boluwatife Ekundayo on 3 Feb 2024
Edited: Boluwatife Ekundayo on 3 Feb 2024
Adding semicolon at the end of a line of code tells the command line not to display the results. From your code it looks like you want the result of R1 to be displayed, so you could try removing the semicolon after the line of code for R1.
  1 Comment
Walter Roberson
Walter Roberson on 3 Feb 2024
No, the question was about why the file name is appearing in the command window.
The answer is that the user is using the green Run button, and the way that the Run button works is that it sends the file name to the command line to be executed, so the file name appearing is inherent in using the Run button.

Sign in to comment.

Categories

Find more on Desktop in Help Center and File Exchange

Tags

Community Treasure Hunt

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

Start Hunting!