解決済み


MATLAB Basic: rounding II
Do rounding nearest integer. Example: -8.8, answer -9 +8.1 answer 8 +8.50 answer 9

5ヶ月 前

解決済み


Length of a short side
Calculate the length of the short side, a, of a right-angled triangle with hypotenuse of length c, and other short side of lengt...

5ヶ月 前

解決済み


Length of the hypotenuse
Given short sides of lengths a and b, calculate the length c of the hypotenuse of the right-angled triangle. <<https://i.imgu...

5ヶ月 前

解決済み


Return area of square
Side of square=input=a Area=output=b

5ヶ月 前

解決済み


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

5ヶ月 前

解決済み


Vector parallel to plane?
Given the coefficients of the equation which defines a plane as follows: ax+by+cz=d, return a boolean indicating whether the 2n...

5ヶ月 前

解決済み


How to find the position of an element in a vector without using the find function
Write a function posX=findPosition(x,y) where x is a vector and y is the number that you are searching for. Examples: fin...

5ヶ月 前

解決済み


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

5ヶ月 前

解決済み


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

5ヶ月 前

解決済み


Remove NaN ?
input -> matrix (n*m) with at least one element equal to NaN; output -> matrix(p*m), the same matrix where we deleted the enti...

5ヶ月 前

解決済み


Remove the air bubbles
Given a matrix a, return a matrix b in which all the zeros have "bubbled" to the top. That is, any zeros in a given column shoul...

5ヶ月 前

解決済み


Doubling elements in a vector
Given the vector A, return B in which all numbers in A are doubling. So for: A = [ 1 5 8 ] then B = [ 1 1 5 ...

5ヶ月 前

解決済み


Flip the vector from right to left
Flip the vector from right to left. Examples x=[1:5], then y=[5 4 3 2 1] x=[1 4 6], then y=[6 4 1]; Request not to use d...

5ヶ月 前

解決済み


Whether the input is vector?
Given the input x, return 1 if x is vector or else 0.

5ヶ月 前

解決済み


Find max
Find the maximum value of a given vector or matrix.

5ヶ月 前

解決済み


Inner product of two vectors
Find the inner product of two vectors.

5ヶ月 前

解決済み


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

5ヶ月 前

解決済み


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

5ヶ月 前

解決済み


Find the minimum of the column-maximums of a matrix
Given a matrix A, find the maximum value of each column, then return the smallest of those maximum values (ie return the minimum...

5ヶ月 前

解決済み


Given the mass and stiffness of an undamped SDOF system, find the natural frequency and the natural period of vibration
Problem Statement Given the mass and stiffness of an undamped SDOF system, find the system's natural frequency in both Hz and...

5ヶ月 前

解決済み


Back to basics 21 - Matrix replicating
Covering some basic topics I haven't seen elsewhere on Cody. Given an input matrix, generate an output matrix that consists o...

5ヶ月 前

解決済み


Matrix multiplication across rows
Given matrix m, return matrix n such that, rows of n are result of multiplication of the rows of the input matrix Example ...

5ヶ月 前

解決済み


Matrix Quadrants
Write a function that takes N as the input, and outputs a matrix whose upper-left (NxN) quadrant contains all ones, the lower-ri...

5ヶ月 前

解決済み


Create an arrow matrix
An arrow matrix is a square matrix that contains ones on the diagonal, the last column, and last row. ...

5ヶ月 前

解決済み


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

5ヶ月 前

解決済み


Solve the set of simultaneous linear equations
Given this pair of simultaneous linear equations: 2x + 3y = 23 3x + 4y = 32 Find the solution set (x,y)

5ヶ月 前

解決済み


Linear system of equations
Solve the system of equations in three variables.

5ヶ月 前

解決済み


Vector creation
Create a vector using square brackets going from 1 to the given value x in steps on 1. Hint: use increment.

5ヶ月 前

解決済み


Create a vector
Create a vector from 0 to n by intervals of 2.

5ヶ月 前

解決済み


Get the length of a given vector
Given a vector x, the output y should equal the length of x.

5ヶ月 前

さらに読み込む