uncover the call structure of a recursive function call

バージョン 1.0.0 (3.5 KB) 作成者: Thomas
recurse(tree) helps to uncover the call structure of a recursive function call.
ダウンロード: 14
更新 2020/7/11

ライセンスの表示

The recursive function to examine shall be y = f(x) , then the first call of f must be modified to: [y,tree] = f( x , recurse() ).
When f recursively calls itself use: y = f( x, recurse(tree) )
The call structure of f will be traced in an adjacency matrix "tree.glo.adjacency" by calling recurse(tree) together with f. The adjacency matrix can be plotted as a directed graph using the method RecursionStructure(tree).
As an example see the use of recurse(tree) in the karatsuba function.
run: "karatsubatest" in order to multiply two large integers using the karatsuba method.

引用

Thomas (2024). uncover the call structure of a recursive function call (https://www.mathworks.com/matlabcentral/fileexchange/78044-uncover-the-call-structure-of-a-recursive-function-call), MATLAB Central File Exchange. 取得済み .

MATLAB リリースの互換性
作成: R2019a
すべてのリリースと互換性あり
プラットフォームの互換性
Windows macOS Linux

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!
バージョン 公開済み リリース ノート
1.0.0