Resuelto


Add two numbers
Given a and b, return the sum a+b in c.

alrededor de 10 años hace

Resuelto


Make a checkerboard matrix
Given an integer n, make an n-by-n matrix made up of alternating ones and zeros as shown below. The a(1,1) should be 1. Example...

alrededor de 10 años hace

Resuelto


Triangle Numbers
Triangle numbers are the sums of successive integers. So 6 is a triangle number because 6 = 1 + 2 + 3 which can be displa...

alrededor de 10 años hace

Resuelto


Find the sum of all the numbers of the input vector
Find the sum of all the numbers of the input vector x. Examples: Input x = [1 2 3 5] Output y is 11 Input x ...

alrededor de 10 años hace

Resuelto


Make the vector [1 2 3 4 5 6 7 8 9 10]
In MATLAB, you create a vector by enclosing the elements in square brackets like so: x = [1 2 3 4] Commas are optional, s...

alrededor de 10 años hace

Resuelto


Times 2 - START HERE
Try out this test problem first. Given the variable x as your input, multiply it by two and put the result in y. Examples:...

alrededor de 10 años hace

Pregunta


locate particles in squares (combinatorics)
I have a problem: I have a lot of particles with given coordinates (x,y). My (x,y) plane is divided into a bunch of squares 32x...

alrededor de 10 años hace | 1 respuesta | 0

1

respuesta

Respondida
How do I store user input values from a for loop?
Create a vector to store your data,say,a: a=zeros(x,1) in for loop save values on each step: for R=1:x a(R)=input('W...

alrededor de 10 años hace | 0

Respondida
Extract multiple data series from *.fig
1) get id of your axes: a=get(gcf,'Children') 2) get data you needed: y=(get(a(1),'Children'),'YData') If there is ...

alrededor de 10 años hace | 0

Respondida
Double integral of a simple function
integral2 http://www.mathworks.com/help/matlab/ref/integral2.html

alrededor de 10 años hace | 0

Respondida
Help: Display a different layout when pushing a button in a GUI?
Didn't see your code. In your push button callback function write: set("edit box id",'String','tab2'), where "edit box id" is yo...

alrededor de 10 años hace | 0

Pregunta


Debug mode in code with blocks(cells)
Hi, I often use blocks (cells?) (%%) in my programm. When I want to debug,say,third block, I insert breakpoint somewhere in this...

alrededor de 10 años hace | 2 respuestas | 1

2

respuestas

Respondida
Delet zeros after final number
There are plenty of ways to do that. For instance, find(A) will find indexes of all nonzero elements. So you can write: B= A(...

alrededor de 10 años hace | 0

Pregunta


Subtract column from a matrix
In matlab it is easy to subtract number from column or row. I want to subtract column [n x 1] from a matrix [n x m]. Is it possi...

alrededor de 10 años hace | 2 respuestas | 0

2

respuestas

Respondida
mean without stable step
You can write a=mean(M,2) - this will find mean of matrix M along each column. And then take only values you need. For 3033*2005...

alrededor de 10 años hace | 0

Respondida
Find a real number
You can adopt rand function: 10*rand+10 will give you random real number from 10 to 20 randi(10) will give you random integer...

alrededor de 10 años hace | 0

| aceptada

Respondida
convert number to string but keep it the same as it is
You can convert each number separetely in the for loop. for i=1:numel(M) out(:,i)=int2Str(M(i)) end And you will h...

alrededor de 10 años hace | 0

Respondida
how to save the content of the current figure as an image?
If you want to save in with your hands - just click file-> save figure. Or use http://www.mathworks.com/help/matlab/ref/imwri...

alrededor de 10 años hace | 0

Pregunta


Cannot set axes limits
Hi, I am working with GUI interface. I want to set ,y own xlimits and ylimits. But I cannot do it: figure('name','MomentFinde...

alrededor de 10 años hace | 1 respuesta | 0

1

respuesta

Respondida
matrix with different randperm rows
Yes, try http://www.mathworks.com/help/matlab/ref/perms.html

alrededor de 10 años hace | 0

Respondida
GUI how can I connect check boxes to uitable?
Try to define them as children of uitable. Similar to uipanel (see example on this page http://www.mathworks.com/help/matlab/ref...

alrededor de 10 años hace | 0

Respondida
How to make 'blue' variable?
<</matlabcentral/answers/uploaded_files/18181/Untitled.png>> Look! only 1 global variable is defined, however you can see a l...

alrededor de 10 años hace | 0

Pregunta


How to make 'blue' variable?
Hi all, I'm trying to make my own ImageViewer. Using some program as a template, I saw a lot of 'blue' variables in it (when I p...

alrededor de 10 años hace | 2 respuestas | 0

2

respuestas

Pregunta


Scrolling and choosing image to display on figure.
Hi there, I have a bunch of images. After some processing, I want to display them. However there are a lot of them. So I want to...

alrededor de 10 años hace | 2 respuestas | 0

2

respuestas

Respondida
how to create text file
Hi, http://www.mathworks.com/help/matlab/ref/fprintf.html - to write into a file (and create it) http://www.mathworks.com/he...

alrededor de 10 años hace | 0

| aceptada

Pregunta


How can I install user-developed toolbox?
http://www.mathworks.com/matlabcentral/fileexchange/27659-pivlab-time-resolved-particle-image-velocimetry--piv--tool Like thi...

alrededor de 10 años hace | 1 respuesta | 0

1

respuesta

Pregunta


"Download App" in File Exchange
In File Exchange, when I choose some application, say, <http://www.mathworks.com/matlabcentral/fileexchange/47602-reversi Reve...

alrededor de 10 años hace | 2 respuestas | 0

2

respuestas

Respondida
how to plot double integral of bessel function?
Do you have Symbolic Math Toolbox? Function int is in this toolbox.

más de 10 años hace | 0

Respondida
imshow does not work in 2014a
No! Imread doesn't require Image Processing Toolbox. Once again: type ver in command line and check if you have Image Process...

más de 10 años hace | 0

Respondida
imshow does not work in 2014a
That is because you don't have Image Processing Toolbox required for imshow

más de 10 años hace | 1

Cargar más