已解决


Column norms of a matrix
Given a matrix M, return a vector y such that for each k y(k)=norm(M(:,k)) (y(k) is the Euclidean norm of the k-th col...

8 days 前

已解决


Create a Standard Size Vector
Given an input x, create a row vector y from 1 to x with 5 elements.

8 days 前

已解决


Square a Number
Given an input x, return y, which is equal to the square of x.

8 days 前

已解决


Matlab Basics - y as a function of x
Write a function to calculate y as a function of x, such that y = 6x^2 + 5x - 2

8 days 前

已解决


03 - Matrix Variables 4
Make the following variable: <<http://samle.dk/STTBDP/Assignment1_3d.png>> A 3x4 NaN (Not a Number) matrix (Hint: use ...

8 days 前

已解决


Create a two dimensional zero matrix
You have to create a zero matrix of size (mxn) whose inputs are m and n and the elements of your matrix should be zeros. Exam...

8 days 前

已解决


Find nth maximum
Find nth maximum in a vector of integer numbers. Return NaN if no such number exists. x = [2 6 4 9 -10 3 1 5 -10]; So ...

8 days 前

已解决


First non-zero element in each column
For a given matrix, calculate the index of the first non-zero element in each column. Assuming a column with all elements zero i...

8 days 前

已解决


Transpose
Write a MATLAB script in order to convert a random length row vector (v) into a column vector.

8 days 前

已解决


Find the index of the largest value in any vector X=[4,3,4,5,9,12,0,4.....5]
The given function returns the index of the maximum value in a given matrix. such as X=[4,3,4,5,9,12,0,5] Ans= 6 if maxim...

8 days 前

已解决


Remove the two elements next to NaN value
The aim is to *remove the two elements next to NaN values* inside a vector. For example: x = [6 10 5 8 9 NaN 23 9 7 3 21 ...

8 days 前

已解决


Arrange Vector in descending order
If x=[0,3,4,2,1] then y=[4,3,2,1,0]

9 days 前

已解决


Related Vectors
I have two vectors A & B. If the values in vector A is zero then the corresponding value in vector B should be zero. Example:...

9 days 前

已解决


Add a row of zeros on top of a matrix
Given a matrix, insert a row of zeros as the top row.

9 days 前

已解决


Which quadrant?
Given a complex number, output quadrant 'I' 'II' 'III' or 'IV' | II | I | ...

9 days 前

已解决


Deleting an element in a matrix
For vector Grades=[98 56 78 34 100 88 87], delete the number 78 to get the following matrix Grades=[98 56 34 100 88 87] **re...

9 days 前

已解决


Building matrices
If you have matrix A, create matrix B using matrix A as an "element" A = [1 2 3 4; 5 6 7 8...

9 days 前

已解决


Matlab Basics II - Extract last 3 elements of a vector
Let x be a vector of unknown length, we are always interested in the last 3 numbers in the vector, write a function that gives t...

9 days 前

已解决


Finding an element in a vector
x is a vector of unknown length your function should return the index of the first element in the vector that is greater than...

9 days 前

已解决


Basics: 'Find the eigenvalues of given matrix
Find the eigenvalues y for a given matrix x.

9 days 前

已解决


square root
Find the square root (y) of an input (x).

9 days 前

已解决


Back to basics 14 - Keywords
Covering some basic topics I haven't seen elsewhere on Cody. Return a cell array of all MATLAB keywords

9 days 前

已解决


Compute a dot product of two vectors x and y
x and y are input vectors, d is a number and contains their dot product

10 days 前

已解决


Create an index-powered vector
Given a input vector x, return y as index-powered vector as shown below. Example x = [2 3 6 9] then y should be [...

10 days 前

已解决


Add two numbers
Calculate the sum of two numbers. Example input = [2 3] output = 5

10 days 前

已解决


calculate linear convolution two vectors
for e.g in: a = [1 2 3] b = [4 5 6] out: y = [4 13 28 27 18]

10 days 前

已解决


Switch matrix to a column vector
for e.g. x = [1 2 3 4] y = 1 3 2 4

10 days 前

已解决


Find the minimum element of the matrix
Example: If x = [3 9; 5 2] then y = 2

10 days 前

已解决


find the maximum element of the matrix
for e.g x = [1 2; 3 4] y = 4

10 days 前

已解决


Matlab Basics - Assigning Variables
Assign different types of data to variables: integer, double, and strings Example: A is a double, for example 2.34 B is a...

10 days 前

加载更多