0s autopkgtest [18:12:57]: starting date and time: 2025-03-15 18:12:57+0000 0s autopkgtest [18:12:57]: git checkout: 325255d2 Merge branch 'pin-any-arch' into 'ubuntu/production' 0s autopkgtest [18:12:57]: host juju-7f2275-prod-proposed-migration-environment-20; command line: /home/ubuntu/autopkgtest/runner/autopkgtest --output-dir /tmp/autopkgtest-work.qclnls4w/out --timeout-copy=6000 --setup-commands /home/ubuntu/autopkgtest-cloud/worker-config-production/setup-canonical.sh --apt-pocket=proposed=src:glibc --apt-upgrade r-cran-nleqslv --timeout-short=300 --timeout-copy=20000 --timeout-build=20000 --env=ADT_TEST_TRIGGERS=glibc/2.41-1ubuntu2 -- ssh -s /home/ubuntu/autopkgtest/ssh-setup/nova -- --flavor autopkgtest-s390x --security-groups autopkgtest-juju-7f2275-prod-proposed-migration-environment-20@bos03-s390x-11.secgroup --name adt-plucky-s390x-r-cran-nleqslv-20250315-181257-juju-7f2275-prod-proposed-migration-environment-20-f26cc978-f374-43be-a8dc-7ae61d14207e --image adt/ubuntu-plucky-s390x-server --keyname testbed-juju-7f2275-prod-proposed-migration-environment-20 --net-id=net_prod-proposed-migration-s390x -e TERM=linux -e ''"'"'http_proxy=http://squid.internal:3128'"'"'' -e ''"'"'https_proxy=http://squid.internal:3128'"'"'' -e ''"'"'no_proxy=127.0.0.1,127.0.1.1,login.ubuntu.com,localhost,localdomain,novalocal,internal,archive.ubuntu.com,ports.ubuntu.com,security.ubuntu.com,ddebs.ubuntu.com,changelogs.ubuntu.com,keyserver.ubuntu.com,launchpadlibrarian.net,launchpadcontent.net,launchpad.net,10.24.0.0/24,keystone.ps5.canonical.com,objectstorage.prodstack5.canonical.com,radosgw.ps5.canonical.com'"'"'' --mirror=http://ftpmaster.internal/ubuntu/ 105s autopkgtest [18:14:42]: testbed dpkg architecture: s390x 105s autopkgtest [18:14:42]: testbed apt version: 2.9.33 105s autopkgtest [18:14:42]: @@@@@@@@@@@@@@@@@@@@ test bed setup 105s autopkgtest [18:14:42]: testbed release detected to be: None 106s autopkgtest [18:14:43]: updating testbed package index (apt update) 106s Get:1 http://ftpmaster.internal/ubuntu plucky-proposed InRelease [126 kB] 107s Hit:2 http://ftpmaster.internal/ubuntu plucky InRelease 107s Hit:3 http://ftpmaster.internal/ubuntu plucky-updates InRelease 107s Hit:4 http://ftpmaster.internal/ubuntu plucky-security InRelease 107s Get:5 http://ftpmaster.internal/ubuntu plucky-proposed/universe Sources [379 kB] 107s Get:6 http://ftpmaster.internal/ubuntu plucky-proposed/main Sources [99.7 kB] 107s Get:7 http://ftpmaster.internal/ubuntu plucky-proposed/multiverse Sources [15.8 kB] 107s Get:8 http://ftpmaster.internal/ubuntu plucky-proposed/main s390x Packages [113 kB] 107s Get:9 http://ftpmaster.internal/ubuntu plucky-proposed/main s390x c-n-f Metadata [1824 B] 107s Get:10 http://ftpmaster.internal/ubuntu plucky-proposed/restricted s390x c-n-f Metadata [116 B] 107s Get:11 http://ftpmaster.internal/ubuntu plucky-proposed/universe s390x Packages [320 kB] 107s Get:12 http://ftpmaster.internal/ubuntu plucky-proposed/universe s390x c-n-f Metadata [13.4 kB] 107s Get:13 http://ftpmaster.internal/ubuntu plucky-proposed/multiverse s390x Packages [3776 B] 107s Get:14 http://ftpmaster.internal/ubuntu plucky-proposed/multiverse s390x c-n-f Metadata [240 B] 107s Fetched 1073 kB in 1s (1107 kB/s) 108s Reading package lists... 109s Reading package lists... 109s Building dependency tree... 109s Reading state information... 109s Calculating upgrade... 109s Calculating upgrade... 109s The following packages were automatically installed and are no longer required: 109s libnsl2 libpython3.12-minimal libpython3.12-stdlib libpython3.12t64 109s linux-headers-6.11.0-8 linux-headers-6.11.0-8-generic 109s linux-modules-6.11.0-8-generic linux-tools-6.11.0-8 109s linux-tools-6.11.0-8-generic 109s Use 'sudo apt autoremove' to remove them. 109s The following packages will be upgraded: 109s pinentry-curses python3-jinja2 strace 109s 3 upgraded, 0 newly installed, 0 to remove and 0 not upgraded. 109s Need to get 652 kB of archives. 109s After this operation, 27.6 kB of additional disk space will be used. 109s Get:1 http://ftpmaster.internal/ubuntu plucky/main s390x strace s390x 6.13+ds-1ubuntu1 [500 kB] 110s Get:2 http://ftpmaster.internal/ubuntu plucky/main s390x pinentry-curses s390x 1.3.1-2ubuntu3 [42.9 kB] 110s Get:3 http://ftpmaster.internal/ubuntu plucky/main s390x python3-jinja2 all 3.1.5-2ubuntu1 [109 kB] 110s Fetched 652 kB in 1s (988 kB/s) 110s (Reading database ... (Reading database ... 5% (Reading database ... 10% (Reading database ... 15% (Reading database ... 20% (Reading database ... 25% (Reading database ... 30% (Reading database ... 35% (Reading database ... 40% (Reading database ... 45% (Reading database ... 50% (Reading database ... 55% (Reading database ... 60% (Reading database ... 65% (Reading database ... 70% (Reading database ... 75% (Reading database ... 80% (Reading database ... 85% (Reading database ... 90% (Reading database ... 95% (Reading database ... 100% (Reading database ... 81428 files and directories currently installed.) 110s Preparing to unpack .../strace_6.13+ds-1ubuntu1_s390x.deb ... 110s Unpacking strace (6.13+ds-1ubuntu1) over (6.11-0ubuntu1) ... 110s Preparing to unpack .../pinentry-curses_1.3.1-2ubuntu3_s390x.deb ... 110s Unpacking pinentry-curses (1.3.1-2ubuntu3) over (1.3.1-2ubuntu2) ... 110s Preparing to unpack .../python3-jinja2_3.1.5-2ubuntu1_all.deb ... 110s Unpacking python3-jinja2 (3.1.5-2ubuntu1) over (3.1.5-2) ... 110s Setting up pinentry-curses (1.3.1-2ubuntu3) ... 110s Setting up python3-jinja2 (3.1.5-2ubuntu1) ... 110s Setting up strace (6.13+ds-1ubuntu1) ... 110s Processing triggers for man-db (2.13.0-1) ... 111s Reading package lists... 111s Building dependency tree... 111s Reading state information... 111s Solving dependencies... 111s The following packages will be REMOVED: 111s libnsl2* libpython3.12-minimal* libpython3.12-stdlib* libpython3.12t64* 111s linux-headers-6.11.0-8* linux-headers-6.11.0-8-generic* 111s linux-modules-6.11.0-8-generic* linux-tools-6.11.0-8* 111s linux-tools-6.11.0-8-generic* 111s 0 upgraded, 0 newly installed, 9 to remove and 5 not upgraded. 111s After this operation, 167 MB disk space will be freed. 112s (Reading database ... (Reading database ... 5% (Reading database ... 10% (Reading database ... 15% (Reading database ... 20% (Reading database ... 25% (Reading database ... 30% (Reading database ... 35% (Reading database ... 40% (Reading database ... 45% (Reading database ... 50% (Reading database ... 55% (Reading database ... 60% (Reading database ... 65% (Reading database ... 70% (Reading database ... 75% (Reading database ... 80% (Reading database ... 85% (Reading database ... 90% (Reading database ... 95% (Reading database ... 100% (Reading database ... 81428 files and directories currently installed.) 112s Removing linux-tools-6.11.0-8-generic (6.11.0-8.8) ... 112s Removing linux-tools-6.11.0-8 (6.11.0-8.8) ... 112s Removing libpython3.12t64:s390x (3.12.9-1) ... 112s Removing libpython3.12-stdlib:s390x (3.12.9-1) ... 112s Removing libnsl2:s390x (1.3.0-3build3) ... 112s Removing libpython3.12-minimal:s390x (3.12.9-1) ... 112s Removing linux-headers-6.11.0-8-generic (6.11.0-8.8) ... 112s Removing linux-headers-6.11.0-8 (6.11.0-8.8) ... 113s Removing linux-modules-6.11.0-8-generic (6.11.0-8.8) ... 113s Processing triggers for libc-bin (2.41-1ubuntu1) ... 113s (Reading database ... (Reading database ... 5% (Reading database ... 10% (Reading database ... 15% (Reading database ... 20% (Reading database ... 25% (Reading database ... 30% (Reading database ... 35% (Reading database ... 40% (Reading database ... 45% (Reading database ... 50% (Reading database ... 55% (Reading database ... 60% (Reading database ... 65% (Reading database ... 70% (Reading database ... 75% (Reading database ... 80% (Reading database ... 85% (Reading database ... 90% (Reading database ... 95% (Reading database ... 100% (Reading database ... 56328 files and directories currently installed.) 113s Purging configuration files for libpython3.12-minimal:s390x (3.12.9-1) ... 113s Purging configuration files for linux-modules-6.11.0-8-generic (6.11.0-8.8) ... 113s autopkgtest [18:14:50]: upgrading testbed (apt dist-upgrade and autopurge) 113s Reading package lists... 113s Building dependency tree... 113s Reading state information... 114s Calculating upgrade...Starting pkgProblemResolver with broken count: 0 114s Starting 2 pkgProblemResolver with broken count: 0 114s Done 114s Entering ResolveByKeep 114s 114s Calculating upgrade... 114s The following packages will be upgraded: 114s libc-bin libc-dev-bin libc6 libc6-dev locales 114s 5 upgraded, 0 newly installed, 0 to remove and 0 not upgraded. 114s Need to get 9512 kB of archives. 114s After this operation, 8192 B of additional disk space will be used. 114s Get:1 http://ftpmaster.internal/ubuntu plucky-proposed/main s390x libc6-dev s390x 2.41-1ubuntu2 [1678 kB] 115s Get:2 http://ftpmaster.internal/ubuntu plucky-proposed/main s390x libc-dev-bin s390x 2.41-1ubuntu2 [24.3 kB] 115s Get:3 http://ftpmaster.internal/ubuntu plucky-proposed/main s390x libc6 s390x 2.41-1ubuntu2 [2892 kB] 115s Get:4 http://ftpmaster.internal/ubuntu plucky-proposed/main s390x libc-bin s390x 2.41-1ubuntu2 [671 kB] 115s Get:5 http://ftpmaster.internal/ubuntu plucky-proposed/main s390x locales all 2.41-1ubuntu2 [4246 kB] 116s Preconfiguring packages ... 116s Fetched 9512 kB in 1s (6403 kB/s) 116s (Reading database ... (Reading database ... 5% (Reading database ... 10% (Reading database ... 15% (Reading database ... 20% (Reading database ... 25% (Reading database ... 30% (Reading database ... 35% (Reading database ... 40% (Reading database ... 45% (Reading database ... 50% (Reading database ... 55% (Reading database ... 60% (Reading database ... 65% (Reading database ... 70% (Reading database ... 75% (Reading database ... 80% (Reading database ... 85% (Reading database ... 90% (Reading database ... 95% (Reading database ... 100% (Reading database ... 56326 files and directories currently installed.) 116s Preparing to unpack .../libc6-dev_2.41-1ubuntu2_s390x.deb ... 116s Unpacking libc6-dev:s390x (2.41-1ubuntu2) over (2.41-1ubuntu1) ... 116s Preparing to unpack .../libc-dev-bin_2.41-1ubuntu2_s390x.deb ... 116s Unpacking libc-dev-bin (2.41-1ubuntu2) over (2.41-1ubuntu1) ... 116s Preparing to unpack .../libc6_2.41-1ubuntu2_s390x.deb ... 116s Unpacking libc6:s390x (2.41-1ubuntu2) over (2.41-1ubuntu1) ... 116s Setting up libc6:s390x (2.41-1ubuntu2) ... 116s (Reading database ... (Reading database ... 5% (Reading database ... 10% (Reading database ... 15% (Reading database ... 20% (Reading database ... 25% (Reading database ... 30% (Reading database ... 35% (Reading database ... 40% (Reading database ... 45% (Reading database ... 50% (Reading database ... 55% (Reading database ... 60% (Reading database ... 65% (Reading database ... 70% (Reading database ... 75% (Reading database ... 80% (Reading database ... 85% (Reading database ... 90% (Reading database ... 95% (Reading database ... 100% (Reading database ... 56326 files and directories currently installed.) 116s Preparing to unpack .../libc-bin_2.41-1ubuntu2_s390x.deb ... 116s Unpacking libc-bin (2.41-1ubuntu2) over (2.41-1ubuntu1) ... 116s Setting up libc-bin (2.41-1ubuntu2) ... 116s (Reading database ... (Reading database ... 5% (Reading database ... 10% (Reading database ... 15% (Reading database ... 20% (Reading database ... 25% (Reading database ... 30% (Reading database ... 35% (Reading database ... 40% (Reading database ... 45% (Reading database ... 50% (Reading database ... 55% (Reading database ... 60% (Reading database ... 65% (Reading database ... 70% (Reading database ... 75% (Reading database ... 80% (Reading database ... 85% (Reading database ... 90% (Reading database ... 95% (Reading database ... 100% (Reading database ... 56326 files and directories currently installed.) 116s Preparing to unpack .../locales_2.41-1ubuntu2_all.deb ... 116s Unpacking locales (2.41-1ubuntu2) over (2.41-1ubuntu1) ... 116s Setting up locales (2.41-1ubuntu2) ... 117s Generating locales (this might take a while)... 118s en_US.UTF-8... done 118s Generation complete. 118s Setting up libc-dev-bin (2.41-1ubuntu2) ... 118s Setting up libc6-dev:s390x (2.41-1ubuntu2) ... 118s Processing triggers for man-db (2.13.0-1) ... 119s Processing triggers for systemd (257.3-1ubuntu3) ... 119s Reading package lists... 120s Building dependency tree... 120s Reading state information... 120s Starting pkgProblemResolver with broken count: 0 120s Starting 2 pkgProblemResolver with broken count: 0 120s Done 120s Solving dependencies... 120s 0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded. 120s autopkgtest [18:14:57]: rebooting testbed after setup commands that affected boot 138s autopkgtest [18:15:15]: testbed running kernel: Linux 6.14.0-10-generic #10-Ubuntu SMP Wed Mar 12 14:53:49 UTC 2025 140s autopkgtest [18:15:17]: @@@@@@@@@@@@@@@@@@@@ apt-source r-cran-nleqslv 142s Get:1 http://ftpmaster.internal/ubuntu plucky/universe r-cran-nleqslv 3.3.5-1 (dsc) [2073 B] 142s Get:2 http://ftpmaster.internal/ubuntu plucky/universe r-cran-nleqslv 3.3.5-1 (tar) [82.5 kB] 142s Get:3 http://ftpmaster.internal/ubuntu plucky/universe r-cran-nleqslv 3.3.5-1 (diff) [2444 B] 142s gpgv: Signature made Mon Nov 27 19:33:07 2023 UTC 142s gpgv: using RSA key F1F007320A035541F0A663CA578A0494D1C646D1 142s gpgv: issuer "tille@debian.org" 142s gpgv: Can't check signature: No public key 142s dpkg-source: warning: cannot verify inline signature for ./r-cran-nleqslv_3.3.5-1.dsc: no acceptable signature found 142s autopkgtest [18:15:19]: testing package r-cran-nleqslv version 3.3.5-1 142s autopkgtest [18:15:19]: build not needed 146s autopkgtest [18:15:23]: test generic: preparing testbed 146s Reading package lists... 146s Building dependency tree... 146s Reading state information... 146s Starting pkgProblemResolver with broken count: 0 146s Starting 2 pkgProblemResolver with broken count: 0 146s Done 147s The following NEW packages will be installed: 147s fontconfig fontconfig-config fonts-dejavu-core fonts-dejavu-mono libblas3 147s libcairo2 libdatrie1 libdeflate0 libfontconfig1 libfreetype6 libgfortran5 147s libgomp1 libgraphite2-3 libharfbuzz0b libice6 libjbig0 libjpeg-turbo8 147s libjpeg8 liblapack3 libpango-1.0-0 libpangocairo-1.0-0 libpangoft2-1.0-0 147s libpaper-utils libpaper2 libpixman-1-0 libsharpyuv0 libsm6 libtcl8.6 147s libthai-data libthai0 libtiff6 libtk8.6 libwebp7 libxcb-render0 libxcb-shm0 147s libxft2 libxrender1 libxss1 libxt6t64 r-base-core r-cran-nleqslv unzip 147s x11-common xdg-utils zip 147s 0 upgraded, 45 newly installed, 0 to remove and 0 not upgraded. 147s Need to get 40.2 MB of archives. 147s After this operation, 81.2 MB of additional disk space will be used. 147s Get:1 http://ftpmaster.internal/ubuntu plucky/main s390x libfreetype6 s390x 2.13.3+dfsg-1 [431 kB] 147s Get:2 http://ftpmaster.internal/ubuntu plucky/main s390x fonts-dejavu-mono all 2.37-8 [502 kB] 147s Get:3 http://ftpmaster.internal/ubuntu plucky/main s390x fonts-dejavu-core all 2.37-8 [835 kB] 147s Get:4 http://ftpmaster.internal/ubuntu plucky/main s390x fontconfig-config s390x 2.15.0-2ubuntu1 [37.5 kB] 147s Get:5 http://ftpmaster.internal/ubuntu plucky/main s390x libfontconfig1 s390x 2.15.0-2ubuntu1 [150 kB] 147s Get:6 http://ftpmaster.internal/ubuntu plucky/main s390x fontconfig s390x 2.15.0-2ubuntu1 [191 kB] 148s Get:7 http://ftpmaster.internal/ubuntu plucky/main s390x libblas3 s390x 3.12.1-2 [252 kB] 148s Get:8 http://ftpmaster.internal/ubuntu plucky/main s390x libpixman-1-0 s390x 0.44.0-3 [201 kB] 148s Get:9 http://ftpmaster.internal/ubuntu plucky/main s390x libxcb-render0 s390x 1.17.0-2 [17.0 kB] 148s Get:10 http://ftpmaster.internal/ubuntu plucky/main s390x libxcb-shm0 s390x 1.17.0-2 [5862 B] 148s Get:11 http://ftpmaster.internal/ubuntu plucky/main s390x libxrender1 s390x 1:0.9.10-1.1build1 [20.4 kB] 148s Get:12 http://ftpmaster.internal/ubuntu plucky/main s390x libcairo2 s390x 1.18.2-2 [580 kB] 148s Get:13 http://ftpmaster.internal/ubuntu plucky/main s390x libdatrie1 s390x 0.2.13-3build1 [20.6 kB] 148s Get:14 http://ftpmaster.internal/ubuntu plucky/main s390x libdeflate0 s390x 1.23-1 [46.1 kB] 148s Get:15 http://ftpmaster.internal/ubuntu plucky/main s390x libgfortran5 s390x 15-20250222-0ubuntu1 [620 kB] 148s Get:16 http://ftpmaster.internal/ubuntu plucky/main s390x libgomp1 s390x 15-20250222-0ubuntu1 [152 kB] 148s Get:17 http://ftpmaster.internal/ubuntu plucky/main s390x libgraphite2-3 s390x 1.3.14-2ubuntu1 [79.8 kB] 148s Get:18 http://ftpmaster.internal/ubuntu plucky/main s390x libharfbuzz0b s390x 10.2.0-1 [538 kB] 148s Get:19 http://ftpmaster.internal/ubuntu plucky/main s390x x11-common all 1:7.7+23ubuntu3 [21.7 kB] 148s Get:20 http://ftpmaster.internal/ubuntu plucky/main s390x libice6 s390x 2:1.1.1-1 [45.4 kB] 148s Get:21 http://ftpmaster.internal/ubuntu plucky/main s390x libjpeg-turbo8 s390x 2.1.5-3ubuntu2 [147 kB] 148s Get:22 http://ftpmaster.internal/ubuntu plucky/main s390x libjpeg8 s390x 8c-2ubuntu11 [2146 B] 148s Get:23 http://ftpmaster.internal/ubuntu plucky/main s390x liblapack3 s390x 3.12.1-2 [2971 kB] 148s Get:24 http://ftpmaster.internal/ubuntu plucky/main s390x libthai-data all 0.1.29-2build1 [158 kB] 148s Get:25 http://ftpmaster.internal/ubuntu plucky/main s390x libthai0 s390x 0.1.29-2build1 [20.7 kB] 148s Get:26 http://ftpmaster.internal/ubuntu plucky/main s390x libpango-1.0-0 s390x 1.56.2-1 [253 kB] 148s Get:27 http://ftpmaster.internal/ubuntu plucky/main s390x libpangoft2-1.0-0 s390x 1.56.2-1 [50.2 kB] 148s Get:28 http://ftpmaster.internal/ubuntu plucky/main s390x libpangocairo-1.0-0 s390x 1.56.2-1 [28.2 kB] 148s Get:29 http://ftpmaster.internal/ubuntu plucky/main s390x libpaper2 s390x 2.2.5-0.3 [17.2 kB] 148s Get:30 http://ftpmaster.internal/ubuntu plucky/main s390x libpaper-utils s390x 2.2.5-0.3 [15.3 kB] 148s Get:31 http://ftpmaster.internal/ubuntu plucky/main s390x libsharpyuv0 s390x 1.5.0-0.1 [16.7 kB] 148s Get:32 http://ftpmaster.internal/ubuntu plucky/main s390x libsm6 s390x 2:1.2.4-1 [18.4 kB] 148s Get:33 http://ftpmaster.internal/ubuntu plucky/main s390x libtcl8.6 s390x 8.6.16+dfsg-1 [1034 kB] 148s Get:34 http://ftpmaster.internal/ubuntu plucky/main s390x libjbig0 s390x 2.1-6.1ubuntu2 [33.1 kB] 148s Get:35 http://ftpmaster.internal/ubuntu plucky/main s390x libwebp7 s390x 1.5.0-0.1 [210 kB] 148s Get:36 http://ftpmaster.internal/ubuntu plucky/main s390x libtiff6 s390x 4.5.1+git230720-4ubuntu4 [217 kB] 148s Get:37 http://ftpmaster.internal/ubuntu plucky/main s390x libxft2 s390x 2.3.6-1build1 [49.6 kB] 148s Get:38 http://ftpmaster.internal/ubuntu plucky/main s390x libxss1 s390x 1:1.2.3-1build3 [7396 B] 148s Get:39 http://ftpmaster.internal/ubuntu plucky/main s390x libtk8.6 s390x 8.6.16-1 [830 kB] 148s Get:40 http://ftpmaster.internal/ubuntu plucky/main s390x libxt6t64 s390x 1:1.2.1-1.2build1 [184 kB] 148s Get:41 http://ftpmaster.internal/ubuntu plucky/main s390x zip s390x 3.0-14ubuntu2 [187 kB] 148s Get:42 http://ftpmaster.internal/ubuntu plucky/main s390x unzip s390x 6.0-28ubuntu6 [186 kB] 148s Get:43 http://ftpmaster.internal/ubuntu plucky/main s390x xdg-utils all 1.2.1-2ubuntu1 [66.0 kB] 148s Get:44 http://ftpmaster.internal/ubuntu plucky/universe s390x r-base-core s390x 4.4.3-1 [28.6 MB] 151s Get:45 http://ftpmaster.internal/ubuntu plucky/universe s390x r-cran-nleqslv s390x 3.3.5-1 [104 kB] 151s Preconfiguring packages ... 151s Fetched 40.2 MB in 4s (9840 kB/s) 151s Selecting previously unselected package libfreetype6:s390x. 151s (Reading database ... (Reading database ... 5% (Reading database ... 10% (Reading database ... 15% (Reading database ... 20% (Reading database ... 25% (Reading database ... 30% (Reading database ... 35% (Reading database ... 40% (Reading database ... 45% (Reading database ... 50% (Reading database ... 55% (Reading database ... 60% (Reading database ... 65% (Reading database ... 70% (Reading database ... 75% (Reading database ... 80% (Reading database ... 85% (Reading database ... 90% (Reading database ... 95% (Reading database ... 100% (Reading database ... 56326 files and directories currently installed.) 151s Preparing to unpack .../00-libfreetype6_2.13.3+dfsg-1_s390x.deb ... 151s Unpacking libfreetype6:s390x (2.13.3+dfsg-1) ... 151s Selecting previously unselected package fonts-dejavu-mono. 151s Preparing to unpack .../01-fonts-dejavu-mono_2.37-8_all.deb ... 151s Unpacking fonts-dejavu-mono (2.37-8) ... 151s Selecting previously unselected package fonts-dejavu-core. 151s Preparing to unpack .../02-fonts-dejavu-core_2.37-8_all.deb ... 151s Unpacking fonts-dejavu-core (2.37-8) ... 151s Selecting previously unselected package fontconfig-config. 151s Preparing to unpack .../03-fontconfig-config_2.15.0-2ubuntu1_s390x.deb ... 151s Unpacking fontconfig-config (2.15.0-2ubuntu1) ... 151s Selecting previously unselected package libfontconfig1:s390x. 151s Preparing to unpack .../04-libfontconfig1_2.15.0-2ubuntu1_s390x.deb ... 151s Unpacking libfontconfig1:s390x (2.15.0-2ubuntu1) ... 151s Selecting previously unselected package fontconfig. 151s Preparing to unpack .../05-fontconfig_2.15.0-2ubuntu1_s390x.deb ... 151s Unpacking fontconfig (2.15.0-2ubuntu1) ... 151s Selecting previously unselected package libblas3:s390x. 151s Preparing to unpack .../06-libblas3_3.12.1-2_s390x.deb ... 151s Unpacking libblas3:s390x (3.12.1-2) ... 151s Selecting previously unselected package libpixman-1-0:s390x. 151s Preparing to unpack .../07-libpixman-1-0_0.44.0-3_s390x.deb ... 151s Unpacking libpixman-1-0:s390x (0.44.0-3) ... 151s Selecting previously unselected package libxcb-render0:s390x. 151s Preparing to unpack .../08-libxcb-render0_1.17.0-2_s390x.deb ... 151s Unpacking libxcb-render0:s390x (1.17.0-2) ... 151s Selecting previously unselected package libxcb-shm0:s390x. 151s Preparing to unpack .../09-libxcb-shm0_1.17.0-2_s390x.deb ... 151s Unpacking libxcb-shm0:s390x (1.17.0-2) ... 151s Selecting previously unselected package libxrender1:s390x. 151s Preparing to unpack .../10-libxrender1_1%3a0.9.10-1.1build1_s390x.deb ... 151s Unpacking libxrender1:s390x (1:0.9.10-1.1build1) ... 151s Selecting previously unselected package libcairo2:s390x. 151s Preparing to unpack .../11-libcairo2_1.18.2-2_s390x.deb ... 151s Unpacking libcairo2:s390x (1.18.2-2) ... 151s Selecting previously unselected package libdatrie1:s390x. 151s Preparing to unpack .../12-libdatrie1_0.2.13-3build1_s390x.deb ... 151s Unpacking libdatrie1:s390x (0.2.13-3build1) ... 151s Selecting previously unselected package libdeflate0:s390x. 151s Preparing to unpack .../13-libdeflate0_1.23-1_s390x.deb ... 151s Unpacking libdeflate0:s390x (1.23-1) ... 151s Selecting previously unselected package libgfortran5:s390x. 151s Preparing to unpack .../14-libgfortran5_15-20250222-0ubuntu1_s390x.deb ... 151s Unpacking libgfortran5:s390x (15-20250222-0ubuntu1) ... 151s Selecting previously unselected package libgomp1:s390x. 151s Preparing to unpack .../15-libgomp1_15-20250222-0ubuntu1_s390x.deb ... 151s Unpacking libgomp1:s390x (15-20250222-0ubuntu1) ... 151s Selecting previously unselected package libgraphite2-3:s390x. 151s Preparing to unpack .../16-libgraphite2-3_1.3.14-2ubuntu1_s390x.deb ... 151s Unpacking libgraphite2-3:s390x (1.3.14-2ubuntu1) ... 151s Selecting previously unselected package libharfbuzz0b:s390x. 151s Preparing to unpack .../17-libharfbuzz0b_10.2.0-1_s390x.deb ... 151s Unpacking libharfbuzz0b:s390x (10.2.0-1) ... 151s Selecting previously unselected package x11-common. 151s Preparing to unpack .../18-x11-common_1%3a7.7+23ubuntu3_all.deb ... 151s Unpacking x11-common (1:7.7+23ubuntu3) ... 151s Selecting previously unselected package libice6:s390x. 151s Preparing to unpack .../19-libice6_2%3a1.1.1-1_s390x.deb ... 151s Unpacking libice6:s390x (2:1.1.1-1) ... 151s Selecting previously unselected package libjpeg-turbo8:s390x. 151s Preparing to unpack .../20-libjpeg-turbo8_2.1.5-3ubuntu2_s390x.deb ... 151s Unpacking libjpeg-turbo8:s390x (2.1.5-3ubuntu2) ... 152s Selecting previously unselected package libjpeg8:s390x. 152s Preparing to unpack .../21-libjpeg8_8c-2ubuntu11_s390x.deb ... 152s Unpacking libjpeg8:s390x (8c-2ubuntu11) ... 152s Selecting previously unselected package liblapack3:s390x. 152s Preparing to unpack .../22-liblapack3_3.12.1-2_s390x.deb ... 152s Unpacking liblapack3:s390x (3.12.1-2) ... 152s Selecting previously unselected package libthai-data. 152s Preparing to unpack .../23-libthai-data_0.1.29-2build1_all.deb ... 152s Unpacking libthai-data (0.1.29-2build1) ... 152s Selecting previously unselected package libthai0:s390x. 152s Preparing to unpack .../24-libthai0_0.1.29-2build1_s390x.deb ... 152s Unpacking libthai0:s390x (0.1.29-2build1) ... 152s Selecting previously unselected package libpango-1.0-0:s390x. 152s Preparing to unpack .../25-libpango-1.0-0_1.56.2-1_s390x.deb ... 152s Unpacking libpango-1.0-0:s390x (1.56.2-1) ... 152s Selecting previously unselected package libpangoft2-1.0-0:s390x. 152s Preparing to unpack .../26-libpangoft2-1.0-0_1.56.2-1_s390x.deb ... 152s Unpacking libpangoft2-1.0-0:s390x (1.56.2-1) ... 152s Selecting previously unselected package libpangocairo-1.0-0:s390x. 152s Preparing to unpack .../27-libpangocairo-1.0-0_1.56.2-1_s390x.deb ... 152s Unpacking libpangocairo-1.0-0:s390x (1.56.2-1) ... 152s Selecting previously unselected package libpaper2:s390x. 152s Preparing to unpack .../28-libpaper2_2.2.5-0.3_s390x.deb ... 152s Unpacking libpaper2:s390x (2.2.5-0.3) ... 152s Selecting previously unselected package libpaper-utils. 152s Preparing to unpack .../29-libpaper-utils_2.2.5-0.3_s390x.deb ... 152s Unpacking libpaper-utils (2.2.5-0.3) ... 152s Selecting previously unselected package libsharpyuv0:s390x. 152s Preparing to unpack .../30-libsharpyuv0_1.5.0-0.1_s390x.deb ... 152s Unpacking libsharpyuv0:s390x (1.5.0-0.1) ... 152s Selecting previously unselected package libsm6:s390x. 152s Preparing to unpack .../31-libsm6_2%3a1.2.4-1_s390x.deb ... 152s Unpacking libsm6:s390x (2:1.2.4-1) ... 152s Selecting previously unselected package libtcl8.6:s390x. 152s Preparing to unpack .../32-libtcl8.6_8.6.16+dfsg-1_s390x.deb ... 152s Unpacking libtcl8.6:s390x (8.6.16+dfsg-1) ... 152s Selecting previously unselected package libjbig0:s390x. 152s Preparing to unpack .../33-libjbig0_2.1-6.1ubuntu2_s390x.deb ... 152s Unpacking libjbig0:s390x (2.1-6.1ubuntu2) ... 152s Selecting previously unselected package libwebp7:s390x. 152s Preparing to unpack .../34-libwebp7_1.5.0-0.1_s390x.deb ... 152s Unpacking libwebp7:s390x (1.5.0-0.1) ... 152s Selecting previously unselected package libtiff6:s390x. 152s Preparing to unpack .../35-libtiff6_4.5.1+git230720-4ubuntu4_s390x.deb ... 152s Unpacking libtiff6:s390x (4.5.1+git230720-4ubuntu4) ... 152s Selecting previously unselected package libxft2:s390x. 152s Preparing to unpack .../36-libxft2_2.3.6-1build1_s390x.deb ... 152s Unpacking libxft2:s390x (2.3.6-1build1) ... 152s Selecting previously unselected package libxss1:s390x. 152s Preparing to unpack .../37-libxss1_1%3a1.2.3-1build3_s390x.deb ... 152s Unpacking libxss1:s390x (1:1.2.3-1build3) ... 152s Selecting previously unselected package libtk8.6:s390x. 152s Preparing to unpack .../38-libtk8.6_8.6.16-1_s390x.deb ... 152s Unpacking libtk8.6:s390x (8.6.16-1) ... 152s Selecting previously unselected package libxt6t64:s390x. 152s Preparing to unpack .../39-libxt6t64_1%3a1.2.1-1.2build1_s390x.deb ... 152s Unpacking libxt6t64:s390x (1:1.2.1-1.2build1) ... 152s Selecting previously unselected package zip. 152s Preparing to unpack .../40-zip_3.0-14ubuntu2_s390x.deb ... 152s Unpacking zip (3.0-14ubuntu2) ... 152s Selecting previously unselected package unzip. 152s Preparing to unpack .../41-unzip_6.0-28ubuntu6_s390x.deb ... 152s Unpacking unzip (6.0-28ubuntu6) ... 152s Selecting previously unselected package xdg-utils. 152s Preparing to unpack .../42-xdg-utils_1.2.1-2ubuntu1_all.deb ... 152s Unpacking xdg-utils (1.2.1-2ubuntu1) ... 152s Selecting previously unselected package r-base-core. 152s Preparing to unpack .../43-r-base-core_4.4.3-1_s390x.deb ... 152s Unpacking r-base-core (4.4.3-1) ... 152s Selecting previously unselected package r-cran-nleqslv. 152s Preparing to unpack .../44-r-cran-nleqslv_3.3.5-1_s390x.deb ... 152s Unpacking r-cran-nleqslv (3.3.5-1) ... 152s Setting up libgraphite2-3:s390x (1.3.14-2ubuntu1) ... 152s Setting up libpixman-1-0:s390x (0.44.0-3) ... 152s Setting up libsharpyuv0:s390x (1.5.0-0.1) ... 152s Setting up libxrender1:s390x (1:0.9.10-1.1build1) ... 152s Setting up libdatrie1:s390x (0.2.13-3build1) ... 152s Setting up libxcb-render0:s390x (1.17.0-2) ... 152s Setting up unzip (6.0-28ubuntu6) ... 152s Setting up x11-common (1:7.7+23ubuntu3) ... 152s Setting up libdeflate0:s390x (1.23-1) ... 152s Setting up libxcb-shm0:s390x (1.17.0-2) ... 152s Setting up libgomp1:s390x (15-20250222-0ubuntu1) ... 152s Setting up libjbig0:s390x (2.1-6.1ubuntu2) ... 152s Setting up zip (3.0-14ubuntu2) ... 152s Setting up libblas3:s390x (3.12.1-2) ... 152s update-alternatives: using /usr/lib/s390x-linux-gnu/blas/libblas.so.3 to provide /usr/lib/s390x-linux-gnu/libblas.so.3 (libblas.so.3-s390x-linux-gnu) in auto mode 152s Setting up libfreetype6:s390x (2.13.3+dfsg-1) ... 152s Setting up fonts-dejavu-mono (2.37-8) ... 152s Setting up libtcl8.6:s390x (8.6.16+dfsg-1) ... 152s Setting up fonts-dejavu-core (2.37-8) ... 152s Setting up libjpeg-turbo8:s390x (2.1.5-3ubuntu2) ... 152s Setting up libgfortran5:s390x (15-20250222-0ubuntu1) ... 152s Setting up libwebp7:s390x (1.5.0-0.1) ... 152s Setting up libharfbuzz0b:s390x (10.2.0-1) ... 152s Setting up libthai-data (0.1.29-2build1) ... 152s Setting up libxss1:s390x (1:1.2.3-1build3) ... 152s Setting up libpaper2:s390x (2.2.5-0.3) ... 152s Setting up xdg-utils (1.2.1-2ubuntu1) ... 152s update-alternatives: using /usr/bin/xdg-open to provide /usr/bin/open (open) in auto mode 152s Setting up libjpeg8:s390x (8c-2ubuntu11) ... 152s Setting up libice6:s390x (2:1.1.1-1) ... 152s Setting up liblapack3:s390x (3.12.1-2) ... 152s update-alternatives: using /usr/lib/s390x-linux-gnu/lapack/liblapack.so.3 to provide /usr/lib/s390x-linux-gnu/liblapack.so.3 (liblapack.so.3-s390x-linux-gnu) in auto mode 152s Setting up fontconfig-config (2.15.0-2ubuntu1) ... 153s Setting up libpaper-utils (2.2.5-0.3) ... 153s Setting up libthai0:s390x (0.1.29-2build1) ... 153s Setting up libtiff6:s390x (4.5.1+git230720-4ubuntu4) ... 153s Setting up libfontconfig1:s390x (2.15.0-2ubuntu1) ... 153s Setting up libsm6:s390x (2:1.2.4-1) ... 153s Setting up fontconfig (2.15.0-2ubuntu1) ... 155s Regenerating fonts cache... done. 155s Setting up libxft2:s390x (2.3.6-1build1) ... 155s Setting up libtk8.6:s390x (8.6.16-1) ... 155s Setting up libpango-1.0-0:s390x (1.56.2-1) ... 155s Setting up libcairo2:s390x (1.18.2-2) ... 155s Setting up libxt6t64:s390x (1:1.2.1-1.2build1) ... 155s Setting up libpangoft2-1.0-0:s390x (1.56.2-1) ... 155s Setting up libpangocairo-1.0-0:s390x (1.56.2-1) ... 155s Setting up r-base-core (4.4.3-1) ... 155s Creating config file /etc/R/Renviron with new version 155s Setting up r-cran-nleqslv (3.3.5-1) ... 155s Processing triggers for man-db (2.13.0-1) ... 156s Processing triggers for install-info (7.1.1-1) ... 156s Processing triggers for libc-bin (2.41-1ubuntu2) ... 157s autopkgtest [18:15:34]: test generic: [----------------------- 157s BEGIN TEST tests/brdban.R 157s 157s R version 4.4.3 (2025-02-28) -- "Trophy Case" 157s Copyright (C) 2025 The R Foundation for Statistical Computing 157s Platform: s390x-ibm-linux-gnu 157s 157s R is free software and comes with ABSOLUTELY NO WARRANTY. 157s You are welcome to redistribute it under certain conditions. 157s Type 'license()' or 'licence()' for distribution details. 157s 157s R is a collaborative project with many contributors. 157s Type 'contributors()' for more information and 157s 'citation()' on how to cite R or R packages in publications. 157s 157s Type 'demo()' for some demos, 'help()' for on-line help, or 157s 'help.start()' for an HTML browser interface to help. 157s Type 'q()' to quit R. 157s 157s > # Broyden banded function 157s > 157s > library("nleqslv") 157s > 157s > brdban <- function(x) { 157s + ml <- 5 157s + mu <- 1 157s + n <- length(x) 157s + y <- numeric(n) 157s + 157s + for( k in 1:n ) { 157s + 157s + k1 <- max(1, k - ml) 157s + k2 <- min(n, k + mu) 157s + 157s + temp = 0.0 157s + for(j in k1:k2) { 157s + if ( j != k ) { 157s + temp <- temp + x[j] * (1.0 + x[j]) 157s + } 157s + } 157s + 157s + y[k] <- x[k] * (2.0 + 5.0 * x[k]**2) + 1.0 - temp 157s + 157s + } 157s + y 157s + } 157s > 157s > n <- 10 157s > xstart <- -rep(1,n) 157s > 157s > xsol <- c( -0.42830, -0.47660, -0.51965, -0.55810, -0.59251, 157s + -0.62450, -0.62324, -0.62139, -0.62045, -0.58647 ) 157s > 157s > fsol <- brdban(xsol) 157s > 157s > znlq <- nleqslv(xstart, brdban, global="dbldog", method="Newton", 157s + control=list(trace=0,ftol=1e-8,xtol=1e-8,btol=1e-2,delta=-1.0)) 157s > znlq$termcd # should be 2 for x values within tolerance 157s [1] 1 157s > all(abs(znlq$fvec)<=1e-7) # may not have achieved ftol 157s [1] TRUE 157s > 157s > xstart <- -2*rep(1,n) 157s > znlq <- nleqslv(xstart, brdban, global="dbldog", method="Newton", 157s + control=list(trace=0,ftol=1e-8,xtol=1e-8,btol=1e-2,delta=-1.0)) 157s > znlq$termcd 157s [1] 1 157s > all(abs(znlq$fvec)<=1e-8) 157s [1] TRUE 157s > 157s > znlq <- nleqslv(xstart, brdban, global="dbldog", 157s + control=list(trace=0,ftol=1e-8,xtol=1e-8,btol=1e-2,delta=-1.0)) 157s > znlq$termcd # should be 2 for x values within tolerance 157s [1] 1 157s > all(abs(znlq$fvec)<=1e-7) # may not have achieved ftol 157s [1] TRUE 157s > 157s > xstart <- -2*rep(1,n) 157s > znlq <- nleqslv(xstart, brdban, global="dbldog", 157s + control=list(trace=0,ftol=1e-8,xtol=1e-8,btol=1e-2,delta=-1.0)) 157s > znlq$termcd 157s [1] 1 157s > all(abs(znlq$fvec)<=1e-8) 157s [1] TRUE 157s > 157s BEGIN TEST tests/brdbanded.R 157s 157s R version 4.4.3 (2025-02-28) -- "Trophy Case" 157s Copyright (C) 2025 The R Foundation for Statistical Computing 157s Platform: s390x-ibm-linux-gnu 157s 157s R is free software and comes with ABSOLUTELY NO WARRANTY. 157s You are welcome to redistribute it under certain conditions. 157s Type 'license()' or 'licence()' for distribution details. 157s 157s R is a collaborative project with many contributors. 157s Type 'contributors()' for more information and 157s 'citation()' on how to cite R or R packages in publications. 157s 157s Type 'demo()' for some demos, 'help()' for on-line help, or 157s 'help.start()' for an HTML browser interface to help. 157s Type 'q()' to quit R. 157s 157s > # Broyden banded 157s > 157s > library("nleqslv") 157s > 157s > brdban <- function(x,ml=5,mu=1) { 157s + n <- length(x) 157s + y <- numeric(n) 157s + 157s + for( k in 1:n ) { 157s + 157s + k1 <- max(1, k - ml) 157s + k2 <- min(n, k + mu) 157s + 157s + temp <- 0.0 157s + for(j in k1:k2) { 157s + if ( j != k ) { 157s + temp <- temp + x[j] * (1.0 + x[j]) 157s + } 157s + } 157s + 157s + y[k] <- x[k] * (2.0 + 5.0 * x[k]**2) + 1.0 - temp 157s + 157s + } 157s + y 157s + } 157s > 157s > n <- 10 157s > xstart <- -rep(1,n) 157s > ztol <- 1000*.Machine$double.eps 157s > 157s > z1 <- nleqslv(xstart,brdban, method="Newton") 157s > z2 <- nleqslv(xstart,brdban, method="Newton", control=list(dsub=5,dsuper=1)) 157s > 157s > cat("z1 termcd=",z1$termcd, "jcnt,fcnt=",z1$njcnt,z1$nfcnt,"\n") 157s z1 termcd= 1 jcnt,fcnt= 5 5 157s > cat("z2 termcd=",z2$termcd, "jcnt,fcnt=",z2$njcnt,z2$nfcnt,"\n") 157s z2 termcd= 1 jcnt,fcnt= 5 5 157s > z1$message 157s [1] "Function criterion near zero" 157s > z2$message 157s [1] "Function criterion near zero" 157s > all.equal(z2$x,z1$x) 157s [1] TRUE 157s > all.equal(z2$x,z1$x, tolerance=ztol) 157s [1] TRUE 157s > 157s > z1 <- nleqslv(xstart,brdban, ml=2,mu=2, method="Newton") 157s > z2 <- nleqslv(xstart,brdban, ml=2,mu=2, method="Newton", control=list(dsub=2,dsuper=2)) 157s > 157s > cat("z1 termcd=",z1$termcd, "jcnt,fcnt=",z1$njcnt,z1$nfcnt,"\n") 157s z1 termcd= 1 jcnt,fcnt= 5 5 157s > cat("z2 termcd=",z2$termcd, "jcnt,fcnt=",z2$njcnt,z2$nfcnt,"\n") 157s z2 termcd= 1 jcnt,fcnt= 5 5 157s > z1$message 157s [1] "Function criterion near zero" 157s > z2$message 157s [1] "Function criterion near zero" 157s > all.equal(z2$x,z1$x, tolerance=ztol) 157s [1] TRUE 157s > 157s > z3 <- nleqslv(xstart,brdban, ml=2,mu=2, method="Broyden") 157s > z4 <- nleqslv(xstart,brdban, ml=2,mu=2, method="Broyden", control=list(dsub=2,dsuper=2)) 157s > 157s > cat("z3 termcd=",z1$termcd, "jcnt,fcnt=",z3$njcnt,z3$nfcnt,"\n") 157s z3 termcd= 1 jcnt,fcnt= 1 20 157s > cat("z4 termcd=",z2$termcd, "jcnt,fcnt=",z4$njcnt,z4$nfcnt,"\n") 157s z4 termcd= 1 jcnt,fcnt= 1 20 157s > z3$message 157s [1] "Function criterion near zero" 157s > z4$message 157s [1] "Function criterion near zero" 157s > all.equal(z3$x,z1$x) 157s [1] TRUE 157s > all.equal(z4$x,z1$x) 157s [1] TRUE 157s > all.equal(z4$x,z3$x, tolerance=ztol) 157s [1] TRUE 157s > 157s BEGIN TEST tests/brdtri.R 157s 157s R version 4.4.3 (2025-02-28) -- "Trophy Case" 157s Copyright (C) 2025 The R Foundation for Statistical Computing 157s Platform: s390x-ibm-linux-gnu 157s 157s R is free software and comes with ABSOLUTELY NO WARRANTY. 157s You are welcome to redistribute it under certain conditions. 157s Type 'license()' or 'licence()' for distribution details. 157s 157s R is a collaborative project with many contributors. 157s Type 'contributors()' for more information and 157s 'citation()' on how to cite R or R packages in publications. 157s 157s Type 'demo()' for some demos, 'help()' for on-line help, or 157s 'help.start()' for an HTML browser interface to help. 157s Type 'q()' to quit R. 157s 157s > # Broyden tridiagonal 157s > 157s > library("nleqslv") 157s > 157s > brdtri <- function(x) { 157s + n <- length(x) 157s + y <- numeric(n) 157s + 157s + y[1] <- (3-2*x[1])*x[1] - 2*x[2] + 1 157s + y[n] <- (3-2*x[n])*x[n] - x[n-1] + 1 157s + 157s + k <- 2:(n-1) 157s + y[k] <- (3-2*x[k])*x[k] - x[k-1] - 2 * x[k+1] + 1 157s + 157s + y 157s + } 157s > 157s > n <- 100 157s > xstart <- -rep(1,n) 157s > ztol <- 1000*.Machine$double.eps 157s > 157s > z1 <- nleqslv(xstart,brdtri, method="Newton") 157s > z2 <- nleqslv(xstart,brdtri, method="Newton", control=list(dsub=1,dsuper=1)) 157s > 157s > cat("z1 termcd=",z1$termcd, "jcnt,fcnt=",z1$njcnt,z1$nfcnt,"\n") 157s z1 termcd= 1 jcnt,fcnt= 4 4 157s > cat("z2 termcd=",z2$termcd, "jcnt,fcnt=",z2$njcnt,z2$nfcnt,"\n") 157s z2 termcd= 1 jcnt,fcnt= 4 4 157s > z1$message 157s [1] "Function criterion near zero" 157s > z2$message 157s [1] "Function criterion near zero" 157s > all.equal(z2$x,z1$x) 157s [1] TRUE 157s > all.equal(z2$x,z1$x, tolerance=ztol) 157s [1] TRUE 157s > 157s > z1 <- nleqslv(xstart,brdtri, method="Newton") 157s > z2 <- nleqslv(xstart,brdtri, method="Newton", control=list(dsub=1,dsuper=1)) 157s > 157s > cat("z1 termcd=",z1$termcd, "jcnt,fcnt=",z1$njcnt,z1$nfcnt,"\n") 157s z1 termcd= 1 jcnt,fcnt= 4 4 157s > cat("z2 termcd=",z2$termcd, "jcnt,fcnt=",z2$njcnt,z2$nfcnt,"\n") 157s z2 termcd= 1 jcnt,fcnt= 4 4 157s > z1$message 157s [1] "Function criterion near zero" 157s > z2$message 157s [1] "Function criterion near zero" 157s > all.equal(z2$x,z1$x, tolerance=ztol) 157s [1] TRUE 157s > 157s > z3 <- nleqslv(xstart,brdtri, method="Broyden") 157s > z4 <- nleqslv(xstart,brdtri, method="Broyden", control=list(dsub=1,dsuper=1)) 157s > 157s > cat("z3 termcd=",z1$termcd, "jcnt,fcnt=",z3$njcnt,z3$nfcnt,"\n") 157s z3 termcd= 1 jcnt,fcnt= 1 10 157s > cat("z4 termcd=",z2$termcd, "jcnt,fcnt=",z4$njcnt,z4$nfcnt,"\n") 157s z4 termcd= 1 jcnt,fcnt= 1 10 157s > z3$message 157s [1] "x-values within tolerance 'xtol'" 157s > z4$message 157s [1] "x-values within tolerance 'xtol'" 157s > all.equal(z3$x,z1$x) 157s [1] TRUE 157s > all.equal(z4$x,z1$x) 157s [1] TRUE 157s > all.equal(z4$x,z3$x, tolerance=ztol) 157s [1] TRUE 157s > 157s BEGIN TEST tests/brdtrijac.R 158s 158s R version 4.4.3 (2025-02-28) -- "Trophy Case" 158s Copyright (C) 2025 The R Foundation for Statistical Computing 158s Platform: s390x-ibm-linux-gnu 158s 158s R is free software and comes with ABSOLUTELY NO WARRANTY. 158s You are welcome to redistribute it under certain conditions. 158s Type 'license()' or 'licence()' for distribution details. 158s 158s R is a collaborative project with many contributors. 158s Type 'contributors()' for more information and 158s 'citation()' on how to cite R or R packages in publications. 158s 158s Type 'demo()' for some demos, 'help()' for on-line help, or 158s 'help.start()' for an HTML browser interface to help. 158s Type 'q()' to quit R. 158s 158s > # Broyden banded function 158s > 158s > library(nleqslv) 158s > 158s > brdtri <- function(x) { 158s + n <- length(x) 158s + y <- numeric(n) 158s + 158s + # y[1] <- (3-2*x[1])*x[1] - 2*x[2] + 1 158s + # y[n] <- (3-2*x[n])*x[n] - x[n-1] + 1 158s + # 158s + # k <- 2:(n-1) 158s + # y[k] <- (3-2*x[k])*x[k] - x[k-1] - 2 * x[k+1] + 1 158s + # 158s + y <- (3-2*x)*x - c(0,x[-n]) - 2*c(x[-1],0) + 1 158s + y 158s + } 158s > 158s > brdtrijac <- function(x) { 158s + n <- length(x) 158s + J <- diag(3-4*x,n,n) 158s + J[row(J)==col(J)+1] <- -1 158s + J[row(J)==col(J)-1] <- -2 158s + J 158s + } 158s > 158s > options(echo=TRUE) 158s > 158s > n <- 10 158s > xstart <- -rep(1,n) 158s > fstart <- brdtri(xstart) 158s > 158s > z0 <- nleqslv(xstart,brdtri, method="Newton", global="dbldog") 158s > z0$message 158s [1] "Function criterion near zero" 158s > 158s > z1 <- nleqslv(xstart,brdtri, brdtrijac, method="Newton", global="dbldog",control=list(trace=0)) 158s > z1$message 158s [1] "Function criterion near zero" 158s > all.equal(z1$x,z0$x) 158s [1] TRUE 158s > 158s > z2 <- nleqslv(xstart,brdtri, brdtrijac, method="Newton", global="dbldog",control=list(trace=0,chkjac=TRUE)) 158s > z2$message 158s [1] "Function criterion near zero" 158s > all.equal(z2$x,z0$x) 158s [1] TRUE 158s > 158s > z3 <- nleqslv(xstart,brdtri, brdtrijac, method="Newton", global="dbldog",control=list(trace=0,dsub=1,dsuper=1)) 158s > z3$message 158s [1] "Function criterion near zero" 158s > all.equal(z2$x,z0$x) 158s [1] TRUE 158s > 158s > z4 <- nleqslv(xstart,brdtri, brdtrijac, method="Newton", global="dbldog",control=list(trace=0,dsub=1,dsuper=1,chkjac=TRUE)) 158s > z4$message 158s [1] "Function criterion near zero" 158s > all.equal(z2$x,z0$x) 158s [1] TRUE 158s > 158s BEGIN TEST tests/chquad.R 158s 158s R version 4.4.3 (2025-02-28) -- "Trophy Case" 158s Copyright (C) 2025 The R Foundation for Statistical Computing 158s Platform: s390x-ibm-linux-gnu 158s 158s R is free software and comes with ABSOLUTELY NO WARRANTY. 158s You are welcome to redistribute it under certain conditions. 158s Type 'license()' or 'licence()' for distribution details. 158s 158s R is a collaborative project with many contributors. 158s Type 'contributors()' for more information and 158s 'citation()' on how to cite R or R packages in publications. 158s 158s Type 'demo()' for some demos, 'help()' for on-line help, or 158s 'help.start()' for an HTML browser interface to help. 158s Type 'q()' to quit R. 158s 158s > 158s > # Chebyquad functions (no solution for n=8) 158s > 158s > library("nleqslv") 158s > 158s > chebyquad <- function(x) { 158s + n <- length(x) 158s + y <- numeric(n) 158s + 158s + for(j in 1:n) { 158s + t1 <- 1.0 158s + t2 <- 2.0*x[j] - 1.0 158s + tmp <- 2.0*t2 158s + 158s + for(i in 1:n) { 158s + y[i] <- y[i] + t2 158s + t3 <- tmp * t2 - t1 158s + t1 <- t2 158s + t2 <- t3 158s + } 158s + } 158s + 158s + y = y / n 158s + 158s + for(i in 1:n) { 158s + if ( i%%2 == 0 ) { 158s + y[i] = y[i] + 1.0 / (i * i - 1) 158s + } 158s + } 158s + 158s + y 158s + } 158s > 158s > chebyinit <- function(n) { 158s + x <- (1:n) / (n + 1) 158s + } 158s > 158s > for (n in c(1:7,9)) { # exclude n=8 since there is no solution 158s + xstart <- chebyinit(n) 158s + fstart <- chebyquad(xstart) 158s + 158s + zz <- nleqslv(xstart, chebyquad, global="dbldog", 158s + control=list(ftol=1e-8,xtol=1e-8,trace=0,btol=.01,delta=-2)) 158s + print(all(abs(zz$fvec)<=1e-8)) 158s + } 158s [1] TRUE 158s [1] TRUE 158s [1] TRUE 158s [1] TRUE 158s [1] TRUE 158s [1] TRUE 158s [1] TRUE 158s [1] TRUE 158s > 158s > for (n in c(1:7,9)) { # exclude n=8 since there is no solution 158s + xstart <- chebyinit(n) 158s + fstart <- chebyquad(xstart) 158s + 158s + zz <- nleqslv(xstart, chebyquad, global="dbldog", method="Newton", 158s + control=list(ftol=1e-8,xtol=1e-8,trace=0,btol=.01,delta=-2)) 158s + print(all(abs(zz$fvec)<=1e-8)) 158s + } 158s [1] TRUE 158s [1] TRUE 158s [1] TRUE 158s [1] TRUE 158s [1] TRUE 158s [1] TRUE 158s [1] TRUE 158s [1] TRUE 158s > 158s BEGIN TEST tests/control-try.R 158s 158s R version 4.4.3 (2025-02-28) -- "Trophy Case" 158s Copyright (C) 2025 The R Foundation for Statistical Computing 158s Platform: s390x-ibm-linux-gnu 158s 158s R is free software and comes with ABSOLUTELY NO WARRANTY. 158s You are welcome to redistribute it under certain conditions. 158s Type 'license()' or 'licence()' for distribution details. 158s 158s R is a collaborative project with many contributors. 158s Type 'contributors()' for more information and 158s 'citation()' on how to cite R or R packages in publications. 158s 158s Type 'demo()' for some demos, 'help()' for on-line help, or 158s 'help.start()' for an HTML browser interface to help. 158s Type 'q()' to quit R. 158s 158s > 158s > library(nleqslv) 158s > 158s > # Dennis Schnabel example 6.5.1 page 149 158s > f <- function(x) { 158s + y <- numeric(2) 158s + y[1] <- x[1]^2 + x[2]^2 - 2 158s + y[2] <- exp(x[1]-1) + x[2]^3 - 2 158s + y 158s + } 158s > 158s > # check error handling in control argument 158s > try(nleqslv(f,control=list(1e-3))) 158s Error in nleqslv(f, control = list(0.001)) : 158s 'control' argument must be a named list 158s > try(nleqslv(f,control=list(f=1e-3))) 158s > try(nleqslv(f,control=list(f=1e-7,b=1e-3))) 158s Error in nleqslv(f, control = list(f = 0.001)) : 158s unknown names in control: 'f' 158s > 158s Error in nleqslv(f, control = list(f = 1e-07, b = 0.001)) : 158s unknown names in control: 'f', 'b' 158s BEGIN TEST tests/dslnex.R 158s 158s R version 4.4.3 (2025-02-28) -- "Trophy Case" 158s Copyright (C) 2025 The R Foundation for Statistical Computing 158s Platform: s390x-ibm-linux-gnu 158s 158s R is free software and comes with ABSOLUTELY NO WARRANTY. 158s You are welcome to redistribute it under certain conditions. 158s Type 'license()' or 'licence()' for distribution details. 158s 158s R is a collaborative project with many contributors. 158s Type 'contributors()' for more information and 158s 'citation()' on how to cite R or R packages in publications. 158s 158s Type 'demo()' for some demos, 'help()' for on-line help, or 158s 'help.start()' for an HTML browser interface to help. 158s Type 'q()' to quit R. 158s 158s > 158s > library("nleqslv") 158s > 158s > # Dennis & Schnabel,1996,"Numerical methods for unconstrained optimization and nonlinear equations", SIAM 158s > # example 6.5.1 page 149 158s > 158s > dslnex <- function(x) { 158s + y <- numeric(2) 158s + y[1] <- x[1]^2 + x[2]^2 - 2 158s + y[2] <- exp(x[1]-1) + x[2]^3 - 2 158s + y 158s + } 158s > 158s > jacdsln <- function(x) { 158s + n <- length(x) 158s + Df <- matrix(numeric(n*n),n,n) 158s + Df[1,1] <- 2*x[1] 158s + Df[1,2] <- 2*x[2] 158s + Df[2,1] <- exp(x[1]-1) 158s + Df[2,2] <- 3*x[2]^2 158s + 158s + Df 158s + } 158s > 158s > xstart <- c(2,0.5) 158s > fstart <- dslnex(xstart) 158s > xstart 158s [1] 2.0 0.5 158s > fstart 158s [1] 2.2500000 0.8432818 158s > 158s > # a solution is c(1,1) 158s > 158s > do.print.xf <- FALSE 158s > 158s > print.result <- function(z) { 158s + if( do.print.xf ) { 158s + print(z$x) 158s + print(z$fvec) 158s + } 158s + print(z$message) 158s + print(all(abs(z$fvec)<=1e-8)) 158s + } 158s > 158s > # Broyden numerical Jacobian 158s > for( z in c("cline", "qline", "gline") ) { # cubic, quadratic, geometric linesearch 158s + znlq <- nleqslv(xstart, dslnex, global=z,control=list(btol=.01)) 158s + print.result(znlq) 158s + } 158s [1] "Function criterion near zero" 158s [1] TRUE 158s [1] "Function criterion near zero" 158s [1] TRUE 158s [1] "Function criterion near zero" 158s [1] TRUE 158s > 158s > # Broyden numerical Jacobian 158s > for( z in c("dbldog","pwldog") ) { # double dogleg, Powell (single) dogleg 158s + for( delta in c(-1.0, -2.0) ) { # Cauchy step , Newton step 158s + znlq <- nleqslv(xstart, dslnex, global=z, control=list(btol=.01,delta=delta)) 158s + print.result(znlq) 158s + } 158s + } 158s [1] "Function criterion near zero" 158s [1] TRUE 158s [1] "Function criterion near zero" 158s [1] TRUE 158s [1] "Function criterion near zero" 158s [1] TRUE 158s [1] "Function criterion near zero" 158s [1] TRUE 158s > 158s > # Broyden analytical jacobian 158s > for( z in c("dbldog","pwldog") ) { # double dogleg, Powell (single) dogleg 158s + for( delta in c(-1.0, -2.0) ) { # Cauchy step , Newton step 158s + znlq <- nleqslv(xstart, dslnex, jacdsln, global=z, control=list(btol=.01,delta=delta)) 158s + print.result(znlq) 158s + } 158s + } 158s [1] "Function criterion near zero" 158s [1] TRUE 158s [1] "Function criterion near zero" 158s [1] TRUE 158s [1] "Function criterion near zero" 158s [1] TRUE 158s [1] "Function criterion near zero" 158s [1] TRUE 158s > 158s > # Newton analytical jacobian 158s > for( z in c("dbldog","pwldog") ) { # double dogleg, Powell (single) dogleg 158s + for( delta in c(-1.0, -2.0) ) { # Cauchy step , Newton step 158s + znlq <- nleqslv(xstart, dslnex, jacdsln, method="Newton", global=z, control=list(btol=.01,delta=delta)) 158s + print.result(znlq) 158s + } 158s + } 158s [1] "Function criterion near zero" 158s [1] TRUE 158s [1] "Function criterion near zero" 158s [1] TRUE 158s [1] "Function criterion near zero" 158s [1] TRUE 158s [1] "Function criterion near zero" 158s [1] TRUE 158s > 158s BEGIN TEST tests/dslnexCN.R 158s 158s R version 4.4.3 (2025-02-28) -- "Trophy Case" 158s Copyright (C) 2025 The R Foundation for Statistical Computing 158s Platform: s390x-ibm-linux-gnu 158s 158s R is free software and comes with ABSOLUTELY NO WARRANTY. 158s You are welcome to redistribute it under certain conditions. 158s Type 'license()' or 'licence()' for distribution details. 158s 158s R is a collaborative project with many contributors. 158s Type 'contributors()' for more information and 158s 'citation()' on how to cite R or R packages in publications. 158s 158s Type 'demo()' for some demos, 'help()' for on-line help, or 158s 'help.start()' for an HTML browser interface to help. 158s Type 'q()' to quit R. 158s 158s > 158s > library("nleqslv") 158s > 158s > # Dennis & Schnabel,1996,"Numerical methods for unconstrained optimization and nonlinear equations", SIAM 158s > # example 6.5.1 page 149 158s > 158s > dslnex <- function(x) { 158s + y <- numeric(2) 158s + y[1] <- x[1]^2 + x[2]^2 - 2 158s + y[2] <- exp(x[1]-1) + x[2]^3 - 2 158s + y 158s + } 158s > 158s > 158s > xstart <- c(2,0.5) 158s > fstart <- dslnex(xstart) 158s > xstart 158s [1] 2.0 0.5 158s > fstart 158s [1] 2.2500000 0.8432818 158s > 158s > do.print.xf <- TRUE 158s > 158s > print.result <- function(z) { 158s + if( do.print.xf ) { 158s + print(z$x) 158s + print(z$fvec) 158s + } 158s + print(z$message) 158s + print(all(abs(z$fvec)<=1e-8)) 158s + } 158s > 158s > sink("dslnexCN-num.txt") 158s > for( z in c("dbldog","pwldog") ) { # double dogleg, Powell (single) dogleg 158s + for( delta in c(-1.0, -2.0) ) { # Cauchy step , Newton step 158s + znlq <- nleqslv(xstart, dslnex, global=z, control=list(btol=.01,delta=delta, trace=1)) 158s + print.result(znlq) 158s + } 158s + } 158s > sink() 158s > 158s > sink("dslnexCN-char.txt") 158s > for( z in c("dbldog","pwldog") ) { # double dogleg, Powell (single) dogleg 158s + for( delta in c("cauchy", "newton") ) { # Cauchy step , Newton step 158s + znlq <- nleqslv(xstart, dslnex, global=z, control=list(btol=.01,delta=delta,trace=1)) 158s + print.result(znlq) 158s + } 158s + } 158s > sink() 158s > 158s > z1 <- readLines(con="dslnexCN-num.txt") 158s > z2 <- readLines(con="dslnexCN-char.txt") 158s > 158s > all.equal(z1,z2) 158s [1] TRUE 158s > 158s BEGIN TEST tests/dslnexHook.R 158s 158s R version 4.4.3 (2025-02-28) -- "Trophy Case" 158s Copyright (C) 2025 The R Foundation for Statistical Computing 158s Platform: s390x-ibm-linux-gnu 158s 158s R is free software and comes with ABSOLUTELY NO WARRANTY. 158s You are welcome to redistribute it under certain conditions. 158s Type 'license()' or 'licence()' for distribution details. 158s 158s R is a collaborative project with many contributors. 158s Type 'contributors()' for more information and 158s 'citation()' on how to cite R or R packages in publications. 158s 158s Type 'demo()' for some demos, 'help()' for on-line help, or 158s 'help.start()' for an HTML browser interface to help. 158s Type 'q()' to quit R. 158s 158s > 158s > library(nleqslv) 159s > 159s > # Dennis & Schnabel,1996,"Numerical methods for unconstrained optimization and nonlinear equations", SIAM 159s > # example 6.5.1 page 149 159s > 159s > dslnex <- function(x) { 159s + y <- numeric(2) 159s + y[1] <- x[1]^2 + x[2]^2 - 2 159s + y[2] <- exp(x[1]-1) + x[2]^3 - 2 159s + y 159s + } 159s > 159s > 159s > do.print.xf <- FALSE 159s > do.trace <- 0 159s > print.result <- function(z) { 159s + if( do.print.xf ) { 159s + print(z$x) 159s + print(z$fvec) 159s + } 159s + print(z$message) 159s + print(all(abs(z$fvec)<=1e-8)) 159s + } 159s > 159s > xcmp.result <- function(z1,z2) all(abs(z1$x-z2$x) <= 1e-8) 159s > 159s > xstart <- c(2,0.5) 159s > hnlq1 <- nleqslv(xstart, dslnex, global="hook", control=list(btol=.01,delta="cauchy", trace=do.trace)) 159s > hnlq2 <- nleqslv(xstart, dslnex, global="hook", control=list(btol=.01,delta="newton", trace=do.trace)) 159s > print.result(hnlq1) 159s [1] "Function criterion near zero" 159s [1] TRUE 159s > print.result(hnlq2) 159s [1] "Function criterion near zero" 159s [1] TRUE 159s > xcmp.result(hnlq1,hnlq2) 159s [1] TRUE 159s > 159s > dnlq1 <- nleqslv(xstart, dslnex, global="dbldog", control=list(btol=.01,delta="cauchy", trace=do.trace)) 159s > dnlq2 <- nleqslv(xstart, dslnex, global="dbldog", control=list(btol=.01,delta="newton", trace=do.trace)) 159s > print.result(dnlq1) 159s [1] "Function criterion near zero" 159s [1] TRUE 159s > print.result(dnlq2) 159s [1] "Function criterion near zero" 159s [1] TRUE 159s > xcmp.result(dnlq1,dnlq2) 159s [1] TRUE 159s > xcmp.result(hnlq1,dnlq1) 159s [1] TRUE 159s > 159s > xstart <- c(1.1,1.1) 159s > hnlq1 <- nleqslv(xstart, dslnex, global="hook", control=list(btol=.01,delta="cauchy", trace=do.trace)) 159s > hnlq2 <- nleqslv(xstart, dslnex, global="hook", control=list(btol=.01,delta="newton", trace=do.trace)) 159s > print.result(hnlq1) 159s [1] "Function criterion near zero" 159s [1] TRUE 159s > print.result(hnlq2) 159s [1] "Function criterion near zero" 159s [1] TRUE 159s > xcmp.result(hnlq1,hnlq2) 159s [1] TRUE 159s > 159s > dnlq1 <- nleqslv(xstart, dslnex, global="dbldog", control=list(btol=.01,delta="cauchy", trace=do.trace)) 159s > dnlq2 <- nleqslv(xstart, dslnex, global="dbldog", control=list(btol=.01,delta="newton", trace=do.trace)) 159s > print.result(dnlq1) 159s [1] "Function criterion near zero" 159s [1] TRUE 159s > print.result(dnlq2) 159s [1] "Function criterion near zero" 159s [1] TRUE 159s > xcmp.result(dnlq1,dnlq2) 159s [1] TRUE 159s > xcmp.result(hnlq1,dnlq1) 159s [1] TRUE 159s > 159s BEGIN TEST tests/dslnexauto.R 159s 159s R version 4.4.3 (2025-02-28) -- "Trophy Case" 159s Copyright (C) 2025 The R Foundation for Statistical Computing 159s Platform: s390x-ibm-linux-gnu 159s 159s R is free software and comes with ABSOLUTELY NO WARRANTY. 159s You are welcome to redistribute it under certain conditions. 159s Type 'license()' or 'licence()' for distribution details. 159s 159s R is a collaborative project with many contributors. 159s Type 'contributors()' for more information and 159s 'citation()' on how to cite R or R packages in publications. 159s 159s Type 'demo()' for some demos, 'help()' for on-line help, or 159s 'help.start()' for an HTML browser interface to help. 159s Type 'q()' to quit R. 159s 159s > # Dennis Schnabel example 159s > 159s > library("nleqslv") 159s > 159s > dslnex <- function(x) { 159s + y <- numeric(2) 159s + y[1] <- x[1]^2 + x[2]^2 - 2 159s + y[2] <- exp(x[1]-1) + x[2]^3 - 2 159s + y 159s + } 159s > 159s > jacdsln <- function(x) { 159s + n <- length(x) 159s + Df <- matrix(numeric(n*n),n,n) 159s + Df[1,1] <- 2*x[1] 159s + Df[1,2] <- 2*x[2] 159s + Df[2,1] <- exp(x[1]-1) 159s + Df[2,2] <- 3*x[2]^2 159s + 159s + Df 159s + } 159s > 159s > xstart <- c(2,0.5) 159s > fstart <- dslnex(xstart) 159s > xstart 159s [1] 2.0 0.5 159s > fstart 159s [1] 2.2500000 0.8432818 159s > 159s > # a solution is c(1,1) 159s > 159s > do.print.xf <- FALSE 159s > 159s > print.result <- function(z) { 159s + if( do.print.xf ) { 159s + print(z$x) 159s + print(z$fvec) 159s + } 159s + print(z$message) 159s + print(all(abs(z$fvec)<=1e-8)) 159s + } 159s > 159s > # Use automatic scaling of x-values. Dosn't always work. 159s > 159s > # Broyden numerical Jacobian 159s > for( z in c("qline", "gline") ) { # quadratic, geometric linesearch 159s + znlq <- nleqslv(xstart, dslnex, global=z,xscalm="auto",control=list(btol=.01)) 159s + print.result(znlq) 159s + } 159s [1] "Function criterion near zero" 159s [1] TRUE 159s [1] "Function criterion near zero" 159s [1] TRUE 159s > 159s > # Broyden numerical Jacobian 159s > for( z in c("dbldog","pwldog") ) { # double dogleg, Powell (single) dogleg 159s + for( delta in c(-1.0, -2.0) ) { # Cauchy step , Newton step 159s + znlq <- nleqslv(xstart, dslnex, global=z,xscalm="auto", control=list(btol=.01,delta=delta)) 159s + print.result(znlq) 159s + } 159s + } 159s [1] "Function criterion near zero" 159s [1] TRUE 159s [1] "No better point found (algorithm has stalled)" 159s [1] FALSE 159s [1] "Function criterion near zero" 159s [1] TRUE 159s [1] "No better point found (algorithm has stalled)" 159s [1] FALSE 159s > 159s > # Broyden analytical jacobian 159s > for( z in c("dbldog","pwldog") ) { # double dogleg, Powell (single) dogleg 159s + for( delta in c(-1.0, -2.0) ) { # Cauchy step , Newton step 159s + znlq <- nleqslv(xstart, dslnex, jacdsln, global=z,xscalm="auto", control=list(btol=.01,delta=delta)) 159s + print.result(znlq) 159s + } 159s + } 159s [1] "Function criterion near zero" 159s [1] TRUE 159s [1] "No better point found (algorithm has stalled)" 159s [1] FALSE 159s [1] "Function criterion near zero" 159s [1] TRUE 159s [1] "No better point found (algorithm has stalled)" 159s [1] FALSE 159s > 159s > # Newton analytical jacobian 159s > for( z in c("dbldog","pwldog") ) { # double dogleg, Powell (single) dogleg 159s + for( delta in c(-1.0, -2.0) ) { # Cauchy step , Newton step 159s + znlq <- nleqslv(xstart, dslnex, jacdsln, method="Newton", global=z,xscalm="auto", control=list(btol=.01,delta=delta)) 159s + print.result(znlq) 159s + } 159s + } 159s [1] "No better point found (algorithm has stalled)" 159s [1] FALSE 159s [1] "No better point found (algorithm has stalled)" 159s [1] FALSE 159s [1] "No better point found (algorithm has stalled)" 159s [1] FALSE 159s [1] "No better point found (algorithm has stalled)" 159s [1] FALSE 159s > 159s BEGIN TEST tests/dslnexjacout.R 159s 159s R version 4.4.3 (2025-02-28) -- "Trophy Case" 159s Copyright (C) 2025 The R Foundation for Statistical Computing 159s Platform: s390x-ibm-linux-gnu 159s 159s R is free software and comes with ABSOLUTELY NO WARRANTY. 159s You are welcome to redistribute it under certain conditions. 159s Type 'license()' or 'licence()' for distribution details. 159s 159s R is a collaborative project with many contributors. 159s Type 'contributors()' for more information and 159s 'citation()' on how to cite R or R packages in publications. 159s 159s Type 'demo()' for some demos, 'help()' for on-line help, or 159s 'help.start()' for an HTML browser interface to help. 159s Type 'q()' to quit R. 159s 159s > # Dennis & Schnabel,1996,"Numerical methods for unconstrained optimization and nonlinear equations", SIAM 159s > # example 6.5.1 page 149 159s > 159s > library(nleqslv) 159s > 159s > dslnex <- function(x) { 159s + y <- numeric(2) 159s + y[1] <- x[1]^2 + x[2]^2 - 2 159s + y[2] <- exp(x[1]-1) + x[2]^3 - 2 159s + y 159s + } 159s > 159s > jacdsln <- function(x) { 159s + n <- length(x) 159s + Df <- matrix(numeric(n*n),n,n) 159s + Df[1,1] <- 2*x[1] 159s + Df[1,2] <- 2*x[2] 159s + Df[2,1] <- exp(x[1]-1) 159s + Df[2,2] <- 3*x[2]^2 159s + 159s + Df 159s + } 159s > 159s > do.print.xf <- FALSE 159s > do.trace <- 0 159s > 159s > print.result <- function(z) { 159s + if( do.print.xf ) { 159s + print(z$x) 159s + print(z$fvec) 159s + } 159s + print(z$message) 159s + print(all(abs(z$fvec)<=1e-8)) 159s + } 159s > 159s > xstart <- c(2,.5) 159s > 159s > z <- nleqslv(xstart,dslnex, jacobian=TRUE, control=list(trace=do.trace)) 159s > print.result(z) 159s [1] "Function criterion near zero" 159s [1] TRUE 159s > all.equal(z$jac,jacdsln(z$x), tolerance=0.05) 159s [1] TRUE 159s > 159s > z <- nleqslv(xstart,dslnex,jacdsln, jacobian=TRUE, control=list(trace=do.trace)) 159s > print.result(z) 159s [1] "Function criterion near zero" 159s [1] TRUE 159s > all.equal(z$jac,jacdsln(z$x), tolerance=0.05) 159s [1] TRUE 159s > 159s > z <- nleqslv(xstart,dslnex, method="Newton", jacobian=TRUE, control=list(trace=do.trace)) 159s > print.result(z) 159s [1] "Function criterion near zero" 159s [1] TRUE 159s > all.equal(z$jac,jacdsln(z$x), tolerance=10^3*.Machine$double.eps^0.5) 159s [1] TRUE 159s > 159s > z <- nleqslv(xstart,dslnex, jacdsln, method="Newton", jacobian=TRUE, control=list(trace=do.trace)) 159s > print.result(z) 159s [1] "Function criterion near zero" 159s [1] TRUE 159s > identical(z$jac,jacdsln(z$x)) 159s [1] TRUE 159s > 159s BEGIN TEST tests/dslnexscaled.R 159s 159s R version 4.4.3 (2025-02-28) -- "Trophy Case" 159s Copyright (C) 2025 The R Foundation for Statistical Computing 159s Platform: s390x-ibm-linux-gnu 159s 159s R is free software and comes with ABSOLUTELY NO WARRANTY. 159s You are welcome to redistribute it under certain conditions. 159s Type 'license()' or 'licence()' for distribution details. 159s 159s R is a collaborative project with many contributors. 159s Type 'contributors()' for more information and 159s 'citation()' on how to cite R or R packages in publications. 159s 159s Type 'demo()' for some demos, 'help()' for on-line help, or 159s 'help.start()' for an HTML browser interface to help. 159s Type 'q()' to quit R. 159s 159s > # Dennis Schnabel example 159s > 159s > library("nleqslv") 159s > 159s > dslnex <- function(x) { 159s + y <- numeric(2) 159s + y[1] <- x[1]^2 + x[2]^2 - 2 159s + y[2] <- exp(x[1]-1) + x[2]^3 - 2 159s + y 159s + } 159s > 159s > jacdsln <- function(x) { 159s + n <- length(x) 159s + Df <- matrix(numeric(n*n),n,n) 159s + Df[1,1] <- 2*x[1] 159s + Df[1,2] <- 2*x[2] 159s + Df[2,1] <- exp(x[1]-1) 159s + Df[2,2] <- 3*x[2]^2 159s + 159s + Df 159s + } 159s > 159s > xstart <- c(2,0.5) 159s > fstart <- dslnex(xstart) 159s > xstart 159s [1] 2.0 0.5 159s > fstart 159s [1] 2.2500000 0.8432818 159s > 159s > # a solution is c(1,1) 159s > 159s > do.print.xf <- FALSE 159s > 159s > print.result <- function(z) { 159s + if( do.print.xf ) { 159s + print(z$x) 159s + print(z$fvec) 159s + } 159s + print(z$message) 159s + print(all(abs(z$fvec)<=1e-8)) 159s + } 159s > 159s > # Use our fixed scaling 159s > 159s > znlq <- nleqslv(xstart, dslnex, jacdsln, global="dbldog", control=list(btol=.01,delta=-1.0,chkjac=TRUE,scalex=c(2,3))) 159s > if(znlq$termcd == -10) stop("Internal error in check analytical jacobian") 159s > 159s > # Broyden analytical jacobian 159s > for( z in c("dbldog","pwldog") ) { # double dogleg, Powell (single) dogleg 159s + for( delta in c(-1.0, -2.0) ) { # Cauchy step , Newton step 159s + znlq <- nleqslv(xstart, dslnex, jacdsln, global=z, control=list(btol=.01,delta=delta,chkjac=TRUE,scalex=c(2,3))) 159s + print.result(znlq) 159s + } 159s + } 159s [1] "Function criterion near zero" 159s [1] TRUE 159s [1] "Function criterion near zero" 159s [1] TRUE 159s [1] "Function criterion near zero" 159s [1] TRUE 159s [1] "Function criterion near zero" 159s [1] TRUE 159s > 159s > # Newton analytical jacobian 159s > for( z in c("dbldog","pwldog") ) { # double dogleg, Powell (single) dogleg 159s + for( delta in c(-1.0, -2.0) ) { # Cauchy step , Newton step 159s + znlq <- nleqslv(xstart, dslnex, jacdsln, method="Newton", global=z, control=list(btol=.01,delta=delta,chkjac=TRUE,scalex=c(2,3))) 159s + print.result(znlq) 159s + } 159s + } 159s [1] "Function criterion near zero" 159s [1] TRUE 159s [1] "Function criterion near zero" 159s [1] TRUE 159s [1] "Function criterion near zero" 159s [1] TRUE 159s [1] "Function criterion near zero" 159s [1] TRUE 159s > 159s BEGIN TEST tests/singular1.R 159s 159s R version 4.4.3 (2025-02-28) -- "Trophy Case" 159s Copyright (C) 2025 The R Foundation for Statistical Computing 159s Platform: s390x-ibm-linux-gnu 159s 159s R is free software and comes with ABSOLUTELY NO WARRANTY. 159s You are welcome to redistribute it under certain conditions. 159s Type 'license()' or 'licence()' for distribution details. 159s 159s R is a collaborative project with many contributors. 159s Type 'contributors()' for more information and 159s 'citation()' on how to cite R or R packages in publications. 159s 159s Type 'demo()' for some demos, 'help()' for on-line help, or 159s 'help.start()' for an HTML browser interface to help. 159s Type 'q()' to quit R. 159s 159s > 159s > library(nleqslv) 159s > 159s > # Brown almost linear function 159s > 159s > brown <- function(x) { 159s + n <- length(x) 159s + y <- numeric(n) 159s + 159s + y[1:(n-1)] <- x[1:(n-1)] + sum(x[1:n]) - (n + 1) 159s + y[n] <- prod(x[1:n]) - 1.0 159s + 159s + y 159s + } 159s > 159s > brownjac <- function(x) { 159s + n <- length(x) 159s + J <- matrix(1,nrow=n,ncol=n) 159s + diag(J) <- 2 159s + xprod <- prod(x) 159s + J[n,] <- xprod/x # exact 159s + J 159s + } 159s > 159s > print.result <- function(z, do.print.xf=FALSE) { 159s + if( do.print.xf ) { 159s + print(z$x) 159s + print(z$fvec) 159s + } 159s + print(z$message) 159s + print(all(abs(z$fvec)<=1e-8)) 159s + } 159s > 159s > for( m in c("Newton","Broyden") ) { 159s + for( n in c(50,100) ) { 159s + xstart <- rep(1,n)/2 159s + z <- nleqslv(xstart, brown, brownjac, method="Newton", 159s + control=list(trace=0,ftol=1e-10,delta="cauchy",allowSingular=TRUE)) 159s + print.result(z) 159s + } 159s + } 159s [1] "Function criterion near zero" 159s [1] TRUE 159s [1] "Function criterion near zero" 159s [1] TRUE 159s [1] "Function criterion near zero" 159s [1] TRUE 159s [1] "Function criterion near zero" 159s [1] TRUE 159s > 159s BEGIN TEST tests/singular2.R 159s 159s R version 4.4.3 (2025-02-28) -- "Trophy Case" 159s Copyright (C) 2025 The R Foundation for Statistical Computing 159s Platform: s390x-ibm-linux-gnu 159s 159s R is free software and comes with ABSOLUTELY NO WARRANTY. 159s You are welcome to redistribute it under certain conditions. 159s Type 'license()' or 'licence()' for distribution details. 159s 159s R is a collaborative project with many contributors. 159s Type 'contributors()' for more information and 159s 'citation()' on how to cite R or R packages in publications. 159s 159s Type 'demo()' for some demos, 'help()' for on-line help, or 159s 'help.start()' for an HTML browser interface to help. 159s Type 'q()' to quit R. 159s 159s > # http://stackoverflow.com/questions/29134996/solving-nonlinear-equation-in-r 159s > 159s > # wants to know if system has closed form solution 159s > # I want to see how nleqslv behaves 159s > 159s > set.seed(29) 159s > 159s > library(nleqslv) 159s > 159s > print.result <- function(z, do.print.xf=FALSE) { 159s + if( do.print.xf ) { 159s + print(z$x) 159s + print(z$fvec) 159s + } 159s + print(z$message) 159s + print(all(abs(z$fvec)<=1e-8)) 159s + } 159s > 159s > f <- function(X, a, b, c1, c2, c3) { 159s + Y <- numeric(3) 159s + x <- X[1] 159s + y <- X[2] 159s + z <- X[3] 159s + Y[1] <- x + y - x*y - c1 159s + Y[2] <- x + z - x*z - c2 159s + Y[3] <- a*y + b*z - c3 159s + return(Y) 159s + } 159s > 159s > Jac <- function(X, a, b, c1, c2, c3) { 159s + J <- matrix(0,nrow=3,ncol=3) 159s + x <- X[1] 159s + y <- X[2] 159s + z <- X[3] 159s + 159s + J[1,1] <- 1-y 159s + J[2,1] <- 1-z 159s + J[3,1] <- 0 159s + J[1,2] <- 1-x 159s + J[2,2] <- 0 159s + J[3,2] <- a 159s + J[1,3] <- 0 159s + J[2,3] <- 1-x 159s + J[3,3] <- b 159s + J 159s + } 159s > 159s > a <- 1 159s > b <- 1 159s > c1 <- 2 159s > c2 <- 3 159s > c3 <- 4 159s > 159s > # exact solution 159s > x <- (a*c1+b*c2-c3)/(a+b-c3) 159s > y <- (b*c1-b*c2-c1*c3+c3)/(-a*c1+a-b*c2+b) 159s > z <- (a*(c1-c2)+(c2-1)*c3)/(a*(c1-1)+b*(c2-1)) 159s > xsol <- c(x,y,z) 159s > 159s > X.start <- c(1,2,3) 159s > z1 <- nleqslv(X.start,f,Jac,a=a,b=b,c1=c1,c2=c2,c3=c3, 159s + method="Newton",control=list(trace=0,allowSingular=TRUE)) 159s > 159s > z2 <- nleqslv(X.start,f,Jac,a=a,b=b,c1=c1,c2=c2,c3=c3, 159s + method="Broyden",control=list(trace=0,allowSingular=TRUE)) 159s > 159s > all.equal(z1$x,xsol) 159s [1] TRUE 159s > all.equal(z2$x,xsol) 159s [1] TRUE 159s > print.result(z1) 159s [1] "Function criterion near zero" 159s [1] TRUE 159s > print.result(z2) 159s [1] "Function criterion near zero" 159s [1] TRUE 159s > 159s BEGIN TEST tests/singular3.R 160s 160s R version 4.4.3 (2025-02-28) -- "Trophy Case" 160s Copyright (C) 2025 The R Foundation for Statistical Computing 160s Platform: s390x-ibm-linux-gnu 160s 160s R is free software and comes with ABSOLUTELY NO WARRANTY. 160s You are welcome to redistribute it under certain conditions. 160s Type 'license()' or 'licence()' for distribution details. 160s 160s R is a collaborative project with many contributors. 160s Type 'contributors()' for more information and 160s 'citation()' on how to cite R or R packages in publications. 160s 160s Type 'demo()' for some demos, 'help()' for on-line help, or 160s 'help.start()' for an HTML browser interface to help. 160s Type 'q()' to quit R. 160s 160s > 160s > library(nleqslv) 160s > 160s > print.result <- function(z, do.print.xf=FALSE) { 160s + if( do.print.xf ) { 160s + print(z$x) 160s + print(z$fvec) 160s + } 160s + print(z$message) 160s + print(all(abs(z$fvec)<=1e-8)) 160s + } 160s > 160s > # Powell cautionary example 160s > # M.J.D. Powell, "A Hybrid Method for Nonlinear Equations", 160s > # in Numerical methods for Nonlinear Algebraic Equations, ed. P. Rabinowitz, 1970. 160s > 160s > 160s > f <- function(x) { 160s + y <- numeric(2) 160s + y[1] <- x[1] 160s + y[2] <- 10*x[1]/(x[1]+.1) + 2*x[2]^2 160s + 160s + y 160s + } 160s > 160s > jac <- function(x) { 160s + fjac <- matrix(0,nrow=2,ncol=2) 160s + 160s + fjac[1, 1] <- 1 160s + fjac[1, 2] <- 0 160s + fjac[2, 1] <- 1/(x[1]+0.1)^2 160s + fjac[2, 2] <- 4*x[2] 160s + 160s + fjac 160s + } 160s > 160s > xstart <- c(3,1) 160s > z1 <- nleqslv(xstart,f, method="Newton",control=list(trace=0,allowSingular=TRUE)) 160s > print.result(z1) 160s [1] "Function criterion near zero" 160s [1] TRUE 160s > xstart <- c(3,0) # singular start 160s > z2 <- nleqslv(xstart,f, method="Newton",control=list(trace=0,allowSingular=TRUE)) 160s > print.result(z2) 160s [1] "Function criterion near zero" 160s [1] TRUE 160s > 160s BEGIN TEST tests/trig.R 160s 160s R version 4.4.3 (2025-02-28) -- "Trophy Case" 160s Copyright (C) 2025 The R Foundation for Statistical Computing 160s Platform: s390x-ibm-linux-gnu 160s 160s R is free software and comes with ABSOLUTELY NO WARRANTY. 160s You are welcome to redistribute it under certain conditions. 160s Type 'license()' or 'licence()' for distribution details. 160s 160s R is a collaborative project with many contributors. 160s Type 'contributors()' for more information and 160s 'citation()' on how to cite R or R packages in publications. 160s 160s Type 'demo()' for some demos, 'help()' for on-line help, or 160s 'help.start()' for an HTML browser interface to help. 160s Type 'q()' to quit R. 160s 160s > 160s > library("nleqslv") 160s > 160s > # Trigonometric function 160s > trig <- function(x) { 160s + n <- length(x) 160s + y <- cos(x) 160s + s <- sum(y) 160s + y <- n - s + c(1:n) * (1-y) - sin(x) 160s + 160s + y 160s + } 160s > 160s > trigjac <- function(x) { 160s + n <- length(x) 160s + J <- matrix(numeric(n*n),n,n) 160s + 160s + for (p in 1:n) { 160s + J[,p] <- sin(x[p]) 160s + J[p,p] <- (p+1) * sin(x[p]) - cos(x[p]) 160s + } 160s + 160s + J 160s + } 160s > 160s > do.print.xf <- FALSE 160s > 160s > print.result <- function(z) { 160s + if( do.print.xf ) { 160s + print(z$x) 160s + print(z$fvec) 160s + } 160s + print(z$message) 160s + print(all(abs(z$fvec)<=1e-8)) 160s + } 160s > 160s > n <- 10 160s > xstart <- rep(1,n)/n 160s > fstart <- trig(xstart) 160s > 160s > znlm <- nleqslv(xstart, trig, global="dbldog", control=list(trace=0)) 160s > print.result(znlm) 160s [1] "Function criterion near zero" 160s [1] TRUE 160s > 160s BEGIN TEST tests/tscalargrad.R 160s 160s R version 4.4.3 (2025-02-28) -- "Trophy Case" 160s Copyright (C) 2025 The R Foundation for Statistical Computing 160s Platform: s390x-ibm-linux-gnu 160s 160s R is free software and comes with ABSOLUTELY NO WARRANTY. 160s You are welcome to redistribute it under certain conditions. 160s Type 'license()' or 'licence()' for distribution details. 160s 160s R is a collaborative project with many contributors. 160s Type 'contributors()' for more information and 160s 'citation()' on how to cite R or R packages in publications. 160s 160s Type 'demo()' for some demos, 'help()' for on-line help, or 160s 'help.start()' for an HTML browser interface to help. 160s Type 'q()' to quit R. 160s 160s > # http://r.789695.n4.nabble.com/newton-method-td2306111.html#a2306111 160s > # R-help, 29-07-2010: newton.method 160s > 160s > library(nleqslv) 160s > 160s > f <- function(x) 2.5*exp(-0.5*(2*0.045 - x)) + 2.5*exp(-0.045) + 2.5*exp(-1.5*x) - 100 160s > 160s > g1 <- function(x) 0.5*2.5*exp(-0.5*(2*0.045 - x)) - 1.5*2.5*exp(-1.5*x) 160s > g2 <- function(x) matrix(0.5*2.5*exp(-0.5*(2*0.045 - x)) - 1.5*2.5*exp(-1.5*x), nrow=1,ncol=1) 160s > 160s > xu.1 <- uniroot(f,c(-3,0), tol=1e-8)$root 160s > xu.2 <- uniroot(f,c( 6,8), tol=1e-8)$root 160s > 160s > xg1.1 <- nleqslv(-2,f,g1)$x 160s > xg2.1 <- nleqslv(-2,f,g2)$x 160s > 160s > xg1.2 <- nleqslv(8,f,g1)$x 160s > xg2.2 <- nleqslv(8,f,g2)$x 160s > 160s > all.equal(xg1.1, xu.1) 160s [1] TRUE 160s > all.equal(xg1.2, xu.2) 160s [1] TRUE 160s > all.equal(xg1.2, xg2.2) 160s [1] TRUE 160s > 160s > all.equal(xg2.1, xu.1) 160s [1] TRUE 160s > all.equal(xg2.2, xu.2) 160s [1] TRUE 160s > all.equal(xg1.2, xg2.2) 160s [1] TRUE 160s > 160s BEGIN TEST tests/xcutlip1p2.R 160s 160s R version 4.4.3 (2025-02-28) -- "Trophy Case" 160s Copyright (C) 2025 The R Foundation for Statistical Computing 160s Platform: s390x-ibm-linux-gnu 160s 160s R is free software and comes with ABSOLUTELY NO WARRANTY. 160s You are welcome to redistribute it under certain conditions. 160s Type 'license()' or 'licence()' for distribution details. 160s 160s R is a collaborative project with many contributors. 160s Type 'contributors()' for more information and 160s 'citation()' on how to cite R or R packages in publications. 160s 160s Type 'demo()' for some demos, 'help()' for on-line help, or 160s 'help.start()' for an HTML browser interface to help. 160s Type 'q()' to quit R. 160s 160s > # Steady-State solution for reaction rate equations 160s > # Shacham homotopy method (discrete changing of one or more parameters) 160s > # M. Shacham: Numerical Solution of Constrained Non-linear algebriac equations 160s > # International Journal for Numerical Methods in Engineering, 1986, pp.1455--1481. 160s > 160s > # solution should always be > 0 160s > 160s > library(nleqslv) 160s > 160s > RNGkind(kind="Wichmann-Hill") 160s > set.seed(123) 160s > 160s > # Problem 2, page 1463/1464 160s > 160s > cutlip <- function(x) { 160s + # paper has wrong order of parameters 160s + # use the Fortran program to get the correct values 160s + 160s + # parameter set 2 160s + k1 <- 17.721 160s + k2 <- 3.483 160s + k3 <- 505.051 160s + kr1<- 0.118 160s + kr2<- 0.033 160s + 160s + r <- numeric(6) 160s + 160s + r[1] = 1 - x[1] - k1*x[1]*x[6] + kr1 * x[4] 160s + r[2] = 1 - x[2] - k2*x[2]*x[6] + kr2 * x[5] 160s + r[3] = -x[3] + 2*k3*x[4]*x[5] 160s + r[4] = k1*x[1]*x[6] - kr1*x[4] - k3*x[4]*x[5] 160s + r[5] = 1.5*(k2*x[2]*x[6] - kr2*x[5]) - k3*x[4]*x[5] 160s + r[6] = 1 - x[4] - x[5] - x[6] 160s + 160s + r 160s + } 160s > 160s > 160s > Nrep <- 50 160s > xstart <- matrix(0,nrow=Nrep, ncol=6) 160s > xstart[,1] <- runif(Nrep,min=0,max=2) 160s > xstart[,2] <- runif(Nrep,min=0,max=1) 160s > xstart[,3] <- runif(Nrep,min=0,max=2) 160s > xstart[,4] <- runif(Nrep,min=0,max=1) 160s > xstart[,5] <- runif(Nrep,min=0,max=1) 160s > xstart[,6] <- runif(Nrep,min=0,max=1) 160s > 160s > ans <- searchZeros(xstart,cutlip, method="Broyden",global="dbldog") 160s > nrow(ans$x)==4 160s [1] TRUE 160s > all(ans$xfnorm <= 1e-10) 160s [1] TRUE 160s > 160s > zans <- searchZeros(ans$xstart,cutlip, method="Broyden",global="dbldog") 160s > length(zans$idxcvg)==4 160s [1] TRUE 160s > all(ans$xfnorm == zans$xfnorm) 160s [1] TRUE 160s > 160s BEGIN TEST tests/xnames.R 160s 160s R version 4.4.3 (2025-02-28) -- "Trophy Case" 160s Copyright (C) 2025 The R Foundation for Statistical Computing 160s Platform: s390x-ibm-linux-gnu 160s 160s R is free software and comes with ABSOLUTELY NO WARRANTY. 160s You are welcome to redistribute it under certain conditions. 160s Type 'license()' or 'licence()' for distribution details. 160s 160s R is a collaborative project with many contributors. 160s Type 'contributors()' for more information and 160s 'citation()' on how to cite R or R packages in publications. 160s 160s Type 'demo()' for some demos, 'help()' for on-line help, or 160s 'help.start()' for an HTML browser interface to help. 160s Type 'q()' to quit R. 160s 160s > 160s > library(nleqslv) 160s > 160s > f <- function(x) { 160s + y <-numeric(length(x)) 160s + y[1] <- x[1]^2 + x[2]^3 160s + y[2] <- x[1] + 2*x[2] + 3 160s + y 160s + } 160s > 160s > # test named x-values 160s > xstart <- c(a=1.0, b=0.5) 160s > xstart 160s a b 160s 1.0 0.5 160s > 160s > z <- nleqslv(xstart,f, control=list(trace=0)) 160s > all(names(z$x) == names(xstart)) 160s [1] TRUE 160s > 160s > # test named x-values 160s > xstart <- c(u=1.0, 0.5) 160s > xstart 160s u 160s 1.0 0.5 160s > 160s > z <- nleqslv(xstart,f, control=list(trace=0)) 160s > all(names(z$x) == names(xstart)) 160s [1] TRUE 160s > 160s BEGIN TEST tests/xsearchzeros.R 160s 160s R version 4.4.3 (2025-02-28) -- "Trophy Case" 160s Copyright (C) 2025 The R Foundation for Statistical Computing 160s Platform: s390x-ibm-linux-gnu 160s 160s R is free software and comes with ABSOLUTELY NO WARRANTY. 160s You are welcome to redistribute it under certain conditions. 160s Type 'license()' or 'licence()' for distribution details. 160s 160s R is a collaborative project with many contributors. 160s Type 'contributors()' for more information and 160s 'citation()' on how to cite R or R packages in publications. 160s 160s Type 'demo()' for some demos, 'help()' for on-line help, or 160s 'help.start()' for an HTML browser interface to help. 160s Type 'q()' to quit R. 160s 161s > # R. Baker Kearfott, Some tests of Generalized Bisection, 161s > # ACM Transactions on Methematical Software, Vol. 13, No. 3, 1987, pp 197-220 161s > 161s > # A high-degree polynomial system (section 4.3 Problem 12) 161s > # There are 12 real roots (and 126 complex roots to this system!) 161s > 161s > library(nleqslv) 161s > 161s > hdp <- function(x) { 161s + f <- numeric(length(x)) 161s + f[1] <- 5 * x[1]^9 - 6 * x[1]^5 * x[2]^2 + x[1] * x[2]^4 + 2 * x[1] * x[3] 161s + f[2] <- -2 * x[1]^6 * x[2] + 2 * x[1]^2 * x[2]^3 + 2 * x[2] * x[3] 161s + f[3] <- x[1]^2 + x[2]^2 - 0.265625 161s + f 161s + } 161s > 161s > 161s > N <- 40 161s > set.seed(123) 161s > xstart <- matrix(runif(3*N,min=-1,max=1), N, 3) # N starting values, each of length 3 161s > 161s > ans <- searchZeros(xstart,hdp, method="Broyden",global="dbldog") 161s > nrow(ans$x) == 12 161s [1] TRUE 161s > all(ans$xfnorm <= 1e-10) 161s [1] TRUE 161s > 161s > zans <- searchZeros(ans$xstart,hdp, method="Broyden",global="dbldog") 161s > length(zans$idxcvg) == 12 161s [1] TRUE 161s > 161s BEGIN TEST tests/xtestnslv.R 161s 161s R version 4.4.3 (2025-02-28) -- "Trophy Case" 161s Copyright (C) 2025 The R Foundation for Statistical Computing 161s Platform: s390x-ibm-linux-gnu 161s 161s R is free software and comes with ABSOLUTELY NO WARRANTY. 161s You are welcome to redistribute it under certain conditions. 161s Type 'license()' or 'licence()' for distribution details. 161s 161s R is a collaborative project with many contributors. 161s Type 'contributors()' for more information and 161s 'citation()' on how to cite R or R packages in publications. 161s 161s Type 'demo()' for some demos, 'help()' for on-line help, or 161s 'help.start()' for an HTML browser interface to help. 161s Type 'q()' to quit R. 161s 161s > 161s > library(nleqslv) 161s > 161s > # function to replace small number with OK or if not with NZ 161s > # this is to avoid differences in the Fnorm column between machines/cpu/os/compilers 161s > 161s > # the test is for checking that testnslv (still) works as expected 161s > 161s > fixsmall <- function(x) { 161s + z <- ifelse(x < .Machine$double.eps^(2/3), "OK","NZ") 161s + z <- ifelse(is.na(z), "NA", z) 161s + z 161s + } 161s > 161s > dslnex <- function(x) { 161s + y <- numeric(2) 161s + y[1] <- x[1]^2 + x[2]^2 - 2 161s + y[2] <- exp(x[1]-1) + x[2]^3 - 2 161s + y 161s + } 161s > xstart <- c(0.5,0.5) 161s > fstart <- dslnex(xstart) 161s > z <- testnslv(xstart,dslnex) 161s > zfn <- z$out[,"Fnorm"] 161s > z$out[,"Fnorm"] <- fixsmall(zfn) 161s > z 161s Call: 161s testnslv(x = xstart, fn = dslnex) 161s 161s Results: 161s Method Global termcd Fcnt Jcnt Iter Message Fnorm 161s 1 Newton cline 1 7 6 6 Fcrit OK 161s 2 Newton qline 1 7 6 6 Fcrit OK 161s 3 Newton gline 1 9 5 5 Fcrit OK 161s 4 Newton pwldog 1 7 6 6 Fcrit OK 161s 5 Newton dbldog 1 7 6 6 Fcrit OK 161s 6 Newton hook 1 7 6 6 Fcrit OK 161s 7 Newton none 1 8 8 8 Fcrit OK 161s 8 Broyden cline 1 12 1 9 Fcrit OK 161s 9 Broyden qline 1 12 1 9 Fcrit OK 161s 10 Broyden gline 1 14 1 10 Fcrit OK 161s 11 Broyden pwldog 1 12 1 10 Fcrit OK 161s 12 Broyden dbldog 1 12 1 10 Fcrit OK 161s 13 Broyden hook 1 12 1 10 Fcrit OK 161s 14 Broyden none 1 13 1 13 Fcrit OK 161s > 161s > # this will encounter an error 161s > xstart <- c(2.0,0.5) 161s > fstart <- dslnex(xstart) 161s > z <- testnslv(xstart,dslnex) 161s Error (method=Newton global=none): non-finite value(s) detected in jacobian (row=2,col=1) 161s > zfn <- z$out[,"Fnorm"] 161s > z$out[,"Fnorm"] <- fixsmall(zfn) 161s > z 161s Call: 161s testnslv(x = xstart, fn = dslnex) 161s 161s Results: 161s Method Global termcd Fcnt Jcnt Iter Message Fnorm 161s 1 Newton cline 1 11 7 7 Fcrit OK 161s 2 Newton qline 1 10 7 7 Fcrit OK 161s 3 Newton gline 1 17 7 7 Fcrit OK 161s 4 Newton pwldog 1 6 5 5 Fcrit OK 161s 5 Newton dbldog 1 6 5 5 Fcrit OK 161s 6 Newton hook 1 11 7 7 Fcrit OK 161s 7 Newton none NA NA NA NA ERROR NA 161s 8 Broyden cline 1 17 1 11 Fcrit OK 161s 9 Broyden qline 1 18 1 13 Fcrit OK 161s 10 Broyden gline 1 25 1 11 Fcrit OK 161s 11 Broyden pwldog 1 12 1 10 Fcrit OK 161s 12 Broyden dbldog 1 12 1 10 Fcrit OK 161s 13 Broyden hook 1 16 1 12 Fcrit OK 161s 14 Broyden none 4 20 1 20 Maxiter NZ 161s > 161s autopkgtest [18:15:38]: test generic: -----------------------] 162s generic PASS 162s autopkgtest [18:15:39]: test generic: - - - - - - - - - - results - - - - - - - - - - 162s autopkgtest [18:15:39]: test pkg-r-autopkgtest: preparing testbed 162s Reading package lists... 162s Building dependency tree... 162s Reading state information... 162s Starting pkgProblemResolver with broken count: 0 162s Starting 2 pkgProblemResolver with broken count: 0 162s Done 163s The following NEW packages will be installed: 163s build-essential cpp cpp-14 cpp-14-s390x-linux-gnu cpp-s390x-linux-gnu 163s dctrl-tools g++ g++-14 g++-14-s390x-linux-gnu g++-s390x-linux-gnu gcc gcc-14 163s gcc-14-s390x-linux-gnu gcc-s390x-linux-gnu gfortran gfortran-14 163s gfortran-14-s390x-linux-gnu gfortran-s390x-linux-gnu icu-devtools libasan8 163s libblas-dev libbz2-dev libcc1-0 libdeflate-dev libgcc-14-dev 163s libgfortran-14-dev libicu-dev libisl23 libitm1 libjpeg-dev 163s libjpeg-turbo8-dev libjpeg8-dev liblapack-dev liblzma-dev libmpc3 163s libncurses-dev libpcre2-16-0 libpcre2-32-0 libpcre2-dev libpcre2-posix3 163s libpkgconf3 libpng-dev libreadline-dev libstdc++-14-dev libtirpc-dev 163s libubsan1 pkg-r-autopkgtest pkgconf pkgconf-bin r-base-dev zlib1g-dev 163s 0 upgraded, 51 newly installed, 0 to remove and 0 not upgraded. 163s Need to get 82.3 MB of archives. 163s After this operation, 279 MB of additional disk space will be used. 163s Get:1 http://ftpmaster.internal/ubuntu plucky/main s390x libisl23 s390x 0.27-1 [704 kB] 163s Get:2 http://ftpmaster.internal/ubuntu plucky/main s390x libmpc3 s390x 1.3.1-1build2 [57.8 kB] 163s Get:3 http://ftpmaster.internal/ubuntu plucky/main s390x cpp-14-s390x-linux-gnu s390x 14.2.0-17ubuntu3 [9572 kB] 164s Get:4 http://ftpmaster.internal/ubuntu plucky/main s390x cpp-14 s390x 14.2.0-17ubuntu3 [1028 B] 164s Get:5 http://ftpmaster.internal/ubuntu plucky/main s390x cpp-s390x-linux-gnu s390x 4:14.2.0-1ubuntu1 [5556 B] 164s Get:6 http://ftpmaster.internal/ubuntu plucky/main s390x cpp s390x 4:14.2.0-1ubuntu1 [22.4 kB] 164s Get:7 http://ftpmaster.internal/ubuntu plucky/main s390x libcc1-0 s390x 15-20250222-0ubuntu1 [49.2 kB] 164s Get:8 http://ftpmaster.internal/ubuntu plucky/main s390x libitm1 s390x 15-20250222-0ubuntu1 [31.2 kB] 164s Get:9 http://ftpmaster.internal/ubuntu plucky/main s390x libasan8 s390x 15-20250222-0ubuntu1 [2970 kB] 164s Get:10 http://ftpmaster.internal/ubuntu plucky/main s390x libubsan1 s390x 15-20250222-0ubuntu1 [1212 kB] 164s Get:11 http://ftpmaster.internal/ubuntu plucky/main s390x libgcc-14-dev s390x 14.2.0-17ubuntu3 [1037 kB] 165s Get:12 http://ftpmaster.internal/ubuntu plucky/main s390x gcc-14-s390x-linux-gnu s390x 14.2.0-17ubuntu3 [18.7 MB] 166s Get:13 http://ftpmaster.internal/ubuntu plucky/main s390x gcc-14 s390x 14.2.0-17ubuntu3 [526 kB] 166s Get:14 http://ftpmaster.internal/ubuntu plucky/main s390x gcc-s390x-linux-gnu s390x 4:14.2.0-1ubuntu1 [1204 B] 166s Get:15 http://ftpmaster.internal/ubuntu plucky/main s390x gcc s390x 4:14.2.0-1ubuntu1 [5004 B] 166s Get:16 http://ftpmaster.internal/ubuntu plucky/main s390x libstdc++-14-dev s390x 14.2.0-17ubuntu3 [2611 kB] 166s Get:17 http://ftpmaster.internal/ubuntu plucky/main s390x g++-14-s390x-linux-gnu s390x 14.2.0-17ubuntu3 [11.0 MB] 167s Get:18 http://ftpmaster.internal/ubuntu plucky/main s390x g++-14 s390x 14.2.0-17ubuntu3 [21.8 kB] 167s Get:19 http://ftpmaster.internal/ubuntu plucky/main s390x g++-s390x-linux-gnu s390x 4:14.2.0-1ubuntu1 [956 B] 167s Get:20 http://ftpmaster.internal/ubuntu plucky/main s390x g++ s390x 4:14.2.0-1ubuntu1 [1080 B] 167s Get:21 http://ftpmaster.internal/ubuntu plucky/main s390x build-essential s390x 12.10ubuntu1 [4930 B] 167s Get:22 http://ftpmaster.internal/ubuntu plucky/main s390x dctrl-tools s390x 2.24-3build3 [106 kB] 167s Get:23 http://ftpmaster.internal/ubuntu plucky/main s390x libgfortran-14-dev s390x 14.2.0-17ubuntu3 [654 kB] 167s Get:24 http://ftpmaster.internal/ubuntu plucky/main s390x gfortran-14-s390x-linux-gnu s390x 14.2.0-17ubuntu3 [10.3 MB] 168s Get:25 http://ftpmaster.internal/ubuntu plucky/main s390x gfortran-14 s390x 14.2.0-17ubuntu3 [13.6 kB] 168s Get:26 http://ftpmaster.internal/ubuntu plucky/main s390x gfortran-s390x-linux-gnu s390x 4:14.2.0-1ubuntu1 [1012 B] 168s Get:27 http://ftpmaster.internal/ubuntu plucky/main s390x gfortran s390x 4:14.2.0-1ubuntu1 [1160 B] 168s Get:28 http://ftpmaster.internal/ubuntu plucky/main s390x icu-devtools s390x 76.1-1ubuntu2 [225 kB] 168s Get:29 http://ftpmaster.internal/ubuntu plucky/main s390x libblas-dev s390x 3.12.1-2 [254 kB] 168s Get:30 http://ftpmaster.internal/ubuntu plucky/main s390x libbz2-dev s390x 1.0.8-6 [39.1 kB] 168s Get:31 http://ftpmaster.internal/ubuntu plucky/main s390x libdeflate-dev s390x 1.23-1 [52.2 kB] 168s Get:32 http://ftpmaster.internal/ubuntu plucky/main s390x libicu-dev s390x 76.1-1ubuntu2 [12.2 MB] 169s Get:33 http://ftpmaster.internal/ubuntu plucky/main s390x libjpeg-turbo8-dev s390x 2.1.5-3ubuntu2 [281 kB] 169s Get:34 http://ftpmaster.internal/ubuntu plucky/main s390x libjpeg8-dev s390x 8c-2ubuntu11 [1484 B] 169s Get:35 http://ftpmaster.internal/ubuntu plucky/main s390x libjpeg-dev s390x 8c-2ubuntu11 [1484 B] 169s Get:36 http://ftpmaster.internal/ubuntu plucky/main s390x liblapack-dev s390x 3.12.1-2 [5967 kB] 169s Get:37 http://ftpmaster.internal/ubuntu plucky/main s390x libncurses-dev s390x 6.5+20250216-2 [407 kB] 169s Get:38 http://ftpmaster.internal/ubuntu plucky/main s390x libpcre2-16-0 s390x 10.45-1 [259 kB] 169s Get:39 http://ftpmaster.internal/ubuntu plucky/main s390x libpcre2-32-0 s390x 10.45-1 [245 kB] 169s Get:40 http://ftpmaster.internal/ubuntu plucky/main s390x libpcre2-posix3 s390x 10.45-1 [7080 B] 169s Get:41 http://ftpmaster.internal/ubuntu plucky/main s390x libpcre2-dev s390x 10.45-1 [899 kB] 169s Get:42 http://ftpmaster.internal/ubuntu plucky/main s390x libpkgconf3 s390x 1.8.1-4 [31.2 kB] 169s Get:43 http://ftpmaster.internal/ubuntu plucky/main s390x zlib1g-dev s390x 1:1.3.dfsg+really1.3.1-1ubuntu1 [898 kB] 169s Get:44 http://ftpmaster.internal/ubuntu plucky/main s390x libpng-dev s390x 1.6.47-1 [278 kB] 169s Get:45 http://ftpmaster.internal/ubuntu plucky/main s390x libreadline-dev s390x 8.2-6 [187 kB] 169s Get:46 http://ftpmaster.internal/ubuntu plucky/main s390x liblzma-dev s390x 5.6.4-1 [183 kB] 169s Get:47 http://ftpmaster.internal/ubuntu plucky/main s390x pkgconf-bin s390x 1.8.1-4 [21.5 kB] 169s Get:48 http://ftpmaster.internal/ubuntu plucky/main s390x pkgconf s390x 1.8.1-4 [16.7 kB] 169s Get:49 http://ftpmaster.internal/ubuntu plucky/main s390x libtirpc-dev s390x 1.3.4+ds-1.3 [196 kB] 169s Get:50 http://ftpmaster.internal/ubuntu plucky/universe s390x r-base-dev all 4.4.3-1 [4176 B] 169s Get:51 http://ftpmaster.internal/ubuntu plucky/universe s390x pkg-r-autopkgtest all 20231212ubuntu1 [6448 B] 170s Fetched 82.3 MB in 7s (12.4 MB/s) 170s Selecting previously unselected package libisl23:s390x. 170s (Reading database ... (Reading database ... 5% (Reading database ... 10% (Reading database ... 15% (Reading database ... 20% (Reading database ... 25% (Reading database ... 30% (Reading database ... 35% (Reading database ... 40% (Reading database ... 45% (Reading database ... 50% (Reading database ... 55% (Reading database ... 60% (Reading database ... 65% (Reading database ... 70% (Reading database ... 75% (Reading database ... 80% (Reading database ... 85% (Reading database ... 90% (Reading database ... 95% (Reading database ... 100% (Reading database ... 58538 files and directories currently installed.) 170s Preparing to unpack .../00-libisl23_0.27-1_s390x.deb ... 170s Unpacking libisl23:s390x (0.27-1) ... 170s Selecting previously unselected package libmpc3:s390x. 170s Preparing to unpack .../01-libmpc3_1.3.1-1build2_s390x.deb ... 170s Unpacking libmpc3:s390x (1.3.1-1build2) ... 170s Selecting previously unselected package cpp-14-s390x-linux-gnu. 170s Preparing to unpack .../02-cpp-14-s390x-linux-gnu_14.2.0-17ubuntu3_s390x.deb ... 170s Unpacking cpp-14-s390x-linux-gnu (14.2.0-17ubuntu3) ... 170s Selecting previously unselected package cpp-14. 170s Preparing to unpack .../03-cpp-14_14.2.0-17ubuntu3_s390x.deb ... 170s Unpacking cpp-14 (14.2.0-17ubuntu3) ... 170s Selecting previously unselected package cpp-s390x-linux-gnu. 170s Preparing to unpack .../04-cpp-s390x-linux-gnu_4%3a14.2.0-1ubuntu1_s390x.deb ... 170s Unpacking cpp-s390x-linux-gnu (4:14.2.0-1ubuntu1) ... 170s Selecting previously unselected package cpp. 170s Preparing to unpack .../05-cpp_4%3a14.2.0-1ubuntu1_s390x.deb ... 170s Unpacking cpp (4:14.2.0-1ubuntu1) ... 170s Selecting previously unselected package libcc1-0:s390x. 170s Preparing to unpack .../06-libcc1-0_15-20250222-0ubuntu1_s390x.deb ... 170s Unpacking libcc1-0:s390x (15-20250222-0ubuntu1) ... 170s Selecting previously unselected package libitm1:s390x. 170s Preparing to unpack .../07-libitm1_15-20250222-0ubuntu1_s390x.deb ... 170s Unpacking libitm1:s390x (15-20250222-0ubuntu1) ... 170s Selecting previously unselected package libasan8:s390x. 170s Preparing to unpack .../08-libasan8_15-20250222-0ubuntu1_s390x.deb ... 170s Unpacking libasan8:s390x (15-20250222-0ubuntu1) ... 170s Selecting previously unselected package libubsan1:s390x. 170s Preparing to unpack .../09-libubsan1_15-20250222-0ubuntu1_s390x.deb ... 170s Unpacking libubsan1:s390x (15-20250222-0ubuntu1) ... 170s Selecting previously unselected package libgcc-14-dev:s390x. 170s Preparing to unpack .../10-libgcc-14-dev_14.2.0-17ubuntu3_s390x.deb ... 170s Unpacking libgcc-14-dev:s390x (14.2.0-17ubuntu3) ... 170s Selecting previously unselected package gcc-14-s390x-linux-gnu. 170s Preparing to unpack .../11-gcc-14-s390x-linux-gnu_14.2.0-17ubuntu3_s390x.deb ... 170s Unpacking gcc-14-s390x-linux-gnu (14.2.0-17ubuntu3) ... 170s Selecting previously unselected package gcc-14. 170s Preparing to unpack .../12-gcc-14_14.2.0-17ubuntu3_s390x.deb ... 170s Unpacking gcc-14 (14.2.0-17ubuntu3) ... 170s Selecting previously unselected package gcc-s390x-linux-gnu. 170s Preparing to unpack .../13-gcc-s390x-linux-gnu_4%3a14.2.0-1ubuntu1_s390x.deb ... 170s Unpacking gcc-s390x-linux-gnu (4:14.2.0-1ubuntu1) ... 170s Selecting previously unselected package gcc. 170s Preparing to unpack .../14-gcc_4%3a14.2.0-1ubuntu1_s390x.deb ... 170s Unpacking gcc (4:14.2.0-1ubuntu1) ... 170s Selecting previously unselected package libstdc++-14-dev:s390x. 170s Preparing to unpack .../15-libstdc++-14-dev_14.2.0-17ubuntu3_s390x.deb ... 170s Unpacking libstdc++-14-dev:s390x (14.2.0-17ubuntu3) ... 170s Selecting previously unselected package g++-14-s390x-linux-gnu. 170s Preparing to unpack .../16-g++-14-s390x-linux-gnu_14.2.0-17ubuntu3_s390x.deb ... 170s Unpacking g++-14-s390x-linux-gnu (14.2.0-17ubuntu3) ... 170s Selecting previously unselected package g++-14. 170s Preparing to unpack .../17-g++-14_14.2.0-17ubuntu3_s390x.deb ... 170s Unpacking g++-14 (14.2.0-17ubuntu3) ... 170s Selecting previously unselected package g++-s390x-linux-gnu. 170s Preparing to unpack .../18-g++-s390x-linux-gnu_4%3a14.2.0-1ubuntu1_s390x.deb ... 170s Unpacking g++-s390x-linux-gnu (4:14.2.0-1ubuntu1) ... 170s Selecting previously unselected package g++. 170s Preparing to unpack .../19-g++_4%3a14.2.0-1ubuntu1_s390x.deb ... 170s Unpacking g++ (4:14.2.0-1ubuntu1) ... 170s Selecting previously unselected package build-essential. 170s Preparing to unpack .../20-build-essential_12.10ubuntu1_s390x.deb ... 170s Unpacking build-essential (12.10ubuntu1) ... 170s Selecting previously unselected package dctrl-tools. 170s Preparing to unpack .../21-dctrl-tools_2.24-3build3_s390x.deb ... 170s Unpacking dctrl-tools (2.24-3build3) ... 171s Selecting previously unselected package libgfortran-14-dev:s390x. 171s Preparing to unpack .../22-libgfortran-14-dev_14.2.0-17ubuntu3_s390x.deb ... 171s Unpacking libgfortran-14-dev:s390x (14.2.0-17ubuntu3) ... 171s Selecting previously unselected package gfortran-14-s390x-linux-gnu. 171s Preparing to unpack .../23-gfortran-14-s390x-linux-gnu_14.2.0-17ubuntu3_s390x.deb ... 171s Unpacking gfortran-14-s390x-linux-gnu (14.2.0-17ubuntu3) ... 171s Selecting previously unselected package gfortran-14. 171s Preparing to unpack .../24-gfortran-14_14.2.0-17ubuntu3_s390x.deb ... 171s Unpacking gfortran-14 (14.2.0-17ubuntu3) ... 171s Selecting previously unselected package gfortran-s390x-linux-gnu. 171s Preparing to unpack .../25-gfortran-s390x-linux-gnu_4%3a14.2.0-1ubuntu1_s390x.deb ... 171s Unpacking gfortran-s390x-linux-gnu (4:14.2.0-1ubuntu1) ... 171s Selecting previously unselected package gfortran. 171s Preparing to unpack .../26-gfortran_4%3a14.2.0-1ubuntu1_s390x.deb ... 171s Unpacking gfortran (4:14.2.0-1ubuntu1) ... 171s Selecting previously unselected package icu-devtools. 171s Preparing to unpack .../27-icu-devtools_76.1-1ubuntu2_s390x.deb ... 171s Unpacking icu-devtools (76.1-1ubuntu2) ... 171s Selecting previously unselected package libblas-dev:s390x. 171s Preparing to unpack .../28-libblas-dev_3.12.1-2_s390x.deb ... 171s Unpacking libblas-dev:s390x (3.12.1-2) ... 171s Selecting previously unselected package libbz2-dev:s390x. 171s Preparing to unpack .../29-libbz2-dev_1.0.8-6_s390x.deb ... 171s Unpacking libbz2-dev:s390x (1.0.8-6) ... 171s Selecting previously unselected package libdeflate-dev:s390x. 171s Preparing to unpack .../30-libdeflate-dev_1.23-1_s390x.deb ... 171s Unpacking libdeflate-dev:s390x (1.23-1) ... 171s Selecting previously unselected package libicu-dev:s390x. 171s Preparing to unpack .../31-libicu-dev_76.1-1ubuntu2_s390x.deb ... 171s Unpacking libicu-dev:s390x (76.1-1ubuntu2) ... 171s Selecting previously unselected package libjpeg-turbo8-dev:s390x. 171s Preparing to unpack .../32-libjpeg-turbo8-dev_2.1.5-3ubuntu2_s390x.deb ... 171s Unpacking libjpeg-turbo8-dev:s390x (2.1.5-3ubuntu2) ... 171s Selecting previously unselected package libjpeg8-dev:s390x. 171s Preparing to unpack .../33-libjpeg8-dev_8c-2ubuntu11_s390x.deb ... 171s Unpacking libjpeg8-dev:s390x (8c-2ubuntu11) ... 171s Selecting previously unselected package libjpeg-dev:s390x. 171s Preparing to unpack .../34-libjpeg-dev_8c-2ubuntu11_s390x.deb ... 171s Unpacking libjpeg-dev:s390x (8c-2ubuntu11) ... 171s Selecting previously unselected package liblapack-dev:s390x. 171s Preparing to unpack .../35-liblapack-dev_3.12.1-2_s390x.deb ... 171s Unpacking liblapack-dev:s390x (3.12.1-2) ... 171s Selecting previously unselected package libncurses-dev:s390x. 171s Preparing to unpack .../36-libncurses-dev_6.5+20250216-2_s390x.deb ... 171s Unpacking libncurses-dev:s390x (6.5+20250216-2) ... 171s Selecting previously unselected package libpcre2-16-0:s390x. 171s Preparing to unpack .../37-libpcre2-16-0_10.45-1_s390x.deb ... 171s Unpacking libpcre2-16-0:s390x (10.45-1) ... 171s Selecting previously unselected package libpcre2-32-0:s390x. 171s Preparing to unpack .../38-libpcre2-32-0_10.45-1_s390x.deb ... 171s Unpacking libpcre2-32-0:s390x (10.45-1) ... 171s Selecting previously unselected package libpcre2-posix3:s390x. 171s Preparing to unpack .../39-libpcre2-posix3_10.45-1_s390x.deb ... 171s Unpacking libpcre2-posix3:s390x (10.45-1) ... 171s Selecting previously unselected package libpcre2-dev:s390x. 171s Preparing to unpack .../40-libpcre2-dev_10.45-1_s390x.deb ... 171s Unpacking libpcre2-dev:s390x (10.45-1) ... 171s Selecting previously unselected package libpkgconf3:s390x. 171s Preparing to unpack .../41-libpkgconf3_1.8.1-4_s390x.deb ... 171s Unpacking libpkgconf3:s390x (1.8.1-4) ... 171s Selecting previously unselected package zlib1g-dev:s390x. 171s Preparing to unpack .../42-zlib1g-dev_1%3a1.3.dfsg+really1.3.1-1ubuntu1_s390x.deb ... 171s Unpacking zlib1g-dev:s390x (1:1.3.dfsg+really1.3.1-1ubuntu1) ... 171s Selecting previously unselected package libpng-dev:s390x. 171s Preparing to unpack .../43-libpng-dev_1.6.47-1_s390x.deb ... 171s Unpacking libpng-dev:s390x (1.6.47-1) ... 171s Selecting previously unselected package libreadline-dev:s390x. 171s Preparing to unpack .../44-libreadline-dev_8.2-6_s390x.deb ... 171s Unpacking libreadline-dev:s390x (8.2-6) ... 171s Selecting previously unselected package liblzma-dev:s390x. 171s Preparing to unpack .../45-liblzma-dev_5.6.4-1_s390x.deb ... 171s Unpacking liblzma-dev:s390x (5.6.4-1) ... 171s Selecting previously unselected package pkgconf-bin. 171s Preparing to unpack .../46-pkgconf-bin_1.8.1-4_s390x.deb ... 171s Unpacking pkgconf-bin (1.8.1-4) ... 171s Selecting previously unselected package pkgconf:s390x. 171s Preparing to unpack .../47-pkgconf_1.8.1-4_s390x.deb ... 171s Unpacking pkgconf:s390x (1.8.1-4) ... 171s Selecting previously unselected package libtirpc-dev:s390x. 171s Preparing to unpack .../48-libtirpc-dev_1.3.4+ds-1.3_s390x.deb ... 171s Unpacking libtirpc-dev:s390x (1.3.4+ds-1.3) ... 171s Selecting previously unselected package r-base-dev. 171s Preparing to unpack .../49-r-base-dev_4.4.3-1_all.deb ... 171s Unpacking r-base-dev (4.4.3-1) ... 171s Selecting previously unselected package pkg-r-autopkgtest. 171s Preparing to unpack .../50-pkg-r-autopkgtest_20231212ubuntu1_all.deb ... 171s Unpacking pkg-r-autopkgtest (20231212ubuntu1) ... 171s Setting up libjpeg-turbo8-dev:s390x (2.1.5-3ubuntu2) ... 171s Setting up libncurses-dev:s390x (6.5+20250216-2) ... 171s Setting up libreadline-dev:s390x (8.2-6) ... 171s Setting up libpcre2-16-0:s390x (10.45-1) ... 171s Setting up libpcre2-32-0:s390x (10.45-1) ... 171s Setting up libtirpc-dev:s390x (1.3.4+ds-1.3) ... 171s Setting up libpkgconf3:s390x (1.8.1-4) ... 171s Setting up libmpc3:s390x (1.3.1-1build2) ... 171s Setting up icu-devtools (76.1-1ubuntu2) ... 171s Setting up pkgconf-bin (1.8.1-4) ... 171s Setting up liblzma-dev:s390x (5.6.4-1) ... 171s Setting up libubsan1:s390x (15-20250222-0ubuntu1) ... 171s Setting up zlib1g-dev:s390x (1:1.3.dfsg+really1.3.1-1ubuntu1) ... 171s Setting up libpcre2-posix3:s390x (10.45-1) ... 171s Setting up libasan8:s390x (15-20250222-0ubuntu1) ... 171s Setting up libjpeg8-dev:s390x (8c-2ubuntu11) ... 171s Setting up libisl23:s390x (0.27-1) ... 171s Setting up libdeflate-dev:s390x (1.23-1) ... 171s Setting up libicu-dev:s390x (76.1-1ubuntu2) ... 171s Setting up libcc1-0:s390x (15-20250222-0ubuntu1) ... 171s Setting up libblas-dev:s390x (3.12.1-2) ... 171s update-alternatives: using /usr/lib/s390x-linux-gnu/blas/libblas.so to provide /usr/lib/s390x-linux-gnu/libblas.so (libblas.so-s390x-linux-gnu) in auto mode 171s Setting up dctrl-tools (2.24-3build3) ... 171s Setting up libitm1:s390x (15-20250222-0ubuntu1) ... 171s Setting up libbz2-dev:s390x (1.0.8-6) ... 171s Setting up libpcre2-dev:s390x (10.45-1) ... 171s Setting up libpng-dev:s390x (1.6.47-1) ... 171s Setting up libjpeg-dev:s390x (8c-2ubuntu11) ... 171s Setting up pkgconf:s390x (1.8.1-4) ... 171s Setting up liblapack-dev:s390x (3.12.1-2) ... 171s update-alternatives: using /usr/lib/s390x-linux-gnu/lapack/liblapack.so to provide /usr/lib/s390x-linux-gnu/liblapack.so (liblapack.so-s390x-linux-gnu) in auto mode 171s Setting up cpp-14-s390x-linux-gnu (14.2.0-17ubuntu3) ... 171s Setting up cpp-14 (14.2.0-17ubuntu3) ... 171s Setting up libgcc-14-dev:s390x (14.2.0-17ubuntu3) ... 171s Setting up libstdc++-14-dev:s390x (14.2.0-17ubuntu3) ... 171s Setting up libgfortran-14-dev:s390x (14.2.0-17ubuntu3) ... 171s Setting up cpp-s390x-linux-gnu (4:14.2.0-1ubuntu1) ... 171s Setting up gcc-14-s390x-linux-gnu (14.2.0-17ubuntu3) ... 171s Setting up gcc-s390x-linux-gnu (4:14.2.0-1ubuntu1) ... 171s Setting up g++-14-s390x-linux-gnu (14.2.0-17ubuntu3) ... 171s Setting up cpp (4:14.2.0-1ubuntu1) ... 171s Setting up gfortran-14-s390x-linux-gnu (14.2.0-17ubuntu3) ... 171s Setting up g++-s390x-linux-gnu (4:14.2.0-1ubuntu1) ... 171s Setting up gcc-14 (14.2.0-17ubuntu3) ... 171s Setting up g++-14 (14.2.0-17ubuntu3) ... 171s Setting up gfortran-14 (14.2.0-17ubuntu3) ... 171s Setting up gfortran-s390x-linux-gnu (4:14.2.0-1ubuntu1) ... 171s Setting up gcc (4:14.2.0-1ubuntu1) ... 171s Setting up g++ (4:14.2.0-1ubuntu1) ... 171s update-alternatives: using /usr/bin/g++ to provide /usr/bin/c++ (c++) in auto mode 171s Setting up build-essential (12.10ubuntu1) ... 171s Setting up gfortran (4:14.2.0-1ubuntu1) ... 171s update-alternatives: using /usr/bin/gfortran to provide /usr/bin/f95 (f95) in auto mode 171s update-alternatives: warning: skip creation of /usr/share/man/man1/f95.1.gz because associated file /usr/share/man/man1/gfortran.1.gz (of link group f95) doesn't exist 171s update-alternatives: using /usr/bin/gfortran to provide /usr/bin/f77 (f77) in auto mode 171s update-alternatives: warning: skip creation of /usr/share/man/man1/f77.1.gz because associated file /usr/share/man/man1/gfortran.1.gz (of link group f77) doesn't exist 171s Setting up r-base-dev (4.4.3-1) ... 171s Setting up pkg-r-autopkgtest (20231212ubuntu1) ... 171s Processing triggers for libc-bin (2.41-1ubuntu2) ... 171s Processing triggers for man-db (2.13.0-1) ... 171s Processing triggers for install-info (7.1.1-1) ... 172s autopkgtest [18:15:49]: test pkg-r-autopkgtest: /usr/share/dh-r/pkg-r-autopkgtest 172s autopkgtest [18:15:49]: test pkg-r-autopkgtest: [----------------------- 172s Test: Try to load the R library nleqslv 173s 173s R version 4.4.3 (2025-02-28) -- "Trophy Case" 173s Copyright (C) 2025 The R Foundation for Statistical Computing 173s Platform: s390x-ibm-linux-gnu 173s 173s R is free software and comes with ABSOLUTELY NO WARRANTY. 173s You are welcome to redistribute it under certain conditions. 173s Type 'license()' or 'licence()' for distribution details. 173s 173s R is a collaborative project with many contributors. 173s Type 'contributors()' for more information and 173s 'citation()' on how to cite R or R packages in publications. 173s 173s Type 'demo()' for some demos, 'help()' for on-line help, or 173s 'help.start()' for an HTML browser interface to help. 173s Type 'q()' to quit R. 173s 173s > library('nleqslv') 173s > 173s > 173s Other tests are currently unsupported! 173s They will be progressively added. 173s autopkgtest [18:15:50]: test pkg-r-autopkgtest: -----------------------] 173s autopkgtest [18:15:50]: test pkg-r-autopkgtest: - - - - - - - - - - results - - - - - - - - - - 173s pkg-r-autopkgtest PASS 174s autopkgtest [18:15:51]: @@@@@@@@@@@@@@@@@@@@ summary 174s generic PASS 174s pkg-r-autopkgtest PASS 191s nova [W] Using flock in prodstack6-s390x 191s Creating nova instance adt-plucky-s390x-r-cran-nleqslv-20250315-181257-juju-7f2275-prod-proposed-migration-environment-20-f26cc978-f374-43be-a8dc-7ae61d14207e from image adt/ubuntu-plucky-s390x-server-20250315.img (UUID 3d3557fa-fd0f-4bba-9b89-8d5964e09f61)... 191s nova [W] Timed out waiting for 9d8142f9-3045-4791-884e-41e5749b8123 to get deleted.