Re: removing zeros from a vector



Jeremy Smith wrote:


What is the double tilde for in the following statement?

A = A(~~A)

~~ is the double negation

It's a matlab trick to get a logical vector with trues when A is not
zero. It is basically the same as
logical(A)

Jos
.



Relevant Pages

  • Re: eg
    ... A tilde should mean "approximate", ... > two character sets, they decided to map between those two vaguely ... of tilde as negation must go back further than this, ... Many introductory books still do use that horrible notation ...
    (comp.text.tex)
  • Re: eg
    ... Donald Arseneau wrote: ... of tilde as negation must go back further than this, and probably had something to do with what symbols were available on Bertrand Russell's typewriter or something. ...
    (comp.text.tex)
  • Re: reductio ad falsum versus reductio ad absurdum
    ... constructive reductio ADDS a tilde, ... DN (double negation). ... Prev by Date: ...
    (sci.logic)

Loading