plot if FOR loop
I want to plot some figure in a "FOR" loop. i use "hold on" to have one figure but i want to have graphs in different colors. please guide me. ... 14 Feb 2010 16:16
changing select values in a vector
I want to change values of vector 'a' that are less than 0 to a(n)+10. This code does produce the correct values, but for the values that dont meet the criterion 'a(n)<0' a zero is inserted into the vector b instead of the original value. Any ideas? for n=1:length(a) if a(n)<0 b(n)=a(n)+10 end end ... 14 Feb 2010 10:39
using trap to numerically integrate between bounds
Hi, I have a set of data points in which I would like to numerically integrate using trap. Rather than just calculate the area under the curve, I would like to plot the integral with respect to time. So what I am trying to do is perform the integral between two times, increment the time step to integrate and populate a... 14 Feb 2010 07:22
imnoise and de-noise problem
Hi, I have a question about imnoise and de-moise of matlab problem. The question is as below. Create noisy images, using imnoise(im, &lsquo;salt&amp;pepper&rsquo;, lvl) from Matlab, using levels 0.01, 0.02, 0.03 and 0.04 Show de-noising results with Average and Median filters of size 3x3, 5x5 and 11x11. Do not... 14 Feb 2010 11:46
building matrix with diffrent rows length
Hi, I want to build matrix X in 'for' loop by: for i=1:50 v=bla bla bla; % v is row vector X(i,:)=v; end the problem that the length of vector v is changed every loop, I try to set X(1:100,1:100)=0 but it didn't work. What can I do about? ... 14 Feb 2010 09:33
solve Ax=0
I have a equation AX=0; which A is parametric. First I solved det(A)=0 and then I use null(A) to give me X. But when I use subs() function and then use null(A), reply is 3 column and it is not true. Would you please help me. syms x A=[1 1 0 0;2 3 4 0;cos(x) cosh(x) 0 1;sin(x) sinh(x) 1 1]; y=det(A) reply: y=4*c... 14 Feb 2010 06:17
Calculating the age of a person
"Miki Nikolic" <mni(a)e-mid.dk> wrote in message <40048534$0$30078$edfadb0f(a)dtext01.news.tele.dk>... Hi, Can somebody help me with a accurate way to calculate the age of a person when the input to the function is the date of birth in the form DD/MM/YYYY? I was trying for example: (datenum('09/29/1... 14 Feb 2010 04:08
How draw a marker at the intersection of join of two lines?
See Subject. I seldom use ML, but I'm told it can be done. My real app is for Python Matplotlib. There's likely a corresponding way there, hopefully with the same name. ... 14 Feb 2010 19:37
Please help
hi, guys as i'm new to matlab & i need to create a double delay line filter in time domain it's equation is s(t)-2*s(t-T)+s(t-2T) . And later i have to put the result in a column matrix & get the plot of this result. Please do provide me with the matlab code fir this data given above. ... 13 Feb 2010 21:37
LED with matlab
Hi!! All of my friends I have a problem I have 16-LED(light emitting diodes). It connect with controller.The controller and PC i usually connect with cabel. I want to control this LED via matlab program.I used following comments obj=serial('COM1'); set(obj,'baudrate',115200); set(obj,'databits',8); set(obj,'Tim... 13 Feb 2010 21:37