Add `factorise` to lock_exchange.cpp example
Nobody has claimed this yet.
Assessment
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Newbie friendliness
- 84/100
Research direction
Open lock_exchange.cpp and inspect how the sparse system is currently solved across repeated steps. Use the requested Armadillo factoriser setup and solve flow as the starting point, then run the example with the higher-resolution parameters given in the issue; done means the example completes and renders the billows.
Written by the indexing model from the issue text.
Description
Is your feature request related to a problem? Please describe.
When solving a system, if the LHS does not change, there are mechanisms to reuse the factorization. In Armadillo, this is achieved with factorise.
Describe the solution you'd like
Implement factorise in the lock_exchange.cpp example. This will let users run a higher resolution in the example, which will render the billows.
// Factorizer for the sparse solve, Armadillo
spsolve_factoriser SF;
// L is a pure-Neumann Laplacian, singular to working precision (constants are
// in its null space); factorise() rejects it unless allow_ugly is set.
superlu_opts opts;
opts.allow_ugly = true;
bool status = SF.factorise(L, opts);
...
bool solution1_ok = SF.solve(p_vec, b);
if(solution1_ok == false) { cout << "couldn't find pvec" << endl; }
Here is an example with b=50, d=5, m=800, n=160, dt=0.1.
Keep-open request
- I am requesting maintainer review for
keep-open.
Reason:
- Dominant language
- MATLAB
- Stars
- 41
- Forks
- 85
- Avg merge
- 1d 19h
- Merged PRs (30d)
- 8
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from csrc-sdsu/mole
-
Documentation Good first issue MOLE.jl
Difficulty 1/5 Under an hour Newbie friendliness 90/100
-
C++ Enhancement Octave/MATLAB
-
Bug Octave/MATLAB
-
Bug
-
Bug
Similar issues
-
Component: Continuous Integration Component: MATLAB Type: enhancement
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
-
Difficulty 1/5 Under an hour Newbie friendliness 94/100
VH-Lab/NDIcalc-vis-matlab#107 ·
-
bug unconfirmed
Difficulty 1/5 Under an hour Newbie friendliness 88/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 70/100
gnu-octave/statistics#498 ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 86/100