How to make a loop for an array of ands including cell arrays
1 Ansicht (letzte 30 Tage)
Ältere Kommentare anzeigen
Hossein
am 18 Aug. 2016
Kommentiert: Hossein
am 19 Aug. 2016
Hi
I want to make a loop for the following expression:
location1=find ( ...
equation{1}<1e-1 & ...
equation{2}<1e-1 & ...
equation{3}<1e-1);
each "equation {}" is a cell array and each cell includes a three dimensional matrix. I do not know how to and all of these equations in a loop way.
Thanks
2 Kommentare
James Tursa
am 18 Aug. 2016
Please provide more detail. Maybe a short example showing inputs and desired output.
Akzeptierte Antwort
Azzi Abdelmalek
am 18 Aug. 2016
%------Example--------------------
A=cell(1,5)
A=cellfun(@(x) rand(10,9,8),A,'un',0)
%--------------------------------------
idx=cellfun(@(x) find(x<0.01),A,'un',0) % Locations
Weitere Antworten (0)
Siehe auch
Kategorien
Mehr zu Elementary Math finden Sie in Help Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!