How to compute the coset C of A w.r. to I ( where I is the union of C and A)

1 visualizzazione (ultimi 30 giorni)
Hello, does somebody know a function which gives me the Coset C of A(subset I), such that I is the union of C and A (as set)
e.g., input I=[1,2,3,4,5] , A = [1,2,4]
output C=[3,5]

Risposta accettata

James Tursa
James Tursa il 6 Ott 2016
Is this what you want?
C = I(~ismember(I,A));

Più risposte (1)

Steven Lord
Steven Lord il 6 Ott 2016
I think you want the setdiff of the two vectors.

Categorie

Scopri di più su Structures in Help Center e File Exchange

Community Treasure Hunt

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

Start Hunting!

Translated by