Solved

Operate on matrices of unequal, yet similar, size

You may want to add a vector to a matrix, implying that the vector is added to each column of the matrix. Or multiply a 3x4x5 ma...

environ 2 heures ago

Answered

Error: Array indices must be positive integers or logical values.

You are still indexing at zero. If you just want cosd at each theta then: x=cosd(theta);

Error: Array indices must be positive integers or logical values.

You are still indexing at zero. If you just want cosd at each theta then: x=cosd(theta);

environ 15 heures ago | 0

Solved

Convert Decimal Number to Hex number (including non integer value)

Convert Decimal Number to Hex number (including non integer value) E.X. (2598.675) in decimal = A26.ACCC in hexa

environ 16 heures ago

Answered

color area between functions

x = -1:.01:4; g = exp(-x.^2./2); h = x.^2-3.*x+2; plot(x, g, 'r', 'LineWidth', 2); hold on; plot(x, h, 'b', 'LineWidth', 2)...

color area between functions

x = -1:.01:4; g = exp(-x.^2./2); h = x.^2-3.*x+2; plot(x, g, 'r', 'LineWidth', 2); hold on; plot(x, h, 'b', 'LineWidth', 2)...

1 jour ago | 0

| accepted

Solved

Find out base of following arithmetic operation

Find out base of the following arithmetic operation. So for example 41/3=13 is true in base 8. Another example: 23+44+14...

1 jour ago

Answered

Converting Output from a Function

Recommend you look at datetime() function. You can easily add two datetimes together.

Converting Output from a Function

Recommend you look at datetime() function. You can easily add two datetimes together.

1 jour ago | 0

Answered

How can i store the values of a polynomial equations in a for loop condition?

You could enter all of your equations at once in the form of a matrix, padding any polynomial equations with zeros if they are o...

How can i store the values of a polynomial equations in a for loop condition?

You could enter all of your equations at once in the form of a matrix, padding any polynomial equations with zeros if they are o...

1 jour ago | 0

Answered

WHY THE CODE GIVE ERROR AT THE d=a*(b+c);

x=0:1:20; a=exp(-1.3*x); b=-1.56*10^-5*sin(13*x); c=3.4*10^-6*cos(13*x); d=a.*(b+c);%need a dot (.*) plot(x,d);

WHY THE CODE GIVE ERROR AT THE d=a*(b+c);

x=0:1:20; a=exp(-1.3*x); b=-1.56*10^-5*sin(13*x); c=3.4*10^-6*cos(13*x); d=a.*(b+c);%need a dot (.*) plot(x,d);

1 jour ago | 0

Answered

How can i use polyval on the input polynomial question?

Why not just enter the polynomial coefficents instead of an equation? p=input('Polynomial coefficents, (like [1 2 3 4]):'); va...

How can i use polyval on the input polynomial question?

Why not just enter the polynomial coefficents instead of an equation? p=input('Polynomial coefficents, (like [1 2 3 4]):'); va...

1 jour ago | 0

Answered

Error printing plot to PDF

x=0:.01:2*pi; y=sin(x); plot(x,y); plot2pdf('sin') Simple function below generates pdf. function plot2pdf(NAME) fig = ...

Error printing plot to PDF

x=0:.01:2*pi; y=sin(x); plot(x,y); plot2pdf('sin') Simple function below generates pdf. function plot2pdf(NAME) fig = ...

2 jours ago | 0

Answered

call an equation within the function

You can pass the data function to your other function. Not sure this helps. I still don't know exactly what you are trying to do...

call an equation within the function

You can pass the data function to your other function. Not sure this helps. I still don't know exactly what you are trying to do...

3 jours ago | 0

| accepted

Answered

Matlab resizing a matrix

Not sure how you want to select the elements between the first and last. newMatrix=reshape([yourMatrix(1:58:end),yourMatrix(end...

Matlab resizing a matrix

Not sure how you want to select the elements between the first and last. newMatrix=reshape([yourMatrix(1:58:end),yourMatrix(end...

4 jours ago | 0

Answered

Solve systems of equations graphically

Do you just want to plot them to see where the curves cross? x=-5:5; y=.5*x.^2-2; z=x+2; plot(x,y,x,z); grid on; grid mino...

Solve systems of equations graphically

Do you just want to plot them to see where the curves cross? x=-5:5; y=.5*x.^2-2; z=x+2; plot(x,y,x,z); grid on; grid mino...

4 jours ago | 0

| accepted

Answered

How to select every second number from a file of numbers separated by a comma

a=reshape(load('UE1.txt'),4,[])'; yourNumbers=a(:,2);

How to select every second number from a file of numbers separated by a comma

a=reshape(load('UE1.txt'),4,[])'; yourNumbers=a(:,2);

4 jours ago | 0

Solved

Replace all odd numbers with NaN

Replace all odd numbers in the vector or matrix with NaN. For example, if x = [1 3 4 5 8 11]; then return y = [NaN Na...

5 jours ago

Solved

String Array Basics, Part 1: Convert Cell Array to String Array; No Missing Values

<http://www.mathworks.com/help/matlab/characters-and-strings.html String array> and cell array are two types of containers for s...

5 jours ago

Solved

Remove element(s) from cell array

You can easily remove an element (or a column in any dimension) from a normal matrix, but assigning that value (or range) empty....

5 jours ago

Solved

Create a cell array out of a struct

Create a cell array out of a (single) struct with the fieldname in the first column and the value in the second column: in: ...

5 jours ago

Solved

Natural numbers in string form

Create a cell array of strings containing the first n natural numbers. _Slightly_ harder than it seems like it should be. Ex...

5 jours ago

Solved

Fix the last element of a cell array

Note: this is lifted directly from <http://www.mathworks.com/matlabcentral/answers/82825-puzzler-for-a-monday Puzzler for a Mond...

6 jours ago

Solved

Solve system of equation!

Given provided system of equation, and find x and y. System of equation can be expressed as each term's coefficient. For exam...

6 jours ago

Solved

Removing vibration!

There are [y] that vary with [x] but y including small useless vibration. x=1:10 y=[1.71 2.03 3.28 4.05 5.10 6.82 7.69 8.3...

6 jours ago