'unexpected matlab expression'

In summary, the conversation discusses an issue with running a MATLAB program on a different computer, resulting in an 'unexpected MATLAB expression' error message. Additional information is requested, such as the specific line of code causing the error. It is suggested to seek help from the MATLAB community forum for more appropriate assistance.
  • #1
arashna
3
0
I write MATLAB program on my computer but when I copy the file to another computer and press F5 to run, there is a message 'unexpected MATLAB expression'
what should I do?
 
Physics news on Phys.org
  • #2
please, give more information: for example, what is the line of your code that generates the error?BTW, consider that someone in this forum might argue that such a question could be more appropriately posted to the Matlab community forum, since not necessarily all the users in physicsforums use Matlab.

Also, I suspect your problem is not related to a general mathematics discussion, but to some specific MATLAB settings.
I can try to help you anyways.
 
Last edited:

1. What does "unexpected matlab expression" mean?

When this error is displayed in Matlab, it means that the program encountered an unexpected command or symbol. This could be due to a typo, missing parenthesis, or incorrect syntax.

2. How can I fix the "unexpected matlab expression" error?

To fix this error, you will need to carefully review your code and check for any typos or missing commands. Make sure all parentheses and brackets are properly closed and that the syntax is correct.

3. Why am I getting an "unexpected matlab expression" error?

This error can occur for a variety of reasons, such as using an undefined variable, using an incorrect function, or having a typo in your code. It is important to carefully review your code to identify the cause of the error.

4. Can I prevent the "unexpected matlab expression" error from occurring?

While it is not always possible to prevent this error from occurring, you can reduce the chances by being careful when writing your code and double checking for any mistakes. Using proper indentation and commenting your code can also help with identifying errors.

5. How can I troubleshoot the "unexpected matlab expression" error?

To troubleshoot this error, you can use the Matlab debugger to step through your code and identify where the unexpected expression occurs. You can also use the "disp" function to display the value of variables and track their values throughout your code.

Similar threads

  • MATLAB, Maple, Mathematica, LaTeX
Replies
4
Views
1K
  • MATLAB, Maple, Mathematica, LaTeX
Replies
1
Views
1K
  • MATLAB, Maple, Mathematica, LaTeX
Replies
6
Views
1K
  • MATLAB, Maple, Mathematica, LaTeX
Replies
10
Views
2K
  • MATLAB, Maple, Mathematica, LaTeX
Replies
2
Views
2K
  • MATLAB, Maple, Mathematica, LaTeX
Replies
5
Views
2K
  • MATLAB, Maple, Mathematica, LaTeX
Replies
2
Views
1K
  • MATLAB, Maple, Mathematica, LaTeX
Replies
32
Views
2K
  • MATLAB, Maple, Mathematica, LaTeX
Replies
5
Views
1K
  • MATLAB, Maple, Mathematica, LaTeX
Replies
2
Views
803
Back
Top