# FETI-method in FreeFEM

Hi everyone,

I changed some things up in my code and all of a sudden, my Dirichlet conditions aren’t working anymore. I receive the message “We expected an unknown u=… of the problem”. Can please someone tell me what is wrong here? The error occurs in problem pb1 and pb2:

macro dn(u)(dx(u)*N.x+dy(u)*N.y) //

// Parameters
int inside = 2; int outside = 1; int n = 4;

// Mesh
border a(t=1, 2){x=t; y=0; label=outside;};
border b(t=0, 1){x=2; y=t; label=outside;};
border c(t=2, 0){x=t; y=1; label=outside;};
border d(t=1, 0){x=1-t; y=t; label=inside;};
border g(t=0, 1){x=1-t; y=t; label=inside;};
border g1(t=pi/2, 2*pi){x=cos(t); y=sin(t); label=outside;};

mesh th = buildmesh(a(5n) + b(5n) + c(10n) + d(5n));
mesh TH = buildmesh(g(5n) + g1(25n));

fespace vh(th, P2);
vh u, v, w=0, e;

fespace VH(TH, P2);
VH U, V, W=0, E;

// Problem
problem PB1 (U, V, init=0, solver=Cholesky)
= int2d(TH)(
dx(U)dx(V)
+ dy(U)dy(V)
)
+ int2d(TH)(
- V
)
+ int1d(TH, inside)(
V
(dn(W) - (1/2)
(dn(W) + dn(w))))
+ on(outside, U=0);

problem PB2 (u, v, init=0, solver=Cholesky)
= int2d(th)(
dx(u)dx(v)
+ dy(u)dy(v)
)
+ int2d(th)(
- v
)
+ int1d(th, inside)(
v
(dn(w) - (1/2)
(dn(W) + dn(w))))
+ on(outside, u=0);

problem pb1 (E, V, init=0, solver=Cholesky)
= int2d(TH)(
dx(E)*dx(V)
+ dy(E)dy(V)
)
+ on(inside, E=(1/2)
(u-U));
+ on(outside, E=0);

problem pb2 (e, v, init=0, solver=Cholesky)
= int2d(th)(
dx(e)*dx(v)
+ dy(e)dy(v)
)
+ on(inside, e=(1/2)
(U-u));
+ on(outside, e=0);

int i = 0;
for (i = 0; i < 10; i++){
// Solve
PB1;
PB2;
pb1;
pb2;

``````W = U + E;
w = u + e;
plot(W, w, wait=true);
``````

}

// Plot
plot(W, w);