Solve linear tensor equation
5 views (last 30 days)
Show older comments
I am building a fem code and want to solve an equation of the form
f= tensorprod(A,u,[2,4],[1,2])
where:
size(A)= n by n by 2 by 2
Size(u) = n by 2
Size(F) = n by 2.
A and f are known, u is to be solved
please note that n is a large number e.g order of 1e4 and this equation has to be solved often
n=5;
A=rand(n,n,2,2);
u=rand(n,2); %u is actually the variable that is to be solved while f is known
f=tensorprod(A,u,[2 4],[1 2])
0 Comments
Accepted Answer
More Answers (0)
See Also
Categories
Find more on Mathematics and Optimization in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!