Solved


Rescaling vector
Rescale the entries of a vector x so that it spams [a,b]. The new values should be linearly stretched into the new range. _Ex...

5 years ago

Solved


Check if any duplicates in your data
Given an array x, return a number n equal to the largest number of repetitions in your data. For example: If x=[1 2 3 6 8 4 9]...

5 years ago

Solved


Find the coefficients for numerical integration using Simpson's rule
For using numerical integration using Simpson's rule, we need some coefficients to be determined first. Suppose the n is the nu...

5 years ago

Solved


Tridiagonal matrix
Given vectors u and v, make a tri-diagonal symmetric matrix such that u is in the main diagonal and v is below and above diagona...

5 years ago

Solved


Find the binary code
Given a sinusoidal signal, create a function that returns the binary code of a quantized value. The function takes the bit lengt...

5 years ago

Solved


Logical array indexing - part 1
Given an array |A| of size |p x q| , return an array |Y| of the same size such that the following conditions are satisfied. (...

5 years ago

Solved


Second Diagonal
Transpose the matrix from it's second diagonal.

5 years ago

Solved


Divisible by 21
Write a function to determine if a number is divisible by 21.

5 years ago

Solved


For given xx,x, y vectors build spline of x and y and find yy values for xx vector.
For given xx,x, y vectors build spline of x and y and find yy values for xx vector. Example x = [ 1.0000 1.5000 2.00...

5 years ago

Solved


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

5 years ago

Solved


Find cosine between two given vectors u and v.
Find cosine between two given vectors u and v. Example u = [5 2 0 5 3 0]; v = [3 2 5 1 ...

5 years ago

Solved


Opposite task convert string hexadecimal numbers array into array of decimal numbers .
Opposite task convert string hexadecimal numbers array into array of decimal numbers . Example x=[ '208'; '209'; '20A'; ...

5 years ago

Solved


Convert array of decimal numbers into hexadecimal numbers array.
Convert array of decimal numbers into hexadecimal numbers array. Example x =[ 32 33 34 35 36 37 38 ...

5 years ago

Solved


Sort (high on middle, low on ends)
Sort the vector of numbers in order low-high-low. Even numbers appear in ascending order on the left and odd numbers appear in d...

5 years ago

Solved


Repeat the entries of the vector to their reference times in the vector.
e.g for input x: [ 7 3 9 5] output y: [ 7 3 3 9 9 9 5 5 5 5]

5 years ago

Solved


Pad zero between every adjacent values of the vector.
you are given a vector x. you have to make an output vector y with zeros padded between every adjacent values of x. e.g x: ...

5 years ago

Solved


design a magic matrix without using the command magic.
Like magic(4) = 16 3 2 13;5 10 11 8;9 6 7 12;4 15 14 1

5 years ago

Solved


replace empty matrices with '[]'
for example a=1;a(:,1)=[]; returns a = Empty matrix: 1-by-0 use this as the input,and the output should be '[]...

5 years ago

Solved


ismember: Enhanced Performance for 'rows' and width - Speed Scoring (66% savings)
The Challenge is to perform very fast the 'ismember' function for a long and wide array. The width of the array is expanded fro...

5 years ago

Solved


Adding and Subtracting UINT variables
Given UINT class variables output the correct solution to A-B+C. *Input:* A,B,C Three uint variables *Output:* solution ...

5 years ago

Solved


Find the first N zeros of the 666 function
Using the following definition of the 666 function for this problem: _f(n)=sin('nnn')-cos(n*n*n)_, write a function that returns...

5 years ago

Solved


Unusual Concatenations
The sum of the squares of certain unusual integers is equal to the concatenation of their individual digits. For example: ...

5 years ago

Solved


Dudeney Numbers: Numbers which are the cube of their decimal sum
From Wikipedia: _A Dudeney number is a positive integer that is a perfect cube such that the sum of its decimal digits is equa...

5 years ago

Solved


Factorions: Numbers that equal the sum of the factorials of their digits
From Wikipedia: _A factorion is a natural number that equals the sum of the factorials of its decimal digits_ For example: ...

5 years ago

Solved


Equal temperament - musical notes and frequency
Starting from 440Hz note (musical note A above middle C), create 13 notes, using twelve-tone equal temperament, in Herz units. ...

5 years ago

Solved


Make a rainbow matrix (follow-up to checkerboard matrix)
Given an integer n, make an n-by-n matrix as shown below. The a(1,1) should be 0. As we move away from the top-left, the number ...

5 years ago

Solved


Tent matrix
Create an n x n matrix that resembles one kind of tent. The variable n is provided to the function and will be an odd number. As...

5 years ago

Solved


Odd row
Create a row 'y' with odd numbers where the potential maximum number is given by 'x' and the space between them by 'm'. The firs...

5 years ago

Solved


house of cards
How many cards do one need to build a house of cards with n stages? Short explanation: /\ 2 cards for 1 stage ...

5 years ago

Solved


means
Calculate the arithmetic, the geometric and the harmonic mean of a given vector (with positive elements) and return them in a ve...

5 years ago

Load more