CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Visualization & Post-Processing Software > Tecplot

mat2tecplot

Register Blogs Community New Posts Updated Threads Search

Like Tree21Likes

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   March 4, 2014, 18:10
Exclamation
  #1
New Member
 
Italy
Join Date: Mar 2014
Posts: 1
Rep Power: 0
ciccio is on a distinguished road
Hi
I'm new in using TecPlot and I need it for a university project.
I downloaded the mat2tecplot.m code but I couldn't manage by myself.
My problem is the following:
I have a cube represented by a matrix 36X36X36, and for each cell center I know exactly the velocity of that cell(vx,vy,vz). The velocity field is represented by 3 different matrix, one for vx (36X36X36) same size for vy, vz.
I tried to use the example 11, but when I load in Tecplot and I try to interpolate an error window appears and says that the interpolation can be done only for nodal value. How could I solve this problem?
Thank you, any help is really appreciated
ciccio is offline   Reply With Quote

Old   March 21, 2014, 18:31
Default
  #2
New Member
 
wen long
Join Date: May 2012
Posts: 29
Rep Power: 13
wenlong is on a distinguished road
Hi ciccio

Cubes are simple, because you have 36x36x36 for the cubes vertex points and your u,v,w are on the center of each cube, that means you should supply u,v,w as 35x35x35 arrays instead.

Here is an example code

----------------------
tdata=[];

tdata.Nvar=6;
tdata.varnames={'x','y','z','u','v','w'};
tdata.cubes(1).zonename='my IJK volume cubes zone';

x=(1:1:36);
y=(1:1:36);
z=z(1:1:36);
[x3d,y3d,z3d]=meshgrid(x,y,z);
tdata.cubes(1).x=x3d;
tdata.cubes(1).y=y3d;
tdata.cubes(1).z=z3d;
u3d=repmat(random('norm',0.1,0.2,35),[1,1,35]);
v3d=repmat(random('norm',0.1,0.2,35),[1,1,35]);
w3d=repmat(random('norm',0.1,0.2,35),[1,1,35]);
tdata.cubes(1).v(1,:,:,: )=u3d;
tdata.cubes(1).v(2,:,:,: )=v3d;
tdata.cubes(1).v(3,:,:,: )=w3d;
tdata.cubes(1).varloc=1;
mat2tecplot(tdata,'mycube_IJK_volume_cellcenter.pl t')

------------------
Then you can view the plot in tecplot, and attached pic is what I got.



Wen
Attached Images
File Type: jpg uvw.jpg (99.6 KB, 178 views)
Echem likes this.
wenlong is offline   Reply With Quote

Old   June 3, 2014, 15:37
Default mat2tecplot.m
  #3
New Member
 
nacera
Join Date: Feb 2014
Posts: 4
Rep Power: 12
chernac2000 is on a distinguished road
hello
I have a problem when I load data file in tecplot, the file is generate with matlab with mat2tecplot.m . I get this message: Binary file version newer than tecplot version. Upgrade Tecplot or use an older preplot to produce the data
chernac2000 is offline   Reply With Quote

Old   June 4, 2014, 09:50
Default
  #4
New Member
 
wen long
Join Date: May 2012
Posts: 29
Rep Power: 13
wenlong is on a distinguished road
Open mat2tecplot.m in a text editor, search for "magic number"
which is the version number, change to earlier version

Wen
wenlong is offline   Reply With Quote

Old   June 4, 2014, 11:26
Default mat2tecplot.m
  #5
New Member
 
nacera
Join Date: Feb 2014
Posts: 4
Rep Power: 12
chernac2000 is on a distinguished road
Hi wen,
I have a tecplot version 10, what is the earlier version of TDV that I will add it.
Thanks
chernac2000 is offline   Reply With Quote

Old   June 4, 2014, 12:32
Default
  #6
New Member
 
wen long
Join Date: May 2012
Posts: 29
Rep Power: 13
wenlong is on a distinguished road
Try TDV010 or TDV100
wenlong is offline   Reply With Quote

Old   June 4, 2014, 13:04
Default
  #7
New Member
 
nacera
Join Date: Feb 2014
Posts: 4
Rep Power: 12
chernac2000 is on a distinguished road
I have another problem when I put TDV100 and TDV010. The TDV100 give error as : "out of space while allocating var names" and /invalid header in binary datafile" and "unable to read binary datafile header.

The TDV010 give error as: unexpected end of file in datafile header
chernac2000 is offline   Reply With Quote

Old   June 4, 2014, 13:28
Default
  #8
New Member
 
wen long
Join Date: May 2012
Posts: 29
Rep Power: 13
wenlong is on a distinguished road
Oops, that means you would have to experiment a bit, the binary file format may have been changed from 10.0 to 11.0.
not sure what exactly your line of the magic number looks like unless you post it

also try "#!TDV101" which means 10.1 or "!TDV75 " for version 7.5 notice there is a space after 75
wenlong is offline   Reply With Quote

Old   June 4, 2014, 14:29
Default
  #9
New Member
 
nacera
Join Date: Feb 2014
Posts: 4
Rep Power: 12
chernac2000 is on a distinguished road
I've tested (TDV101 and TDV75 ), but they give the same error as TDV100. all older versions TDV105 give the same error
chernac2000 is offline   Reply With Quote

Old   June 5, 2014, 11:53
Default
  #10
Senior Member
 
Scott Rumage
Join Date: May 2009
Location: Seattle, WA
Posts: 152
Rep Power: 17
scott_rumage is on a distinguished road
I do believe you will need to upgrade your Tecplot license to the new version, as the option to use “Preplot” does not apply to the mat2tecplot.m application.

Preplot is used to convert Tecplot ASCII formatted data to Tecplot binary formatted data – which is not the situation for the use of mat2tecplot.m

Here is a link to the product page on Preplot (and TecIO) if you want to learn more about this application: http://www.tecplot.com/downloads/tecio-library/ . BTW – Preplot is already installed on your computer in the Tecplot 360 “bin” folder.

Contact Tecplot via the email -- sales at Tecplot dot com -- to get your license upgraded.

Scott
scott_rumage is offline   Reply With Quote

Old   July 30, 2014, 17:43
Default
  #11
Senior Member
 
Scott Rumage
Join Date: May 2009
Location: Seattle, WA
Posts: 152
Rep Power: 17
scott_rumage is on a distinguished road
Tecplot intern Devon Simpson has written a blog that provides a script and data showing how to use Wen Long’s Mat2Tecplot.m converter. The blog is located here: http://www.tecplot.com/blog/2014/07/28/create-tecplot-format-files-matlab-data/ .


Regards,
Scott
scott_rumage is offline   Reply With Quote

Old   December 12, 2014, 16:05
Default What version of Tecplot are you using
  #12
Member
 
Durrell Rittenberg
Join Date: May 2011
Location: Bellevue WA
Posts: 38
Rep Power: 15
Durrell4 is on a distinguished road
Send a message via MSN to Durrell4 Send a message via Yahoo to Durrell4 Send a message via Skype™ to Durrell4
Hi nacera,

What version of Tecplot are you using?

Durrell
Durrell4 is offline   Reply With Quote

Old   December 30, 2014, 12:36
Default how can i visualize isotherms and streamlines using this way?
  #13
Member
 
amine
Join Date: Jun 2012
Posts: 65
Rep Power: 13
lbmagis is on a distinguished road
Hello,
Could any one tell us how to use this way to visualize isotherms and streamlines in 2Dimensions.
Thank you
lbmagis is offline   Reply With Quote

Old   December 30, 2014, 12:51
Default Check out the videos at the link below
  #14
Member
 
Durrell Rittenberg
Join Date: May 2011
Location: Bellevue WA
Posts: 38
Rep Power: 15
Durrell4 is on a distinguished road
Send a message via MSN to Durrell4 Send a message via Yahoo to Durrell4 Send a message via Skype™ to Durrell4
Quote:
Originally Posted by lbmagis View Post
Hello,
Could any one tell us how to use this way to visualize isotherms and streamlines in 2Dimensions.
Thank you
One can add streamlines interactively via the streamtrace placement tool on the sidebar.


Isotherms can be produced via our contour groups and using a surface contour.

Check out some the videos on using Tecplot here http://www.tecplot.com/products/tecp...deo-tutorials/

Best

Durrell
Durrell4 is offline   Reply With Quote

Old   February 2, 2015, 08:38
Default Superpose two matlab figures or more in one figure like these
  #15
Member
 
amine
Join Date: Jun 2012
Posts: 65
Rep Power: 13
lbmagis is on a distinguished road
Hello and thank you so much for your quick reply

what i am intresting in is how to put many contours on the same matlab's figure? like these below: look to one of these figures ,please let's choose the first one on the left, did you observe that on the first contour (dashed lines), there's another one but with (solid lines).

how can i make the same thing???
NB: no way to imagesc them at the same time on the matlab code, we obtain these contours one by one .... so i thinking about export them (2 contours or more) together to tecplot wishing make the necessary post-processing treatment
in order to get the same result
Thanks
Attached Images
File Type: jpg matlab.jpg (82.0 KB, 32 views)
lbmagis is offline   Reply With Quote

Old   July 6, 2015, 04:53
Default
  #16
New Member
 
Oğuzhan Medet
Join Date: Jul 2015
Posts: 3
Rep Power: 10
the_aviator is on a distinguished road
i need help about processing a test data in matlab. after processing matlab, i have to transfer it to tecplot. Who can help me?
the_aviator is offline   Reply With Quote

Old   July 6, 2015, 18:23
Default
  #17
New Member
 
wen long
Join Date: May 2012
Posts: 29
Rep Power: 13
wenlong is on a distinguished road
I can if you describe your data and upload a mat file somewhere
wenlong is offline   Reply With Quote

Old   July 7, 2015, 01:15
Default
  #18
New Member
 
Oğuzhan Medet
Join Date: Jul 2015
Posts: 3
Rep Power: 10
the_aviator is on a distinguished road
my data is 240*216 matrix. My task is to transform it to a form which tecplot can read and can plot a graph or can simulate it.
the_aviator is offline   Reply With Quote

Old   July 7, 2015, 03:52
Default
  #19
New Member
 
wen long
Join Date: May 2012
Posts: 29
Rep Power: 13
wenlong is on a distinguished road
very easy, follow one of the 2D ij- examples in mat2tecplot
wenlong is offline   Reply With Quote

Old   July 7, 2015, 04:14
Default
  #20
New Member
 
Oğuzhan Medet
Join Date: Jul 2015
Posts: 3
Rep Power: 10
the_aviator is on a distinguished road
can you send me the link?
the_aviator is offline   Reply With Quote

Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are On



All times are GMT -4. The time now is 07:25.