From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,FREEMAIL_FROM autolearn=ham autolearn_force=no version=3.4.4 X-Google-Thread: a07f3367d7,a83584e000bc28fa X-Google-Attributes: gida07f3367d7,public,usenet X-Google-NewGroupId: yes X-Google-Language: ENGLISH,ASCII-7-bit Received: by 10.68.232.200 with SMTP id tq8mr1959866pbc.7.1345441050964; Sun, 19 Aug 2012 22:37:30 -0700 (PDT) Path: p10ni110028759pbh.1!nntp.google.com!border1.nntp.dca.giganews.com!nntp.giganews.com!border6.newsrouter.astraweb.com!news.astraweb.com!border6.a.newsrouter.astraweb.com!feed.xsnews.nl!border-2.ams.xsnews.nl!plix.pl!newsfeed2.plix.pl!news.mi.ras.ru!goblin1!goblin2!goblin.stu.neva.ru!novso.com!nerim.net!usenet-fr.net!proxad.net!feeder1-2.proxad.net!74.125.178.16.MISMATCH!postnews.google.com!glegroupsg2000goo.googlegroups.com!not-for-mail From: Ada novice Newsgroups: comp.lang.ada Subject: Re: ada lapack Date: Thu, 16 Aug 2012 23:25:22 -0700 (PDT) Organization: http://groups.google.com Message-ID: <615dd222-9c8b-4878-94f7-b1cd4792bd3e@googlegroups.com> References: <12f929e9-eea3-4dc9-b10d-71e4f5732e0d@googlegroups.com> NNTP-Posting-Host: 130.240.232.139 Mime-Version: 1.0 X-Trace: posting.google.com 1345185065 32462 127.0.0.1 (17 Aug 2012 06:31:05 GMT) X-Complaints-To: groups-abuse@google.com NNTP-Posting-Date: Fri, 17 Aug 2012 06:31:05 +0000 (UTC) In-Reply-To: <12f929e9-eea3-4dc9-b10d-71e4f5732e0d@googlegroups.com> Complaints-To: groups-abuse@google.com Injection-Info: glegroupsg2000goo.googlegroups.com; posting-host=130.240.232.139; posting-account=Rr9I-QoAAACS-nOzpA-mGxtAlZ46Nb6I User-Agent: G2/1.0 Content-Type: text/plain; charset=ISO-8859-1 Date: 2012-08-16T23:25:22-07:00 List-Id: On Wednesday, August 15, 2012 7:16:48 AM UTC+1, Leo Brewin wrote: > Greetings, > > I've made available a small set of Ada routines that implement a subset of the Lapack routines. > Comments, opinions, suggestions etc. are most welcome. > Thanks for this VERY important and useful contribution. I got some error messages when running "make tests". The only change that I made in the Makefile was to put my path for gnatmake as: /usr/local/gnat-2012/bin/gnatmake I am putting below the outputs that I get with "make" and "make tests". I do get all solutions as expected though. Errors that I am getting with "make tests" are as /bin/sh: 3: example01: not found and this for each test file. Here are my complete outputs: (a) make $ make for file in ada_lapack ada_lapack-extras example01 example02 example03 example04 tdgeev tdgesv tdgetri tzgeev tzgesv tzgetri; do make ${file}; done; make[1]: Entering directory `/home/mint/work/ada/lapackport/ada_lapack' /usr/local/gnat-2012/bin/gnatmake -O3 -gnatwA -gnat2012 ada_lapack gcc -c -O3 -gnatwA -gnat2012 ada_lapack.adb ada_lapack.adb:9606:10: info: code between label and backwards goto rewritten as loop ada_lapack.adb:9632:10: info: code between label and backwards goto rewritten as loop ada_lapack.adb:31332:10: info: code between label and backwards goto rewritten as loop ada_lapack.adb:31358:10: info: code between label and backwards goto rewritten as loop make[1]: Leaving directory `/home/mint/work/ada/lapackport/ada_lapack' make[1]: Entering directory `/home/mint/work/ada/lapackport/ada_lapack' /usr/local/gnat-2012/bin/gnatmake -O3 -gnatwA -gnat2012 ada_lapack-extras gcc -c -O3 -gnatwA -gnat2012 ada_lapack-extras.adb make[1]: Leaving directory `/home/mint/work/ada/lapackport/ada_lapack' make[1]: Entering directory `/home/mint/work/ada/lapackport/ada_lapack' /usr/local/gnat-2012/bin/gnatmake -O3 -gnatwA -gnat2012 example01 gcc -c -O3 -gnatwA -gnat2012 example01.adb gnatbind -x example01.ali gnatlink example01.ali -O3 make[1]: Leaving directory `/home/mint/work/ada/lapackport/ada_lapack' make[1]: Entering directory `/home/mint/work/ada/lapackport/ada_lapack' /usr/local/gnat-2012/bin/gnatmake -O3 -gnatwA -gnat2012 example02 gcc -c -O3 -gnatwA -gnat2012 example02.adb gnatbind -x example02.ali gnatlink example02.ali -O3 make[1]: Leaving directory `/home/mint/work/ada/lapackport/ada_lapack' make[1]: Entering directory `/home/mint/work/ada/lapackport/ada_lapack' /usr/local/gnat-2012/bin/gnatmake -O3 -gnatwA -gnat2012 example03 gcc -c -O3 -gnatwA -gnat2012 example03.adb gnatbind -x example03.ali gnatlink example03.ali -O3 make[1]: Leaving directory `/home/mint/work/ada/lapackport/ada_lapack' make[1]: Entering directory `/home/mint/work/ada/lapackport/ada_lapack' /usr/local/gnat-2012/bin/gnatmake -O3 -gnatwA -gnat2012 example04 gcc -c -O3 -gnatwA -gnat2012 example04.adb gnatbind -x example04.ali gnatlink example04.ali -O3 make[1]: Leaving directory `/home/mint/work/ada/lapackport/ada_lapack' make[1]: Entering directory `/home/mint/work/ada/lapackport/ada_lapack' /usr/local/gnat-2012/bin/gnatmake -O3 -gnatwA -gnat2012 tdgeev gcc -c -O3 -gnatwA -gnat2012 tdgeev.adb gnatbind -x tdgeev.ali gnatlink tdgeev.ali -O3 make[1]: Leaving directory `/home/mint/work/ada/lapackport/ada_lapack' make[1]: Entering directory `/home/mint/work/ada/lapackport/ada_lapack' /usr/local/gnat-2012/bin/gnatmake -O3 -gnatwA -gnat2012 tdgesv gcc -c -O3 -gnatwA -gnat2012 tdgesv.adb gnatbind -x tdgesv.ali gnatlink tdgesv.ali -O3 make[1]: Leaving directory `/home/mint/work/ada/lapackport/ada_lapack' make[1]: Entering directory `/home/mint/work/ada/lapackport/ada_lapack' /usr/local/gnat-2012/bin/gnatmake -O3 -gnatwA -gnat2012 tdgetri gcc -c -O3 -gnatwA -gnat2012 tdgetri.adb gnatbind -x tdgetri.ali gnatlink tdgetri.ali -O3 make[1]: Leaving directory `/home/mint/work/ada/lapackport/ada_lapack' make[1]: Entering directory `/home/mint/work/ada/lapackport/ada_lapack' /usr/local/gnat-2012/bin/gnatmake -O3 -gnatwA -gnat2012 tzgeev gcc -c -O3 -gnatwA -gnat2012 tzgeev.adb gnatbind -x tzgeev.ali gnatlink tzgeev.ali -O3 make[1]: Leaving directory `/home/mint/work/ada/lapackport/ada_lapack' make[1]: Entering directory `/home/mint/work/ada/lapackport/ada_lapack' /usr/local/gnat-2012/bin/gnatmake -O3 -gnatwA -gnat2012 tzgesv gcc -c -O3 -gnatwA -gnat2012 tzgesv.adb gnatbind -x tzgesv.ali gnatlink tzgesv.ali -O3 make[1]: Leaving directory `/home/mint/work/ada/lapackport/ada_lapack' make[1]: Entering directory `/home/mint/work/ada/lapackport/ada_lapack' /usr/local/gnat-2012/bin/gnatmake -O3 -gnatwA -gnat2012 tzgetri gcc -c -O3 -gnatwA -gnat2012 tzgetri.adb gnatbind -x tzgetri.ali gnatlink tzgetri.ali -O3 make[1]: Leaving directory `/home/mint/work/ada/lapackport/ada_lapack' (b) make tests $ make tests Testing example01 /bin/sh: 3: example01: not found 0a1,2 > The eigenvaluess > ( -9.4299,-12.9833) ( -3.4418, 12.6897) ( 0.1055, -3.3950) ( 5.7562, 7.1286) Testing example02 /bin/sh: 3: example02: not found 0a1,8 > The eigenvalues > ( -9.4299,-12.9833) ( -3.4418, 12.6897) ( 0.1055, -3.3950) ( 5.7562, 7.1286) > > The right eigenvectors > ( 0.4309, 0.3268) ( 0.8257, 0.0000) ( 0.5984, 0.0000) ( -0.3054, 0.0333) > ( 0.5087, -0.0288) ( 0.0750, -0.2487) ( -0.4005, -0.2014) ( 0.0398, 0.3445) > ( 0.6198, 0.0000) ( -0.2458, 0.2789) ( -0.0901, -0.4753) ( 0.3583, 0.0606) > ( -0.2269, 0.1104) ( -0.1034, -0.3192) ( -0.4348, 0.1337) ( 0.8082, 0.0000) Testing example03 /bin/sh: 3: example03: not found 0a1,5 > Solution > ( -1.088, -0.183) ( 1.282, 1.205) > ( 0.966, 0.521) ( -0.222, -0.968) > ( -0.202, 0.187) ( 0.534, 1.358) > ( -0.586, 0.918) ( 2.222, -0.998) Testing example04 /bin/sh: 3: example04: not found 0a1,5 > Inverse > ( -0.113, -0.054) ( -0.086, 0.011) ( 0.127, 0.189) ( 0.155, -0.034) > ( 0.057, 0.057) ( 0.006, 0.013) ( -0.027, -0.098) ( -0.041, -0.034) > ( -0.059, -0.028) ( -0.093, 0.025) ( 0.042, 0.036) ( 0.014, 0.012) > ( -0.102, 0.067) ( 0.021, 0.126) ( 0.126, -0.095) ( 0.039, -0.114) Testing tdgeev /bin/sh: 3: tdgeev: not found 0a1,16 > The eigenvalues > ( 2.858, 10.763) ( 2.858,-10.763) ( -0.687, 4.704) ( -0.687, -4.704) -10.463 > > The left eigenvectors > ( 0.044, 0.288) ( 0.044, -0.288) ( -0.133, -0.327) ( -0.133, 0.327) 0.041 > ( 0.618, 0.000) ( 0.618, -0.000) ( 0.687, 0.000) ( 0.687, -0.000) 0.560 > ( -0.036, -0.577) ( -0.036, 0.577) ( -0.390, -0.075) ( -0.390, 0.075) -0.129 > ( 0.284, 0.011) ( 0.284, -0.011) ( -0.018, -0.187) ( -0.018, 0.187) -0.797 > ( -0.045, 0.341) ( -0.045, -0.341) ( -0.403, 0.218) ( -0.403, -0.218) 0.183 > > The right eigenvectors > ( 0.108, 0.169) ( 0.108, -0.169) ( 0.732, 0.000) ( 0.732, -0.000) 0.461 > ( 0.406, -0.259) ( 0.406, 0.259) ( -0.026, -0.017) ( -0.026, 0.017) 0.338 > ( 0.102, -0.509) ( 0.102, 0.509) ( 0.192, -0.293) ( 0.192, 0.293) 0.309 > ( 0.399, -0.091) ( 0.399, 0.091) ( -0.079, -0.078) ( -0.079, 0.078) -0.744 > ( 0.540, 0.000) ( 0.540, -0.000) ( -0.292, -0.493) ( -0.292, 0.493) 0.159 Testing tdgesv /bin/sh: 3: tdgesv: not found 0a1,32 > Solution > 4.020 -1.560 9.810 > 6.190 4.000 -4.090 > -8.220 -8.670 -4.570 > -7.570 1.750 -8.610 > -3.030 2.860 8.990 > > The LU factorization > 8.230 1.080 9.040 2.140 -6.870 > 0.826 -6.942 -7.919 6.552 -3.994 > 0.688 -0.665 -14.184 7.236 -5.191 > 0.725 0.752 0.023 -13.820 14.189 > -0.256 0.435 -0.588 -0.337 -3.429 > > The pivot indices > ( 5 5 3 4 5 ) > > The original matrix > 6.800 -6.050 -0.450 8.320 -9.670 > -2.110 -3.300 2.580 2.710 -5.140 > 5.660 5.360 -2.700 4.350 -7.260 > 5.970 -4.440 0.270 -7.170 6.080 > 8.230 1.080 9.040 2.140 -6.870 > > The reconstructed matrix > 6.800 -6.050 -0.450 8.320 -9.670 > -2.110 -3.300 2.580 2.710 -5.140 > 5.660 5.360 -2.700 4.350 -7.260 > 5.970 -4.440 0.270 -7.170 6.080 > 8.230 1.080 9.040 2.140 -6.870 > > The residual error : 2.1413E-18 Testing tdgetri /bin/sh: 3: tdgetri: not found 0a1,15 > The optimal value for LWORK is 320 > > Matrix > 6.800 -6.050 -0.450 8.320 -9.670 > -2.110 -3.300 2.580 2.710 -5.140 > 5.660 5.360 -2.700 4.350 -7.260 > 5.970 -4.440 0.270 -7.170 6.080 > 8.230 1.080 9.040 2.140 -6.870 > > Inverse > 0.048 -0.107 0.003 0.027 0.033 > -0.052 -0.062 0.045 -0.047 0.030 > -0.005 -0.046 -0.096 -0.052 0.096 > 0.146 -0.299 -0.172 -0.173 0.046 > 0.088 -0.292 -0.169 -0.098 0.040 Testing tzgeev /bin/sh: 3: tzgeev: not found 0a1,16 > The optimal value for LWORK is 132 > > The eigenvalues > ( -9.4299,-12.9833) ( -3.4418, 12.6897) ( 0.1055, -3.3950) ( 5.7562, 7.1286) > > The left eigenvectors > ( 0.2414, -0.1847) ( 0.6135, 0.0000) ( -0.1828, -0.3347) ( 0.2765, 0.0884) > ( 0.7861, 0.0000) ( -0.0499, -0.2721) ( 0.8218, 0.0000) ( -0.5477, 0.1572) > ( 0.2195, -0.2689) ( -0.2088, 0.5347) ( -0.3714, 0.1525) ( 0.4451, 0.0912) > ( -0.0170, 0.4109) ( 0.4027, -0.2353) ( 0.0575, 0.1208) ( 0.6202, 0.0000) > > The right eigenvectors > ( 0.4309, 0.3268) ( 0.8257, 0.0000) ( 0.5984, 0.0000) ( -0.3054, 0.0333) > ( 0.5087, -0.0288) ( 0.0750, -0.2487) ( -0.4005, -0.2014) ( 0.0398, 0.3445) > ( 0.6198, 0.0000) ( -0.2458, 0.2789) ( -0.0901, -0.4753) ( 0.3583, 0.0606) > ( -0.2269, 0.1104) ( -0.1034, -0.3192) ( -0.4348, 0.1337) ( 0.8082, 0.0000) Testing tzgesv /bin/sh: 3: tzgesv: not found 0a1,28 > Solution > ( 8.330, -7.320) ( -6.110, -3.810) > ( -6.180, -4.800) ( 0.140, -7.710) > ( -5.710, -2.800) ( 1.410, 3.400) > ( -1.600, 3.080) ( 8.540, -4.050) > > The LU factorization > ( -4.300, -7.100) ( -6.470, 2.520) ( -6.510, -2.670) ( -5.860, 7.380) > ( 0.490, 0.470) ( 12.265, -3.574) ( -7.865, -0.492) ( -0.980, 6.708) > ( 0.249, -0.151) ( -0.601, -0.370) (-11.699, -4.642) ( -1.353, 1.376) > ( -0.830, -0.324) ( 0.052, 0.579) ( 0.933, -0.499) ( 2.664, 7.857) > > The pivot indices > ( 3 3 3 4 ) > > The original matrix > ( 1.230, -5.500) ( 7.910, -5.380) ( -9.800, -4.860) ( -7.320, 7.570) > ( -2.140, -1.120) ( -9.920, -0.790) ( -9.180, -1.120) ( 1.370, 0.430) > ( -4.300, -7.100) ( -6.470, 2.520) ( -6.510, -2.670) ( -5.860, 7.380) > ( 1.270, 7.290) ( 8.900, 6.920) ( -8.820, 1.250) ( 5.410, 5.370) > > The reconstructed matrix > ( 1.230, -5.500) ( 7.910, -5.380) ( -9.800, -4.860) ( -7.320, 7.570) > ( -2.140, -1.120) ( -9.920, -0.790) ( -9.180, -1.120) ( 1.370, 0.430) > ( -4.300, -7.100) ( -6.470, 2.520) ( -6.510, -2.670) ( -5.860, 7.380) > ( 1.270, 7.290) ( 8.900, 6.920) ( -8.820, 1.250) ( 5.410, 5.370) > > The residual error : 3.9701E-18 Testing tzgetri /bin/sh: 3: tzgetri: not found 0a1,13 > The optimal value for LWORK is 256 > > Matrix > ( 1.230, -5.500) ( 7.910, -5.380) ( -9.800, -4.860) ( -7.320, 7.570) > ( -2.140, -1.120) ( -9.920, -0.790) ( -9.180, -1.120) ( 1.370, 0.430) > ( -4.300, -7.100) ( -6.470, 2.520) ( -6.510, -2.670) ( -5.860, 7.380) > ( 1.270, 7.290) ( 8.900, 6.920) ( -8.820, 1.250) ( 5.410, 5.370) > > Inverse > ( -0.113, -0.054) ( -0.086, 0.011) ( 0.127, 0.189) ( 0.155, -0.034) > ( 0.057, 0.057) ( 0.006, 0.013) ( -0.027, -0.098) ( -0.041, -0.034) > ( -0.059, -0.028) ( -0.093, 0.025) ( 0.042, 0.036) ( 0.014, 0.012) > ( -0.102, 0.067) ( 0.021, 0.126) ( 0.126, -0.095) ( 0.039, -0.114) make: *** [tests] Error 1 $ Do I need to fix something? Thanks. YC