Coupled problem - square variable

Hello erevyone,

I am contacting you to try to get some answers about a problem related to a squared variable.
Indeed, I put here my simplified program with simple constants A, B, C etc and the variable c1 and the test function c2.

The variational form is :

image

The corresponding code is :

problem first(c1,c2) =
int2d(Sh)(c2c1c1/dt)
- int2d(Sh)(c2c1c/dt)
+ int2d(Sh)(Rc1(dx(c1)dx(c2)+dy(c1)dy(c2)))
+ int2d(Sh)(E
S
N*(dx(c1)dx(c2)+dy(c1)dy(c2))c1)
- int2d(Sh)(R
F/N
c1
c1Dgrad(c2)‘grad(S))
- int2d(Sh)(E
SFc1*grad(c2)’*grad(S))
+ on(1,c1=C0)
+ on(2,c1=C0)
+ on(3,c1=C0)
+ on(4,c1=C0)

I don’t understand why the code doesn’t accept the variable c1 to the square.

Would someone be able to answer me or give me a hint?

To give more details, at first, I started with a simple problem and it worked very well.
The simple model was with a variational form like :

image

So, as you can see, this simple code had no square variable c1*c1 :

problem first(c1,c2) =
int2d(Sh)(c2c1/dt)
- int2d(Sh)(c2
c/dt)
+ int2d(Sh)(R*(dx(c1)dx(c2)+dy(c1)dy(c2)))
- int2d(Sh)(R
F/N
c1Dgrad(c2)’*grad(S))
+ on(1,c1=C0)
+ on(2,c1=C0)
+ on(3,c1=C0)
+ on(4,c1=C0)

Thank you in advance for your response,

Lisa

I tried to linearize the equation by c1= c0+dc1 where c0 is an initial value and dc1 is the increment but even thanks to this linearization, I didn’t succeed to resolve the problem.
This linearization allows me to have : c1c1 = c0c0+2c0dc1.
But the code continues to show a problem…

Do you have some idea to help me, please?

Thank you in advance.