- edited description
FunctionAXPY with sub function should be possible
Issue #687
resolved
The example below fails because the subfunctions are not on the same FunctionSpace. The old formulation MixedFunctionSpace([Q,Q,Q]) kept the same underlying subspace but this information is lost with the new formulation. This is incovenient when using the subfunctions iteratively in a NewtonSolver for example.
mesh = UnitIntervalMesh(10)
Q = FunctionSpace(mesh,'CG',1)
mixed_element = ufl.MixedElement([Q.ufl_element()]*3)
Q3 = FunctionSpace(mesh,mixed_element)
u_mixed = Function (Q3)
u1, u2, u3 = u_mixed.split(deepcopy=False)
#this fails because the sub function are not on the same function_space
u_comb = FunctionAXPY([(1.0,u1),(2.0,u2),(3.0,u3)])
Comments (4)
-
reporter -
- removed milestone
Removing milestone: 1.7 (automated comment)
-
@chaffra The above code does not fail any more. Could you provide a failing example or confirm the this is not an issue?
-
reporter - changed status to resolved
You are right. This no longer fails.
- Log in to comment