LUSolver with annotation turned off raises exception
Bug #1171322 reported by
Marie Rognes
This bug affects 1 person
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
dolfin-adjoint |
Fix Committed
|
High
|
Unassigned |
Bug Description
The following code gives the exception: "Your matrix A has to have the .form attribute: was it assembled after from dolfin_adjoint import *". (The purpose of the code is to be able to turn annotate completely on and off.) Perhaps the check for the .form attribute should be when calling solve (with annotate == True) rather than in the creation of the LUSolver?
from dolfin import *
from dolfin_adjoint import *
mesh = UnitInterval(10)
V = FunctionSpace(mesh, "CG", 1)
u = TrialFunction(V)
v = TestFunction(V)
a = u*v*dx
A = assemble(a, annotate=False)
solver = LUSolver(A)
To post a comment you must log in.
Hi Marie,
Thanks for the useful bug report. Should be fixed in r632.
Patrick