-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 On 11/11/15 11:49, Anna Kalogirou wrote:
Hi Lawrence,
Can I manually configure/multiply those matrices in Python and then solve the linear system Ax=b in UFL by writing solve(A, x, b), where b can be assembled using other known functions?
No, A must be a firedrake Matrix for solve(A, x, b) to work. If it is a PETSc Mat, you will need to get the PETSc Vecs from x and b and use a PETSc KSP to solve the system. If you're working in serial and have A as a numpy matrix, you'll need to use numpy.linalg.solve having obtained the data arrays defining x and b. Lawrence -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.22 (GNU/Linux) iQEcBAEBAgAGBQJWQy1IAAoJECOc1kQ8PEYvV9EIAI2/gnMn/nfeNIvVZYTBqFgG wGJUhfhdGoe1aHPzU47BUtYLKusj9ai1Zz9hNBUa6E/nFAHO1aqvVj15EWGqt6Yf K7qp5hsMw+vvhCPd17vlHHyAtimFduLegtEzRQTHeHVJqFoX5e4+cY/AhMUEVdO7 MzCIndac7QSTIHarJXIPgNZTQK5BOaZarj6liwC8UOETkGgGcDuiY1QamzyXqSwn nBd80EcQsFlVquE1WV3lsR1QTA2Ft3JwVL/SDbFUhzuzIDS00Y4vN4ZcFWaZ2AbY gXfAGPleomblmm7cujeEiaSsQFKM2w2tJFD5sb0GtzRF6HcJHFcgX+t7N7i+H3c= =9gWg -----END PGP SIGNATURE-----