add character cells arrays
1 Ansicht (letzte 30 Tage)
Ältere Kommentare anzeigen
we have a character cell [d d d d] and [d -d d -d]. how can we get [d+d d-d d+d d-d].
0 Kommentare
Antworten (1)
Walter Roberson
am 23 Nov. 2016
first = {'d', 'd', 'd', 'd'};
second = {'d', '-d', 'd', '-d'};
result = regexprep(strcat(first(:), {'+'}, second(:)), '+-', '-').' ;
0 Kommentare
Siehe auch
Kategorien
Mehr zu Get Started with MATLAB 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!