Please help, how do I use the 'for' command in this situation?

I know how to subplot, but how do I not overwite a function values while using for command?
In the end my function is a 1x1 matrix but i want a vector.

Antworten (1)

Rik
Rik am 4 Mai 2020
Use logical indexing:
V=zeros(size(x));
M=zeros(size(x));
L= 12<=x & x<=20;
V(L)= ____%replace x with x(L)
%etc

Diese Frage ist geschlossen.

Produkte

Version

R2020a

Gefragt:

am 4 Mai 2020

Geschlossen:

am 20 Aug. 2021

Community Treasure Hunt

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

Start Hunting!

Translated by