Skip to main content
1-Visitor
May 3, 2011
Question

Is it possible to plot a tensor (4D surface) in Mathcad 13 or 14?

  • May 3, 2011
  • 2 replies
  • 4688 views

I would like to plot a 4-dimensional surface using Mathcad. I think this would be a tensor, i.e. visualized as a 3D surface with vectors of various heights projected on top. I found in Mathcad 14 an quicksheet (Using Regress: Multivariate Regression) of a 3D plot using the 'regress' and 'mesh' functions. I wonder if this is the limit, or if I can plot a tensor somehow using these, or other mathcad 14 functions? Thanks - JCG

2 replies

24-Ruby IV
May 3, 2011

John Gray wrote:

I would like to plot a 4-dimensional surface using Mathcad.

John!

Do you have a function of 3 variables - f(x, y, z)?

John_G1-VisitorAuthor
1-Visitor
May 3, 2011

I have not yet generated the function in 3 variables - I have test data reduced to 4 sets of (3 sets of (a function of 1 variable))). Further data reduction is required. With the quick sheet method using 'regress' referenced in my original question, I will likely be able to get a least squares reduction to 2 variables.

So, in parallel with my first question, I have a second one. That is: Is there a way to generate a least squares data fit in 3 variables using Mathcad, perhaps using the 'regress' function?

Thanks,

JCG

24-Ruby IV
May 3, 2011

John Gray wrote:

So, in parallel with my first question, I have a second one. That is: Is there a way to generate a least squares data fit in 3 variables using Mathcad, perhaps using the 'regress' function?

It is possible. You must convert your matrix into 4 vectors f, x, y and z and use the minimize or minerr function.

See same task for 2 variables:

http://twt.mpei.ac.ru/ochkov/car/c_e.html

23-Emerald V
May 3, 2011

John Gray wrote:

I would like to plot a 4-dimensional surface using Mathcad. I think this would be a tensor, i.e. visualized as a 3D surface with vectors of various heights projected on top. I found in Mathcad 14 an quicksheet (Using Regress: Multivariate Regression) of a 3D plot using the 'regress' and 'mesh' functions. I wonder if this is the limit, or if I can plot a tensor somehow using these, or other mathcad 14 functions? Thanks - JCG

John,

You could try, as a starting point, something like the attached. However, it is rather contingent upon your 'surface' being amenable to such a representation. Sadly, the 3D plot component doesn't seem to allow setting of colour by x,y,z position otherwise that might be another way of visualizing the data.

Stuart

John_G1-VisitorAuthor
1-Visitor
May 3, 2011

The example mathcad tensor plots certainly have all the graphic elements I have been seeking.

I will need to study the program you've written to generate the arrows as this is an aspect of Mathcad programming that I've not yet worked. I plan to attempt this method and get back to you with any detailed questions.

Thanks,

JCG