Beantwortet
how to assign a variable using a string
Try (genvarname) with (eval) functions. Example (alter the example below to your use, i.e., instead of eval([b]) use eval([b = '...

fast 13 Jahre vor | 0

Beantwortet
Making a magic square matrix singular
I don't think details are required since A=magic(n)-ones(n)*((1+n*n)/2) is changed into an antisymmetric matrix, any such...

fast 13 Jahre vor | 1

| akzeptiert

Beantwortet
Please help me implement the equations: Pij = (f(i,j))/(∑_(i=1)^M∑_(j=1)^N〖f(i,j)〗) and H = ─∑_(i=1)^M∑_(j=1)^NPijlog2Pij
It would be something like (provide your own functions for f, and set up the values of M and N), clc;clear;close; % set u...

fast 13 Jahre vor | 0

| akzeptiert

Beantwortet
How to calculate the determinant of a symbolic matrix 5x5
I don't think it is possible to concatenate a matrix such as K if A-F have sizes > (1,1), thus no value of the determinant exist...

fast 13 Jahre vor | 0

| akzeptiert

Beantwortet
How do I assign a matrix column as my x or y values so that can plot them?
Use the basic matrix notation, the colon operator is very helpful in such cases. Example: y=magic(5) y = 17 ...

fast 13 Jahre vor | 1

Beantwortet
Plotting Legends of Rows of a Matrix ???
A=[1 2 3 4; 1 2 3 5; 2 3 4 5]; plot(A) C=num2str(A); H=legend(C); set(H,'Interpreter','none');

fast 13 Jahre vor | 0

Beantwortet
background suppression from any real time image
I've tried (Embedded Matlab Function) blocks once for a similar thing, and used my own program to handle the output.

fast 13 Jahre vor | 0

Beantwortet
Why does the function real return expressions containing i ?
Check the math, e.g.: ... TheEq=w*1i*eye(n)-A-B1*e1-B2*e2- B3*(cos(tau3*w)-1i*sin(tau3*w))-B4*cos(tau4*w)-1i*sin(tau4...

fast 13 Jahre vor | 0

Beantwortet
How do i interpolate a large matrix of data thats not in ascending order?
There are few interpolation techniques in Matlab. You can start with the functions interp1q % for simple 1-D interpolation...

fast 13 Jahre vor | 0

| akzeptiert

Beantwortet
Can rectangularized data be achieved by modifying a text file with MATLAB?
Hi Brad. Instead of InputText=textscan(fid,'%s',1,'delimiter','\n'); Try this out [InputText, dn1]=fscanf(fid,'...

fast 13 Jahre vor | 0

| akzeptiert

Beantwortet
Make error when using a embedded matlab function
Probably there is a simulink model with the same name. Try to use a slightly different function name for youe swap function such...

fast 13 Jahre vor | 0

Gelöst


Create times-tables
At one time or another, we all had to memorize boring times tables. 5 times 5 is 25. 5 times 6 is 30. 12 times 12 is way more th...

fast 13 Jahre vor

Beantwortet
Check each pixel for a specific color
Try I=imread('imageHere'); [a,b,c]=size(I); % change is needed for i=1:a for j=1:b F(i,j)=all(I(i,j)==0); e...

fast 13 Jahre vor | 0

Beantwortet
how to resize a given signal?
Use reshape Y=function(X,m,n) It works for any input matrix (X) with number of elements (m x n). The output is Y with m...

fast 13 Jahre vor | 0

Beantwortet
large text file reading
Try this and note to specify your filename input (FIN) and filename output (FOUT) properly, i.e., FOUT must be with extension (...

fast 13 Jahre vor | 0

Beantwortet
How to convert a string to a symbol ?
@Jacky (the actual expression is : (x>=1 & x<9)). This is the question! This is a logical comparison statement. The meaning...

fast 13 Jahre vor | 1

| akzeptiert

Gesendet


immovieFolder.m
IMMOVIEFOLDER records a movie from a group of image files in a specified folder, and plays it.

fast 13 Jahre vor | 1 Download |

0.0 / 5

Beantwortet
How to convert a string to a symbol ?
sym and syms are used to declare symbolic variables, see: <http://www.mathworks.com/help/symbolic/symbolic-variables-express...

fast 13 Jahre vor | 1

Gelöst


Remove the vowels
Remove all the vowels in the given phrase. Example: Input s1 = 'Jack and Jill went up the hill' Output s2 is 'Jck nd Jll wn...

fast 13 Jahre vor

Gelöst


Reverse the vector
Reverse the vector elements. Example: Input x = [1,2,3,4,5,6,7,8,9] Output y = [9,8,7,6,5,4,3,2,1]

fast 13 Jahre vor

Gelöst


Swap the input arguments
Write a two-input, two-output function that swaps its two input arguments. For example: [q,r] = swap(5,10) returns q = ...

fast 13 Jahre vor

Beantwortet
can someone explain to me what is this entire code means?
This code finds log10 of the values of some vector (x). The line: y = -Inf*ones(size(x)); is meaningless in this part o...

fast 13 Jahre vor | 0

Gesendet


folderFiles.m
Reads filename contents of a folder.

fast 13 Jahre vor | 2 Downloads |

5.0 / 5

Gelöst


Return the 3n+1 sequence for n
A Collatz sequence is the sequence where, for a given number n, the next number in the sequence is either n/2 if the number is e...

fast 13 Jahre vor

Gelöst


Column Removal
Remove the nth column from input matrix A and return the resulting matrix in output B. So if A = [1 2 3; 4 5 6]; and ...

fast 13 Jahre vor

Gelöst


Triangle Numbers
Triangle numbers are the sums of successive integers. So 6 is a triangle number because 6 = 1 + 2 + 3 which can be displa...

fast 13 Jahre vor

Gelöst


Find the sum of all the numbers of the input vector
Find the sum of all the numbers of the input vector x. Examples: Input x = [1 2 3 5] Output y is 11 Input x ...

fast 13 Jahre vor

Gelöst


Make the vector [1 2 3 4 5 6 7 8 9 10]
In MATLAB, you create a vector by enclosing the elements in square brackets like so: x = [1 2 3 4] Commas are optional, s...

fast 13 Jahre vor

Gelöst


Determine if input is odd
Given the input n, return true if n is odd or false if n is even.

fast 13 Jahre vor

Gelöst


Times 2 - START HERE
Try out this test problem first. Given the variable x as your input, multiply it by two and put the result in y. Examples:...

fast 13 Jahre vor

Mehr laden