Assistant Professor, University of the Philippines - Diliman, Department of Chemical Engineering. Research Interests: process data analytics, process systems engineering, machine learning.

Solved

Approximate the cosine function

Without using MATLAB trigonometric functions, calculate the cosine of an argument |x| to a precision of |0.0001| *Hint:* You ...

1 month ago

Solved

Procrustean bed

Given a vector x and an integer n, convert x to a vector of length n by (1) chopping off the end if it is too long, or (2) addin...

3 months ago

Solved

Try and Catch Simple Example

Try and Catch Simple Example <http://in.mathworks.com/help/matlab/ref/try.html Example> Vector x=[1 4 6 8 10]; Create...

3 months ago

Solved

Repetition of matrices

*A is a bold matrix: [1 2 3; 4 5 6;7 8 9]* Given an integer 'n' , a matrix B exists such that has n copies of A in the row an...

3 months ago

Solved

Let's make puddings !

We will make puddings with eggs, milk and sugar. To make one pudding, we need one egg, 140(cc) of milk, 15 (g) of sugar. Now W...

3 months ago

Solved

Please check if calorie intake is less than 300 kcal.

I like eating some puddings and some chocolate cookies around 3 o'clock. However, I care about calorie intake. Please check whe...

3 months ago

Solved

'Determine if array of numbers is odd'

Return true if the input single number is odd. If the input is a vector, it will return a vector or array of logical values indi...

3 months ago

Solved

Refresh your system of equations

Given square matrix, and solution vector, find the values of the variables Example: xyz = [1 -1 2; 0 2 5; 4 0 -3]; //x-y+2...

3 months ago

Solved

Roots of a quadratic equation.

Calculate the roots of a quadratic equation, given coefficients a, b, and c, for the equation a*x^2 + b*x + c = 0.

3 months ago

Solved

Select every other element of a matrix

Write a function called outMat = odd_idx( myMat ) that takes a matrix, myMat, as input argument and returns a matrix th...

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

3 months ago

Solved

Reverse the Matrix

Given a Matrix A, reverse it. Such that, last element of A becomes 1st and vice versa. for example: Input = [1 2 3;4 5 ...

3 months ago

Solved

Determinants

Given a square matrix(A), find the determinant(d). For example: A = [1,3;4,5] d = 1*5-4*3 = -7

3 months ago

Solved

Find same numbers touching each other...

So the goal here is to find any number that is equal to its immediate neighbors and mark it true. Here is some examples: x...

3 months ago

Solved

Get the array of sum for three consecutive numbers in an array

Get the array of sum, for three consecutive numbers in an array. if Input 'x' does not have at-least 3 elements then 'y' shou...

3 months ago

Solved

Size of this cup?

The given vector has diameter of the cup in mm sampled at micrometer increments in depth from top to bottom, need output in cc a...

3 months ago

Solved

persistant sum

There will be 9 tests for this problem. In each test you will be provided with 2 integers n=[n1,n2], where n2 is equal to t...

3 months ago

Solved

Find offset of an element of a multi dimensional matrix

For a given multi dimensional matrix and given element, find its offset from the 1st element. Return 0, if element is not fo...

3 months ago