### backflow issue when C=0

Posted:

**Wed Apr 14, 2021 9:41 am**Dear Casino developer!

Quite randomly, I generate test data for backflow calculations I found a combination of parameters that issues SIGSEGV (files in the attachments).

As far as I understand, the error occurs when executing

Unfortunately, I myself cannot figure out what the error is.

Best, Vladimir.

PS:

may be in highloghted line of code

m should be compared with N_phi_ee(set) because m loop is between do m=1,N_phi_ee(set)?

Quite randomly, I generate test data for backflow calculations I found a combination of parameters that issues SIGSEGV (files in the attachments).

As far as I understand, the error occurs when executing

**SUBROUTINE construct_C**or somewhere nearby, I specially chose C=0, to follow the corresponding branches in the code, and for all combinations**N_eN**and**N_ee**less than five with the exception of (5, 4) everything is fine.Unfortunately, I myself cannot figure out what the error is.

Best, Vladimir.

PS:

may be in highloghted line of code

**if(k>1.and.m<N_phi_eN(set))C(n,p+nphi-1*inc_k+1*inc_m)=-real(m,dp)**m should be compared with N_phi_ee(set) because m loop is between do m=1,N_phi_ee(set)?

Code: Select all

```
! Do irrotational bit of the constraint matrix.
if(set_phi_is_ae(set))then
offset_irrot=offset_eN3b+NN_2
else
offset_irrot=offset_eN1a+NN_1
endif
if(set_phi_is_irrot(set))then
p=0 ; n=offset_irrot
inc_k=1
inc_l=inc_k*N_phi_eN(set)
inc_m=inc_l*N_phi_eN(set)
nphi=inc_m*N_phi_ee(set)
do m=1,N_phi_ee(set)
do l=1,N_phi_eN(set)
do k=1,N_phi_eN(set)
p=p+1 ; n=n+1
if(C_trunc>0)then
if(m>1)then
C(n,p-1*inc_m)=real(C_trunc+k-1,dp)
if(k<N_phi_eN(set))C(n,p+1*inc_k-1*inc_m)=-Lc*real(k,dp)
endif
if(m<N_phi_ee(set))then
if(k>2)C(n,p+nphi-2*inc_k+1*inc_m)=-real(m,dp)
if(k>1)C(n,p+nphi-1*inc_k+1*inc_m)=Lc*real(m,dp)
endif
else ! C=0
if(m>1.and.k<N_phi_eN(set))C(n,p+1*inc_k-1*inc_m)=real(k,dp)
if(k>1.and.m<N_phi_eN(set))C(n,p+nphi-1*inc_k+1*inc_m)=-real(m,dp)
endif ! C>0 or not
enddo ! k
enddo ! l
enddo ! m
```