Resuelto


Calculate the mean of each half of a matrix
Given a matrix with an even number of columns, n, return a 1-by-2 row vector where the first element is the mean of all the elem...

casi 3 años hace

Resuelto


My Problem, Find the square of the horizontal concatenation of the third and fifth elements of a vector.
given the 1x5 vector x, y must be the square of the horizontal concatenation of the third and fifth elements. So, if x = [1 1 1 ...

casi 3 años hace

Resuelto


Summy's odd sum

casi 3 años hace

Resuelto


Vertically stack two vectors
Stack two vectors on top of each-other so that... if A = [1 5 3] and B = [8 6 4] then C = [1 5 3 ; 8 6 4]

casi 3 años hace

Resuelto


Shift elements of vector left
Shift elements of vector to the left. For ex. : Input_vec = [1 2 3 4 5] Output_vec = [2 3 4 5 1]

casi 3 años hace

Resuelto


Sort in descending order.

casi 3 años hace

Resuelto


Set x value to each odd index of vector y.
Set x value to each odd index of vector y.

casi 3 años hace

Resuelto


Matlab Basics - Convert a row vector to a column vector
Write a script to convert a row (e.g. x = [1 2 3]) to a column (e.g. y = [1;2;3]), your script should be able to do this for any...

casi 3 años hace

Resuelto


Matlab Basics - Pick out parts of a vector
Consider x a vector of length >= 7 (there are at least 7 elements in the vector, write a script that extracts the 2nd element, a...

casi 3 años hace

Resuelto


Delete x value in given vector y.
Delete x value in given vector y. Exapmle x=5; y=[ 1 2 5 6 74 5 2 5] result=[1 2 6 74 2]

casi 3 años hace

Resuelto


Find sum of alternate numbers in a vector
Find sum of alternate numbers in a vector starting from index 1

casi 3 años hace

Resuelto


07 - Common functions and indexing 6
Create a variable _m_ as a magic square with the size 6 x 6 Magic squares are defined as square matrices, where the sum of a...

casi 3 años hace

Resuelto


matrix of natural number
Given a number n, create an n-by-n matrix in which the integers from 1 to n^2 resides seially as shown in the examples below. ...

casi 3 años hace

Resuelto


Calculating the total earnings of a factory
The row vector, prods contains the number of various products manufactured per hour. The second row vector, prices holds values ...

casi 3 años hace

Resuelto


Volume and area of a sphere
Input(r) - radius Output([v,s]) - volume and area

casi 3 años hace

Resuelto


Create an array (n,n) where only diagonal elements are '1' and others are '0'
Create an array (n,n) where only diagonal elements are '1' and others are '0' EX: n = 3; then Resultant array would be [ 1 0...

casi 3 años hace

Resuelto


findPositiveEvenNumbers
Write a MATLAB function findPositiveEvenNumbers that takes an array of integers as input and returns a new array containing only...

casi 3 años hace

Resuelto


Unique - Very Very Large Numbers
Given a vector column, with some very large numbers, create the ascending sort and unique vector. *Input:* A (column vector)...

casi 3 años hace

Resuelto


Sum of Squares
Given a vector v of length n, write a MATLAB function to calculate the sum of the squares of its elements.

casi 3 años hace

Resuelto


Independent direction vectors of a plane
Given the equation of a plan of the form ax+by+cz=d, return 2 independent direction vectors which could e.g. be used to determin...

casi 3 años hace

Resuelto


Find all prime factors of the input
Given an input x, find its all prime factors. Return the vector with all factors in ascending order. Efficiency is the key here...

casi 3 años hace

Resuelto


Implement zero-based indexing for Matrices
Given an input vector and position (which is zero based) output the value Example: x = [1 2; 4 5] pos = [0 1] value = 5 ...

casi 3 años hace

Resuelto


Find the minimal value in N*N Matrix
Suppose that we have N by N matrix, we try to find the minimal value in that matrix. examples: Input A=[1 2 3 5 6;52 58 56 45...

casi 3 años hace

Resuelto


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

casi 3 años hace

Resuelto


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

casi 3 años hace

Resuelto


What is Sum Of all elements of Matrix
Given the matrix x, return the sum of all elements of matrix. Example: Input x = [ 1 2 0 0 0 0 6 9 3 3 ] ...

casi 3 años hace

Resuelto


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

casi 3 años hace

Resuelto


Matrix multiplication
Multiply two incoming matrices via matrix multiplication

casi 3 años hace

Resuelto


Basic matrix operations using standard MATLAB commands
Create the matrix: 1.0e+15 * 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000...

casi 3 años hace

Resuelto


Eye Squared
For a positive integer |n| create the identity matrix with |n| elements. In case it is not possible to produce an identity ma...

casi 3 años hace

Cargar más