*BUCKLE with fewer unknowns than ARPACK needs: "*ERROR in arpackbu: info=-3", but ccx goes on, writes a buckling factor of 0 and exits 0

Summary

*BUCKLE uses 4 x (number of factors) Lanczos vectors by default, plus the number of factors (2.23 manual, section 7.5: “# Lanczos vectors calculated in each iteration (default: 4 * #eigenvalues)”; buckles.f adds the number of factors). ARPACK needs that number to be at most the number of equations N. When the model has fewer equations, ARPACK returns info=-3. ccx prints

 *ERROR in arpackbu: info=-3
       # of converged eigenvalues=0

and goes on. The .dat gets a buckling factor of 0.0000000E+00 and a zero mode shape, the output ends with “Job finished”, and the exit status is 0.

Test: one C3D8 cube with 4 unknowns, 1 buckling factor requested (default 5 Lanczos vectors > 4). With the third entry set so that ccx uses 4 Lanczos vectors, the same deck gives 1000 = E/sigma.

*FREQUENCY handles the same situation. arpack.c checks the limits before calling ARPACK (“for the limits: look for “ierr = -3” in dsaupd.f and dnaupd.f”), reduces the number of eigenvalues with a message and computes the rest. On the same cube, 5 frequencies requested gives “too many eigenvalues requested, number is reduced to: 3” and three correct eigenvalues. arpackbu.c has no such check.

This matters for small models, e.g. 10 buckling factors on a model with fewer than 50 equations.

Version

ccx 2.23 (macOS arm64). Source: master 9ba5d76 (16 Oct 2026).

Already reported or fixed?

Not reported: I found no matching GitHub issue (open or closed) or pull request in Dhondtguido/CalculiX, and no calculix.discourse.group topic (searched 21 Oct 2026). Not fixed: arpackbu.c and buckles.f are unchanged in this respect on master (9ba5d76).

Related:

Minimal input

buckle_small.inp:

** One C3D8 cube, bottom face held, top face free to move only along z
** (4 unknowns). *BUCKLE for 1 factor under a compressive top load.
*NODE, NSET=NALL
1, 0., 0., 0.
2, 1., 0., 0.
3, 1., 1., 0.
4, 0., 1., 0.
5, 0., 0., 1.
6, 1., 0., 1.
7, 1., 1., 1.
8, 0., 1., 1.
*ELEMENT, TYPE=C3D8, ELSET=EALL
1, 1, 2, 3, 4, 5, 6, 7, 8
*NSET, NSET=BOT
1, 2, 3, 4
*NSET, NSET=TOP
5, 6, 7, 8
*MATERIAL, NAME=M
*ELASTIC
1000., 0.
*SOLID SECTION, ELSET=EALL, MATERIAL=M
*BOUNDARY
BOT, 1, 3
TOP, 1, 2
*STEP
*BUCKLE
1
*CLOAD
TOP, 3, -0.25
*NODE PRINT, NSET=TOP
U
*END STEP

buckle_small_ncv.inp: the same with the second line of *BUCKLE as 1, 1.E-2, 3 (ccx then uses 3 + 1 = 4 Lanczos vectors).

freq_small.inp: the same model with *DENSITY / 1.E-9, without the *CLOAD, and *FREQUENCY / 5 instead of *BUCKLE / 1.

How to run

ccx buckle_small
ccx buckle_small_ncv
ccx freq_small

Expected

Either ccx limits the number of Lanczos vectors to the number of equations (as arpack.c does for *FREQUENCY) and computes the factor, or it stops with an error. The factor of this test is E/sigma = 1000 / 1 = 1000, which buckle_small_ncv gives.

Actual

deck screen .dat exit
buckle_small *ERROR in arpackbu: info=-3, # of converged eigenvalues=0, then “Job finished” buckling factor 0.0000000E+00, mode shape all zero 0
buckle_small_ncv no error buckling factor 0.1000000E+04 0
freq_small *ERROR in arpack: too many eigenvalues requested / number is reduced to: 3 3 eigenvalues 0

All three have 4 equations (“number of equations 4”).

Where it goes wrong

buckles.f (lines 156-159) sets the number of Lanczos vectors:

      if(ncv.le.0) then
         ncv=4*nev
      endif
      ncv=ncv+nev

arpack.c checks it against the number of equations before calling ARPACK (lines 706-741, symmetric case):

      /* nev+1 <= ncv <= n */
      
      if(nev+1>neq[1]){
	printf(" *ERROR in arpack: too many eigenvalues requested\n");
	...
	nev=neq[1]-1;
      }
      if(ncv<nev+1){
	ncv=nev+1;
      }else{
	if(ncv>neq[1]){ncv=neq[1];}
      }

arpackbu.c calls dsaupd with ncv unchanged (line 598). When dsaupd returns info=-3, arpackbu.c only prints it (lines 731-734), then calls dseupd and writes the (zero) result:

    if(info!=0){
      printf(" *ERROR in arpackbu: info=%" ITGFORMAT "\n",info);
      printf("       # of converged eigenvalues=%" ITGFORMAT "\n\n",iparam[4]);
    }

Fix

Not built or tested here. Apply the same limits in arpackbu.c before the first dsaupd call (nev+1 <= ncv <= neq[0], reducing nev with a message if needed). Also stop, or at least skip the output, when dsaupd or dseupd returns info != 0, instead of writing factors that were never computed.

Workaround: give the number of Lanczos vectors explicitly as the third entry of the *BUCKLE data line, so that it plus the number of factors does not exceed the number of equations.

Confirmed using official build of ccx 2.23 on Windows, needs a GitHub ticket.

buckle_small:

 Calculating the buckling factors and buckling modes:

 *ERROR in arpackbu: info=-3
       # of converged eigenvalues=-618665324

sigma=1.000000,d[0]=0.000000

 Using up to 1 cpu(s) for the stress calculation.


 Job finished

________________________________________

Total CalculiX Time: 0.006372
________________________________________

freq_small:

 Calculating the eigenvalues and the eigenmodes

 *ERROR in arpack: too many eigenvalues requested
                   number is reduced to: 3

U^T*M*U=1.000000 for eigenmode 1
U^T*M*U=1.000000 for eigenmode 2
U^T*M*U=1.000000 for eigenmode 3
 Using up to 1 cpu(s) for the stress calculation.

 Using up to 1 cpu(s) for the stress calculation.

 Using up to 1 cpu(s) for the stress calculation.


 Job finished

________________________________________

Total CalculiX Time: 0,012958
________________________________________
1 Like

posted: *BUCKLE with fewer unknowns than ARPACK needs: "*ERROR in arpackbu: info=-3", but ccx goes on, writes a buckling factor of 0 and exits 0 · Issue #277 · Dhondtguido/CalculiX · GitHub

1 Like