← Back to team overview

dolfin team mailing list archive

Re: la/solve

 



Dag Lindbo wrote:
Ola Skavhaug wrote:
Should be change:
  /// Solve linear system Ax = b
  void solve(const Matrix& A, Vector& x, const Vector& b);

to
  /// Solve linear system Ax = b
  void solve(const GenericMatrix& A, GenericVector& x, const GenericVector& b);

?

Ola

Can you keep both? People still use the construction like in the conv-diff demo:

Matrix A;
Vector x, b;

assemble(A, a, mesh);
assemble(b, L, mesh);
bc.apply(A, b, a);
solve(A, x, b);

Function u(mesh, x, a);
File file("temperature.pvd");
file << u;

I'm sorry I keep complaining about this change. I don't want to be obstructive. :(


The above code should be fine because Matrix/Vector derives from GenericMatrix/GenericVector.

Garth

/Dag
_______________________________________________
DOLFIN-dev mailing list
DOLFIN-dev@xxxxxxxxxx
http://www.fenics.org/mailman/listinfo/dolfin-dev




References