Topic: New container type for representing rectangular data fields


Author: Ahmed Han <ahmedhan@gmail.com>
Date: Tue, 14 Jul 2015 05:39:25 -0700 (PDT)
Raw View
------=_Part_43_657874269.1436877565367
Content-Type: multipart/alternative;
 boundary="----=_Part_44_1388270237.1436877565367"

------=_Part_44_1388270237.1436877565367
Content-Type: text/plain; charset=UTF-8

Rectangular data grids are vastly used in computer programming. Examples
are matrices, scientific calculations, games, algorithms. Mostly preferred
solutions for representing this kind of data are:

   - Multidimensional arrays (data[][])
   Not safe.

   - Nested STL containers (std::vector<std::vector<T>>)
   Not efficient.

   - External libraries (e.g.; boost::multi_array)
   Requires external libraries.

   - One dimensional containers (e.g.; data[ROW_SIZE * j + i])
   Confusing. Gets more confusing at higher dimensions.


I think STL should provide a standard container library for this need. It
shouldn't be limited to 2D usage, but should also support higher
dimensional matrices if it wouldn't increase complexity of the code.

--

---
You received this message because you are subscribed to the Google Groups "ISO C++ Standard - Future Proposals" group.
To unsubscribe from this group and stop receiving emails from it, send an email to std-proposals+unsubscribe@isocpp.org.
To post to this group, send email to std-proposals@isocpp.org.
Visit this group at http://groups.google.com/a/isocpp.org/group/std-proposals/.

------=_Part_44_1388270237.1436877565367
Content-Type: text/html; charset=UTF-8
Content-Transfer-Encoding: quoted-printable

<div dir=3D"ltr">Rectangular data grids are vastly used in computer program=
ming. Examples are matrices, scientific calculations, games, algorithms. Mo=
stly preferred solutions for representing this kind of data are:<br><ul><li=
>Multidimensional arrays (<span style=3D"font-family: courier new,monospace=
;">data[][]</span>)<br>Not safe.<br><br></li><li>Nested STL containers (<sp=
an style=3D"font-family: courier new,monospace;">std::vector&lt;std::vector=
&lt;T&gt;&gt;</span>)<br>Not efficient.<br><br></li><li>External libraries =
(e.g.; <span style=3D"font-family: courier new,monospace;">boost::multi_arr=
ay</span>)<br>Requires external libraries.<br><br></li><li>One dimensional =
containers (e.g.; <span style=3D"font-family: courier new,monospace;">data[=
ROW_SIZE * j + i]</span>)<br>Confusing. Gets more confusing at higher dimen=
sions.<br></li></ul><br>I think STL should provide a standard container lib=
rary for this need. It shouldn&#39;t be limited to 2D usage, but should als=
o support higher dimensional matrices if it wouldn&#39;t increase complexit=
y of the code.<br></div>

<p></p>

-- <br />
<br />
--- <br />
You received this message because you are subscribed to the Google Groups &=
quot;ISO C++ Standard - Future Proposals&quot; group.<br />
To unsubscribe from this group and stop receiving emails from it, send an e=
mail to <a href=3D"mailto:std-proposals+unsubscribe@isocpp.org">std-proposa=
ls+unsubscribe@isocpp.org</a>.<br />
To post to this group, send email to <a href=3D"mailto:std-proposals@isocpp=
..org">std-proposals@isocpp.org</a>.<br />
Visit this group at <a href=3D"http://groups.google.com/a/isocpp.org/group/=
std-proposals/">http://groups.google.com/a/isocpp.org/group/std-proposals/<=
/a>.<br />

------=_Part_44_1388270237.1436877565367--
------=_Part_43_657874269.1436877565367--

.