|
[Sponsors] |
Problem with extracting data from contour in matlab |
![]() |
|
LinkBack | Thread Tools | Search this Thread | Display Modes |
![]() |
![]() |
#1 |
Member
Mihir Makwana
Join Date: May 2015
Posts: 79
Rep Power: 11 ![]() |
I have plotted temperature field on a square domain with 80X80 grid points using a contour command in MATLAB
contourf(xp,zp,T_new,25); where xp,zp : co-ordinates T_new : Temperature of which contour is to be plotted I have a " .fig " file of the contour. I want to get the temperature values at all the 80X80 points in the form of a matrix using this " .fig " file . Can anyone please tell me the syntax to extract the data ? I searched various forums but I am not able to get the solution to this. Please help. Thanks in advance. -Mihir |
|
![]() |
![]() |
![]() |
![]() |
#2 | |
Senior Member
Filippo Maria Denaro
Join Date: Jul 2010
Posts: 6,830
Rep Power: 73 ![]() ![]() ![]() |
Quote:
I am not sure to understand your question ... the variable T_new should already be a 80x80 matrix ...thus, you have all values you want |
||
![]() |
![]() |
![]() |
![]() |
#3 | |
Member
Mihir Makwana
Join Date: May 2015
Posts: 79
Rep Power: 11 ![]() |
Quote:
T_new is 80X80 matrix : This I know as I had taken the no. of grid points in both directions as 80 I just need the syntax to extract the 80X80 matrix from the .fig file . - Mihir |
||
![]() |
![]() |
![]() |
![]() |
#4 |
Senior Member
Filippo Maria Denaro
Join Date: Jul 2010
Posts: 6,830
Rep Power: 73 ![]() ![]() ![]() |
||
![]() |
![]() |
![]() |
![]() |
#5 |
Member
Mihir Makwana
Join Date: May 2015
Posts: 79
Rep Power: 11 ![]() |
||
![]() |
![]() |
![]() |
![]() |
#6 |
Member
Alex
Join Date: Jan 2014
Posts: 54
Rep Power: 12 ![]() |
You really cant figure this out and you are a PhD student?
I was going to write about using fopen and creating a filestream, but matlab has a quick command to do this: http://www.mathworks.com/help/matlab/ref/dlmwrite.html The .fig file contains information about the figure only. |
|
![]() |
![]() |
![]() |
![]() |
#7 | |
Senior Member
Filippo Maria Denaro
Join Date: Jul 2010
Posts: 6,830
Rep Power: 73 ![]() ![]() ![]() |
Quote:
https://www.mathworks.com/matlabcent..._thread/249507 But I still believe you have to work on the original matrix instead of using this method....rum again the code and write the Matrix on a file to manage after. |
||
![]() |
![]() |
![]() |
|
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
Moving boundary problem based on calculated data | sandro.grm | OpenFOAM Programming & Development | 52 | October 28, 2023 13:10 |
How to assign the inlet B.C using a bunch of data set for an unsteady problem? | ali8500 | CFX | 3 | March 28, 2012 18:41 |
[OpenFOAM] How to create an contour plot for arbitrary plane with interpolated data | navaladi | ParaView | 0 | June 4, 2008 07:57 |
Exporting data to MATLAB | Ryan | FLUENT | 2 | July 12, 2006 06:41 |
How to update polyPatchbs localPoints | liu | OpenFOAM Running, Solving & CFD | 6 | December 30, 2005 17:27 |