A résolu


Determine whether a vector is monotonically increasing
Return true if the elements of the input vector increase monotonically (i.e. each element is larger than the previous). Return f...

presque 11 ans il y a

A résolu


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...

presque 11 ans il y a

A résolu


Column Removal
Remove the nth column from input matrix A and return the resulting matrix in output B. So if A = [1 2 3; 4 5 6]; and ...

presque 11 ans il y a

A résolu


Select every other element of a vector
Write a function which returns every other element of the vector passed in. That is, it returns the all odd-numbered elements, s...

presque 11 ans il y a

A résolu


Is my wife right?
Regardless of input, output the string 'yes'.

presque 11 ans il y a

A résolu


Determine if input is odd
Given the input n, return true if n is odd or false if n is even.

presque 11 ans il y a

A résolu


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

presque 11 ans il y a

A résolu


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 ...

presque 11 ans il y a

A résolu


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...

presque 11 ans il y a

A résolu


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:...

presque 11 ans il y a

A résolu


Fahrenheit to Celsius using multiple statements
Given a Fahrenheit value F, convert to a Celsius value C. While the equation is C = 5/9 * (F - 32), as an exercise use two state...

presque 11 ans il y a

A résolu


Most nonzero elements in row
Given the matrix a, return the index r of the row with the most nonzero elements. Assume there will always be exactly one row th...

presque 11 ans il y a

A résolu


Swap the first and last columns
Flip the outermost columns of matrix A, so that the first column becomes the last and the last column becomes the first. All oth...

presque 11 ans il y a

A résolu


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...

presque 11 ans il y a

A résolu


Find all elements less than 0 or greater than 10 and replace them with NaN
Given an input vector x, find all elements of x less than 0 or greater than 10 and replace them with NaN. Example: Input ...

presque 11 ans il y a

Question


bug in zoom in timeseries plot
before i report a bug i want to ask if someone have a problem with the zoom button on a timeseries plot. i create a time-seri...

environ 11 ans il y a | 1 réponse | 0

0

réponse

Réponse apportée
How Can I Assign variable Name?
you can use <http://www.mathworks.com/help/matlab/ref/eval.html eval> function.but it not recommended. and you cannot use / in ...

environ 11 ans il y a | 0

Réponse apportée
create new matrix with special structure
The simple way: for j=0:2:m-1 for i=1:n newmatrix(1+j,2*i-1:2*i)=p(j+[1 2],1); end end

environ 11 ans il y a | 0

Réponse apportée
Concatenate two cells into another
do you try to use <https://www.mathworks.com/help/matlab/ref/strcat.html strcat>? It allow you to concatenate two cells. ...

environ 11 ans il y a | 0

| A accepté

Réponse apportée
i dont know why my code is not working..
plot(f,Pyy(1:2^(N-1))); the length of pyy in 14 so you cannot take cell number 16384 (2^13). another problem: length(f)=81...

environ 11 ans il y a | 0

Réponse apportée
Save figures in a subfolder after 2 for loops?
use <http://www.mathworks.com/help/matlab/ref/mkdir.html mkdir> to create a folder and change the folder name you save on to the...

environ 11 ans il y a | 0

| A accepté

Question


using xlsread for cell variable
I have a data store in .csv files. in the data i have vector of number that i want get in cell not in string (and some more data...

environ 11 ans il y a | 2 réponses | 0

2

réponses

Question


save an excel file to be read only
can we save data on excel file (by xlswrite function or other way) and define the file to be read-only from matlab?

environ 11 ans il y a | 2 réponses | 0

2

réponses

Question


find n-st element that meet a logical expression
I have 2 question: 1) find function can give the all n-th element (first or last) that meet a logical expression. i want only t...

environ 11 ans il y a | 1 réponse | 0

1

réponse

Réponse apportée
Function to aggregate data
first you don't need to put them together, you just need to track the line you want and take them from the second matrix (for ex...

environ 11 ans il y a | 0

Question


dynamic y-tick label
It have a way to save the y-tick to be dynamic and decide what will be the label format. In default is show 5 number, i want to...

plus de 11 ans il y a | 1 réponse | 0

1

réponse

Question


save size of Matlab environment variable
Hi, I have some question about the presentation of variable in Variables window. 1) I have a matrix with 18 Column. when ...

plus de 11 ans il y a | 1 réponse | 0

1

réponse

Question


It is possible to find all m-file i call to another m-file?
my problem is that i create a function and call it in several programs (m-files), now i find a better way and change the functio...

plus de 11 ans il y a | 1 réponse | 0

1

réponse

Réponse apportée
Problem in using the "While" loop function
you need to define all variables. n(1)=n0; while 1 if n(end) <=0 break; end n(end+1)=n(end)-S*exp(...

plus de 11 ans il y a | 0

| A accepté

Réponse apportée
plotting using data from a cell array
you can use <http://www.mathworks.com/help/matlab/ref/bar.html bar> and specify xlabel name. figure name = {'m1';'m2';'m...

plus de 11 ans il y a | 0

Charger plus