[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: 3D plot from a matrix
From: |
guido.bonalumi |
Subject: |
Re: 3D plot from a matrix |
Date: |
Sun, 18 May 2014 07:47:44 -0700 (PDT) |
Yes I think so, but I am not sure. I am trying to implement /quiver/ in my
code but I am having some troubles with the vectors /u/ and /v/.
Here is my code:
/X=[0, 6.8, 13.6, 20.4, 27.2, 34, 40.7, 47.5, 52.1, 56.6, 61.1, 65.6, 67.9];
X=X/(2*max(X));
Y=linspace(0,1,30);
Z=load("data.dat");
[XX YY]=meshgrid(X,Y);
save("-ascii", "matrix", '[XX YY]');
map=jet(256);
colormap (map);
surf(YY,XX,Z);
shading interp;
#title("Vista frontale");
xlabel("tg");
ylabel("rad");
colorbar("EastOutside");
view(2)
print -color perdite3D_vista_frontale.eps
#title("Vista in prospettiva");
xlabel("tg");
ylabel("rad");
zlabel("\\zeta");
colorbar("EastOutside");
view (25, 30);
print -color perdite3D.eps/
I am plotting a coefficient (Kinetic Energy Loss Coefficient) which is saved
in the file "data.dat" for each point defined by an couple of coordinates
(X, Y). For each point I know the three components of the Mach number and so
I created two matrix: one for the tangential coordinate and another one for
the radial (and saved them in two file: "tg.dat" and "rad.dat"). Then I
tried with this:
/
tg=("tg.dat");
rad=("rad.dat");
h=quiver(XX, YY, tg, rad);
set(h, "maxheadsize", 0.33);/
I have two problem:
- the result is not what I was expecting and it does not agree with my
vortex;
- /quiver/ create another graph while I want that these vectors show up in
my graph (the one that show the vortex), like two overlapping layers.
Any idea?
--
View this message in context:
http://octave.1599824.n4.nabble.com/3D-plot-from-a-matrix-tp4664087p4664150.html
Sent from the Octave - General mailing list archive at Nabble.com.
- 3D plot from a matrix, guido.bonalumi, 2014/05/15
- Re: 3D plot from a matrix, Juan Pablo Carbajal, 2014/05/15
- Re: 3D plot from a matrix, Andy Buckle, 2014/05/15
- Re: 3D plot from a matrix, guido.bonalumi, 2014/05/15
- Re: 3D plot from a matrix, Andy Buckle, 2014/05/15
- Re: 3D plot from a matrix, guido.bonalumi, 2014/05/15
- Re: 3D plot from a matrix, Juan Pablo Carbajal, 2014/05/15
- Re: 3D plot from a matrix, guido.bonalumi, 2014/05/17
- Re: 3D plot from a matrix, Juan Pablo Carbajal, 2014/05/17
- Re: 3D plot from a matrix, Francesco Potortì, 2014/05/18
- Re: 3D plot from a matrix,
guido.bonalumi <=
- Re: 3D plot from a matrix, Andy Buckle, 2014/05/19
- Re: 3D plot from a matrix, guido.bonalumi, 2014/05/19
- Re: 3D plot from a matrix, Andy Buckle, 2014/05/19
- Re: 3D plot from a matrix, guido.bonalumi, 2014/05/19
- Re: 3D plot from a matrix, guido.bonalumi, 2014/05/20
Re: 3D plot from a matrix, Przemek Klosowski, 2014/05/15