Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Reuse the compositional matrix if more than one compositional field need to be solved? #990

Closed
yinghe616 opened this issue Jun 26, 2016 · 3 comments

Comments

@yinghe616
Copy link
Contributor

When solve the compositional advection equations for multiple compositional fields, the left hand side matrix in most of time will be the same (mass matrix+dt *advection matrix), so only the right hand sides vector will be differ. Currently the codes just reassemble the matrix for each compositional field and then solve.
Maybe we could only assemble LHS matrix once and save some assembling time for solving the multiple compositional filed case... ?

@bangerth
Copy link
Contributor

That's not true. The left hand side matrix contains the artificial viscosity term, which is dependent on the solution (i.e., the specific compositional field we solve for). At least this term has to be re-assembled for each field, and that negates almost all of the benefit of avoiding some assembly.

@yinghe616
Copy link
Contributor Author

ah, I see what you meant. But for DG with upwind-flux, it's all the same...

@bangerth
Copy link
Contributor

I suppose so, assuming that the upwind flux only depends on the velocity field and not on the compositional field. (I.e., if the flux operator is linear.)

@bangerth bangerth changed the title Reuse the compositional matrix if more than one compositional filed need to be solved? Reuse the compositional matrix if more than one compositional field need to be solved? Jun 26, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants