Resuelto


Create an n-by-n null matrix and fill with ones certain positions
The positions will be indicated by a z-by-2 matrix. Each row in this z-by-2 matrix will have the row and column in which a 1 has...

casi 5 años hace

Resuelto


Trimming Spaces
Given a string, remove all leading and trailing spaces (where space is defined as ASCII 32). Input a = ' singular value deco...

casi 5 años hace

Resuelto


Calculate value of capacitor
Given the value of resistance and time at which capacitor charges to it's 99%. calculate the value of capacitor

casi 5 años hace

Resuelto


Average of square wave
given positive and negative peak , calculate dc level, 50% duty cycle

casi 5 años hace

Resuelto


String count
given a string 'str', count the number of the followings - * letters * digits * white space * capital letters * smal...

casi 5 años hace

Resuelto


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

casi 5 años hace

Resuelto


Find product of eigenvalues of n*n magic matrix.
Find product of eigenvalues of n*n magic matrix. Example n=3 Matrix= [ 8 1 6; 3 5 7; 4 ...

casi 5 años hace

Resuelto


Evaluate Polynomial
Given a polynomial equation coefficients in a vector p, you have to return its value at x. Example: For inputs p and x ...

casi 5 años hace

Resuelto


The Tower of Hanoi
In the <http://en.wikipedia.org/wiki/Tower_of_Hanoi Tower of Hanoi problem> with 3 rods (1, 2 & 3), the goal is to move a tower ...

casi 5 años hace

Resuelto


Negative Infinity
Round the given array a towards negative infinity.

casi 5 años hace

Resuelto


Find the product of a Vector
How would you find the product of the vector [1.0 1.5 2.0 2.5 3.0 3.5 4.0 4.5 5.0 5.5 6.0] times 2?; x = [1 : 0.5 : 6]; y ...

casi 5 años hace

Resuelto


Positive Infinity
Round the array a towards positive infinity

casi 5 años hace

Resuelto


Negative matrix
Change the sign of all elements in given matrix.

casi 5 años hace

Resuelto


Plot Line Specifications
Create a line plot for function cos(x) where x is a vector of linearly spaced values going from 0 to input N with an increment o...

casi 5 años hace

Resuelto


Basic commands - Least common multiple
Make a function which will return least common multiple of "a" and "b" Example: a=8; b=6; y=24;

casi 5 años hace

Resuelto


Basic commands - Greatest common divisor
Please write a function, which, will put as output greatest common divisor. Example: A = [-5 17; 10 0];...

casi 5 años hace

Resuelto


Basics - not so easy division
Please make a function whcih divides x/y, but pay attention for some exceptions with NaN,0,Inf. Sometimes return "ERROR" instead...

casi 5 años hace

Resuelto


Basic commands - rounding
make a function which will round to integer, which is nearer to zero. Example x=[-2.5 2]; y=[-2 2];

casi 5 años hace

Resuelto


Remove all the words that end with "ain"
Given the string s1, return the string s2 with the target characters removed. For example, given s1 = 'the main event' your ...

casi 5 años hace

Resuelto


cross in array
Make a cross from "1" in odd size array. Other value from array should be equal to "0"; As input you get length of side of arra...

casi 5 años hace

Resuelto


Find the alphabetic word product
If the input string s is a word like 'hello', then the output word product p is a number based on the correspondence a=1, b=2, ....

casi 5 años hace

Resuelto


Column norms of a matrix
Given a matrix M, return a vector y such that for each k y(k)=norm(M(:,k)) (y(k) is the Euclidean norm of the k-th col...

casi 5 años hace

Resuelto


Find the Best Hotels
Given three input variables: * |hotels| - a list of hotel names * |ratings| - their ratings in a city * |cutoff| - the rat...

casi 5 años hace

Resuelto


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. Examples: fin...

casi 5 años hace

Resuelto


Reverse a matrix
Its simple. You have to reverse a given matrix.

casi 5 años hace

Resuelto


Basics: Divide integers to get integer outputs in all cases
Divide integers a and b in such a way that output y is always an integer (in ceil manner)

casi 5 años hace

Resuelto


Calculate compression ratio of engine
Calculate compression ratio of engine given compression volume of cylinder(Vc), piston stroke(s) and valve diameter(d)

casi 5 años hace

Resuelto


Calculate Engine Power
Calculate Engine Power (P) in kW given the values of Torque(M) in Nm and Engine Speed(n) in rpm

casi 5 años hace

Resuelto


Matrix indexing with two vectors of indices
Given a matrix M and two index vectors a and b, return a row vector x where x(i) = M(a(i),b(i)).

casi 5 años hace

Resuelto


Volume difference between Ellipsoid and Sphere
Given an ellipsoid of semi principal axis (a,b,c) find the volume of the difference between this ellipsoid and the sphere with...

casi 5 años hace

Cargar más