Advertisement
jborya

timing QRFact

Jun 15th, 2020
2,173
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Octave 0.54 KB | None | 0 0
  1. #{
  2.  
  3. Gemessene Zeiten
  4. Oben: Mit find
  5. Unten: Ohne find
  6.  
  7. >> test(A1,1000)
  8. Elapsed time is 0.016741 seconds.
  9. Elapsed time is 0.0168991 seconds.
  10. >> test(A1,100000)
  11. Elapsed time is 0.0150471 seconds.
  12. Elapsed time is 0.0165188 seconds.
  13. >> test(A1,1000000)
  14. Elapsed time is 0.0162051 seconds.
  15. Elapsed time is 0.0188031 seconds.
  16. >>
  17.  
  18. #}
  19.  
  20. function [] = test(A1, n)
  21.   disp("QRFact")
  22.   tic
  23.   for i=1:n
  24.     [A, D, p , k ] = QRFact(A1);
  25.   end
  26.   toc
  27.   disp("QRFact2")
  28.   tic
  29.   for i=1:n
  30.     [A, D, p , k ] = QRFact2(A1);
  31.   end
  32.   toc
  33. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement