Using FreeFEM to model Kuramoto Sivashinsky Equation

Hi everyone
I am attempting to model the Kuramoto Sivashinsky equation using FreeFEM. The equation has the form:

u_{t}+\nu u_{xxxx}+u_{xx}+uu_{x}=0

\noindent With 1-periodic boundary condition

u(\cdot,0) = u_{0}

I am fairly new to this software so I could use some help with writing the code to run this model. I am currently attempting to use two spacial dimensions instead of 1 and iterating through time via a for loop. I would like to handle the nonlinear term uu_{x} and the time derivative u_{t} using the function convect as in the projection algorithm navier stokes example. I listed the code I am attempting to run to this post. I have the following issues/questions:

  1. when using the convect term (currently commented out), the program crashes and gives an error that has something to do with projecting types?

  2. I am trying to enforce the periodic boundary condition through lines such as +on(1, u = sin(pi*x)), but this also is leading to an error with the conjugate gradient solver

3)I am not entirely sure how my mesh and fespace need to be defined in order to have a successful model

  1. when i remove the convection term and do not apply the periodic boundary conditions, the solution is constant inside the mesh itself and only seems to change on the border

Any advice on any of these points would be greatly appreciated

\begin{lstlisting}
real nu = 1;
real lambda = 1;
real T = 5.;
real dt = 0.1;
real epsu = 1e-6;

//mesh
mesh Th = square(25,25);

//fespace

fespace Vh(Th, P2b,
periodic = [[0,5],[0,5]]);
Vh u=0;
Vh v;

for(int n = 0; n<30; n++){
Vh uold = u;
//problem
solve ks(u, v, init = n, solver = CG, eps = epsu)
= int2d(Th) (uv)
//- int2d(Th) (
//convect([dx(u), dy(u)], dt, u)v)
+ int2d(Th)(
dt
nu/2
(dxx(u)*dxx(v)+dyy(u)dyy(v)))
- int2d(Th)(
dt/2
(dx(uold)*dx(v)+dy(uold)dy(v)))
- int2d(Th)(
dt/2
(dx(u)dx(v)+dy(u)dy(v)))
+ int2d(Th)(
dt
nu/2
(dxx(uold)*dxx(v)+dyy(uold)dyy(v)))
//+ on(1, u = sin(pi
x))
;
plot(u);
}

\end{lstlisting}