Beantwortet
Smoothing data with sgolay filter
The default order for the 'sgolay' option is 2 (quadratic), however the 'SmoothingFactor' controls the window length (framelen ...

etwa 4 Jahre vor | 0

Beantwortet
How can I draw the transfer function spectra by matlab?
The ‘spectrum’ is the Bode plot: z = tf('z'); H = 5 / (1 + 2*cos(5)*z^-1 + z^-2); H.Variable = 'z^-1' figure bodeplot(H)...

etwa 4 Jahre vor | 0

Beantwortet
Find the relaxation Time from data set
See my latest Comment in find fitting equation and parameters to fit damped oscillations curves from set of data.

etwa 4 Jahre vor | 0

| akzeptiert

Beantwortet
sums up the same rounded numbers in 5-digit decimal arithmetic in n = 10, 9, 8, ..., 3, 2, 1
See the documentation for colon, : and go from there.

etwa 4 Jahre vor | 0

Beantwortet
how to avoid getting 0 overlap on the pie chart?
The code was not returning the correct position vectors. I am not certain what you want to do. This repositions the ‘5%’ t...

etwa 4 Jahre vor | 1

| akzeptiert

Beantwortet
contour() function plots with a solid background (and not a transparent background, which is desired)
Perhaps something like this — [X,Y,Z] = peaks(50); figure surf(X,Y,Z, 'EdgeColor','none') hold on contour3(X, Y, Z, 'Col...

etwa 4 Jahre vor | 0

| akzeptiert

Beantwortet
How to plot bode?
We need to know more. If you have the Control System Toolbox (or the System Identification Toolbox, or both) licensed and ins...

etwa 4 Jahre vor | 0

| akzeptiert

Beantwortet
The upsample function is not working R2022b
I can find two upsample functions in the online documentation, one in the Signal Processing Toolbox (that should work with your ...

etwa 4 Jahre vor | 0

| akzeptiert

Beantwortet
Putting measurement unit and origin in plot
I am not exactly certain what you want, however the xlim and text functions would likely be appropriate.

etwa 4 Jahre vor | 0

| akzeptiert

Beantwortet
Can anyone please tell me how to plot this graph?
Use the polarplot function. It should do evertything you want. For details see PolarAxes Properties and perhaps also Line Pr...

etwa 4 Jahre vor | 1

| akzeptiert

Beantwortet
bode magnitude producing different plots for the same transfer function
The upper plot is plotted with a linear magnitude and the lower one is plotted with the magnitude in decibels.

etwa 4 Jahre vor | 0

| akzeptiert

Beantwortet
Extract data points from bodemag plot
it would likely be easier to use the approach bode in Obtain Magnitude and Phase Data. (Remember to use the squeeze function wi...

etwa 4 Jahre vor | 0

| akzeptiert

Beantwortet
Add axes x and y labels (or title) to a scatter plot, not using tbl notation
Delete the equal sign in the xlabel, ylabel, and title calls — A_full = rand(1,570); B_30_channels = rand(1,570); figure ...

etwa 4 Jahre vor | 1

| akzeptiert

Beantwortet
Fix the random values
The rng function controls the seed. Example — rng(1) r1 = randi(9,1,10) rng(1) r2 = randi(9,1,10) There are a numbe...

etwa 4 Jahre vor | 0

| akzeptiert

Beantwortet
How can I get a bode magnitude to be a certain size vector?
The bode function allows you to specify a vector of frequencies in radians/time_unit.. See the documentation section on Bode Pl...

etwa 4 Jahre vor | 0

| akzeptiert

Beantwortet
How can I compute envelope for three phase current?
I am not certain what you want. Perhaps this — Fs = 0.0001; t = linspace(0, 1, 1/Fs)/Fs; s = sin(2*pi*t*60 + deg2rad([0; ...

etwa 4 Jahre vor | 1

| akzeptiert

Beantwortet
how can i save my values of u into a vector, so i have the result of all the u-values.
The loop is not necessary. Just use matrix multiplication. One approach — x=(0:0.1:1).'; ...

etwa 4 Jahre vor | 1

| akzeptiert

Beantwortet
find fitting equation and parameters to fit damped oscillations curves from set of data
I can approximate the fit, however not to the oscillations. The best model is a mathematical model of the process that create...

etwa 4 Jahre vor | 0

| akzeptiert

Beantwortet
Solve system of equations
Solve the first equation for and then plot both of them as functions of using the hold function.

etwa 4 Jahre vor | 0

Beantwortet
Best Fit Line for Parabola
Try something like this — x = [0; 0.019; 0.036]; y = [0.015; 0.25; 0.05]; p = polyfit(x, y, 2) xv = linspace(min(x), max(x)...

etwa 4 Jahre vor | 0

Beantwortet
vpasolve accuracy in two equations with two variables
I am not certain what problem you are having. One option is to solve the equations and then use vpa on the solutions. Exam...

etwa 4 Jahre vor | 0

| akzeptiert

Beantwortet
How to find the maximum value by comparing 2 cells?
This is not as efficient as I would like it to be, however it works — A = {2,4,5}; B = {1,10}; MaxC = max(cellfun(@(x)max([x...

etwa 4 Jahre vor | 0

| akzeptiert

Beantwortet
Finite Impulse Response filter
I thought about doing this with an optimisation funciton, however it minimises the distance between the estimated transfer funct...

etwa 4 Jahre vor | 0

Beantwortet
FIR_Filter Kaiser
I am not certain what the problem is. Try something like this — fsamp = 12000; %sampling rate fcuts = [1800 2000]; %indic...

etwa 4 Jahre vor | 0

| akzeptiert

Beantwortet
How to find monthly average from daily data?
You will need to combine the year, month, and day into one datetime array, and then replace the individual variables with the da...

etwa 4 Jahre vor | 0

| akzeptiert

Beantwortet
When calling a user defined function, MATLAB throws an error for simple matrix multiplication
It is best to not use global variables. The problem is that they have to be defined in the calling routine as well as the funct...

etwa 4 Jahre vor | 1

| akzeptiert

Beantwortet
How can I get txtscan to read this file?
It would help to have the file to experiment with. If textscan is only reaidng the first line, consider adding: 'EndOfLine'...

etwa 4 Jahre vor | 0

| akzeptiert

Beantwortet
Can't generate histfit subplot (error using histfit, subscripting into a table)
The error is in the histfit code at line 69. That reference has nothing to do with your code or data. The problem is likely ...

etwa 4 Jahre vor | 0

| akzeptiert

Beantwortet
Relative occurance of intersect values
The intersect funciton can output the indices of the intersecting elements. See Intersection of Two Vectors and Their Indices f...

etwa 4 Jahre vor | 0

| akzeptiert

Beantwortet
how can I find the intersection of two surface
MATLAB is case-sensitive so ‘ct’ ~= ‘Ct’ (and so for the others) in the ‘cdot’ and ‘ctdot’ calls. I would like to run this to...

etwa 4 Jahre vor | 0

| akzeptiert

Mehr laden