Answered
Solving the arising equation with preconditioned iteration method.
I'm not sure what you are talking about. BOTH PCG and GMRES are written in MATLAB itself. So the source code is provided to you....

2 years ago | 0

| accepted

Answered
Optimization involving complex variable.
If you just need to find a new matrx B, then there is ABSOLUTELY NO reason to use optimization techniques! A is assumed to be a...

2 years ago | 0

Answered
Finding coefficients and bias term for equation y = (x-B)*A
As my comment stated, this question is impossible to answer in any meaningful way. That is, given 1x3 vectors X and Y, can you f...

2 years ago | 0

Answered
how can i create a smooth curve through data points
It VERY much depends on what you define as "smooth". A smooth curve would generally not have a derivative singularity in it, yet...

2 years ago | 0

| accepted

Answered
Is it possible to use polyfit in a way that it takes into account the errorbars?
Different people mean different things when they say error bars. But you also use the word weights, which is a bit more standard...

2 years ago | 1

Answered
I am looking for advice on the best way to learn matlab. I am a second year PhD student trying to familiarize myself with problems or projects. Any advice?
There is no "best" way to learn. It surely depends on you and your own learning style. Ok, probably the best way would be to hir...

2 years ago | 0

Answered
Derivative of spline with respect to y-values
Bruno is correct. Anyway, is there a good reason why he would lie? Just because something is more complicated, does not make it ...

2 years ago | 1

Answered
How can obtain the probability density function for a random discreate set of data and fit a custom distribution function ??
Can you write custom code to fit a PDF to data? Yes. It is not that truly difficult, if you know what you are doing. HOWEVER, SH...

2 years ago | 1

Answered
How to solve equation with several unknown variables for a specific variable?
When you pose it as you did to solve, solve assumes you are trying to solve TWO equations, one of which is the equation cos...

2 years ago | 1

Answered
How can I plot the innermost contour?
As an aside, since @Cris LaPierre has already suggested the use of LevelList to do the job. And that arguably is the correct ans...

2 years ago | 0

| accepted

Answered
why I get the error message like "Attempt to execute SCRIPT bar as a function"?
Don't use existing function names as the names of your own scripts. If you do, then eventually you will get strange errors like ...

2 years ago | 0

Answered
Element wise multiplication of a 4D Matrix
A confusing question. MAYBE you are asking how to take the product of the elements along the 4th dimension? That is consistent w...

2 years ago | 2

Answered
round() function does not work as expected
Sorry, but it is often the case that your vector X is not what you thought it was, or you have written a function named round. ...

2 years ago | 1

| accepted

Answered
How can I cut four numbers after the decimal number without rounding using MATLAB ?
You want to truncate after the 4th decimal place? Easy peasy. You shift where the decimal place lies, then use floor. format l...

2 years ago | 2

| accepted

Answered
Why isn't vectorization faster than repeating loop comparing 6 about years ago.
Things change. Vectorization OFTEN is faster. But nothing says it MUST ALWAYS be faster. Remember that vectorization often trade...

2 years ago | 1

Answered
Matlab solver for unconstrained convex optimization
Everybody wants things to be incredibly fast. Large problems can take large time. Nothing stops you from writing a simple gradi...

2 years ago | 1

| accepted

Answered
Non-square matrix inverse
You CANNOT do so. That is, you cannot learn the original values. You cannot go backwards. A simple example is: Choose any two n...

2 years ago | 0

Answered
How do i make an exponential curve graph from a vector?
You can't have a polynomial that will fit that curve shape. They simply do not have that characteristic form. So using polyfit (...

2 years ago | 0

| accepted

Answered
How do I get normal numerical answers using solve or vpasolve?
vpa will turn those products involving pi into more normal looking numbers. For example... x = 17*sym(pi) So x has pi in it. ...

2 years ago | 0

Answered
Why these two path strings are different? (manual string vs. pwd + fullfile)
LOOK AT THE STRINGS. They are just strings after all. What is different between them? pwd = "C:\Users\username\certain_path"; ...

2 years ago | 0

Answered
symbolic solving system of non-linear equations
Solve does not apply to over-determined problems. But it does not know there may be some exact solution that solves the entire s...

2 years ago | 1

Answered
Optimization problem using fminunc
Apparently, your objective function is not well defined at the initial point. I know, this is a wild guess, but that is exactly ...

2 years ago | 1

Answered
Interpolation of inaccurate datapoints
Interpolation does NOT allow the data to change. Essentially, that is what interpolation means. You need to do SMOOTHING, not in...

2 years ago | 1

| accepted

Answered
Change variable name across code lines
Use find and replace. It will search for the next occurence of a. Then you click on either replace, or to ignore that occurenc...

2 years ago | 0

Answered
How can I find the determinant and transpose of a 13*13 matrix without writing all the numbers one by one?
You have many almost random looking numbers. So without knowing how they were generate, it is impossible to do better than stuff...

2 years ago | 0

Answered
i'd like to ask is there any function to find asymptotes of an equation y = f(x) that satisfies x = x(t) and y = y(t). I'm new to matlab.
Its an interesting question of mathematics, maybe not really a question about MATLAB in my eyes, because until you know how to s...

2 years ago | 0

Answered
how to suggest a name to save
Asking a computer to suggest a name is impossible. It cannot know what name might be appropriate, and more importantly, what you...

2 years ago | 0

Answered
solve function answer is a 2x1 matrix . how to assign it directly to 2 variables ?
For example, I'll compute the mean of an array, which here will generate a vector of length 2. A = rand(10,2); mean(A,1) Defi...

2 years ago | 0

Answered
How to use substitution on function handle?
ODE45 CANNOT use symbolic parameters. PERIOD. No matter how you try to trick things, you cannot pass a symbolic parameter (here ...

2 years ago | 0

Answered
Coefficents of piecewise polynomial in matlab
Do you understand the result will not be some simple polynomial like you are used to seeing? plot([1 0 -1 0 1],[0 1 0 -1 0...

2 years ago | 0

Load more