Solved


Check if a number belongs in the fibonacci squence
Test if integer i is a number in the fibonacci sequence. Return true if it is.

6 years ago

Solved


An Ohm's Law Calculator
*BACKGROUND / MOTIVATION:* Many important observations in math and science can be described by short, but powerful, equations...

6 years ago

Solved


Check if number is a square number
Test if integer i is a square number. Return logical true if it is.

6 years ago

Solved


generate the matrix
given a value n (say 4) - generate the matrix like below; y= [0 1 2 3 4; -1 0 1 2 3; ...

6 years ago

Solved


wythoff sequence
find the lower wythoff sequence upto n; https://oeis.org/A000201

6 years ago

Solved


Adjoint matrix
given a matrix a, find the adjoint matrix of a.

6 years ago

Solved


find nth even fibonacci number
1st even fibonacci number=2 ; 2nd even fibonacci number=8 ..

6 years ago

Solved


Find edges from a vertex
First input is T, a triplet list of indices. Second input is i, a single index (positive integer). The goal of this function is ...

6 years ago

Solved


Find a common edge
First input is T, a triplet list of indices. Second input is e = [e1 e2], a row vector, couple of indices (positive distinct int...

6 years ago

Solved


Find a common vertex
First input is T, a triplet list of indices. Second input is i, a single index (positive integer). The goal of this function is ...

6 years ago

Solved


How to find the position of an element in a vector without using the find function
Write a function posX=findPosition(x,y) where x is a vector and y is the number that you are searching for.

6 years ago

Solved


Check if integer is a prime number
Check if integer i is a prime number. Returns logical true '1' if it is.

6 years ago

Solved


Squares in Squares - Concentric Squares
Given a number, n, create an n x n sized matrix with concentric squares of 1s from the outside in. There should be a gap between...

6 years ago

Solved


remove numbers from a string
check the given string for any numbers.in case one is found,remove it.but the two portions should be separated. if more than one...

6 years ago

Solved


Calculate the area of a circle
Given a circle of diameter x calculate its area

6 years ago

Solved


find subscripts from linear index
a matrix and the linear index of an element is given as input. find the subscripts of that element. if linear index=3 , outp...

6 years ago

Solved


Convert Fahrenheit to Kelvin
Convert the value f in Fahrenheit to Kelvin

6 years ago

Solved


SAY 'OHYEAH'
Regardless of input, output the string 'OHYEAH'.

6 years ago

Solved


Repeat elements of a vector
Repeat each elements of a given vector according to their values. say x=[1,2,1,3] y=[1,2,2,1,3,3,3]

6 years ago

Solved


factorial
calculate x!

6 years ago

Solved


Given a vector x, return vector y with all negative elements from the vector x.
Given a vector x, return vector y with all negative elements from the vector x if x has negative elements. Otherwise return 0. ...

6 years ago

Solved


Check prime numbers
Let x, return 1 if x is a prime number, 0 otherwise e.g x = 7, return y =1; x = 6 return y = 0;

6 years ago

Solved


Create a "+" flag
Given two odd numbers, [m, n], return a matrix of size m x n which has all elements of the centre column and centre row set as 1...

6 years ago

Solved


Square
square root of x

6 years ago

Solved


Find MPG of Lightest Cars
The file |cars.mat| contains a table named |cars| with variables |Model|, |MPG|, |Horsepower|, |Weight|, and |Acceleration| for ...

6 years ago

Solved


Quadratic equation
given three inputs (a, b, c) for the equation a*x^2+b*x+c=0; return 1 if the roots are complex (non zero imaginary), and 0 if th...

6 years ago

Solved


Calculate the average value of the elements in the array
Calculate the average value of the elements in the array

6 years ago

Solved


square a number twice with square root of 4/5
square a number twice with square root of 4/5

6 years ago

Solved


Sum Sum Sum!
Calculate the sum of the natural numbers from 1 to n

6 years ago

Load more