Solved


Remove the vowels
Remove all the vowels in the given phrase. Example: Input s1 = 'Jack and Jill went up the hill' Output s2 is 'Jck nd Jll wn...

8 years ago

Solved


Remove all the consonants
Remove all the consonants in the given phrase. Example: Input s1 = 'Jack and Jill went up the hill'; Output s2 is 'a ...

8 years ago

Solved


Back and Forth Rows
Given a number n, create an n-by-n matrix in which the integers from 1 to n^2 wind back and forth along the rows as shown in the...

8 years ago

Solved


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

8 years ago

Solved


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

8 years ago

Solved


Create times-tables
At one time or another, we all had to memorize boring times tables. 5 times 5 is 25. 5 times 6 is 30. 12 times 12 is way more th...

8 years ago

Answered
Output of Function in Form of 'Color',[0 0.2 0.4]!
clrs('blue') returns ans = 'Color' [1x3 double] so you cannot use it directly in the plot command. F...

8 years ago | 0

Answered
Error using vertcat Dimensions of matrices being concatenated are not consistent.
You're trying to concatenate a matrix [1 Zt] which is of dimension 1*602 with a matrix [0 1] which is of dimension 1*2. PS : ...

8 years ago | 0

Answered
How to fill a bar graph with colored (hatching) patterns?
I am not sure it is implemented in Matlab (maybe using the 'stacked' option of bar graph, you can have a look <https://fr.mathwo...

8 years ago | 0

Answered
using mat2cell
Maybe not the easiest solution, but try something like : j=1; for i=1:10:201 A{j}=M(i:i+9,:); j=j+1; end

8 years ago | 1

Solved


"Look and say" sequence
What's the next number in this sequence? * [0] * [1 0] * [1 1 1 0] * [3 1 1 0] * [1 3 2 1 1 0] This a variant on the w...

8 years ago

Solved


Alternating sum
Given vector x, calculate the alternating sum y = x(1) - x(2) + x(3) - x(4) + ...

8 years ago

Solved


Project Euler: Problem 6, Natural numbers, squares and sums.
The sum of the squares of the first ten natural numbers is, 1^2 + 2^2 + ... + 10^2 = 385 The square of the sum of the first ...

8 years ago

Solved


Sum all integers from 1 to 2^n
Given the number x, y must be the summation of all integers from 1 to 2^x. For instance if x=2 then y must be 1+2+3+4=10.

8 years ago

Answered
How to work out the position vector?
If you define t=0:0.4:40; then you have size(sin(t)) ans = 1 101 but 0 is a scalar of dimension 1*1 ...

8 years ago | 0

Answered
how to plot multiple curves in the same figure
Have a look at the <https://fr.mathworks.com/help/matlab/ref/hold.html hold on> function

8 years ago | 0

Answered
error using interp1 !!
Maybe the problem comes from the fact that colInd(IndnNAN(r,:)) ans = 1×0 empty double row vector and so is MyMatri...

8 years ago | 0

Answered
change data from cell array to a matrix
To convert a cell array to a matrix, you can use cell2mat : help cell2mat cell2mat Convert the contents of a cell array i...

8 years ago | 0

| accepted

Answered
i don't sure if this code is ture which is written by myself,please help me to check with it,which is about the DFT .and i am new with it.thanks
I think what you want to do is explained here : <https://fr.mathworks.com/matlabcentral/answers/166660-doing-dft-without-usin...

8 years ago | 0

| accepted

Answered
Ubuntu: Fatal Internal Error on Startup
Did you have a look <https://fr.mathworks.com/matlabcentral/answers/363055-matlab-r2017b-not-running-on-ubuntu-17-10 here> ?

8 years ago | 0

Answered
i don't sure if this code is ture which is written by myself,please help me to check with it,which is about the DFT .and i am new with it.thanks
Your first lines are: if true % code end It seems to be useless. Then you define some constants and a vector "inp...

8 years ago | 0

Answered
what is wrong with my code? vertcat error
You are trying to define a matrix that can not exist. In your case, t is a vector of dimension 101 size(t) ans = ...

8 years ago | 0

Solved


Removing rows from a matrix is easy - but what about inserting rows?
Assume A is a 5-by-5 matrix. A([2,4],:) = [] is a quick way to remove rows 2 and 4. Can you find a quick way to insert rows into...

8 years ago

Solved


Make a Star Pyramid
Create a star pyramid. First line will have 1 star, second will have two stars and so on... a basic program which is easily done...

8 years ago

Solved


"mirror" matrix
Create n x 2n "mirror" matrix of this type: Examples For n = 2 m = [ 1 2 2 1 1 2 2 1 ] For n = 3 m = ...

8 years ago

Solved


Create a Multiplication table matrix...
Create a product table in this format: P = [ 1 2 3 4 5; 2 4 6 8 10; 3 6 9 12 15; 4 8 12 1...

8 years ago

Solved


Symmetric matrix
You must create a n-by-n *symmetric* matrix such that A(row,col) = row/col for col >= row. Example if n =3 : output is : ...

8 years ago

Solved


Special matrix
Make a square matrix with this shape. For n=4 M = 1 1 0 0 1 0 1 0 0 1 0 ...

8 years ago

Solved


Magic is simple (for beginners)
Determine for a magic square of order n, the magic sum m. For example m=15 for a magic square of order 3.

8 years ago

Answered
Clarification regarding license of MATLAB
Did you contact <https://mathworks.com/company/aboutus/contact_us.html?s_tid=gn_cntus Mathworks> , as suggested ?

8 years ago | 0

Load more