From: "Nasser M. Abbasi" <nma@12000.org>
Subject: Re: Arrays in Ada 2020
Date: Sat, 17 Jun 2017 22:00:10 -0500
Date: 2017-06-17T22:00:10-05:00 [thread overview]
Message-ID: <oi4qbt$evo$1@gioia.aioe.org> (raw)
In-Reply-To: oi4nk5$4m3$1@dont-email.me
On 6/17/2017 9:14 PM, Ivan Levashev wrote:
> Hello!
>
> FYI Ada 2020 is about to bring some improvements:
>
> http://www.ada-auth.org/standards/2xrm/html/RM-4-3-3.html
>
>> G : constant Matrix :=
>> (for I in 1 .. 4 =>
>> (for J in 1 .. 4 =>
>> (if I = J then 1.0 else 0.0))); -- Identity matrix
>
> Best Regards,
> Ivan Levashev,
> Barnaul
That is nice. But still too much code for such common operation.
In Matlab the same can be done using just
eye(4) % Identity matrix
For other languages
https://rosettacode.org/wiki/Identity_matrix
--Nasser
next prev parent reply other threads:[~2017-06-18 3:00 UTC|newest]
Thread overview: 23+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-06-06 11:47 Arrays in Ada 2012 Anatoly Chernyshev
2017-06-06 12:17 ` Dmitry A. Kazakov
2017-06-06 13:17 ` Simon Wright
2017-06-06 13:57 ` Dmitry A. Kazakov
2017-06-06 21:59 ` Simon Wright
2017-06-06 13:19 ` AdaMagica
2017-06-06 20:56 ` Randy Brukardt
2017-06-07 7:06 ` Dmitry A. Kazakov
2017-06-07 11:47 ` Anatoly Chernyshev
2017-06-07 12:15 ` Dmitry A. Kazakov
2017-06-08 0:55 ` Randy Brukardt
2017-06-08 0:51 ` Randy Brukardt
2017-06-08 7:07 ` Dmitry A. Kazakov
2017-06-09 3:23 ` Randy Brukardt
2017-06-18 2:14 ` Arrays in Ada 2020 Ivan Levashev
2017-06-18 3:00 ` Nasser M. Abbasi [this message]
2017-06-18 12:06 ` Robert Eachus
2017-06-18 20:15 ` Simon Wright
2017-06-20 13:33 ` Robert Eachus
2017-06-19 6:36 ` Ivan Levashev
2017-06-19 12:06 ` AdaMagica
2017-06-23 1:17 ` Randy Brukardt
2017-06-18 20:15 ` Pascal Obry
replies disabled
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox