llnl / llnl/BoBa

TensorTrainAMEN fails when the RHS has an internal TT rank greater than one

Open
#2 1 comment 0 reactions 1 assignee View on GitHub

@i3s93 is already working on this.

Since Sep 1, 2026.

bug
Dominant language
C++
Stars
9
Forks
0
PR merge metrics
No merged PRs in 30d

Description

BoBa’s scalar `TensorTrainAMEN` solver fails when solving a system whose right-hand side has a nontrivial internal TT rank. A minimal example of this is the system $Ax = b$ where

$$
A = I_{2} \otimes I_{2}, \qquad b = e_{1}\otimes e_{1} + e_{2}\otimes e_{2}.
$$

Using a rank-one initial guess such as $x_{0} = e_{1}\otimes e_{1}$ produces the error:

`Invalid contraction.: 1 == 2`

The likely cause is an index-ordering mismatch in `TensorTrainAMEN::project_phizy`. A left-to-right environment produced by compute_next_Phi is ordered as (r_z, r_y, 1), but scalar AMEn labels it as`{"rz", "one", "ry"}`. The correct indexing pattern should instead read `{"rz", "ry", "one"}`. The existing ordering is masked for rank-one RHS tensors because both exchanged axes have length one. BoBa’s block-AMEn implementation already uses the latter ordering.

AMEn should accept general valid RHS TT ranks and solve the identity example with $x = b$. A small rank-two RHS regression test in `test_tt_solvers.cpp` would likely demonstrate the failure and verify the proposed fix.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.