20 years old code
2 次查看(过去 30 天)
显示 更早的评论
I've got a code from 2001 which I need to use for my research. The code runs well but I get a different graph than the one they achieved back then. Does anyone know what changes have been made in the last 20 years that might cause this type of problem?
4 个评论
dpb
2018-8-12
编辑:dpb
2018-8-12
Are you sure it isn't just data not the code per se that is the difference between figures--how do you know the exact code and data produced the exact figure you're comparing to?
It's really not unusual that a reported figure and the code as published don't actually match identically; things get edited and not everything always gets modified to match in a final report/document.
回答(1 个)
Walter Roberson
2018-8-12
- over the last 20 years, the default algorithms have changed for several of the routines in the Optimization Toolbox
- The \ operator can detect more patterns of matrices than it could 20 years ago, handling the special patterns through different code routes. That can lead to increased accuracy and result in different round-off errors
- The \ operator is affected by changes to the underlaying third-party linear algebra routines such as LAPACK, BLAS, and Intel's MKL (Math Kernel Library). Those changes generally serve to improve accuracy, but the changes also tend to handle near-singular matrices differently, potentially leading to very different results for them. Also, those libraries can take advantage of more and more vectorized hardware instructions, but vectorized hardware instructions can have slightly different round off.
- The random number generators use different algorithms by default now than they did 20 years ago.
1 个评论
dpb
2018-8-12
Which raises Q? if it's important does OP know which release was used for the original? I'm not sure w/o going to look just how far back the available releases go, but quite some time; might be feasible to rerun with the original or at least one much closer that would remove at least some of whatever algorithmic changes there have been. Would be, perhaps, an interesting exercise if nothing else.
Of course, we don't know what "a different graph" means; maybe it's just remnants of the HG2 to HG1 switch and nothing at all to do with the calculations.
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Directed Graphs 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!