Product of two CF

Hello communiy
I’m trying to do the porduct with two different ways and i don’t get the same results
Bx,By=Grad(gfu)
First way :
GF1.set(BxBy)
Second way :
GFx.Set(Bx)
GFy.Set(By)
GF2=GFx
GFy

I noticed that GF1 and GF2 arent the same even if they should be!

Can you provide an example?

My guess, but as @christopher mentions, an example would be useful.:

First way: You are interpolating the product, so you first take the product, and then interpolate it into the grid.
Second way: You first interpolate, and then take the product afterwards.

Whats the difference? Suppose my two functions are x and x. Then if my gridfunction is piecewise linear, it cannot actually interpolate a quadratic, and you get a piecewise linear function. I suspect that the second method is taking two piecewise linear functions and then giving you the product, so it is actually quadratic. A relevant StackExchange post would be this post.

I appreciate your reply. While I can’t provide a specific example, I’ve managed to make progress by improving the mesh. As I refine the mesh, I’ve noticed that the results become increasingly accurate, particularly when compared to the initial approach.
So as you said it’s a matter of interpolation.