function s = underlyingType(obj)
%underlyingType Name of underlying data type determining dlarray behavior.
% S = underlyingType(OBJ)
%
%   Example:
%       N = 1000;
%       D = dlarray(ones(1, N, "single"));
%       underlyingType(D) % returns 'single'
%   
%   See also: isUnderlyingType, mustBeUnderlyingType, class, dlarray.

% Copyright 2020 The MathWorks, Inc.
 
s = underlyingType(gatherData(obj.FormattedData));
