Plotting a function with a range of values
10 Ansichten (letzte 30 Tage)
Ältere Kommentare anzeigen
I have coded a function, f(x). For any input, x, my function works correctly. However, when I try to insert a range of x (i.e. x = -10:10), the function doesn't work. There is no error. The output values are just incorrect. Has anyone had this happen to them? Any suggestions on how to fix this issue?
Akzeptierte Antwort
KSSV
am 3 Okt. 2018
I assume...you need to include the element by element operations of MATLAB. Like .* and .^. When you have array, you need to follow up the element by element operations. Read more here: https://in.mathworks.com/help/fixedpoint/ref/times.html
If the error is not due to above reasons. YOu need to show us the code.
3 Kommentare
Weitere Antworten (0)
Siehe auch
Kategorien
Mehr zu Logical finden Sie in Help Center und File Exchange
Produkte
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!