Category "matlab"

Finding median eigenvalue with sparse matrix in r

I am working with SVD on a matrix $$Y_{m,n} = T_{m,m} \Sigma D^T_{n,n} $$ where $T$ and $D$ describe the row and the column entities of Y, respectively. The tru

Open .mtx file in MATLAB

I have a .mtx file which contains a vector which I am suppose to use for matrix vector multiplication. I tried to open the file using fopen('filename') but this

Is there Python command similar to the 'return' function in MATLAB?

Is there function in Python to can return control to the invoking script or function, similar to the function return in MATLAB? Does the function exit() or quit

Matlab App built in runtime 9.10 runs significantly slower in runtime 9.7

I have an app I wrote in Matlab app designer, built in Matlab 2020a (v9.10 runtime environment). I have to compile it in v9.7 runtime though. When I do this it

How to write a function in MATLAB

I want to write a function that returns the value of f(y) for any value of y: f(y) =tan( sin(y) - sin(tan(y)) ) How can I write this as a function in MATLAB?

how to replace the ode45 method with the runge-kutta in this matlab?

I tried everything and looked everywhere but can't find any solution for my question. clc clear all %% Solving the Ordinary Differential Equation G = 6.6740

LUT for sin: calculation sin of x in Matlab

I test sin computation via LUT in Matlab. Nsamples_LUT = 2^10; Nbits_sine_LUT = 14; sine_LUT = sin( (0:Nsamples_LUT-1) / Nsamples_LUT * 2 * pi ) * (2^(Nbits_si

How to read a .mtl model file into MATLAB and visualise it?

Does anyone know how to read a .mtl 3D model file into MATLAB and visualise it? The .mtl file looks like following newmtl body Ns 51.0000 Ni 1.5000 d 1.0000 Tr

Matlab Special Matrix

Is there a MATLAB function to generate this matrix?: [1 2 3 4 5 6 7 ... n; 2 3 4 5 6 7 8 ... n+1; 3 4 5 6 7 8 9 ... n+2; ...; n n+1 n+2 ... 2*n-1]; I

Is the Matlab Cascade Object Detector (using LBP) Invariant to In-Plane Rotation?

I have read that LBP can be used for rotation invariant feature detection, such as here. This makes intuitive sense to me, as LBP is effectively evaluating loca

Pytorch unable to export trained model as ONNX

I have been training a model in the Pytorch framework using multiple convolutional layers (3x3, stride 1, padding same). The model performs well and I want to u

How to export matlab matrix to .txt in a format supported by c

As I state in the title, I want to export a matrix from matlab to a .txt file in format that is supported by C. What I mean is something like this { { 1, 2, 3,

Implementation of Matlab matrix inverse function in C++ with Eigen

So I need to re-write matrix right-handed division from Matlab to C++: At = (xPow*yPow')/(yPow*yPow'); I mocked some matrices: >> xPow*yPow' ans =

Neighboring gray-level dependence matrix (NGLDM) in MATLAB

I would like to calculate a couple of texture features (namely: small/ large number emphasis, number non-uniformity, second moment and entropy). Those can be co

Recorded signal file with .sig extension and plotting the signal

I have a recorded signal file that contains a vector of values containing samples in the form of real and imaginary parts. I need to plot this signal in matlab.

MATLAB Subplot Make Figure Larger

I am plotting two maps next to each other using subplot. However, now, the image is turning out like this: Is there any way to make the map part of the image

Does NumPy have a function equivalent to Matlab's buffer?

I see there is an array_split and split methods but these are not very handy when you have to split an array of length which is not integer multiple of the chun

Ideal dimensions for MATLAB figures on publications

I am asking a short question because I would like to have some opinions on the ideal dimensions that you require/use for a MATLAB figure in a publication. I am

Weighted Lucas Kanade - Gaussian Function MATLAB

I implemented the Basic Lucas Kanade Optical Flow algorithm in Matlab. I used the algorithm from Wikipedia. Since I want to improve this Basic optical flow alg

Is there any Difference of Gaussians function in Matlab?

I am new to Image Processing, and in my experiment I am having difficulty with Difference of Gaussians. Various implementation were given to me but I don't unde