function L = logical(D)
%LOGICAL Convert numeric values of codistributed array to logical
%   L = LOGICAL(X)
%   
%   Example:
%   spmd
%       N = 1000;
%       Du = codistributed.ones(N,'uint8');
%       Dl = logical(Du)
%       classDu = underlyingType(Du)
%       classDl = underlyingType(Dl)
%   end
%   
%   converts the N-by-N uint8 codistributed array Du to the
%   logical codistributed array Dl.
%   classDu is 'uint8' while classDl is 'logical'.
%   
%   See also LOGICAL, CODISTRIBUTED, CODISTRIBUTED/ONES.


%   Copyright 2006-2020 The MathWorks, Inc.

L = codistributed.pElementwiseUnaryOpWithCatch(@logical,D);
