What is the algorithm used for lu built-in MATLAB matrix decomposition function?
Mostrar comentarios más antiguos
I would to know which algorith is used for lu MATLAB built-in function. Also, if I wanna find the algorithm used for building any function in MATLAB where do you advise me to look and search?
Thanks
Respuestas (2)
John D'Errico
el 2 de Abr. de 2016
0 votos
1. READ THE HELP. In general most tools should give SOME idea of what algorithm was employed. Look for references if available.
2. SOME tools are m-files. You can look at the code. Use the type command here to look at code, not edit. He who edits TMW supplied code risks inserting an accidental typo into the code, and then saving it accidentally. So edit is a risky way to view code.
3. Much of the code in MATLAB is compiled. Sorry, but if you want to look at the code behind those tools, plan on getting a job at The MathWorks as your only way to do so.
As far as the LU code goes, I expect this is a moderately basic pivoted LU code, the algorithm for which can be found in dozens of texts. Of course, things like the BLAS factor in, so the code will not be that trivial. And of course, if the matrix is sparse, there are other issues to worry about.
If your goal is to exactly reproduce the results from LU, by writing your own C code, DON'T BOTHER. You will NEVER be able to do so in general.
1 comentario
Duster Smith
el 2 de Abr. de 2016
Editada: Duster Smith
el 2 de Abr. de 2016
Duster Smith
el 2 de Abr. de 2016
0 votos
Categorías
Más información sobre Programming en Centro de ayuda y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!