Resuelto


07 - Common functions and indexing 5
Create the vector _lin_: <<http://samle.dk/STTBDP/Assignment1_7e.png>> (the integers from 1 to 20) Make every other val...

casi 8 años hace

Resuelto


Change the first and last diagonal element of the identity matrix to zero
Starting with the identity matrix, change first and last diagonal element to zero. Example If n=5 A = 0 0 ...

casi 8 años hace

Resuelto


04 - Scalar Equations 3
Define the variables a, b, and c: <<http://samle.dk/STTBDP/Assignment1_4-a.png>> <<http://samle.dk/STTBDP/Assignment1_4-b....

casi 8 años hace

Resuelto


07 - Common functions and indexing 3
Define _eMat_: <<http://samle.dk/STTBDP/Assignment1_3e.png>> Create the variable _eMat2_, which is equal to _eMat_ with th...

casi 8 años hace

Resuelto


Reverse a string
Reverse the given string. Example input = 'reverse' output = 'esrever'

casi 8 años hace

Resuelto


Check for keywords
If the entered string is a MATLAB keyword, return true else false

casi 8 años hace

Resuelto


The prisoner
"We want information, information, information." "Who are you?" Input can be a string or a number (array).

casi 8 años hace

Resuelto


No Twins?
Write a function that accepts as input a vector and returns the same vector, but retaining only the first occurrence of an eleme...

casi 8 años hace

Resuelto


Find out missing number from a vector of 9 elements
You are given a vector of size 9, x = [x1 x2 x3 x4 x5 x6 x7 x8 x9] Elements of x may be randomly selected without repeati...

casi 8 años hace

Resuelto


07 - Common functions and indexing 4
Define the matrix _cMat_: <<http://samle.dk/STTBDP/Assignment1_3c.png>> ( _cMat_ = 10x10 matrix where the numbers from 1 t...

casi 8 años hace

Resuelto


Calculate square and cube of number
Calculate square and cube of number x

casi 8 años hace

Resuelto


All capital?
Are all the letters in the input string capital letters? Examples: 'MNOP' -> 1 'MN0P' -> 0

casi 8 años hace

Resuelto


Matlab Basics II - Extract last 3 elements of a vector
Let x be a vector of unknown length, we are always interested in the last 3 numbers in the vector, write a function that gives t...

casi 8 años hace

Resuelto


Resizing Matrices
Take an 4x3 matrix, and resize it to a 2x6 matrix

casi 8 años hace

Resuelto


Generate the Matrix!
Given n, generate the following matrix: a = [ n n-1 n-2 ... 2 1; n-1 n-1 n-2 ... 2 1; n-2 n-2 n-2 ... 2 1;...

casi 8 años hace

Resuelto


ASCII sum of phrases
Find the sum of the numeric equivalents of all characters entered in a phrase. For example: for the phrase 'My name is test', th...

casi 8 años hace

Resuelto


The answer to life the universe and everything
Write a function that gives the answer to life the universe and everything to every input except the input is 42. In this case t...

casi 8 años hace

Resuelto


Find parts of a circle.
Given radius (r) of a circle find the diameter (d), circumference (c), an area (a).

casi 8 años hace

Resuelto


find the roots of a quadratic equation
for e.g x = [ 2 -1 -3] y = [1.5 -1]

casi 8 años hace

Resuelto


square root
Find the square root (y) of an input (x).

casi 8 años hace

Resuelto


vector to string
Determine what the ASCII characters spell out. Example: input = [ 72 73 71 72] output = 'HIGH'

casi 8 años hace

Resuelto


MATLAB Basic: rounding II
Do rounding nearest integer. Example: -8.8, answer -9 +8.1 answer 8 +8.50 answer 9

casi 8 años hace

Resuelto


Convert yards to feet
The goal of this script is to convert a value given in yards to feet.

casi 8 años hace

Resuelto


Matlab Basics II - Create a vector with a repeated entry
Create a row vector of length n, filled with 4's, for example, if n = 3 output = [4 4 4] make sure to round UP when n is a...

casi 8 años hace

Resuelto


Make a Palindrome Number
Some numbers like 323 are palindromes. Other numbers like 124 are not. But look what happens when we add that number to a revers...

casi 8 años hace

Resuelto


Find the palindrome
Given the string a, find the longest palindromic sub-string b. So when a = 'xkayakyy'; you should return b = 'kayak';

casi 8 años hace

Resuelto


Alternating sum
Given vector x, calculate the alternating sum y = x(1) - x(2) + x(3) - x(4) + ...

casi 8 años hace

Resuelto


Replace values under a limit
For a vector x and number n, the goal is to find every element of x inferior to n and replace it by n. Example x= [ 1 2 3...

casi 8 años hace

Resuelto


Values in Array
How many values are in the array

casi 8 años hace

Resuelto


pressure to dB?
given x ratio of pressure, find corresponding y dB

casi 8 años hace

Cargar más