# Error umpfack umfpack\_di\_numeric status 1

**URL:** <https://community.freefem.org/t/error-umpfack-umfpack-di-numeric-status-1/1600>\
**Category:** General Discussion\
**Created:** [March 14, 2022, 11:28pm UTC](https://community.freefem.org/t/error-umpfack-umfpack-di-numeric-status-1/1600 "2022-03-14T23:28:17Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![larismartins](https://yyz2.discourse-cdn.com/flex030/user_avatar/community.freefem.org/larismartins/32/2712_2.png) [@larismartins](https://community.freefem.org/u/larismartins)\
**Post date:** [March 14, 2022, 11:28pm UTC](https://community.freefem.org/t/error-umpfack-umfpack-di-numeric-status-1/1600/1 "2022-03-14T23:28:17Z")

</div>

I have the following code:

```auto
 //---------------------------------------------------Solving for etaf

  varf ahKf(etafK, varphi)
    = int2d(Th[K])(kappa*grad(etafK)'*grad(varphi));

  varf fhKf(etafK, varphi)
    = int2d(Th[K])(f*varphi); 

  varf bhKf(vf, varphi)
    = int2d(Th[K])(vf*varphi);
 
  // local matrices for etaf
  matrix Akf = ahKf(VhK,VhK);
  matrix Bkf = bhKf(V0,VhK);
  real[int] Fkf(ndofVhK);
  Fkf = fhKf(0, VhK);

  // block matrix LHS
  matrix AAkf = [[ Akf, Bkf],
                  [Bkf', 0] ];

  real[int] rhsetaf(ndofVhK+nDoFu0), soletafk(ndofVhK+nDoFu0);
  real[int] blmf(nDoFu0), lmf(nDoFu0);

  //second equation to hybrid form equal 0
  blmf = 0;

  // block vector RHS
  rhsetaf = [Fkf, blmf];

  set(AAkf, solver=sparsesolver);
  soletafk = AAkf^-1*rhsetaf; //solve linear system

  [etafK[], lmf] = soletafk; //set the value

  cout << "etaF elem " << K << ": " << etafK[] << "\n";

```

but it keeps giving me the following error:

```auto
 Error umpfack umfpack_di_numeric status 1
 Error umfpack_di_solve status 1
etaF elem 0: 6	
	-0.3611303349	-0.3611303349	-0.09386227966	-0.09386227966	0.1877245593
	-0.251181056	

```

I already tried to change the solver to

```auto
set(AAkf,solver="UMFPACK64")

```

but the error remains. Does anyone have any ideia what it could be?

---

<div class="post-metadata">

**Author:** ![frederichecht](https://yyz2.discourse-cdn.com/flex030/user_avatar/community.freefem.org/frederichecht/32/15_2.png) [@frederichecht](https://community.freefem.org/u/frederichecht)\
**Post date:** [March 15, 2022, 8:28am UTC](https://community.freefem.org/t/error-umpfack-umfpack-di-numeric-status-1/1600/2 "2022-03-15T08:28:56Z")

</div>

Remark, in new version (develop) the error stop FreeFEM and the error 1 is

```
            case 1:
                cout << status<< " UMFPACK WARNING singular matrix " <<endl;
                break;
```

---

<div class="post-metadata">

**Author:** ![larismartins](https://yyz2.discourse-cdn.com/flex030/user_avatar/community.freefem.org/larismartins/32/2712_2.png) [@larismartins](https://community.freefem.org/u/larismartins)\
**Post date:** [March 15, 2022, 11:14pm UTC](https://community.freefem.org/t/error-umpfack-umfpack-di-numeric-status-1/1600/3 "2022-03-15T23:14:36Z")

</div>

In this code, I used the following code to build a local mesh

```auto
 real[int, int] nodes = [[coordX0, coordY0], [coordX1,coordY1],
                          [coordX2, coordY2]];

 //cout << nodes << "\n";

 border f0(t=0,1){P.x=nodes(1,0)*t + nodes(0,0)*(1-t);P.y=nodes(1,1)*t + nodes(0,1)*(1-t); label=1;};
 border f1(t=0,1){P.x=nodes(2,0)*t + nodes(1,0)*(1-t);P.y=nodes(2,1)*t + nodes(1,1)*(1-t); label=2;};
 border f2(t=0,1){P.x=nodes(0,0)*t + nodes(2,0)*(1-t);P.y=nodes(0,1)*t + nodes(2,1)*(1-t); label=3;};
 
 Th[K] = buildmesh(f0(localh) + f1(localh) + f2(localh), fixedborder=true);

```

I don’t know if its related, but for etaF I should have only one value, instead I’m getting a vector of values as you can see above. Perhaps you could help me with this?
