Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix #533 find does not consider complex number correctly
- Loading branch information
1 parent
05140df
commit a2233c6
Showing
3 changed files
with
45 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
38 changes: 38 additions & 0 deletions
38
modules/elementary_functions/tests/bug_github_issue_#533.m
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
%============================================================================= | ||
% Copyright (c) 2017 Allan CORNET (Nelson) | ||
%============================================================================= | ||
% This file is part of the Nelson. | ||
%============================================================================= | ||
% LICENCE_BLOCK_BEGIN | ||
% This program is free software; you can redistribute it and/or | ||
% modify it under the terms of the GNU Lesser General Public | ||
% License as published by the Free Software Foundation; either | ||
% version 2.1 of the License, or (at your option) any later version. | ||
% | ||
% Alternatively, you can redistribute it and/or | ||
% modify it under the terms of the GNU General Public License as | ||
% published by the Free Software Foundation; either version 2 of | ||
% the License, or (at your option) any later version. | ||
% | ||
% This program is distributed in the hope that it will be useful, | ||
% but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
% MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
% GNU Lesser General Public License for more details. | ||
% | ||
% You should have received a copy of the GNU Lesser General Public | ||
% License along with this program. If not, see <http://www.gnu.org/licenses/>. | ||
% LICENCE_BLOCK_END | ||
%============================================================================= | ||
% <-- Issue URL --> | ||
% https://github.com/Nelson-numerical-software/nelson/issues/533 | ||
% <-- Short Description --> | ||
% find does not consider complex number correctly | ||
%============================================================================= | ||
R = find([1 i]); | ||
REF = [1 2]; | ||
assert_isequal(R, REF) | ||
%============================================================================= | ||
R = find(single([1 i])); | ||
REF = [1 2]; | ||
assert_isequal(R, REF) | ||
%============================================================================= |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters