On Fri, Jun 10, 2011 at 9:50 AM, Ataollah Mesgarnejad <[email protected]> wrote: > Dear all, > > Is there a way to implement a fourth order tensor A_ijkl using libmesh native > classes?
Nope. > If not how do you recommend to do it ? If it has a fixed size I * J * K * L: Real tensor[I][J][K][L]; If the size is variable, you could use a vector<vector<vector<vector<Real> > > > (This is one reason why Fortran programmers think C++ is dumb.) but a better idea would be to write a class which wraps the data structure above or a 1D vector and do array subscripting tricks. If you want to bring external libraries into the mix, there is probably a good one out there. Don't know of one off the top of my head. -- John ------------------------------------------------------------------------------ EditLive Enterprise is the world's most technically advanced content authoring tool. Experience the power of Track Changes, Inline Image Editing and ensure content is compliant with Accessibility Checking. http://p.sf.net/sfu/ephox-dev2dev _______________________________________________ Libmesh-users mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/libmesh-users
