Beantwortet
How do I plot a line with both thick and thin dashes?
Christopher, could it be the plot grid you are talking about? You can turn it on/off using |grid on| and |grid off|. If it is no...

mehr als 12 Jahre vor | 0

Beantwortet
ode 45 plot of intermediate vraibles of differential equations
Thayumanavan, after the |ode45| call, compute |P|: [t,x]=ode45(@myfunc,Tspan,X0); P = sqrt(x(:,1) + x(:,2)); plot...

mehr als 12 Jahre vor | 0

| akzeptiert

Beantwortet
Formatting Sea Level Data
Edu, this should do: ndays = length(data(:,1))/2; ndata = ndays*24; Tdata = data(:,1); Rdata = reshape(data(:,2:en...

mehr als 12 Jahre vor | 0

| akzeptiert

Beantwortet
autosave a image of figure
Suryakanth, in the code you are showing the variable |fullFileName| is not defined, which is why you get an error for the comman...

mehr als 12 Jahre vor | 0

| akzeptiert

Beantwortet
How to store the result of each iteration of a forloop into an array MATLAB
Chandra, use v{i,j} = tf([K(i*j)],[T(i*j) one(i*j)], [L(i*j)])

mehr als 12 Jahre vor | 0

| akzeptiert

Beantwortet
How to use a loop to create a function calculate a numerical estimate of the integral?
Georgia, check out the following: function sol = my_int(f, ablim, n) % function f on the given range, using the left-re...

mehr als 12 Jahre vor | 1

Beantwortet
how to merge two vectors
How about: C = B + [A zeros(1,length(B)-length(A))] assuming that by merge you mean add-merge. If it's just about adjust...

mehr als 12 Jahre vor | 0

| akzeptiert

Beantwortet
Integration function generates different result by a same expression
Tiger, this is because these are indefinite integrals. Solutions to indefinite integrals can differ by a constant. If you make t...

mehr als 12 Jahre vor | 0

| akzeptiert

Beantwortet
I am getting error in this code?
Rajasekhar, use f = @(x) cos(x)./x; q = integral(f,0.1,10) There is a problem though with |f| approaching |inf| as yo...

mehr als 12 Jahre vor | 1

Beantwortet
expected value of 'exp2' fit for an unavailable data point using available data
Hello Mohammad, you can retrieve the curve fitting parameters using |coeffvalues|, define an anonymous function, and then evalu...

mehr als 12 Jahre vor | 0

Beantwortet
How can I convert this circle drawing code as a Function code? thank you
Maitham, check out the following: function my_circ(imageSize, center, radius) % function definition % Create a logi...

mehr als 12 Jahre vor | 1

| akzeptiert

Beantwortet
How can I calculate the difference in time (seconds) with datetime?
If you are starting with date strings, use <http://www.mathworks.com/help/matlab/ref/datenum.html |datenum|> to convert dates in...

mehr als 12 Jahre vor | 1

| akzeptiert

Beantwortet
refreshdata: stop axis updates
Linford, how about refreshing only the data in the loop using the |set| command: h = surf(X,Y,Z) ... set(h,'ZData',ne...

mehr als 12 Jahre vor | 0

| akzeptiert

Beantwortet
hi..i am writing the code for recursive mean separate histogram equalization..i am getting an error called "Undefined function 'averpixcal' for input arguments of type 'double'."when calling the function 'averpixcal'..code is attached for reference
Vishwas, a couple of thoughts: * Comments in MATLAB appear after percent symbols. E.g., |% This is a comment| * Is the code ...

mehr als 12 Jahre vor | 1

Beantwortet
How do I find a solution to (x.^2)/2-10*atan(x) using the Newton-Raphson method?
Hana, there are a couple of issues with your code. This should work: function Xs = newtonroot(Xest) imax = 100; Err ...

mehr als 12 Jahre vor | 0

| akzeptiert

Beantwortet
problem with 'PLOT' while plotting data acquired from NI DAQ Board
Shailendra, |plot| needs to be spelled lower-case: plot(time, data)

mehr als 12 Jahre vor | 0

Beantwortet
Why is there an error when I called the function inputting the points
Ehi, you need to define function |f| again in |refine()| to make it work. In other words: function points = refine(x1, x2, ...

mehr als 12 Jahre vor | 0

| akzeptiert

Beantwortet
How do I plot d using Matlab
Use Nt = 1000 t = linspace(0,100,Nt+1) d = 0.005*sin(0.5*pi*t).*cos(0.5*pi*t) plot(t,d) Any reason you are us...

mehr als 12 Jahre vor | 0

| akzeptiert

Beantwortet
Subplotting many images in one figure
Edu, this should do: for ii = 1:8 file_name = strcat('Point0',num2str(ceil(ii/4)),'Pic',num2str(ii-4*(ii>4)),'_14012...

mehr als 12 Jahre vor | 1

| akzeptiert

Beantwortet
is it possible that create a exe. working on computer hasnt installed Matlab ?
Yunus, you need <http://www.mathworks.com/products/compiler/ MATLAB Compiler> (and therefore MATLAB) to create the .exe file. To...

mehr als 12 Jahre vor | 0

| akzeptiert

Beantwortet
euclidean distance between two cell.
Thomas, use pdist([reshape(cell2mat(Z1),2,3); reshape(cell2mat(Z2),3,3)]) assumming that |Z1| contains two cells of 1-by...

mehr als 12 Jahre vor | 0

| akzeptiert

Beantwortet
Plot is zeroed out, how to fix this?
Mike, after initializing |u| to zero you enter the first loop that increments |n| all the way to |N|. Which is why you never ent...

mehr als 12 Jahre vor | 0

Beantwortet
How can I read a complex number vector?
André Luiz, this should do: fid = fopen ('VarName4.txt','r'); ii = 1; while ~feof(fid) acorrente(ii, :) = st...

mehr als 12 Jahre vor | 0

| akzeptiert

Beantwortet
log scale y-axis for periodogram
Philippe, it is. Use pxx = periodogram(x,window,nfft) plot(10*log10(pxx)) to plot the periodogram.

mehr als 12 Jahre vor | 0

Beantwortet
vectorize a loop with product and sum operations
Francesco, use bsxfun(@plus, x'*v, x')

mehr als 12 Jahre vor | 0

| akzeptiert

Beantwortet
a chronometer in GUI
There is an app very much like the one you are looking for on <http://www.mathworks.de/matlabcentral/fileexchange/36365-chronome...

mehr als 12 Jahre vor | 0

| akzeptiert

Beantwortet
Problem in saving figure
This <http://www.mathworks.com/matlabcentral/answers/100366#answer_109714 answer> illustrates the how-to well. Simply clip the f...

mehr als 12 Jahre vor | 0

| akzeptiert

Beantwortet
How to change the default background color of a Smith Chart to white?
Hello Floyd, yes it can. Insert myfigure = figure('Color',[1 1 1]); % [1 1 1] corresponds to "white" right before |s...

mehr als 12 Jahre vor | 1

| akzeptiert

Beantwortet
Dynamic Obstacle in matlab environment
I strongly recommend not to "randomize" the position vector since this results in a non-differentiable function. Start with acce...

mehr als 12 Jahre vor | 1

Beantwortet
From "Matlab Function" block in Simulink to Workspace in Matlab
Artur, are you referring to the <http://www.mathworks.com/help/simulink/slref/toworkspace.html |simout|> block? That is typicall...

mehr als 12 Jahre vor | 0

Mehr laden