strand foo (real a) {
output real bar = 0;
update {
vec2 vv = [a,2*a];
tensor[2,2] m22 = [vv,2*vv];
tensor[2,3] m23 = [[0,1,2],[3,4,5]];
tensor[3,2] m32 = [[0,1],[2,3],[4,5]];
tensor[3,3] m33 = [[0,1,2],[3,4,5],[6,7,8]];
// BUG: printing a tensor valued expression should give you
// something that can be copy-pasted back into code as a
// tensor-value (replace "<>" with "[]")
print(vv, "\n");
// BUG: printing tensor[2,2] doesn't work
print(m22, "\n");
// BUG: printing tensor[2,3] doesn't work
print(m23, "\n");
// BUG: printing tensor[3,2] doesn't work
print(m32, "\n");
// BUG: printing tensor[3,3] doesn't work
print(m33, "\n");
stabilize;
}
}
initially {foo(i) | i in 1..1};