Answered
display my generated matrix
You can always use imagesc to display the matrix as a pseudo-coloured image: imagesc(dist),colorbar There are plenty other 2-D...

6 years ago | 0

Answered
Motion blur of a colored image
This is easiest to do color-plane by color-plane: rgbMB(:,:,3) = conv2(rgbIM(:,:,3),K,'same'); rgbMB(:,:,2) = conv2(rgbIM(:,:,...

6 years ago | 1

| accepted

Answered
how to get MTF from PSF
The MTF is simply the absolute of the Fourier-transform of the PSF. That is: MTF = abs(fftshift(fft2(psf))); Just a couple o...

6 years ago | 0

Answered
Cant Solve ODE with dsolve
So you have a linear first-order differential equation looking something like this: Then I'd suggest that special cases are ...

6 years ago | 1

| accepted

Answered
How to implement Discrete Integration of the Gaussian Function on a Grid?
In that case you better integrate your Gaussian (point-spread-function?) over the pixel-areas. You could use something like this...

6 years ago | 1

| accepted

Answered
Modulation Transfer function: From edge spread function to MTF
I've seen definitions of the MTF as the magnitude ot the Fourier-transform of the line-spread-function or the magnitude of the F...

6 years ago | 1

Answered
How to regrid data based on longitude-latitude variables?
First of all, your time-variable contains integers between 1411296 and 1463136, when you try to use those as indices you're look...

6 years ago | 0

Answered
Conduct STFT analysis for chirp signal for 25% overlapping
From the help for spectrogram: S = spectrogram(X,WINDOW,NOVERLAP) NOVERLAP is the number of samples each segment of X ...

6 years ago | 0

Answered
How to solve coupled non linear ode using ode 45
When you have a coupled set of ODEs the ode-function has to return a column-vector with the derivatives. So you'll have to modif...

6 years ago | 0

| accepted

Answered
Why this error? 'Transpose on ND array is not defined. Use PERMUTE instead.'
Because transpose is only defined for 2-D arrays. For a 3-D (or larger dimensions) it is not unambiguous which dimensions you wa...

6 years ago | 0

Answered
solving PDE problem : Linear Advection diffusion equation problem
When you work with problems like this you have to make sure that your matrices end up the sizes you expect them to be. To do tha...

6 years ago | 0

Answered
Empirical source terms with PDEPE
To the best of my understanding you should be able to define your pde-function something like this: function [c,f,s] = pde_inte...

6 years ago | 0

Answered
how to plot a function consisting of sum of dirac deltas?
Have a look at stem, it does somewhat "representing Dirac'ses", maybe it is good enough? HTH

6 years ago | 1

Answered
Non-constant statistical weights in non-linear regression
When I have this type of problems (fitting of functions to photon-counting-data where the weights should be calculated from the ...

6 years ago | 0

Answered
Integration of a function that is built by a loop
You should do two things! 1, write that function definition into a function, then integrate it from 0 to pi. Use the integral o...

6 years ago | 0

| accepted

Answered
How do I convert my matrix of 5799 x 1 double into 1933 rows of 3 x 1 cells?
Have a look at the repmat function. HTH

6 years ago | 0

Answered
How to speed up making large matrices, and reduce memory usage
This looks like a very sparse matrix, right? Then I would first figure out how to assign the blocks of Aineq from its components...

6 years ago | 1

| accepted

Answered
Using ODE45 to solve a system of 2nd order ODEs equation
After fixing the sign-errors in your ODE-function this: thetathetadot0 = [0 0 0 -1]; [t,theta] = ode45(@(t,y) pendulum(t,y),0:...

6 years ago | 0

| accepted

Answered
Conversion to double from struct is not possible.
This is obviously an operation that's not supported. If you look at the contens of one struct, you might find that the Jointname...

6 years ago | 0

Answered
Cross-validation the output of "scatteredInterpolant" in order to choose best method (linear, nearest, and natural)
To me that sound somewhat sensible, but would primarily check the regular-grid interpolation-method, and not the scatteredInterp...

6 years ago | 1

| accepted

Answered
How to create a scatter plot with three variables?
you should use scatter, something like this: psz = 23; scatter(x,y,psz,z,'filled') That should give you something to start wi...

6 years ago | 0

| accepted

Answered
How do I do Pyramid plot
Surely this is a homework task? Regardless, after you've figured out loops and conditional statements, you should start to thin...

6 years ago | 1

Answered
solution to non homogenous time dependent differetial equation using ODE45
You can convert a second order ODE to two coupled first order ODEs: can be split up into 2 by introducing a second variable, ...

6 years ago | 0

| accepted

Answered
The dimension of the input vector in the imagesc function
For this type of scattered data you can use scatter, something like this: scatter(data(:,1),data(:,2),23,data(:,3),'filled') o...

6 years ago | 0

| accepted

Answered
load file with try/catch error
With your first call of load: load -mat filename matlab will try to load a file with the explicit filename filename (or filena...

6 years ago | 1

Answered
Time of Flight measurement
You might get somewhere by calculating the spectrogram (short-time FT) of your signal. That might allow you to identify the time...

6 years ago | 0

Answered
How to smooth a contour plot using the low pass filter
Since your narrow structure is slant relative to your grid this will be difficult. The TriScatteredInterp with the 'natural' met...

6 years ago | 0

Answered
Very basic: Could someone please explain what the 2 stands for in "size(v,2)" ?
You'll need to learn to read the help and doc for matlab-functions and commands. Also: welcome to matlab. For this time only: s...

6 years ago | 2

Answered
Changing the parameters of the dynamical system in the middle of simulation, Part 2
For such conditions you might just get away with simply changing the output of the f-function. This is much easier to achieve if...

6 years ago | 0

| accepted

Answered
Changing the parameters of the dynamical system in the middle of simulation
For your case the easiest way to proceed is to simply run the ODE-integration first from 0-2 and then use the end-state as initi...

6 years ago | 1

| accepted

Load more