Solved


Just another sum (JAS)
*Task:* Write a function that takes a vector X and returns the alternating sum of X: X(1)-X(2)+X(3)-X(4)+... *Example...

2 years ago

Solved


Scalar Matrix Manipulation
Assume, input x is a scalar matrix such as, x = 2 0 0 0 2 0 0 0 2 th...

2 years ago

Solved


write a function to calculate the snr after quantizing the signal in dB
osig : original signal qsig : quantized signal qerror : quantization error HINT: snr = 10×log10(sum(osig × osig)/sum...

2 years ago

Solved


Avengers Assemble!
Given matrix with so many zeroes, trim those zeroes and output a matrix joining all nnz elements Example: input = [0 0 0 0 0; 0...

2 years ago

Solved


generate capital english alphabets
Based on the numeric input 'n', generate the capital english alphabet starting from A till the english alphabet at the 'n'th pos...

2 years ago

Solved


Find the missing numbers.
Total *N* numbers are in the series of natural numbers ( *1,2,3,...,N* ). The input is an array (unsorted) of those natural num...

2 years ago

Solved


ASCII sum of phrases
Find the sum of the numeric equivalents of all characters entered in a phrase. For example: for the phrase 'My name is test', th...

2 years ago

Solved


Performance - summation
Given a vector of natural numbers x = [1,2,3,...,N] compute the sum of its elements by not stressing the machine too much...

2 years ago

Solved


I hope to lose weight healthily...
In order to reduce weight healthily, weight will be reduced by 4% every month. Please calculate how many months it will take...

2 years ago

Solved


surface of parallelogram
Given 2 vectors of each 3 elements, determine the surface of the parallelogram which can be created from these 2 vectors.

2 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]

2 years ago

Solved


Lambert's W
Matlab cody does not support lambertw. Try to create a lambert's w function yourself. Lambert's W is the function that solves...

2 years ago

Solved


Accessing values in a cell
You are given c, which is a 1xN cell array, and a and b, which are each two 1xM vectors. Your job is to give the bth value in t...

2 years ago

Solved


Define the operators of function_handles
Suppose f and g are function_handles, try to define f+g,f-g,f*g and f/g. e.g. if f = @(x)x and g = @(x)x+1 ...

2 years ago

Solved


Accessing value of variable whose name is stored in another variable as string.
Accessing value of variable whose name is stored in another variable as string. for example: var1=n; var2='var1'; %Assigning...

2 years ago

Solved


MATLAB Basics: Complex Numbers
For a given complex number, x, return the real and imaginary parts as a vector, y = [Real Imaginary].

2 years ago

Solved


Dancing with wolves?
let wolf() make one or two steps to get a feel of the beat, it is waltz, do not let wolf() make the third step, return safely ju...

2 years ago

Solved


Genome decoding
Inspired by a question on the answer forum: You are given a matrix of 8-bit integers which encodes a genome. Each integer can...

2 years ago

Solved


Compound Interest: Interest Rate
Theorem : Compound Interest where, F : Future value at the end of n periods P : Present value r : Annual nominal rate n :...

2 years ago

Solved


Remove Repetidos e Ordena
Dado um vetor A, remove todos os valores repetidos deixando apenas 1 valor, e ordene o vetor. RemoveRepetidosEOrdena([1 1 2 3])...

2 years ago

Solved


Reindex a vector (★★)
(copy of Prob. 676) You are given two vectors of equal length. Vector N has numeric values (no Inf or NaN) while vector IDX h...

2 years ago

Solved


Minimum possible M of the maximum side of a triangle of given area A.
Suppose a triangle has area A. Suppose it has three sides S1, S2, and S3. Suppose M = max([S1 S2 S3]). What is the minimum po...

2 years ago

Solved


convert between ascii and characters
I have seen multiple problems like this but none of them have a robust test suite associated with them. The first input C is ...

2 years ago

Solved


Wien's displacement law
Given the black body temperature (in *Celsius*), output the weavelength (in *meters*) at which the radiation peaks, according to...

2 years ago

Solved


Remnant

2 years ago

Solved


short or buy ? take the opportunity
you had already calculated a theoretical stock value, now you checked in bloomberg the quoted price of that stock and you have t...

2 years ago

Solved


Guess the number I'm thinking of (Part 1)
In this game you are competing against two other people to guess the number that I'm thinking of. I randomly choose an integer ...

2 years ago

Solved


Create a New_Word
The output of the function is a new word created from the word entered into the function. The new word is created by deleting th...

2 years ago

Solved


Return all matrix elements except elements on diagonal
Consider a given Matrix A=[a b c; d e f; g h i] then return a row vector T such that it contains all the El...

2 years ago

Solved


Clipper Function
Create a function that emulates a clipper circuit Given sin wave, t and the constant value for clipping, and the direction to re...

2 years ago

Load more