Gelöst


Find the dimensions of a matrix
Just find the number of columns of the given matrix. Example x = [1 2 3 4 5 6] y = 2

fast 10 Jahre vor

Gelöst


Reverse a matrix
Its simple. You have to reverse a given matrix.

fast 10 Jahre vor

Gelöst


Find the area of the four walls
If length, breadth and height of the walls are given, find the area of the four walls.

fast 10 Jahre vor

Gelöst


Concatenate two strings
Its very easy. Just concatenate two strings.

fast 10 Jahre vor

Gelöst


Polynomial division
Divide a polynomial u by polynomial v and return the quotients only. Example: u = x^4+3*x^3+5*x+3 v = x^2+1 Answer: ...

fast 10 Jahre vor

Gelöst


Eight Queens Solution Checker
Write a function to verify whether an arrangement of queens on a chessboard is a valid solution to the classic <http://en.wikipe...

fast 10 Jahre vor

Gelöst


Wheat on a chessboard pt 1
If a chessboard were to have wheat placed upon each square such that one grain were placed on the first square and each successi...

fast 10 Jahre vor

Gelöst


Roll the Dice!
*Description* Return two random integers between 1 and 6, inclusive, to simulate rolling 2 dice. *Example* [x1,x2] =...

fast 10 Jahre vor

Gelöst


radius of a spherical planet
you just measured its surface area, that is the input.

fast 10 Jahre vor

Gelöst


Too mean-spirited
Find the mean of each consecutive pair of numbers in the input row vector. For example, x=[1 2 3] ----> y = [1.5 2.5] x=[1...

fast 10 Jahre vor

Gelöst


Create a function handle that reverses the input arguments of another function handle
Given a function that takes two input arguments and returns one output, create another function handle that performs the same op...

fast 10 Jahre vor

Gelöst


Function composition
Write a function that accepts two function handles f and g and returns the composition h. That is, h = (f o g)(x) = f(g(x)) ...

fast 10 Jahre vor

Gelöst


Function composition - harder
Write a function that accepts an arbitrary number of function handles f_1, f_2, ..., f_n and returns the composition h. That is,...

fast 10 Jahre vor

Gelöst


Create the following sequence : 0 1 1 4 9 25 64 169 ...
The sequence 0, 1, 1, 4, 9, 25, 64, 169, ... represents the square of the sequence of Fibonacci numbers. Let n repres...

fast 10 Jahre vor

Gelöst


Sum of first n terms of a harmonic progression
Given inputs a, d and n, return the sum of the first n terms of the harmonic progression a, a/(1+d), a/(1+2d), a/(1+3d),....

fast 10 Jahre vor

Gelöst


Geometric series
Find the sum, given the first term t1, the common ratio r, and number of terms n. Examples If input t1=1, r=1, n=7 the...

fast 10 Jahre vor

Gelöst


Is the Point in a Circle?
Check whether a point or multiple points is/are in a circle centered at point (x0, y0) with radius r. Points = [x, y]; c...

fast 10 Jahre vor

Gelöst


Differential equations I
Given a function handle |f| an initial condition |y0| and a final time |tf|, solve numerically the differential equation dy...

fast 10 Jahre vor

Gelöst


Frobenius Norm
Write your own version of Frobenius Norm without using the 'norm' function.

fast 10 Jahre vor

Gelöst


Quasi-Newton Method for Unconstrained Minimization using BFGS Update
Write a function to find the values of a design variable vector, _x_, that minimizes an unconstrained scalar objective function,...

fast 10 Jahre vor

Gelöst


Circle area using pi
Given a circle's radius, compute the circle's area. Use the built-in mathematical constant pi.

fast 10 Jahre vor

Gelöst


Steepest Descent Method
Write a function to find the values of a design variable vector, _x_, that minimizes an unconstrained scalar objective function,...

fast 10 Jahre vor

Gelöst


Rosenbrock's Banana Function and its derivatives
Write a function to return the value of <http://en.wikipedia.org/wiki/Rosenbrock_function Rosenbrock's two-dimensional banana fu...

fast 10 Jahre vor

Gelöst


Matrix to column conversion
Given a matrix of any size, convert it into a column vector. e.g A=[10 20 30; 40 50 60] then, B = [10; 40; ...

fast 10 Jahre vor

Gelöst


Sales Prediction
Miss X is a shopaholic person and every weekend she goes to a mall. There are total of 10 shops. Miss X starts from shop #1 and ...

fast 10 Jahre vor

Gelöst


Find best placement for ordered dominoes (harder)
Given a list of ordered pairs, find the order they should be placed in a line, such that the sum of the absolute values of the d...

fast 10 Jahre vor

Gelöst


Find perfect placement of non-rotating dominoes (easier)
Given a list of ordered pairs, find the order they should be placed in a line, such that the sum of the absolute values of the d...

fast 10 Jahre vor

Gelöst


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

fast 10 Jahre vor

Gelöst


Area of an Isoceles Triangle
An isosceles triangle has equal sides of length x and a base of length y. Find the area, A, of the triangle. <<http://upload...

fast 10 Jahre vor

Gelöst


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

fast 10 Jahre vor

Mehr laden