Answered
Unable to perform assignment because the left and right sides have a different number of elements.
k(i) = (4/pi) * (1/(2*i+1)) * sin( ((2*i+1)* pi.* t(i))/T );

4 years ago | 1

| accepted

Answered
Fit multiple sets of data with same function model to get optimal global parameter using lsqcurvefit
This might be what you mean - ExtraData.R=R; ExtraData.G=G; ExtraData.pks_locs1=pks_locs1; ExtraData.pks_locs2=pks_...

4 years ago | 0

| accepted

Answered
Not Enough Input Arguments in fsolve
function myProblem options = optimset('display','off') x = fsolve(@fun,[2 3.5],options) X = x(1) Y = x(2) fun...

4 years ago | 0

| accepted

Answered
My textbook gave me code that has an error I don't know how to fix
alt and flag must be scalars.

4 years ago | 0

| accepted

Answered
Reducing a vector size when it is being updated in a loop
for h=5:-1:1 %code to load all script files if h==1 A = dlmread("Trial 1"); elseif h==2...

4 years ago | 1

| accepted

Answered
How can I go back to the beginning of my program first line by a command?
keepGoing=true; while keepGoing answer=input('Do you wish to continue [yes/no]','s'); keepGoing=(answer=...

4 years ago | 0

Answered
Classdef get methods: allowing get indexing into an array of length either (1x1) or (Nx1).
You would need to overload subsref, e.g., methods function out=subsref(obj,S) if S(1).type=="." && S(1).subs{1}=="A" &&...

4 years ago | 0

| accepted

Answered
(x²+y²+z²)dx-(2xy)dy-(2xz)dz=0
Easy. x=0; y=0; z=0;

4 years ago | 1

Answered
Help with fmincon function
First of all, let's fix your code. g = @(u) 30*u(1) + (20/2)*(u(2))^2 + (20/2)*(u(3))^2 + (10/2)*(u(4))^2 + (40/2)*(u(5))^2; ...

4 years ago | 1

| accepted

Answered
Why dir function is creating additional files while creating a structure? how to ignore it?
Do a more specific search, like files = dir('folder/*.jpg'); Or, just throw the first 2 away files = dir('folder'); files(1:...

4 years ago | 0

| accepted

Answered
Hi guys, I need a lil help,please
Your loop is sending the same x and SNR_dB to the plot command in every iteration. The data you are plotting does not vary throu...

4 years ago | 0

| accepted

Answered
Suitable Optimization Technique using real-time data
Because what else would you use?

4 years ago | 0