Respondida
32 bit exe with a code developed in 2017b Matlab version
I don't think you can make a backward-compatible 32-bit without changing your code. It's just one of those issue with backward c...

más de 6 años hace | 0

Respondida
Cleaner way to write a series of similar sequences
Nope, that style of coding is going to end up with repeated codes like the one you have shown. This should be a good read for yo...

más de 6 años hace | 0

Respondida
Error with parallel toolbox
Do not use batch and scripts if not needed. _"but then won't run in parallel, and seems to just ignore the parfor loop, or pe...

más de 6 años hace | 1

Respondida
mod(a,b) floating-point rounding error
Nope, still a tricky rounding error. isequal(x(3, 121), 0.2) ans = 0 So x(3, 121) is NOT 0.200. Instea...

más de 6 años hace | 0

Respondida
How can I graph the results of the matrix?
plot(real(solucion), imag(solucion), 'x') xlabel('real') ylabel('imag')

más de 6 años hace | 0

Respondida
spectral subtraction in audio file
I see you've already seen some FEX submissions. The question you seem to have is _"how to use this code instead of "nargin"_. na...

más de 6 años hace | 0

| aceptada

Respondida
'parfor' slower than 'for'
When using parfor, Matlab must know if the variables can be processed independently of each other (sliced variable). In your 2...

más de 6 años hace | 2

Respondida
How to solve problem of out memory
The code is very weird. It immediately summons itself with no switch to break the recursion it seems. Also, inputs D and X are j...

más de 6 años hace | 0

Respondida
Does arrayfun function used on a nongpu array utilise multiple cores of CPU?
It doesn't appear to use multi-core, and if anything, it's slower than a regular for loop for most cases. X = 1:100000...

más de 6 años hace | 0

Respondida
Help needed to apply for loop.
Your while loop conditions is odd, why i < 2? See comments below. Not sure what a "strange" answer is. This would be a math log...

más de 6 años hace | 0

Respondida
How to slice a 4-level cell array to perform a parlour
AllCurves = cell(1, 3); for class = 1 : 3 C = AllCurves{class}; parfor caso = 1 : 17 A = C{caso}...

más de 6 años hace | 0

| aceptada

Respondida
Loading large binary files in Matlab, quickly
<https://www.mathworks.com/discovery/stream-processing.html> Seems like you have to use stream processing. Essentially load N...

más de 6 años hace | 0

| aceptada

Respondida
question about the resulting dendrograms in hierarchical clustering
Dendrogram defaults to 30 leaf nodes to draw. To draw more, specify # of leaf nodes to draw. Y = linkage(rand(64, 3)); ...

más de 6 años hace | 0

| aceptada

Respondida
How to reference a cell in a matrix only if it is preceded by a specific number?
A = [rand(10, 1) [16 4 15 6 16 4 4 16 4 3]']; Idx = find(A(1:end-1, 2) == 16 & A(2:end, 2) == 4) + 1; B = A(Idx, :) ...

más de 6 años hace | 0

| aceptada

Respondida
How can I improve the speed of the following code
<https://www.mathworks.com/matlabcentral/answers/42335-array-cellfun-vs-for-loop> I see you're using a lot of |cellfun| and n...

más de 6 años hace | 1

Respondida
How to detect forgery in an image without original image
Are you asking for image forensic analysis tools? I'm not aware of any built-in Matlab tool for this purpose, so you'll have to ...

más de 6 años hace | 0

| aceptada

Respondida
Vectorize a parfor loop to save time
I've looked through the code and it is mostly vectorized already. See comments though for minor improvements. At this point, you...

más de 6 años hace | 0

| aceptada

Respondida
How can I calculate percentage of Euclidean distance?
Assuming you want similarity % as explained here, alter the equation as such : <https://stats.stackexchange.com/questions/5306...

más de 6 años hace | 0

| aceptada

Respondida
How can I smoothly switch between images?
ImOn = ones(100, 'logical'); %For you, imread('lamp_on.png'); ImOff = zeros(100, 'logical'); %For you, imread('lamp_off.p...

más de 6 años hace | 1

| aceptada

Respondida
Is there a simple way to convert all fields of a struct to local variables?
Look into |inputParser| and the StructExpand option. <https://www.mathworks.com/help/matlab/ref/inputparser.html> % S = str...

más de 6 años hace | 0

Respondida
Fast interp1 on multiple vectors, same X, but different V and Xq per vector
The |for| loop was pretty fast for me. See the timing results below: data = rand(10000,512); times = [0 : size(data, 1) ...

más de 6 años hace | 0

Respondida
how to vectorise this for loop?
Jint = 263; Jnew2 = 360; z = 262144; numHarm = 400; n = rand(z, 1); M = rand(z, 1); alpha = rand(1, numHarm)...

más de 6 años hace | 0

Respondida
what is the expect command???????
Don't delete one-by-one. Instead, delete all rows at once, then all columns at once. A = rand(16, 18); B =[ 5 15; ...

más de 6 años hace | 1

| aceptada

Respondida
Receiving I/O error 32 when opening another program (EnergyPlan) inside parfor
energyPlanPath = 'C:\Users\HumptyDumpty\Desktop\Programme etc\Studium\4o Semestre\Master Thesis\EnergyPlan\energyPLAN.exe'; ...

más de 6 años hace | 1

| aceptada

Respondida
Rearranging Bytes in a Cell
A = {'00 11 22 33 AA BB'; '00 11 22 3D AA BC'; '02 11 32 33 AA BB'}; A = cellfun(@(x) sprintf('%c%c%c%c %c%c%c%c %c%c%c%c',...

más de 6 años hace | 0

Respondida
write vectors in cell array to excel
Is this what you're trying to do? %Making a sample cell array with variable-length vectors Data = cell(50, 2); for j ...

más de 6 años hace | 0

| aceptada

Respondida
How to show what direction an object is facing
Because you're missing "depth" information, it's still very hard to do what you want. To you, it's a roof and "north" slant ...

más de 6 años hace | 0

| aceptada

Respondida
Save one and after data in one programme
Here's a simple case for writing 11 files. Without details in your question, you'll have to start from this template and modify ...

más de 6 años hace | 0

Respondida
How can I protect a public script from being changed?
<https://www.mathworks.com/help/matlab/matlab_prog/protect-your-source-code.html> Perhaps convert your code to p-code to disc...

más de 6 años hace | 1

| aceptada

Respondida
How to access vector elements one by one and do some calculation?
p = 2; e1 = 0.5; c = 10; D = [0,0,100,0,39,0,0,55,0,7]; Re = zeros(size(D)); GT50Loc = D > 50; %Greater than 50...

más de 6 años hace | 0

| aceptada

Cargar más