Solving an implicit equation in matlab
D=1/(V-b) is a root of fifth order polynomial, where the coefficients depend on P, T, etc... It looks like it is small non-line...

15 dagar ago | 0

Solving an implicit equation in matlab
The numerical answer is -0.284179329144572 format long -(17211847986098922057056496272843303410021431145154622943954950247403...

15 dagar ago | 0

Creating curved alpha hull, similar to R-package
Just plot the boundary as concave. Some time it doesn't work since the vert returned are not in order, I don't know why and coul...

15 dagar ago | 1

Is it possible to find the limit as a function approaches a complex number?
If seem that what you want can be derived from the the Laurent series of G about p_i I have no idea if Matlab symbolc can compu...

16 dagar ago | 1

How do I calculate the correlation between the rows two large matrices?
Just use the formula of correlation % Fake data for testing A = rand(10,5); B = rand(10,5); Ac = A - mean(A,2); Bc = B - ...

16 dagar ago | 0

| accepted

How to generate uniformly distributed points inside the volume of frustrum with base radius R and tip radius r and with a height of h.
Here we go r = 1; R = 2; % must be > r h = 3; if R <= r error('Non valid parameter') end Zmin = r*h/(R-r); % Posi...

17 dagar ago | 0

| accepted

solving nonlinear equation including max function
The dumb method (buts surely reliable and give all possible solution) is to assume one of the 4 combinations rhs max in (1) is ...

17 dagar ago | 0

While loop not breaking even though condition is met.
Just guessing; Might be it breaks but your function is entered again or there are many instances of function in queue, log more ...

17 dagar ago | 1

| accepted

Applying boundary conditions on a cubic spline interpolation
You can use my function spline1d available here https://fr.mathworks.com/matlabcentral/fileexchange/24996-spline-derivative?s_ti...

19 dagar ago | 0

Generate random numbers with truncated Pareto distribution
According the https://en.wikipedia.org/wiki/Pareto_distribution the pareto has bounded on the lower side by what they called xm...

19 dagar ago | 0

inpolygon usage with big matrices or faster function
Try this https://fr.mathworks.com/matlabcentral/fileexchange/27840-2d-polygon-interior-detection?s_tid=srchtitle At some point ...

19 dagar ago | 0

| accepted

Comparing between and within columns of matrix
A=[2 3 4 5 10 7 15 9 16 12 17 18 19 20]; [As,is] = sort(A(:)); col = 1 + (is>size(A,1...

19 dagar ago | 0

fminunc : A VERY STRANGE PROBLEM!
Just shooting in the dark here and wonder if you let the UseParallel option of fminunc to true or false? It could be that the ...

21 dagar ago | 0

Can we Generate a Random Matrix with No Repeated Elements
Just the reshape long vector returned by randperm m = 3; n = 2; A = reshape(randperm(10,m*n), m, n)

21 dagar ago | 0

| accepted

How to rank 3d matrix across 2 dimensions
iNames(VarSORT); won't change iNames, you need to assign the expression to a variable VarsRank iVars = zeros(361,181,5); iVa...

21 dagar ago | 0

Efficient construction of positive and negative matrix
If your B is given then the 2nd method in this script is faster P = [1 3 8 18]; N = 20; B = fliplr(dec2bin((1:2^N)-1,N)-'0'...

22 dagar ago | 0

Optimoptions - Invalid solver specified error
Check if you have license and installed optimization toolbox by typing ver

22 dagar ago | 0

| accepted

Matrix Product optimization with Bsxfun
You simply cannot invent something that does not exist (support) in MATLAB, the function mtimes is not supported by bsxfun see f...

23 dagar ago | 1

| accepted

how to flip a function
f = @(x) x.^3; ivf = @(y) y.^(1/3); g = @(x)x; ivg = @(y) y; a = 0; b =1; fplot(f, [a, b]), hold on fplot(g, [a, b], 'Li...

24 dagar ago | 1

| accepted

How to create a second command window in my GUI?
Just let the main GUI (with welcome message and push button) to launch another MATLAB session system('matlab -r ...') with -...

24 dagar ago | 0

Matlab Mex File with OpenMP compiling and showing active threads but not actually using them
A little bit late reply. I believe the main reason is there is a problem in your code, not in the compilation option. because ...

24 dagar ago | 0

How can I approximate this large matrix?
What about T = M; niter = 5: for k=1:niter T = M*(speye(size(M)) + T); end This returns T = M + M^2 + .... + M^6

25 dagar ago | 1

Warning: Matrix is singular, close to singular or badly scaled. Results may be inaccurate. RCOND = NaN
Replace ^2 by .^2 (with the dot) in fe if you want to square element wise. There migjt be some other operation like * or / that...

25 dagar ago | 0

Contradictory results in command window with variable class and ischar function?
class structure(8).timetotemp is like class('structure(8).timetotemp') which return char. The correct function syntax call ...

25 dagar ago | 1

| accepted

How to speed up MEX function?
Last experience, Time with C OpenMP, Intel Parallel Studio XE 2022 CIntel_elapsed_time = 0.0574 [sec] 2.5 faster than MATLAB ...

25 dagar ago | 1

| accepted

Using ismembertol for multiple coincidences
Using ismembertol is inappropriate A = [5 3 4 2]; B = [2 4 4 4 6 8]; tol = 1; [ib,ia]=find(B'<=A+tol & B'>=A-tol); c = a...

26 dagar ago | 0

| accepted

equally spaced nodes and chebyshev nodes matlab
I have just answered another fellow here

26 dagar ago | 0

Matrix column updation via optimization
Using Housholder transformation, B is uniquely determined only for n=3. I claim that my code solve the problem of argmin(norm...

26 dagar ago | 0

| accepted