- #1
Muchacho
- 3
- 0
Hi!
It's been like two days since I have tried to make this work, still I got nothing. Searched Google etc. but no help there.
I have a three dimensional matrix in form of {{a,b,c}, {d,e,f}, {g,h,i}, ... etc. } with a total of 51 elements, i.e. 51x3 matrix.
What I want is to plot it as a 2D line using first 2 elements {{a,b},{d,e},{g,h}, ... etc.} and to color the plot using the values from 3rd element {c, f, i, ... etc.}.
And I have to use built in ColorData["Rainbow"] scheme.
The data is quite simple - plotting both parts separately => the first two elements will give letter U upside down and the third element is a 12th order polynomal that looks similar to Sin2[x].
It is somehow possible to fit functions to given data and to plot them using parametric ones (there is a common parameter for all values) but will it help somehow? Since there will be 3 parametric functions, it will still be only possible to plot them using parametric 3D plot function.
Here are a first 15 elements from given array:
{{-1256.89, 1428.53, 3.95091}, {-1244.34, 1494.18,
4.58655}, {-1217.63, 1556.05, 4.9574}, {-1188.06, 1615.99,
5.09292}, {-1168.71, 1679.1, 5.02187}, {-1137.94, 1737.54,
4.7725}, {-1114.76, 1799.63, 4.37291}, {-1084.5, 1858.54,
3.85128}, {-1054.75, 1918.34, 3.23608}, {-1027.34, 1981.06,
2.55586}, {-995.382, 2042.13, 1.83892}, {-963.726, 2105.59,
1.1125}, {-931.068, 2171.05, 0.401884}, {-892.135, 2233.19,
0.27072}, {-848.104, 2292.43, 0.887201}}
If this is not possible in Mathematica, can MatLAB or other software do it?
It's been like two days since I have tried to make this work, still I got nothing. Searched Google etc. but no help there.
I have a three dimensional matrix in form of {{a,b,c}, {d,e,f}, {g,h,i}, ... etc. } with a total of 51 elements, i.e. 51x3 matrix.
What I want is to plot it as a 2D line using first 2 elements {{a,b},{d,e},{g,h}, ... etc.} and to color the plot using the values from 3rd element {c, f, i, ... etc.}.
And I have to use built in ColorData["Rainbow"] scheme.
The data is quite simple - plotting both parts separately => the first two elements will give letter U upside down and the third element is a 12th order polynomal that looks similar to Sin2[x].
It is somehow possible to fit functions to given data and to plot them using parametric ones (there is a common parameter for all values) but will it help somehow? Since there will be 3 parametric functions, it will still be only possible to plot them using parametric 3D plot function.
Here are a first 15 elements from given array:
{{-1256.89, 1428.53, 3.95091}, {-1244.34, 1494.18,
4.58655}, {-1217.63, 1556.05, 4.9574}, {-1188.06, 1615.99,
5.09292}, {-1168.71, 1679.1, 5.02187}, {-1137.94, 1737.54,
4.7725}, {-1114.76, 1799.63, 4.37291}, {-1084.5, 1858.54,
3.85128}, {-1054.75, 1918.34, 3.23608}, {-1027.34, 1981.06,
2.55586}, {-995.382, 2042.13, 1.83892}, {-963.726, 2105.59,
1.1125}, {-931.068, 2171.05, 0.401884}, {-892.135, 2233.19,
0.27072}, {-848.104, 2292.43, 0.887201}}
If this is not possible in Mathematica, can MatLAB or other software do it?
Last edited: