Dear FF developers,
I would like to ask you how to correct the following error,
2 : {
3 : Vh w;
4 : w[] = u;
5 : real tI;
6 : tI = int2d(core) (w);
7 : cout<<tI<<endl;
8 : return tI;Impossible to cast <Pd> in <3KN_IdE>
( <3KN_IdE> : <P3KNMIdE> )
( <3KN_IdE> : <P2KNIdE> )
Error line number 8, in file FFutils/tilt.idp, before token ;
which comes out when I call this function inside my script,
func real[int] tilt(real[int] & u)
{
Vh w;
w[] = u;
real tI;
tI = int2d(core) (w);
cout<<tI<<endl;
return tI;
}
The variable u
is defined in the main script as
fespace Vh(core,P1);
Vh u;
My goal is to perform some integrations over the mesh involving different fespace
arrays. Since I have to perform many integrations over the domain for each fespace
array I define, I need to use an external function.
Thank you so much for any help
Nicolo’