egcd.m

Extended greatest common divisor. Finds g = GCD(x(1), ..., x(end)) and v such that g == sum(v.*x).
ダウンロード: 611
更新 2011/1/24

ライセンスの表示

[g v] = egcd(x) returns g = gcd(x(1), x(2), ..., x(end)) and v such that g == sum(v.*abs(x)).

引用

Steven Gregory (2024). egcd.m (https://www.mathworks.com/matlabcentral/fileexchange/23944-egcd-m), MATLAB Central File Exchange. 取得済み .

MATLAB リリースの互換性
作成: R2007a
すべてのリリースと互換性あり
プラットフォームの互換性
Windows macOS Linux
カテゴリ
Help Center および MATLAB AnswersData Import and Export についてさらに検索
タグ タグを追加
謝辞

ヒントを得たファイル: nextperm, modinv(x, N), logmod

Community Treasure Hunt

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

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

Just realized that egcd works on abs(x) and not x. If you need v, use v = sign(x)*v. Then g == sum(v.*x) will be true.

1.0.0.0