Community Profile

photo

Mitsu


Last seen: Today Active since 2019

Statistics

All
  • Solver
  • Thankful Level 3
  • First Answer

View badges

Content Feed

View by

Answered
Matlab and SPICE toolkit and parfor
When using SPICE libraries, I run the cspice_furnsh function for each parallel thread before the parfor loop where they will be ...

5 Monate ago | 1

Question


Count instances of subarray inside array
For an array A = [2,2,2,2]; I would like to count how many times [2,2] appears in A, using each value only in one possible pa...

7 Monate ago | 1 answer | 0

1

answer

Question


How to store 2D arrays in a for loop inside a parfor loop?
I compute e.g. a 3x1 array inside the inner for-loop. In each iteration of this loop, the 3x1 array is saved in a matrix. At th...

7 Monate ago | 1 answer | 0

1

answer

Question


Is this combination of parfor and global variables prone to errors?
In the main script mainScript.m, a parfor loop goes through N cases. In each case of the parfor loop, the function principalFu...

7 Monate ago | 1 answer | 0

1

answer

Answered
why are my graphs not publishing?
Firstly, For problem 3 and problem 4, you can solve your issue by adding hold on after you define the figure. So instead of f...

7 Monate ago | 0

Question


Is there a way to overlap two markers on the same legend label?
In the plot, I resort to plot(x, y, 'bx' , 'DisplayName', 'Data label'); plot(x, y, 'bo' , 'HandleVisiblity'); In the legend,...

8 Monate ago | 0 answers | 0

0

answers

Question


Open .m files in current MATLAB instance from Windows Powershell
I am trying to open matlab files via matlab file.m from Windows PowerShell, so that I can proceed to edit them in MATLAB. Howeve...

8 Monate ago | 1 answer | 0

1

answer

Question


How to deal with two ode events triggered together?
I run an ode() with an event function that contains multiple conditions. Sometimes, event 1 is triggered alone, sometimes event...

9 Monate ago | 0 answers | 0

0

answers

Question


How to prevent plotted contents to spill outside of the axes lines
Using set(gca, 'Layer', 'top') I end up with this: Is there a way to completely hide plotted contents that appear beyond t...

10 Monate ago | 1 answer | 0

1

answer

Question


Is there a one-line code for this?
% I would like to go from A = [1 1;2 2;3 3;4 4;5 5] % to A = [1 1;2 2;3 3;4 4;5 5;1 2;2 3;3 4;4 5;5 6]; ...

11 Monate ago | 1 answer | 0

1

answer

Question


Why does the Simulink point-mass high-precission orbit propagator increase semi-major axis over time?
I am using the "Orbit Propagator High precision" built-in Simulink block. I have set the gravity model to point-mass, and the i...

11 Monate ago | 0 answers | 0

0

answers

Question


Simulink: Is there a difference between Keplerian propagator and point-mass high precision propagator?
In order to see the difference between the fast yet simple propagator and the high-precision propagator of Simulink, I created a...

11 Monate ago | 0 answers | 0

0

answers

Question


Record best solution in each GA generation running with UseParallel=true
Hello, Is there a way to record the best solution at each generation running with parallelization? (that is, with UseParallel=1...

mehr als ein Jahr ago | 1 answer | 1

1

answer

Question


How can one pass arguments to a custom CrossoverFunction in ga?
Hello, I am implementing a custom crossover function following the documentation. I need to pass 2 additional variables along ...

mehr als ein Jahr ago | 1 answer | 0

1

answer

Question


Is it bad practice to have nonlinear constraints array change size depending on the input solution in a genetic algorithm?
In a nonlinear ga, the nonlin constraint function is evaluated with each solution, and the output is [c,ceq]. These arrays conta...

mehr als ein Jahr ago | 1 answer | 0

1

answer

Question


Is slicing one big matrix more efficient than storing smaller matrices in a struct?
An example of the former would be: % allcases = % % +---------+------------+------------+------------+-----+-------------+ ...

mehr als ein Jahr ago | 1 answer | 0

1

answer

Question


Efficient way/best practice to slice array under a logical condition as well as other conditions
I did not know how to properly title this question, so please bear with me. Simply put, with the following two arrays: A = [0 ...

mehr als ein Jahr ago | 1 answer | 0

1

answer

Question


How do MATLAB workers/PC cores divide the work in a parallelized optimization inside a parfor loop?
For example: parfor i = 1:20 options = optimoptions('ga','UseParallel',true,'UseVectorized',false); x = gamultiobj(Ob...

fast 2 Jahre ago | 1 answer | 0

1

answer

Question


Polar plot points appear on wrong position
Hello, I am plotting values in an array of three parameters (angle, radius, and third parameter which is colored) points with a...

fast 2 Jahre ago | 1 answer | 1

1

answer

Question


How can I show radial ticks and axis on top of a polar plot?
Although not a MWE, this is what the code looks like: figure; polaraxes; hold on; polarscatter(vara,varb,[],varc,'.'); c =...

fast 2 Jahre ago | 1 answer | 0

1

answer

Answered
How to put a title on a colorbar?
Alternatively, hcb=colorbar; hcb.Title.String = "A Title"; Among the properties of "hcb" there is "Title", which is a Text da...

fast 2 Jahre ago | 2

Question


Understanding why GA's penalty profile is so similar for any run
I am running a genetic algorithm with only nonlinear inequality constraints. The solutions is an array of "nvars" integers that ...

fast 2 Jahre ago | 1 answer | 0

1

answer

Question


"Failure in initial user-supplied nonlinear constraint function evaluation" in a ga() with integer variables and non-linear inequality constraints
(Edit: Please read answers/comments before pointing out code mistakes.) I am trying to run a GA where the solutions are an arra...

fast 2 Jahre ago | 1 answer | 0

1

answer

Question


How to show a seconds plot axis ticks as hh:mm
[Edited to clarify that X is a 2x2, part of a meshgrid.] Assume the data for the x-axis is duration in seconds, in both directi...

fast 2 Jahre ago | 1 answer | 0

1

answer

Question


Extra independent component in ode integration affects other components
I am trying to understand how the ode functions in MATLAB work. In this case, I am running an ode45 or ode113 with a state that...

etwa 2 Jahre ago | 1 answer | 0

1

answer

Question


Order of elements inside sqrt/exponentiation changes ode output
I am running a code that runs an ode in which the equations of motion are exactly the same for both cases (except the line where...

etwa 2 Jahre ago | 1 answer | 0

1

answer

Question


Ways to shade points-delimited area or smooth the edge
Hi, I have a plot created from a bunch of points, that looks like this: The code looks like this: for k = 1:size(Points,1) ...

mehr als 2 Jahre ago | 1 answer | 0

1

answer