# Walter Roberson

I do not do free private consulting. If you want to bring my attention to something, send a link to the MATLAB Answers location. I am currently caught up to T0099000; if you are waiting on a reply from me for an older issue, please send me a reminder.

**Programming Languages:**

C++, C, MATLAB, Shell, Perl, Fortran

**Spoken Languages:**

English

**Statistics**

RANK**1**

of 244.028

REPUTATION**116.510**

CONTRIBUTIONS

**34** Questions

**52.694** Answers

ANSWER ACCEPTANCE **
52.94%
**

VOTES RECEIVED**14.960**

RANK

of 17.062

REPUTATION**N/A**

AVERAGE RATING**0.00**

CONTRIBUTIONS**0** Files

DOWNLOADS **0**

ALL TIME DOWNLOADS**0**

CONTRIBUTIONS**0 Posts**

CONTRIBUTIONS**0** Public Channels

AVERAGE RATING

CONTRIBUTIONS**0** Highlights

AVERAGE NO. OF LIKES

**Content Feed**

Is it possible if we convert the audio that has 1 channel (mono) to 2 channel (stereo) in Matlab?

Stereo = repmat(Mono(:), 1, 2); In the case where Mono is already known to be a column vector then this can be simplified to S...

circa un'ora ago | 0

break function into individual variable

syms C1 C2 x y = C1*cos(2*x) - C2*sin(2*x) Y1 = children(y, 1) Y2 = children(y, 2)

circa un'ora ago | 0

How to display the time by a method other than the digital timer method from "duration" or "datetime"

hms() can be called passing in a duration object or a datetime object. S = seconds(finTime) ; [h, m, s] = hms(S) ;

circa 3 ore ago | 1

| accepted

draw a 3d graph with mat function

You were not sampling finely enough, and you were also plotting outside the desired range. [X, Y] = meshgrid(linspace(0,2*pi));...

circa 5 ore ago | 0

Empty sym: 0-by-1

Q = @(v) sym(v); Tc = Q(400); Pc = Q(35); R = Q(0.0821); Z = Q(0.34); syms Vc a b c; %assume([b, c], 'real') assumeAlso...

circa 10 ore ago | 1

| accepted

How to plot an Integral

Q = @(x) sym(x); m = Q(0.023); g = Q(9.81); rho = Q(1.2); s = Q(0.00011); Cd = Q(0.9); syms v V real f =(2 .* m .* g)...

circa 13 ore ago | 0

| accepted

how is it possible to introduce the lead value of the inputs of GA in matlab

I want to solve a multi objective problem with Genetic algorithm tool box in matleb. Note that ga() can only be used for single...

1 giorno ago | 0

| accepted

How can I run the calculation of one equation through a range of variables in one loop

S_T = 0:3:60; %row vector TGDs = sind(TS_T); %Sine of incline TGDc = cosd(TC_T); %Cosine of incline Ax = (0:0.25:5).'; %c...

1 giorno ago | 0

Alternative way of defining a variable

https://www.mathworks.com/help/optim/ug/problem-based-workflow.html Problem based optimization permits you to use optimvar() to...

1 giorno ago | 0

Please help me to look at the code. Thx

inf(3) [-1./inf (3)] If inf(3) returns a 3 x 3 array of inf, then why doesn't [-1./inf (3)] take -1 divided by a 3 x 3 array o...

1 giorno ago | 0

What should go in a next-generation MATLAB X?

As part of a discussion https://www.mathworks.com/matlabcentral/answers/1450984-what-should-go-in-a-next-generation-matlab-x#com...

1 giorno ago | 1

I am trying to calculate and plot subsonic coefficients of pressure symbolically, but it is returning a piecewise function that I can't easily plot, what am I doing wrong?

syms x ksi %N = 20; gamma = 1.4; limits = [0 1]; M = 1.2; %alpha = deg2rad([-5:1:20]); %X = linspace(0,1,N); %Geometr...

2 giorni ago | 0

error on start up

Quit MATLAB. Then rename C:\Users\Erasmus\Documents\MATLAB to C:\Users\Erasmus\Documents\old-MATLAB Now start MATLAB again; i...

2 giorni ago | 0

problem with creat function

Your blockDecodeSyndromeMethod is trying to call DecodeSyndromeMethod with more inputs than DecodeSyndromeMethod wants. Howeve...

2 giorni ago | 0

plotting a 2-colum 2d array

That syntax of using . and then a number inside (), only works for table() objects. UIAxes = gca; A = [1, 2; 5, 6; 10, 11; 1...

2 giorni ago | 1

| accepted

Taylor series using For loop to approximate Sin(x).

SIN(-3) function y = SIN(x) %UNTITLED Summary of this function goes here % Detailed explanation goes here n ...

2 giorni ago | 0

| accepted

Check for equality in the contents of two arrays ignoring order

%sets case A = [1 3]; B = [3 1]; isequal(unique(A), unique(B)) For the sets case, a different approach just might be faster...

2 giorni ago | 0

| accepted

How to call the function based on the simulink model?

What should I modify? You should get rid of the "clear all": it is erasing variables in the base or function workspace that you...

2 giorni ago | 0

what changes are needed

filename = 'https://www.mathworks.com/matlabcentral/answers/uploaded_files/769961/G2_A.txt'; C = readmatrix(filename); forceG2...

2 giorni ago | 0

Convert cell array to excel - problem with nested cells

You have several options: write each cell entry as text, perhaps using M2s = cellfun(@mat2str, M2, 'uniform', 0) . If you do th...

2 giorni ago | 0

location information of my laptop

Not directly. However if you are using Windows then you might be able to use a .NET method such as https://docs.microsoft.com/e...

2 giorni ago | 0

How do I test a variable to see if it is empty?

Use detectImportOptions() on the file, and use setvartype() to force the columns to be double, and then readtable. When you do ...

3 giorni ago | 0

Problem running my first program

fsolve(@NL_Syst_HW4, [0,0,0]) Remember that matlab processes arguments before making the calls. The argument NL_Syst_HW4 ha...

3 giorni ago | 0

| accepted

How do I fix my variance? Can't figure out what wrong with my code because I keep getting NaN for my variance and y. If there anyway I could fix my variance or an easier way.

You had a persistent problem where you were assuming that var() of a vector would give you a result the same size as the vector....

3 giorni ago | 0

A faster findsignal method

Maybe. It would not astonish me if parts if it could be rewritten to use an available GPU. However... the algorithm already inv...

3 giorni ago | 0

How do I save the output array (y2) for each loop?

Under what circumstance could c be <= 0 such that the if would fail ? amultiple = input(sprintf('Enter multiple locations (0 - ...

3 giorni ago | 0

how can I plot 3d in matlab

It would probably be easiest to just draw 3D lines using plot3() . And use grid on

4 giorni ago | 0

How to loop equations and expressions used by Dynare in matlab context?

%%%%%%%%%%%%%%%%%%%%%%%%%%%% rule ={ 'a=x;' 'b=y;' "c=rho+(" + newline + ... "@ # for i in number" + n...

4 giorni ago | 1

| accepted

How to solve a double complex ode using ode45 in MATLAB

The infinite boundary condition is a problem for symbolic solution: dsolve() rejects it. The 0 initial time is a problem: you d...

4 giorni ago | 1

| accepted