[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Octave-bug-tracker] [bug #63962] perms - Performance - Usage of native
From: |
Hendrik K |
Subject: |
[Octave-bug-tracker] [bug #63962] perms - Performance - Usage of native C++ algorithm helpful |
Date: |
Mon, 27 Mar 2023 05:43:05 -0400 (EDT) |
Follow-up Comment #5, bug #63962 (project octave):
Everything what can be done in Octave can be relatively easily be done in OCT
C++, so yes it can be done and yes I am happy to support.
Note that the problem is tough though, as Cells and structs can contain
anything including other cells and struct. Not even Octave can do a comparison
on these things. Example:
a = {0.1, "foo"};
b = {0.1, "foo", a};
b{1} == b{3}
error: binary operator '==' not implemented for 'scalar' by 'cell' operations
But if one limits the input to perms (or throws error messages) of cells which
contain only fundamental numerical data types and strings (using 'all' allows
comparing strings) it can be done.
I suggest an n:n comparison to detect the same values and create the index
vector, so no sort (which does not work). Some overhead will occur but the
number of items for perms must be small anyway....
Thoughts ?
_______________________________________________________
Reply to this item at:
<https://savannah.gnu.org/bugs/?63962>
_______________________________________________
Message sent via Savannah
https://savannah.gnu.org/
- [Octave-bug-tracker] [bug #63962] perms - Performance - Usage of native C++ algorithm helpful, Arun Giridhar, 2023/03/26
- [Octave-bug-tracker] [bug #63962] perms - Performance - Usage of native C++ algorithm helpful, Arun Giridhar, 2023/03/26
- [Octave-bug-tracker] [bug #63962] perms - Performance - Usage of native C++ algorithm helpful, Hendrik K, 2023/03/26
- [Octave-bug-tracker] [bug #63962] perms - Performance - Usage of native C++ algorithm helpful, Arun Giridhar, 2023/03/27
- [Octave-bug-tracker] [bug #63962] perms - Performance - Usage of native C++ algorithm helpful,
Hendrik K <=
- [Octave-bug-tracker] [bug #63962] perms - Performance - Usage of native C++ algorithm helpful, Arun Giridhar, 2023/03/27
- [Octave-bug-tracker] [bug #63962] perms - Performance - Usage of native C++ algorithm helpful, Hendrik K, 2023/03/27
- [Octave-bug-tracker] [bug #63962] perms - Performance - Usage of native C++ algorithm helpful, Hendrik K, 2023/03/27
- [Octave-bug-tracker] [bug #63962] perms - Performance - Usage of native C++ algorithm helpful, Nicholas Jankowski, 2023/03/27
- [Octave-bug-tracker] [bug #63962] perms - Performance - Usage of native C++ algorithm helpful, Nicholas Jankowski, 2023/03/27
- [Octave-bug-tracker] [bug #63962] perms - Performance - Usage of native C++ algorithm helpful, Nicholas Jankowski, 2023/03/27
- [Octave-bug-tracker] [bug #63962] perms - Performance - Usage of native C++ algorithm helpful, Arun Giridhar, 2023/03/27
- [Octave-bug-tracker] [bug #63962] perms - Performance - Usage of native C++ algorithm helpful, Arun Giridhar, 2023/03/27
- [Octave-bug-tracker] [bug #63962] perms - Performance - Usage of native C++ algorithm helpful, Nicholas Jankowski, 2023/03/27
- [Octave-bug-tracker] [bug #63962] perms - Performance - Usage of native C++ algorithm helpful, Arun Giridhar, 2023/03/27