解決済み


Create a Matrix of Zeros
Given an input x, create a square matrix y of zeros with x rows and x columns.

9年以上 前

解決済み


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

9年以上 前

解決済み


Factorial Numbers
Factorial is multiplication of integers. So factorial of 6 is 720 = 1 * 2 * 3 * 4* 5 *6 Thus 6 factorial = factorial(720)....

9年以上 前

解決済み


Is it a number?
Determine if input is numeric. If it is,output is 1; if it is not, output is 0.

9年以上 前

解決済み


Maximum value in a matrix
Find the maximum value in the given matrix. For example, if A = [1 2 3; 4 7 8; 0 9 1]; then the answer is 9.

9年以上 前

解決済み


Min of a Matrix
Return the minimum value in the given matrix.

9年以上 前

解決済み


Solution to Ax=b with singular A
Find solution to Ax=b problem if A is singular. Hint: Compute a minimum norm solution

9年以上 前

解決済み


Number of elements in matrix
Calculate the # of elements for given matrix

9年以上 前

解決済み


For given vectors x,y find coresponding spline coefficients.
For given vectors x,y find coresponding spline coefficients. Example x =[ -3 -2 0 2 3] y =[ 0 0 1 ...

9年以上 前

解決済み


Counting candies
In a classroom of |'n'| children, every even numbered child gets one big candy and every odd numbered child gets two small candi...

9年以上 前

解決済み


Calculate the centroid of a triangle
Info: https://en.wikipedia.org/wiki/Centroid Example Input: x = [0 0 1]; % x-coordinate y = [0 1 0]; % y-coordinat...

9年以上 前

解決済み


Roots
Find out the roots of a given polynomial equation.Given are the coefficients of the equation.

9年以上 前

解決済み


Calculate solution of given polynomial
For example, y=function([3 -2 -4]) In here, input vector indicate 3*x^2-2*x-4, y is solution of former equation. y=[1.5...

9年以上 前

解決済み


BASICS - sum part of vector
Please make a function, where as input you get vector "x" and and vector "c", where in "c" vector you get indexes to sum. Examp...

9年以上 前

解決済み


Compare two input matrices
Check which input matrix has more elements. Return "1" if matrix A has more elements than matrix B. Otherwise return "0". Exa...

9年以上 前

解決済み


Sum of the Matrix Elements
Add up all the elements in a NxM matrix where N signifies the number of the rows and M signifies the number of the columns. E...

9年以上 前

解決済み


Max of a Vector
Write a function to return the max of a vector

9年以上 前

解決済み


Determine the square root
Determine the square root of the value the user has entered, n.

9年以上 前

解決済み


Multiply a column by a row
* Given a column vector C and and a row vector R. * Output a matrix M. * Every column of M equals to C multiplied by correspon...

9年以上 前

解決済み


Calculate square and cube of number
Calculate square and cube of number x

9年以上 前

解決済み


Divide by 4
Given the variable x as your input, divide it by 4 and put the result in y.

9年以上 前

解決済み


Create sequnce 1 4 9 16 25.........
Create sequnce 1 4 9 16 25......... upto entered input value using matlab scripting commands. Let y be output and x be input

9年以上 前

解決済み


inner product of two vectors
inner product of two vectors

9年以上 前

解決済み


Compute Fibonacci Number
Compute the _n_-th Fibonacci Number f(0) = 0, f(1) = 1, f(2) = 1, f(3) = 2, ... f(42) = 267914296

9年以上 前

解決済み


Triangle sequence
A sequence of triangles is constructed in the following way: 1) the first triangle is Pythagoras' 3-4-5 triangle 2) the s...

9年以上 前

解決済み


Fibonacci sequence
Calculate the nth Fibonacci number. Given n, return f where f = fib(n) and f(1) = 1, f(2) = 1, f(3) = 2, ... Examples: Inpu...

9年以上 前

解決済み


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

9年以上 前

解決済み


Find the numeric mean of the prime numbers in a matrix.
There will always be at least one prime in the matrix. Example: Input in = [ 8 3 5 9 ] Output out is 4...

9年以上 前

解決済み


sum of first 'n' terms
Given n=10, find the sum of first 'n' terms Example: If n=10, then x=1,2,3,4,5,6,7,8,9,10. The sum of these n=10 terms is 55...

9年以上 前

解決済み


Add two numbers
Add two numbers (For beginners)

9年以上 前

さらに読み込む