inconsistent calculation in matlab
Hi all, I encountered strange problem. Please run the below code. To my mind, the size of data0 and data 1 should be same (and should be 48 by 48), but data0 is 49 by 49. Could you help me why this happens? ========================= x=0.5; b=5; c=0.2; data=rand(2400, 2400); data0=imresize(data, x/b*c, 'nea... 22 Feb 2010 19:48
Two same models but different results? Using SimPowerSystems and SimMechancis
I build two models using SimPowerSystems and SimMechanics. The two models are the same in the main blocks. The only difference is the second model has more scopes then the first one. However, these two models give two quite different results. Does SimPowerSystems or SimMechancis have this kind of problem? Thank y... 24 Feb 2010 14:16
Inverse PSD
Dear all I have a SPD spectrogram, and need to convert it to time state spectrom. Upshot i need PSD inverse function. Thanks all, sajadagh20(a)gmail.com ... 23 Feb 2010 02:27
Forcing grid lines at certain locations?
Hi, Is there a way to tell Matlab where I want the grid lines for either of the axis? I did a get(gca), but did not find any property of the axis that sounded like the location of the grid lines. I could, off course, use "line" to draw the grid lines programatically, but I'm hoping there is a property I can se... 22 Feb 2010 23:09
contrast enhancement
Hi everyone, Here, I have performed the transformation of a given image using the tranformation shown below. The norma image s=(-0.0107)+(0.0107)*exp(4.5510*double(norma)); figure,imshow(s) title('tranformed image') The operation on any image results in an binary image. I want to know if it is right or ther... 22 Feb 2010 16:24
Overlay a 3D mesh onto a 3D image
Well, I just wanted to post that I've figured out one way to do this. I got the idea from Doug's December 2009 post on <a href="http://blogs.mathworks.com/videos/2009/12/07/basics-volume-visualization-99-unifying-example/">Volume Visualization</a>. First, I generate a grid of 3D spatial coordinates (x, y, and z) usi... 22 Feb 2010 16:24
Expanding function parameters
If there is a function with a variable number of parameters, is there a way to expand a vector or matrix to fill them each by each? In python, e.g., one can put a "*" in front of a list and it will expand to fill the positional parameters. I would especially like to expand a struct or a cell array this way , in order... 22 Feb 2010 16:24
PCA2D face recognition,PCA with matlab
i have developped face recogniton by using PCA2D.in my program after using imread to read image, i applay a convertion into double type: x=imread(path) y=double(x); i had to do this because most of matlab application are programmed in double type such as transposition of matrix;in fact;without this conversion i have... 22 Feb 2010 15:16
extracting vectors from a plot
Hi guys, Anyone knows how can one extract vectors of a 3D plot? Thanks alot. Would really appreciate any hints. Ana ... 22 Feb 2010 18:41
in polygon
i try check if point inside polygon using sum of all angles inside ... =0 it not work in all case some idea here is the code =========== clc; xy=[ 0.3 0.4 0.3 0.6 0.5 0.6 0.5 0.4 %0.3 0.4 i try to put first point duplicate it not help ... 23 Feb 2010 13:33