Solved
Multiple Definitions Error
- October 24, 2023
- 2 replies
- 1451 views
Hello,
I am trying to run this code and plot only "U" for the augmented matrix "R". However I am getting an error R has multiple definitions.
Please help!
Thanks
You never defined a variable R (its just a local(!) variable inside of your program). So Prime does not know if you mean the predefined unit R or the predefined constant R - hence the error message.

You defined a function which would have to be called to be evaluated. But as I think you just intended to create a vector R, you should assign the program to that variable.
Furthermore you were missing some multiplications and a pair of parenthesis (otherwise you run into a unit mismatch in the calculation of C).
Its not necessary to redefine e and also omega.n was already defined above.

The start and end value of your for-loop are wrong and off by 1.
But you now run into a unit mismatch in the definition of U. You can't add quantities with different dimensions!
You will have to check your formulas!

Enter your E-mail address. We'll send you an e-mail with instructions to reset your password.