Beantwortet
Roots of a nonlinear equations system
Use the solve function — syms x y fcn = [-4*y^2 + 4*x - 4 == 0; 16*y^2 - 8*x*y ==0] S = solve(fcn) x = S.x y = S.y .

fast 4 Jahre vor | 1

Beantwortet
Write variable label on the Y-axis of graphs
Try this — figure plot(sort(rand(1,10)), rand(1,10), '-p') ylabel('$\tilde{H}_{H,2}^{H,1}$', 'Interpreter','latex', 'FontSiz...

fast 4 Jahre vor | 1

Beantwortet
Batch FFT operation on EMG data
I am not certain what you want to do. After you load the data and select the sections you want to analyse, convert the data i...

fast 4 Jahre vor | 0

| akzeptiert

Beantwortet
Solving ODEs for chemical rate equations
Here is prototype code for integrating the solution for a different kinetic parameter estimation problem with four rate equation...

fast 4 Jahre vor | 1

| akzeptiert

Beantwortet
finding the Column name of a matrix
I am not certain what you want to do. The equality comparison operator in MATLAB is the double-equal (==) operator — A = ra...

fast 4 Jahre vor | 0

| akzeptiert

Beantwortet
Error using / matrix dimensions must agree
The ‘y’ expression is not a function of ‘x’. Correcting that (and assuming the independent variable is actually ‘ec’) — ec ...

fast 4 Jahre vor | 1

| akzeptiert

Beantwortet
Why is the derivative of a matrix not of the same order?
Use the gradient function instead of diff.

fast 4 Jahre vor | 1

| akzeptiert

Beantwortet
SURF Surface-Plot
Concatenate the column vectors horizontally (to create matrices) instead of vertically (to create column vectors) and it sort of...

fast 4 Jahre vor | 0

| akzeptiert

Beantwortet
3 d plot for the symbolic calculation
The problem was with the fsurf call (and ‘r’ was not defined). This changed version: fsurf(series1,[-50 50 0 50]) works —...

fast 4 Jahre vor | 0

Beantwortet
How to sort an excel sheet by one column matlab
Use readtable to import it then sortrows to sort it. If you want to save the sorted version, use writetable to write it as an ....

fast 4 Jahre vor | 0

Beantwortet
why full area not filled? area under the curve
For the fill (and patch) functions it is necessary to create a closed area. One way to do that is to flip the second vector in ...

fast 4 Jahre vor | 1

| akzeptiert

Beantwortet
How to find maximum among several local peaks?
It would help to have the data. If that is the maximum peak in value, it is also the maximum of the vector plotted in the im...

fast 4 Jahre vor | 0

| akzeptiert

Beantwortet
Does findpeaks only provide one output?
First, what version /release of MATLAB are you using? If the version in your documentation (not the online documentation unle...

fast 4 Jahre vor | 2

| akzeptiert

Beantwortet
Change Sample Rate Audio
I would do something like this, using the Signal Processing Toolbox resample funciton — filename = "test.wav"; [y,fs] = audio...

fast 4 Jahre vor | 0

| akzeptiert

Beantwortet
How to take the average every 4 data points?
An easier way is to just reshape the vector to a matrix, and then take the mean of the columns — v = (1:9536).'; vm = reshape...

fast 4 Jahre vor | 3

| akzeptiert

Beantwortet
Can I return 'nan' value for bad data?
One option would be to create the left side as a cell array (so the dimensions do not have to match) and then deal with any inco...

fast 4 Jahre vor | 0

Beantwortet
Finding average heart rate of EKG data
I woiuld use findpeaks with an appropriate value for 'MinPeakProminence' to select only the R-deflections. Example — [y,Fs]...

fast 4 Jahre vor | 0

| akzeptiert

Beantwortet
problem with scatteredInterpolant: are there any limits?
It would help to have the file. It appears to me that the data might be gridded. To determine that, the easiest way would be...

fast 4 Jahre vor | 1

| akzeptiert

Beantwortet
How to display the current result when the program is forced to abort?
One option would be to save the intermediate results to a .mat file. It might be necessary to re-write it in each iteration of ...

fast 4 Jahre vor | 0

Beantwortet
Not enough input arguments using ode45
You already did everything necessary. Just change the ode45 call to: [t, x]=ode45(fun,timerange,IC); and it works — close...

fast 4 Jahre vor | 1

| akzeptiert

Beantwortet
finding the distance between two points
I am not exactly certain what you want. Calculating the perimeters of each segment appears to be straightforward — % prompt...

fast 4 Jahre vor | 0

Beantwortet
Area plot matlab colors
With so little information, I can only suggest one approach, that being serial area calls or concatenating the ‘array’ variables...

fast 4 Jahre vor | 0

| akzeptiert

Beantwortet
Calculating number of operations during GA run
A lot depends on the 'InitialPopulationMatrix' and how it is defined, parameter constraints, and other considerations. If app...

fast 4 Jahre vor | 0

| akzeptiert

Beantwortet
Conversion from FFT to IFFT
It is likely not efficient to do filtering by editing the fft result (although it can be done). If you want to do it that way, ...

fast 4 Jahre vor | 0

Beantwortet
Why can't I put unassigned variables in a 2 x 1 matrix?
One option would be to use the Symbolic Math Toolbox — syms x y coefficients = [2 -1; 3 2] constants = [4; 13] variables =...

fast 4 Jahre vor | 1

| akzeptiert

Beantwortet
Need help with a contour plot
It is difficult for me to understand what you want. It is certainly poossible to get only one contour from each matrix and th...

fast 4 Jahre vor | 0

Beantwortet
Plot of fft of data is mirrored, unsure how to fix it
It respects the Nyquist limit. If you use the fftshift function you will see the result as negative frequencies and positive fr...

fast 4 Jahre vor | 0

| akzeptiert

Beantwortet
Need help on a homework problem
Try something like this — result = MyRand result = MyRand(10) result = MyRand(90, 95) function int = MyRand(a,b) n=nargi...

fast 4 Jahre vor | 0

Beantwortet
How can I plot Kendall tau trend by using MATLAB code?
Start with a File Exchange search for kendall.

fast 4 Jahre vor | 0

| akzeptiert

Beantwortet
Increase the accuracy of vector differentiation
The best way to calculate the numerical derivative is with the gradient function. Since differentiation amplifies noise, filt...

fast 4 Jahre vor | 1

Mehr laden