Risolto


function to compute root mean square of first nn positive odd integers
Write a function called odd_rms that returns orms, which is the square root of the mean of the squares of the first nn positive ...

circa 8 anni fa

Risolto


Datetime basics
Generate the datetime scalar representing the current date

circa 8 anni fa

Risolto


Check if there are white spaces in the input string
If there are white spaces in the input string, output=1 else 0

circa 8 anni fa

Risolto


Remove white spaces at the end of the input string
Remove all trailing white spaces at the end of the input strings

circa 8 anni fa

Risolto


Perimeter of a semicircle
Given the diameter d, find the perimeter of a semicircle

circa 8 anni fa

Risolto


Nth root of a number
Given an input and a number N, find the Nth root of the number(s)

circa 8 anni fa

Risolto


Weave two matrices together to form one matrix
Take the first column from matrix a, then insert the first column from matrix b, and so on. For example: a = [1 2 3 4]; b ...

circa 8 anni fa

Risolto


Translate German decimals to English decimals
The string 'x = [2,5; 5,5; 4,3];' should return 'y = [2.5; 5.5; 4.3];'

circa 8 anni fa

Risolto


Pairwise column flip
Given matrix *M_in*, flip every pair of columns. So if *M_in* is 1 2 3 4 1 2 3 4 then *M_out* is 2 1 4 3 2 1 4 3 ...

circa 8 anni fa

Risolto


Draw a 'N'!
Given n as input, generate a n-by-n matrix 'N' using 0 and 1 . Example: n=5 ans= [1 0 0 0 1 1 1 0 0 1 1 0 ...

circa 8 anni fa

Risolto


Diophantine Equations (Inspired by Project Euler, problem 66)
Consider the quadratic Diophantine equation of the form: x^2 – Dy^2 = 1 When D=13, the minimal solution in x is 649^2 – 13...

circa 8 anni fa

Risolto


Red and green towers
Frankie has a large number of wooden cubes, painted in red and green. He is building little towers with his cubes, by stacking t...

circa 8 anni fa

Risolto


Radial Zernike polynomials
Given an integer _n_ &ge; 0 and an integer _m_ &ge; 0, generate the <http://en.wikipedia.org/wiki/Zernike_polynomials radial Zer...

circa 8 anni fa

Risolto


Generalized Laguerre polynomials
Given an integer _n_ &ge; 0 and a scalar _a_, generate the _n_-th <http://en.wikipedia.org/wiki/Laguerre_polynomials#Generalized...

circa 8 anni fa

Risolto


Chebyshev polynomials of the 2nd Kind
Given an integer _n_ &ge; 0, generate the _n_-th <http://en.wikipedia.org/wiki/Chebyshev_polynomials Chebyshev polynomial of the...

circa 8 anni fa

Risolto


Chebyshev polynomials of the 1st Kind
Given an integer _n_ &ge; 0, generate the _n_-th <http://en.wikipedia.org/wiki/Chebyshev_polynomials Chebyshev polynomial of the...

circa 8 anni fa

Risolto


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

circa 8 anni fa

Risolto


Determine the roots of a cubic equation
Given the coefficients a, b, c, and d of a cubic equation, a*x^3 + b*x^2 + c*x + d = 0, determine its roots.

circa 8 anni fa

Risolto


Frequency Analysis of Text
Frequency analysis is a common task in cryptoanalysis. It is essentially counting the occurrences of alphabets (regardless of ca...

circa 8 anni fa

Risolto


Solve the following boundary value problem
Return the sum of sum(res.y) y"+|y|=0 y(0)=a y(4)=b Tip: use bvp4c

circa 8 anni fa

Risolto


Non trivial identities - differentiation
Return x by differentiating it.

circa 8 anni fa

Risolto


Non trivial identities - reshape
Return x by reshaping it.

circa 8 anni fa

Risolto


Wrap-around effect
In vector x of length n we define (n+1) position as going back to the first position (so called wrap-around effect). Can you ret...

circa 8 anni fa

Risolto


Check capital letters
Check if each first letter of a string is a capital letter. for example: 'This Is Ok' gives a true answer and 'This Is not Ok' ...

circa 8 anni fa

Risolto


time difference
The arrays x and y contain time values in the form of: x = [hours minutes seconds] Create the output z which contains the...

circa 8 anni fa

Risolto


Put all numbers in a string inside square brackets
Examples: 'left3down2' -> 'left[3]down[2]' 'fiat500' -> 'fiat[500]'

circa 8 anni fa

Risolto


What's my favourite food?
The spicier the better.

circa 8 anni fa

Risolto


String revert
Revert all words in a sting x for example, if x = 'this is a sentence' then y should be 'sentence a is this'

circa 8 anni fa

Risolto


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

circa 8 anni fa

Risolto


Calculate vowel / consonant ratio of a string
Given a string, calculate the ratio of vowels to consonants for example : x = 'This is a very good Day!' y = 7/11

circa 8 anni fa

Carica altro