Beantwortet
A = 'hello' B = [0;0;0;0] How do I rename variable B with hello?
Here it is A = 'hello'; B = [0;0;0;0]; v = genvarname(A); eval([v,'=B']);

fast 10 Jahre vor | 0

Beantwortet
Averaging the 3D-array
You may want to histogram the 3D array by 3D histogram. There many functions in Matlab central, just search for "N dimensional h...

fast 10 Jahre vor | 4

| akzeptiert

Gelöst


A shooting competition
In a shooting competition, the target is a square of side L containing a circle of radius R<=L/2. A player scores one point if h...

fast 10 Jahre vor

Problem


A shooting competition
In a shooting competition, the target is a square of side L containing a circle of radius R<=L/2. A player scores one point if h...

fast 10 Jahre vor | 2 | 75 Lösungsvorschläge

Gelöst


Divisible by 2
This is the first problem in a set of "divisible by x" problems. You will be provided a number as a string and the function you ...

fast 10 Jahre vor

Gelöst


UICBioE240 problem 1.8
Given a list of grades in a class, write a script that gives the 2nd highest grade in the class and the average for the class. ...

fast 10 Jahre vor

Gelöst


Can you reshape the matrix?
Given a matrix A, is it possible to reshape it into another matrix with the given number of rows?

fast 10 Jahre vor

Gelöst


Tridiagonal
Return an n-by-n matrix that has a, b, c as the subdiagonal, main diagonal, and superdiagonal entries in the matrix. Example ...

fast 10 Jahre vor

Gelöst


Calculate the peak value of square wave
Given the peak value of sine wave, calculate corresponding peak value of square wave, if both have same RMS voltage.

fast 10 Jahre vor

Gelöst


exactly?
given two strings of numeric expressions such as '1-7/14' and '11/22+0.2^2', return 1 if they are numerically exactly equal othe...

fast 10 Jahre vor

Gelöst


union without repitition
Let a = [9 9 9 9 9 9 8 8 8 8 7 7 7 6 6 6 5 5 4 2 1] b = [1 1 1 3 3 3 3 3 4 4 4 4 4 10 10 10] Output should be [9 8...

fast 10 Jahre vor

Gelöst


Feeling lucky?
Guess which number Cody is thinking (1 to 10)? (This is a game of luck more than skill. Good luck!)

fast 10 Jahre vor

Gelöst


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

fast 10 Jahre vor

Gelöst


Apply a function array to an array of numbers
It is required to apply a cell array of functions to a numerical array, where the functions accept only scalar inputs. Exampl...

fast 10 Jahre vor

Gelöst


Another colon problem
This is simple problem based on problems 555, 801, 1118, etc. Create an index vector from two input vectors. Example: ...

fast 10 Jahre vor

Gelöst


Local Minima
Given a vector of data x, find the values of local minimum that is smaller than its neighbor elements. For example, if x =...

fast 10 Jahre vor

Gelöst


multiple of nine?
Given a positive number n, return true if n is a multiple of 9 and false if not. Do not make the division and do not use functio...

fast 10 Jahre vor

Gelöst


Replace secondary diagonal elements of a square array
Replace all the secondary diagonal elements of the square array A with the number n Example: A = [1 2 3 4 5 6 ...

fast 10 Jahre vor

Gelöst


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

fast 10 Jahre vor

Gelöst


Generate binary combinations for a given number of bit(s)
Generate the binary combination as in the example below. Example: If you are given: bin_comb(2) The answer will be: ...

fast 10 Jahre vor

Gelöst


prime test 2
enter the only non prime,non composite number

fast 10 Jahre vor

Gelöst


metre to feet converter
The idea is to make a converter, which exchange meters to feets. We use a factor of 1m = 3.281*1f. so 3m are equals to 9.843 m...

fast 10 Jahre vor

Gelöst


Unit conversion
Convert x degree Celsius to y degree Fahrenheit.

fast 10 Jahre vor

Gelöst


Test of Quiz
Answer the questions and write in vector. Only one answer is correct. The founder of fuzzy logic is 1a) D. Golberg 1b)...

fast 10 Jahre vor

Gelöst


Celsius to Kelvin
Degrees Celsius = Kelvin - 273.15

fast 10 Jahre vor

Gelöst


Hydrogens in a Saturated Hydrocarbon
Given (c) carbon atoms in a saturated hydrocarbon molecule (all single bonds), how many hydrogen atoms (h) are in the molecule?

fast 10 Jahre vor

Gelöst


Golden ratio
Calculate the golden ratio. Hint: phi^2 = phi + 1.

fast 10 Jahre vor

Gelöst


Reshape a Vector
Write a function that accept three inputs. The first one is a row vector S. The second and third arguments are m and n which de...

fast 10 Jahre vor

Beantwortet
Why 2D sinusoidal grating Phase spectrum looks horizontal line?
Basically Matlab function FFT2 computes the discrete 1D FFT on image columns first, and then again it applies 1D FFT to the rows...

fast 10 Jahre vor | 4

| akzeptiert

Beantwortet
separate colors of image
Here is an example with a default matlab image to extract color bands: IMG=imread('peppers.png'); RED=IMG(:,:,1); GRE...

fast 10 Jahre vor | 4

Mehr laden