Hello everyone,
I am new to FEniCS and I am trying to understand if FEniCS can be useful to my current project.
I would like to solve N coupled PDEs and be able to modify N.
I need to define N functions u_1, .., u_N and to define a weak formulation involving all N variables.
The coupled PDE is linear and is of the form
v_i \cdot \nabla u_i + \sigma ( u_i - \frac{1}{N} \sum_{j=1}^N u_j ) = S_i .
where v_1, .., v_N are fixed.
The main question is that if there is a way to easily write the weak formulation while allowing the number of unknowns N to change ?
The ideal setting would be to be able to write a loop over the unknowns and to add terms to the weak formulation.
Thank you in advance.