Skip to content

Integers with Tensor::operator() #24

Open
@fredrikbk

Description

@fredrikbk

We would be able to use integers to index into Tensor::operator(). Ideally A(0,1) reads coordinate (0,1) and A(0,i) is an index expression that holds the first dimension fixed. (This might not work out; needs to be explored.)

So in addition to writing index expressions you can also use integers (and eventually a mix):

IndexVar i, j;
A(i,j) = B(i,j); // Index expression
A(0,1) = 1;      // Insertion
A(0,i);          // Read the first row?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions