How to restore tensor after applied the PARAFAC model?

2 ビュー (過去 30 日間)
PaulLe
PaulLe 2020 年 4 月 23 日
コメント済み: PaulLe 2020 年 4 月 24 日
Hi everyone,
Suppose I have a tensor have the size of (128 x 128 x 3). When I apply the PARAFAC model (to fit one-component) to decomposition tensor. I get many components a1, b1, c1
My question here:
+/ a1 have size of (128 x 1)
+/ b1 have size of (128 x 1)
+/ c1 have size of (3 x 1).
How to get the result of multiplication a1.b1.c1? (restore original tensor?). Because each factor is not the same size?
Thank you for your help.

採用された回答

Christine Tobler
Christine Tobler 2020 年 4 月 23 日
The three component vectors represent the 3 different dimensions here. For the one-component case (all are vectors), you can use
a1 .* (b1.') .* (reshape(c1, 1, 1, []))
which will return an array of size length(a1) x length(b1) x length(c1).
  1 件のコメント
PaulLe
PaulLe 2020 年 4 月 24 日
Dear Tobler,
Thank you for your help.

サインインしてコメントする。

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeParticle & Nuclear Physics についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by