Pass the Threshold!!
Write a Matlab function that will take as input a matrix of arbitrary dimensions and a
scalar threshold value, and return a vec...
3ヶ月 前
解決済み
UICBioE240 problem 1.13
Compute the following -
y = x^5/(x^-1) and
y = (1-(1/x^5))^-1.
Have the final answer of y to equal a 1 by 2 vector.
Duplicate each element of a vector.
for an n-dimensional vector x, the function should return another vector 2n-dimension which each element is repeated twice.
Ex...
Matlab Basics II - squares
Write a function that takes matrix A, and squares each element in the matrix
example:
A = [1 2 3]
output = [1 4 9]
3ヶ月 前
解決済み
Make a 1 hot vector
Make a vector of length _N_ that consists of all zeros except at index _k_, where it has the value 1.
Example:
Input
...
3ヶ月 前
解決済み
Product of Array
Given an array of numbers. Get the product of the array.
3ヶ月 前
解決済み
Multiply a column by a row
* Given a column vector C and and a row vector R.
* Output a matrix M.
* Every column of M equals to C multiplied by correspon...
3ヶ月 前
解決済み
Matlab Basics II - Free Fall
An object freely falling from rest under gravity covers a distance x given by:
x = 1/2 gt^2
write a function that calculat...
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ヶ月 前
解決済み
Squaring Matrix
Square the following matrix using matlab
%
A = 1 2 3 4
5 6 7 8
So new matrix should display...
Test for balanced parentheses
Given the input inStr, give the boolean output out indicating whether all
the parentheses are balanced.
Examples:
* If ...
3ヶ月 前
解決済み
Square Diagonal
If n is the given number, then make a diagonal matrix of size 2*2 with the square of that number.