Community Profile

photo

Star Strider


11,407 total contributions since 2012

Hic sunt dracones!

PROFESSIONAL: Physician (M.D.): Diplomate of the American Board of Internal Medicine; M.Sc. Biomedical Engineering: Instrumentation, Signal Processing, Control, System Identification, Parameter Estimation

NON-PROFESSIONAL: Amateur Extra Class Amateur Radio Operator; Private Pilot, Airplane Single Engine Land, Instrument Rating Airplane; Gamer

NOTE: I do not respond to emails or personal messages, unless they are about my File Exchange contributions.

Contact

Star Strider's Badges

  • Grand Master
  • 36 Month Streak
  • Thankful Level 3
  • Revival Level 2
  • Knowledgeable Level 4
  • First Answer
  • Scavenger Finisher
  • Solver

View details...

Contributions in
View by

Answered
Perfect circle instances in matlab
Try this: a = linspace(0, 2*pi, 59); x = cos(a); y = sin(a); figure plot(x, y, 'ok', 'MarkerFaceColor','k') axis equal ...

12 minutes ago | 0

Answered
Plot from two curves
Use the hold (link) function: figure plot(A) hold on plot(B) hold off if your ‘points’ are (x,y) pairs, an alternative i...

25 minutes ago | 0

Answered
How can I use the output function of the nonlinear regression model?
There are several ways. Probably the easiest in the context of what you are doing is to use the procedure defined in: Predict o...

3 hours ago | 0

| accepted

Answered
plotting on curve given only x value in a loop
See: numerical integration and solving for limit.

4 hours ago | 0

| accepted

Answered
Adding variable values into legend
There are several ways to do that. One is: figure plot((1:100), rand(1, 100).*sin(1:100)) gravity = 10; gravstr = sprint...

1 day ago | 0

| accepted

Answered
Undefined variable t error
Try this: function [ f ] = dXdT(t,x) e = x(1); cc = x(2); ac = x(3); cb = x(4); g = x(5); t = [0 100]; kc1 = 36; %...

1 day ago | 0

| accepted

Answered
Linear Simulation Tool Problem
This works for me: t = 0:0.1:10; u = ones(size(B,2),1)*sin(t); y = lsim(G, u', t); figure plot(t, u, '--') hold on p...

1 day ago | 1

| accepted

Answered
Converting time format from hh mm ss to minutes or seconds
Try this: Tv = datetime(0.4532343954, 'Format','HH:mm:SS', 'ConvertFrom','excel') Tv = datetime 10:52:45

1 day ago | 0

| accepted

Answered
can you please help in how to calculate area of each loop in hysteria graph separately using Matlab
I managed to identify the beginning and ending indices for each complete loop (at least as I define them) as the ‘comzx’ vector,...

1 day ago | 0

| accepted

Answered
Plotting even and odd extensions of a function
I am not certain what you mean by ‘extensions’. Fourier series are comprised of cosine functions (real coefficients) that are...

2 days ago | 0

Answered
How to sum a row of variables during a loop
See if this does what you want: matrix = randi([0 1], 100, 2); % Create ‘matrix’ multiplier1...

2 days ago | 1

| accepted

Answered
a cell of double heading
Yes. Use Tables (link).

2 days ago | 0

| accepted

Answered
For loop with decimal number matrix
I am not certain what you want to do. If you want to use ‘i’ as a subscript, it must consist only of integers greater than 0....

2 days ago | 1

| accepted

Answered
Error in stiff ode plot
You omitted an operator (that you likely intend to be a multiplication operator) ... dxdt(4)=x(3)*pe*(1-exp(hv(x(5)+x(1))))-de...

2 days ago | 0

| accepted

Answered
read certain range in csv file and save to new file
A loop is the only (and likely the simplest) option, since you need the zero values on both ends of each sub-vector: V = [0 ...

3 days ago | 0

| accepted

Answered
What is the equivalent of "extractBetween" function in MATLAB R2013a?
The extractBetween function deals primarily with string (link) variables, introduced in R2016b. The closest approximation in ...

3 days ago | 0

Answered
Index exceeds array bounds error
Consider: ‘n=100’ ‘dnew is a 100x1 matrix’ and you are addressing: dnew(i+1) that does not exist. Try this instead: ...

3 days ago | 0

| accepted

Answered
I need to reverse the X axis in a stacked plot graph. How can I do that?
That is not one of the options for the stackedplot function, although it is easy enough to do in code: x = linspace(0, 1); ...

3 days ago | 0

| accepted

Answered
how can we calculate interpolation between two double MATLAB arrays?
It depends on how you want to interpolate them. The‘safest’ way is likely to interpolate the longer vector to the length of the...

3 days ago | 0

| accepted

Answered
Changing Axes direction with positive z-axis downwards
If you only want to reverse the direcrtion of the z-axis, try this (after the surf call): set(gca, 'ZDir','reverse') The othe...

3 days ago | 0

Answered
Color background between two ylines patch (datetime)
The error is: Error using patch Non-numeric data is not supported in 'patch' So you can’t use it with datetime objects. I...

3 days ago | 0

| accepted

Answered
State Space modelling from an ODE
The easiest way is to let the Symbolic Math Toolbox do the heavy lifting: syms y(t) u(t) t Dy = diff(y); D2y = diff(y,2); ...

3 days ago | 2

| accepted

Answered
Splitting Cell Arrays by Delimiter
Try this: s = {'qwerty,uiop'; 'asdf,ghjkl,zxcvb'}; for k1 = 1:size(s,1) r(k1) = numel(strsplit(s{k1}, ',')); end Out = r ...

4 days ago | 0

Answered
Error bars in loglog plot
You appear to have ‘x_u’ and ‘x_l’ reversed. Try this: x_u = 3.2000e-12; x_m = 2.7111e-12; x_l = 2.2222e-12; y_u = 1.825...

4 days ago | 0

| accepted

Answered
lsqcurvefit error - Matrix dimensions must agree
I can’t run your code. However, some things are immediately obvious: (1) you are not integrating ‘myode’ inside ‘DiffEqSolver...

4 days ago | 1

Answered
convert two columns( one real number and the other is imaginary but without (i) symbol) in txt file to complex number and one column.
Try this: D = xlsread('New Microsoft Excel Worksheet.xlsx'); Cplx = complex(D(:,1),D(:,2));

4 days ago | 0

| accepted

Answered
How to find the numerical partial derivative of matrix
See if the gradient (link) function will do what you want. You will probably have to experiment with it, since I do not under...

4 days ago | 0

Answered
need to do a string interpolation
‘How can I write logic that would access a matrix but change the last character after each iteration.’ No need. I would conc...

5 days ago | 0

Answered
How can I bin Data
There are probalby several ways. One approach: x = randi(90, 90, 1); % Create Data y = r...

5 days ago | 0

Answered
numerical integration and solving for limit
You have told us nothing about ‘g(x)’. Assuming the integral of ‘g(x)’ is monotonically increasing at least until its integral ...

5 days ago | 1

| accepted

Load more