
I have a problem what is demonstrated in the attached file.
Basically I have the following
create multi_array - a1
create a view on the multiarray which has the same number of dimensions
a1_view
a1 == a1_view fails to compile.
The attached example illustrates this. In the example I verify that
both a1 and a1_view fullfill the requirements for Multi Array. The
documentation
states that in order for a type to be a model of the Multi Array concept.
The
operations
a == b must be valid.
Actually the documentation could be considered ambiguous on this point. But
that is was I get from a plain reading of the document and from a common
sense
interpretation. If two types meeting the requirements of the Multi Array
concept
have the same number of dimensions, I expect to be able to compare them as
this is natural operation to perform and implement.
Robert Ramey
begin 666 test_misc.cpp
M(VEN8VQU9&4@(F)O;W-T+V-O;F-E<'1?8VAE8VLN:'!P(@T*(VEN8VQU9&4@
M(F)O;W-T+VUU;'1I7V%R

Hi Robert, You are correct that the documentation is ambiguous on this point. The MultiArray concept should explicitly state the restrictions on the relationship between both arrays involved in a comparison. However, the library should have been designed to allow comparisons between different models of MultiArray. I will see about updating the documentation and the implementation to reflect this. However, it won't appear until the release of Boost following the current release. Thanks for pointing this out. ron On Apr 21, 2006, at 2:57 PM, Robert Ramey wrote:
I have a problem what is demonstrated in the attached file.
Basically I have the following
create multi_array - a1 create a view on the multiarray which has the same number of dimensions a1_view a1 == a1_view fails to compile. The attached example illustrates this. In the example I verify that both a1 and a1_view fullfill the requirements for Multi Array. The documentation states that in order for a type to be a model of the Multi Array concept. The operations
a == b must be valid.
Actually the documentation could be considered ambiguous on this point. But that is was I get from a plain reading of the document and from a common sense interpretation. If two types meeting the requirements of the Multi Array concept have the same number of dimensions, I expect to be able to compare them as this is natural operation to perform and implement.

Ronald Garcia wrote:
Hi Robert,
You are correct that the documentation is ambiguous on this point. The MultiArray concept should explicitly state the restrictions on the relationship between both arrays involved in a comparison. However, the library should have been designed to allow comparisons between different models of MultiArray.
Now, that is the main issue. How difficult would it be to implement the functionality as templates in terms of the valid operations described in the concept? That is what is really needed. Robert Ramey
I will see about updating the documentation and the implementation to reflect this. However, it won't appear until the release of Boost following the current release.
Thanks for pointing this out.
ron
On Apr 21, 2006, at 2:57 PM, Robert Ramey wrote:
I have a problem what is demonstrated in the attached file.
Basically I have the following
create multi_array - a1 create a view on the multiarray which has the same number of dimensions a1_view a1 == a1_view fails to compile. The attached example illustrates this. In the example I verify that both a1 and a1_view fullfill the requirements for Multi Array. The documentation states that in order for a type to be a model of the Multi Array concept. The operations
a == b must be valid.
Actually the documentation could be considered ambiguous on this point. But that is was I get from a plain reading of the document and from a common sense interpretation. If two types meeting the requirements of the Multi Array concept have the same number of dimensions, I expect to be able to compare them as this is natural operation to perform and implement.

On Apr 26, 2006, at 11:09 AM, Robert Ramey wrote:
Ronald Garcia wrote:
Hi Robert,
You are correct that the documentation is ambiguous on this point. The MultiArray concept should explicitly state the restrictions on the relationship between both arrays involved in a comparison. However, the library should have been designed to allow comparisons between different models of MultiArray.
Now, that is the main issue. How difficult would it be to implement the functionality as templates in terms of the valid operations described in the concept? That is what is really needed.
Correct. I think that all-in-all it shouldn't bee too difficult, though I will likely need to make some changes to the MultiArray concept, specifically the addition of a traits class to establish models of MultiArray as well as dimensionality. From there, implementing the operations should not be difficult. Cheers, ron
participants (3)
-
Robert Ramey
-
Robert Ramey
-
Ronald Garcia