Category: Matlab
Category Archives: Matlab
Why are Name‑Value arguments not visible at function entry breakpoints in MATLAB R2025a?
I am using argument validation in a function that has multiple inputs including Name-Value pair arguments. When I set a breakpoint at the beginning of this function, only the first argument appears in the MATLAB R2025a Workspace immediately. The rest do not appear until after the arguments block finishes running. However, if I remove the Name-Value arguments, all of the values appear immediately.
Why does this occur? Is there a workaround?I am using argument validation in a function that has multiple inputs including Name-Value pair arguments. When I set a breakpoint at the beginning of this function, only the first argument appears in the MATLAB R2025a Workspace immediately. The rest do not appear until after the arguments block finishes running. However, if I remove the Name-Value arguments, all of the values appear immediately.
Why does this occur? Is there a workaround? I am using argument validation in a function that has multiple inputs including Name-Value pair arguments. When I set a breakpoint at the beginning of this function, only the first argument appears in the MATLAB R2025a Workspace immediately. The rest do not appear until after the arguments block finishes running. However, if I remove the Name-Value arguments, all of the values appear immediately.
Why does this occur? Is there a workaround? namevalue, arguments, validation, breakpoint, workspace MATLAB Answers — New Questions
Error converting python DataFrame to Table
I have used the following commands to load in a python .pkl file.
fid = py.open("data.pkl");
data = py.pickle.load(fid);
T = table(data);
This loads a python DataFrame object. Newer versions of MATLAB have the ability to convert this object to a table using the table command, which I tried but encountered the below error:
Error using py.pandas.DataFrame/table
Dimensions of the key and value must be the same, or the value must be scalar.
What does this error mean? I’m guessing it’s because the DataFrame object in the .pkl contains a couple nested fields. Most of the fields are simply 1xN numeric vectors, but a couple are 1xN objects which then have their own fields.
How can I convert this DataFrame object to something usable in MATLAB? I was given this datafile and did not generate it, and I am much more proficient in MATLAB than python, so I would rather solve this within MATLAB rather than having to create a python script or change how the file is created.I have used the following commands to load in a python .pkl file.
fid = py.open("data.pkl");
data = py.pickle.load(fid);
T = table(data);
This loads a python DataFrame object. Newer versions of MATLAB have the ability to convert this object to a table using the table command, which I tried but encountered the below error:
Error using py.pandas.DataFrame/table
Dimensions of the key and value must be the same, or the value must be scalar.
What does this error mean? I’m guessing it’s because the DataFrame object in the .pkl contains a couple nested fields. Most of the fields are simply 1xN numeric vectors, but a couple are 1xN objects which then have their own fields.
How can I convert this DataFrame object to something usable in MATLAB? I was given this datafile and did not generate it, and I am much more proficient in MATLAB than python, so I would rather solve this within MATLAB rather than having to create a python script or change how the file is created. I have used the following commands to load in a python .pkl file.
fid = py.open("data.pkl");
data = py.pickle.load(fid);
T = table(data);
This loads a python DataFrame object. Newer versions of MATLAB have the ability to convert this object to a table using the table command, which I tried but encountered the below error:
Error using py.pandas.DataFrame/table
Dimensions of the key and value must be the same, or the value must be scalar.
What does this error mean? I’m guessing it’s because the DataFrame object in the .pkl contains a couple nested fields. Most of the fields are simply 1xN numeric vectors, but a couple are 1xN objects which then have their own fields.
How can I convert this DataFrame object to something usable in MATLAB? I was given this datafile and did not generate it, and I am much more proficient in MATLAB than python, so I would rather solve this within MATLAB rather than having to create a python script or change how the file is created. python, table, dataframe MATLAB Answers — New Questions
How to add a header to a printed or published PDF from a MATLAB script in MATLAB R2025a?
I am printing a MATLAB script to PDF in MATLAB R2025a, but the header with the timestamp is missing. This header was included automatically in MATLAB R2024b. How can I add the header back in R2025a?I am printing a MATLAB script to PDF in MATLAB R2025a, but the header with the timestamp is missing. This header was included automatically in MATLAB R2024b. How can I add the header back in R2025a? I am printing a MATLAB script to PDF in MATLAB R2025a, but the header with the timestamp is missing. This header was included automatically in MATLAB R2024b. How can I add the header back in R2025a? header, print, matlab, editor, pdf, date, filename MATLAB Answers — New Questions
How to put a title on a colorbar?
I have a 3D surface surf(X,Y,Z) viewed from view(0,90) with a colorbar which I want to put a title on. The help instructions talk about an lcolorbar, TitleString and ZlabelString but there’s no example and I’m lost.
[X Y]=meshgrid(0:100,0:100);
Z=Y;
surf(X,Y,Z);
view(0,90);
hcb=colorbar;
?????? what next to put a title on the colorbar please ?????
Maybe something like set(get(hcb,’Title’),’cb title’) but I wouldn’t be asking if that worked …
Thanks.I have a 3D surface surf(X,Y,Z) viewed from view(0,90) with a colorbar which I want to put a title on. The help instructions talk about an lcolorbar, TitleString and ZlabelString but there’s no example and I’m lost.
[X Y]=meshgrid(0:100,0:100);
Z=Y;
surf(X,Y,Z);
view(0,90);
hcb=colorbar;
?????? what next to put a title on the colorbar please ?????
Maybe something like set(get(hcb,’Title’),’cb title’) but I wouldn’t be asking if that worked …
Thanks. I have a 3D surface surf(X,Y,Z) viewed from view(0,90) with a colorbar which I want to put a title on. The help instructions talk about an lcolorbar, TitleString and ZlabelString but there’s no example and I’m lost.
[X Y]=meshgrid(0:100,0:100);
Z=Y;
surf(X,Y,Z);
view(0,90);
hcb=colorbar;
?????? what next to put a title on the colorbar please ?????
Maybe something like set(get(hcb,’Title’),’cb title’) but I wouldn’t be asking if that worked …
Thanks. colorbar title surf titlestring MATLAB Answers — New Questions
UAV Toolbox Support Package for PX4 Autopilots — SITL plant simulation running much slower after recent windows update
I’ve been developing a custom controller using this toolbox, and everything has been working well after following the examples provided in the documentation.
However, after this last Tuesday, April 14th 2026, I attempted to monitor and tune my controller, and it threw an error saying the build failed and I need to go through the toolbox setup again (this is the first time I’ve gotten this error). I did this, and that is when problems developed. When using a simulink plant simulation for the PX4 SITL Host, the plant can no longer run in real time. It runs at about a quarter of the speed. I booted up the PX4 monitor and tune with plant example, and even that example is now running slowly too! Is it possible the recent security update affected TCP communication between Windows and the WSL network adapter?
Also, I am on R2025a.I’ve been developing a custom controller using this toolbox, and everything has been working well after following the examples provided in the documentation.
However, after this last Tuesday, April 14th 2026, I attempted to monitor and tune my controller, and it threw an error saying the build failed and I need to go through the toolbox setup again (this is the first time I’ve gotten this error). I did this, and that is when problems developed. When using a simulink plant simulation for the PX4 SITL Host, the plant can no longer run in real time. It runs at about a quarter of the speed. I booted up the PX4 monitor and tune with plant example, and even that example is now running slowly too! Is it possible the recent security update affected TCP communication between Windows and the WSL network adapter?
Also, I am on R2025a. I’ve been developing a custom controller using this toolbox, and everything has been working well after following the examples provided in the documentation.
However, after this last Tuesday, April 14th 2026, I attempted to monitor and tune my controller, and it threw an error saying the build failed and I need to go through the toolbox setup again (this is the first time I’ve gotten this error). I did this, and that is when problems developed. When using a simulink plant simulation for the PX4 SITL Host, the plant can no longer run in real time. It runs at about a quarter of the speed. I booted up the PX4 monitor and tune with plant example, and even that example is now running slowly too! Is it possible the recent security update affected TCP communication between Windows and the WSL network adapter?
Also, I am on R2025a. px4, uav toolbox support package, monitor and tune, simulink, plant MATLAB Answers — New Questions
I want to install Matlab on my desktop with connection from Network license server . Steps required
I want to install Matlab on my desktop with connection from Network license server . Steps requiredI want to install Matlab on my desktop with connection from Network license server . Steps required I want to install Matlab on my desktop with connection from Network license server . Steps required client installation MATLAB Answers — New Questions
Evaluate Noise and vibration of an EV motor (PMSM)
I want to find out the Noise and vibration of an EV motor PMSM by given few input data and getting results. So what is the process in the matlab/simulink to get the resultsI want to find out the Noise and vibration of an EV motor PMSM by given few input data and getting results. So what is the process in the matlab/simulink to get the results I want to find out the Noise and vibration of an EV motor PMSM by given few input data and getting results. So what is the process in the matlab/simulink to get the results nvh of an ev motor MATLAB Answers — New Questions
Identifying bright spots in RGB image
I have hundreds of RGB images (one of the image is attached). For reference these are interference images and the RGB color values correspond to certain film thickness between a semi reflective glass surface and a steel surface. I apply electric potential across the surface and observed electric discharges which show as bright spots on the image (highlighted in red circle in attached image).
I want to write a script in MATLAB (2023a) that goes through the images, identify these bright spots stores there location in the XY cordinate system. The end goal is to show spatial distribution of the electric discharges.I have hundreds of RGB images (one of the image is attached). For reference these are interference images and the RGB color values correspond to certain film thickness between a semi reflective glass surface and a steel surface. I apply electric potential across the surface and observed electric discharges which show as bright spots on the image (highlighted in red circle in attached image).
I want to write a script in MATLAB (2023a) that goes through the images, identify these bright spots stores there location in the XY cordinate system. The end goal is to show spatial distribution of the electric discharges. I have hundreds of RGB images (one of the image is attached). For reference these are interference images and the RGB color values correspond to certain film thickness between a semi reflective glass surface and a steel surface. I apply electric potential across the surface and observed electric discharges which show as bright spots on the image (highlighted in red circle in attached image).
I want to write a script in MATLAB (2023a) that goes through the images, identify these bright spots stores there location in the XY cordinate system. The end goal is to show spatial distribution of the electric discharges. image analysis, image processing MATLAB Answers — New Questions
Stateflow transition does not work when using output bus field
Hello together,
I am facing a strange behaviour of my Simulink model. That model is comprised of a Simscape subsystem and a Stateflow subsystem. The latter is used to controll the operation mode of the Simscape model.
For a clear data transfer I implemented several data buses as Stateflow inputs and outputs. For that, I created the necessary Simulink Bus Objects and it works fine so far. But when I want to use one field of the Getoperationdata bus to describe the transition condition, the transition is not exceeded despite the condition is true (as shown in the figure below). The state Empty_Pump_Chamber remains active but should switch to Empty_Complete.
The Getoperationdata bus is implemented as an output bus. When defining a transition condition with a variable from another input bus, the model succeeds. Very strange. Even when I define a local variable, set this variable equal to Getoperationaldata.emptyComplete2 and use this new variable to state the transition condition, the model succeeds. Very strange! What is wrong?
Kind Regards!Hello together,
I am facing a strange behaviour of my Simulink model. That model is comprised of a Simscape subsystem and a Stateflow subsystem. The latter is used to controll the operation mode of the Simscape model.
For a clear data transfer I implemented several data buses as Stateflow inputs and outputs. For that, I created the necessary Simulink Bus Objects and it works fine so far. But when I want to use one field of the Getoperationdata bus to describe the transition condition, the transition is not exceeded despite the condition is true (as shown in the figure below). The state Empty_Pump_Chamber remains active but should switch to Empty_Complete.
The Getoperationdata bus is implemented as an output bus. When defining a transition condition with a variable from another input bus, the model succeeds. Very strange. Even when I define a local variable, set this variable equal to Getoperationaldata.emptyComplete2 and use this new variable to state the transition condition, the model succeeds. Very strange! What is wrong?
Kind Regards! Hello together,
I am facing a strange behaviour of my Simulink model. That model is comprised of a Simscape subsystem and a Stateflow subsystem. The latter is used to controll the operation mode of the Simscape model.
For a clear data transfer I implemented several data buses as Stateflow inputs and outputs. For that, I created the necessary Simulink Bus Objects and it works fine so far. But when I want to use one field of the Getoperationdata bus to describe the transition condition, the transition is not exceeded despite the condition is true (as shown in the figure below). The state Empty_Pump_Chamber remains active but should switch to Empty_Complete.
The Getoperationdata bus is implemented as an output bus. When defining a transition condition with a variable from another input bus, the model succeeds. Very strange. Even when I define a local variable, set this variable equal to Getoperationaldata.emptyComplete2 and use this new variable to state the transition condition, the model succeeds. Very strange! What is wrong?
Kind Regards! simulink bus object, transition MATLAB Answers — New Questions
Only version 2026a appears available for download as a trial. I want version 2025b
Only version 2026a appears available for download as a trial.
I want version 2025b, but it does not appear as an option at https://www.mathworks.com/downloads/web_downloads/13799194.Only version 2026a appears available for download as a trial.
I want version 2025b, but it does not appear as an option at https://www.mathworks.com/downloads/web_downloads/13799194. Only version 2026a appears available for download as a trial.
I want version 2025b, but it does not appear as an option at https://www.mathworks.com/downloads/web_downloads/13799194. r2025a MATLAB Answers — New Questions
Why the figure is not apearing after using plot(x) command?
Hi,
after new instalation of MATLAB 2025b my program does not use function plot properly.
After command "plot(x)" MATLAB opens new window "Figures" as usual but there is no figure.
After this line program continues execution.
I could not find the explanation jet.
Thanks!Hi,
after new instalation of MATLAB 2025b my program does not use function plot properly.
After command "plot(x)" MATLAB opens new window "Figures" as usual but there is no figure.
After this line program continues execution.
I could not find the explanation jet.
Thanks! Hi,
after new instalation of MATLAB 2025b my program does not use function plot properly.
After command "plot(x)" MATLAB opens new window "Figures" as usual but there is no figure.
After this line program continues execution.
I could not find the explanation jet.
Thanks! plot, figures MATLAB Answers — New Questions
I can’t able to see the orange, gray, red or green checks. Instead I can see only the code metrics.
I’m facing the issue i.e., I’m running the polyspace code prover throught the commend prompt. I used all the configuration in the option.txt file. Through that option.txt file i’m start compling by using this cmd ("C:Program FilesPOLYSPACER2023apolyspacebinpolyspace-code-prover" ^ -options-file Options.txt ^ -scheduler CHE6-SV00106 ^ -results-dir "C:UsersaallimutDocumentsSWEET500cb1146_vcore_main_devResult"). Compliation is done sucessfully and the code is pushed to the server. After successful complition of run I Checked the result, It’s only showing the code metrix, not showing any checks in the dashboard.I’m facing the issue i.e., I’m running the polyspace code prover throught the commend prompt. I used all the configuration in the option.txt file. Through that option.txt file i’m start compling by using this cmd ("C:Program FilesPOLYSPACER2023apolyspacebinpolyspace-code-prover" ^ -options-file Options.txt ^ -scheduler CHE6-SV00106 ^ -results-dir "C:UsersaallimutDocumentsSWEET500cb1146_vcore_main_devResult"). Compliation is done sucessfully and the code is pushed to the server. After successful complition of run I Checked the result, It’s only showing the code metrix, not showing any checks in the dashboard. I’m facing the issue i.e., I’m running the polyspace code prover throught the commend prompt. I used all the configuration in the option.txt file. Through that option.txt file i’m start compling by using this cmd ("C:Program FilesPOLYSPACER2023apolyspacebinpolyspace-code-prover" ^ -options-file Options.txt ^ -scheduler CHE6-SV00106 ^ -results-dir "C:UsersaallimutDocumentsSWEET500cb1146_vcore_main_devResult"). Compliation is done sucessfully and the code is pushed to the server. After successful complition of run I Checked the result, It’s only showing the code metrix, not showing any checks in the dashboard. no checks found MATLAB Answers — New Questions
Signal logging for evaluation episode during RL training
I am training a DDPG agent using a simulink environment. I want to log the last (final) value of a specific signal for every evaluation episode, e.g., if there are 10 evaluation episodes then I will have 10 values, possibly in the form of an array. The agent is unaware of this signal. How can I do this?I am training a DDPG agent using a simulink environment. I want to log the last (final) value of a specific signal for every evaluation episode, e.g., if there are 10 evaluation episodes then I will have 10 values, possibly in the form of an array. The agent is unaware of this signal. How can I do this? I am training a DDPG agent using a simulink environment. I want to log the last (final) value of a specific signal for every evaluation episode, e.g., if there are 10 evaluation episodes then I will have 10 values, possibly in the form of an array. The agent is unaware of this signal. How can I do this? simulink, reinforcement learning MATLAB Answers — New Questions
textscatter example, and behavior, is mysterious
The code for the textscatter example at
textscatter – 2-D scatter plot of text – MATLAB
looks like it should produce text at those random points. Instead the figure there shows some text in unusual places, some points that dont belong to any specific label, and in general, the whole thing is mysterious.The code for the textscatter example at
textscatter – 2-D scatter plot of text – MATLAB
looks like it should produce text at those random points. Instead the figure there shows some text in unusual places, some points that dont belong to any specific label, and in general, the whole thing is mysterious. The code for the textscatter example at
textscatter – 2-D scatter plot of text – MATLAB
looks like it should produce text at those random points. Instead the figure there shows some text in unusual places, some points that dont belong to any specific label, and in general, the whole thing is mysterious. textscatter MATLAB Answers — New Questions
Axis not held using hold command in plot3
I need to plot 2 3d points: x1, y1, z1 and x2, y2, z2 on the same axis. When using plot3 I only get the second marker while using plot3 for each point. When using one command for both points I get only one marker.I need to plot 2 3d points: x1, y1, z1 and x2, y2, z2 on the same axis. When using plot3 I only get the second marker while using plot3 for each point. When using one command for both points I get only one marker. I need to plot 2 3d points: x1, y1, z1 and x2, y2, z2 on the same axis. When using plot3 I only get the second marker while using plot3 for each point. When using one command for both points I get only one marker. hold, plot3 MATLAB Answers — New Questions
Can different sample times be used for fair torque ripple comparison?
Hello,
I am comparing two control strategies: one with fixed switching frequency and another with variable switching frequency.
Is it acceptable to use different powergui or sample times for each method so that both operate at a similar switching frequency range before comparing torque ripple?
Or should the same sample time always be used for both methods, even if their switching frequencies become very different?
Thank you.Hello,
I am comparing two control strategies: one with fixed switching frequency and another with variable switching frequency.
Is it acceptable to use different powergui or sample times for each method so that both operate at a similar switching frequency range before comparing torque ripple?
Or should the same sample time always be used for both methods, even if their switching frequencies become very different?
Thank you. Hello,
I am comparing two control strategies: one with fixed switching frequency and another with variable switching frequency.
Is it acceptable to use different powergui or sample times for each method so that both operate at a similar switching frequency range before comparing torque ripple?
Or should the same sample time always be used for both methods, even if their switching frequencies become very different?
Thank you. powergui, simulink, sample time, switching frequency MATLAB Answers — New Questions
App Designer keeps adding multiple Instances of EditFields with the same name on startup
Hello Everyone!
I am having a strange problem with the app designer right now:
Every time I start the app designer and load the .mlapp-File of the Project I’m currently working on, there are multiple instances of the same EditField created. It began with only one copy of an EditField I manually added on the GUI. I didn’t think much about it and simply deleted the second instance. But it seems like this problem has grown exponentially with every start of app designer. Now, when I open up my Project 500 (!!) EditFields with the same name are created! ‘Simply’ deleting all of them is obviously not anymore an acceptable workaround – especially since ‘ctrl+a’ doesn’t work in the Component Browser and you have to selected them all manually…
I have no idea why the app designer creates these multiple instances on the startup – after I deleted all multiple instances, they also didn’t appear in the non-editable Function ‘createComponents(app)’ anymore.
Does anyone of you have an idea on that? Where in my code could be a bug causing this phenomenon? Or could this be an appdesigner-internal bug? The project itself is already quite big with ~260 components even without those multiple and unwanted EditFields…
I’m desperately looking for your help! Thanks a lot in advance.Hello Everyone!
I am having a strange problem with the app designer right now:
Every time I start the app designer and load the .mlapp-File of the Project I’m currently working on, there are multiple instances of the same EditField created. It began with only one copy of an EditField I manually added on the GUI. I didn’t think much about it and simply deleted the second instance. But it seems like this problem has grown exponentially with every start of app designer. Now, when I open up my Project 500 (!!) EditFields with the same name are created! ‘Simply’ deleting all of them is obviously not anymore an acceptable workaround – especially since ‘ctrl+a’ doesn’t work in the Component Browser and you have to selected them all manually…
I have no idea why the app designer creates these multiple instances on the startup – after I deleted all multiple instances, they also didn’t appear in the non-editable Function ‘createComponents(app)’ anymore.
Does anyone of you have an idea on that? Where in my code could be a bug causing this phenomenon? Or could this be an appdesigner-internal bug? The project itself is already quite big with ~260 components even without those multiple and unwanted EditFields…
I’m desperately looking for your help! Thanks a lot in advance. Hello Everyone!
I am having a strange problem with the app designer right now:
Every time I start the app designer and load the .mlapp-File of the Project I’m currently working on, there are multiple instances of the same EditField created. It began with only one copy of an EditField I manually added on the GUI. I didn’t think much about it and simply deleted the second instance. But it seems like this problem has grown exponentially with every start of app designer. Now, when I open up my Project 500 (!!) EditFields with the same name are created! ‘Simply’ deleting all of them is obviously not anymore an acceptable workaround – especially since ‘ctrl+a’ doesn’t work in the Component Browser and you have to selected them all manually…
I have no idea why the app designer creates these multiple instances on the startup – after I deleted all multiple instances, they also didn’t appear in the non-editable Function ‘createComponents(app)’ anymore.
Does anyone of you have an idea on that? Where in my code could be a bug causing this phenomenon? Or could this be an appdesigner-internal bug? The project itself is already quite big with ~260 components even without those multiple and unwanted EditFields…
I’m desperately looking for your help! Thanks a lot in advance. appdesigner, gui MATLAB Answers — New Questions
Can you get matlab to add a really small number to a big number and retain precision
I am trying to calculate small numbers from equations like the one below.
p = -1e17 + sqrt(1e34 + 1e18)
I have tried using ‘vpa(-1e17 + sqrt(1e34 + 1e18), 30) but the output always comes out as p = 0.0. But p is not exactly zero and this propagates errors in subsequent calculations that involve p. Is there another way to retain sig figs to avoid rounding errors?I am trying to calculate small numbers from equations like the one below.
p = -1e17 + sqrt(1e34 + 1e18)
I have tried using ‘vpa(-1e17 + sqrt(1e34 + 1e18), 30) but the output always comes out as p = 0.0. But p is not exactly zero and this propagates errors in subsequent calculations that involve p. Is there another way to retain sig figs to avoid rounding errors? I am trying to calculate small numbers from equations like the one below.
p = -1e17 + sqrt(1e34 + 1e18)
I have tried using ‘vpa(-1e17 + sqrt(1e34 + 1e18), 30) but the output always comes out as p = 0.0. But p is not exactly zero and this propagates errors in subsequent calculations that involve p. Is there another way to retain sig figs to avoid rounding errors? precision, digits MATLAB Answers — New Questions
Why in 2025a figure Export Setup have been removed?
Good morning to everyone,
I have just bought a new laptop, downloaded 2025a, opened a figure I created with 2024b and BOOM I realized (with great regret!) that the "Figure Export Setup" have been removed…
In my academic and professional experience it was an essential feature to produce figures and plots in line with the specific request (journal article, technical report, presentation etc..) and coherent throughout the work for whant concerns font size, figure dimensions and features.
I know that now there’s the "uiexportdlg" https://www.mathworks.com/help/releases/R2025a/matlab/ref/uiexportdlg.html but, in my humble opinion, there is no comparison at all. Is there a way to be able to save profiles for the export of figures as was done in the old “File” > “Export Setup” mode? And, above all, does anyone know the reason why this feature was removed? I simply can’t get the point about it.
I’m not the reactionary kind of software users, but I’m seriously thinking about switching back to 2024b.Good morning to everyone,
I have just bought a new laptop, downloaded 2025a, opened a figure I created with 2024b and BOOM I realized (with great regret!) that the "Figure Export Setup" have been removed…
In my academic and professional experience it was an essential feature to produce figures and plots in line with the specific request (journal article, technical report, presentation etc..) and coherent throughout the work for whant concerns font size, figure dimensions and features.
I know that now there’s the "uiexportdlg" https://www.mathworks.com/help/releases/R2025a/matlab/ref/uiexportdlg.html but, in my humble opinion, there is no comparison at all. Is there a way to be able to save profiles for the export of figures as was done in the old “File” > “Export Setup” mode? And, above all, does anyone know the reason why this feature was removed? I simply can’t get the point about it.
I’m not the reactionary kind of software users, but I’m seriously thinking about switching back to 2024b. Good morning to everyone,
I have just bought a new laptop, downloaded 2025a, opened a figure I created with 2024b and BOOM I realized (with great regret!) that the "Figure Export Setup" have been removed…
In my academic and professional experience it was an essential feature to produce figures and plots in line with the specific request (journal article, technical report, presentation etc..) and coherent throughout the work for whant concerns font size, figure dimensions and features.
I know that now there’s the "uiexportdlg" https://www.mathworks.com/help/releases/R2025a/matlab/ref/uiexportdlg.html but, in my humble opinion, there is no comparison at all. Is there a way to be able to save profiles for the export of figures as was done in the old “File” > “Export Setup” mode? And, above all, does anyone know the reason why this feature was removed? I simply can’t get the point about it.
I’m not the reactionary kind of software users, but I’m seriously thinking about switching back to 2024b. figure export setup MATLAB Answers — New Questions
computation of symbolic terms and error analysis
tic
syms x y m %alpha beta b lambda eta phi
phi=sqrt(0.5)
b=10
eta=1
alpha=2;
beta=1;
T=zeros(1,2,’sym’);
G=zeros(1,2,’sym’);
A=zeros(1,’sym’);
B=zeros(1,’sym’);
C=zeros(1,’sym’);
D=zeros(1,’sym’);
E=zeros(1,’sym’);
F=zeros(1,’sym’);
G_val=zeros(1,’sym’);
series(x)=sym(zeros(1,1));
series1(x)=sym(zeros(1,1));
% Transform Initial condition
T(1)=m;
T(2)=0;
% Initial transform value of exp function
for i=1:4
G(i)=y;
if i==1
E(1)=exp((eta*T(1))/(eta+T(1)));
else
A(1)=0;
for j=1:i-1
E(i)=A(1)+(j/(i-1))*G(j)*E(i-j);
end
B(1)=0;
for j=1:i
B(1)=B(1)+T(j)*G(i-j+1);
end
eq1=G(i)-T(i)+(1/eta)*B(1);
G_val=simplify(solve(eq1,y));
G(i)=simplify(G_val);
E_val=subs(E(i),y,G_val);
E(i)=E_val
end
C(1)=0
for r=1:i
C(1)=C(1)+T(r)*E(i-r+1);
end
T(i + alpha*beta) = (phi^2*C(1)-b*phi^2*E(i))*(gamma(1+(sym(i-1)/beta))/gamma(1+alpha+(sym(i-1)/beta)));
%T(i+2)=simplify((1/(i*(i+1)))*(phi^2*C(1)-b*phi^2*E(i)));
end
for k=1:3
series(x)=simplify(series(x)+T(k)*(power(x,((k-1)*beta))));
end
series
e1=subs(series,x,1);
format long
accuracy=input(‘enter the accuracy’)
f=e1(x)
g=inline(f)
a=input(‘enter the ist approximation=’)
b=input(‘enter the 2nd approximation=’)
fa=feval(g,a)
fb=feval(g,b)
while fa*fb>0
a=input(‘enter the ist approximation=’)
b=input(‘enter the 2nd approximation=’)
fa=feval(g,a)
fb=feval(g,b)
end
for i=1:50
c=(a+b)/2;
fc=feval(g,c);
disp([i a fa b fb c fc abs(b-a)])
if fc==accuracy
fprintf(‘the root of the equation is %f’,c)
break;
elseif abs(b-a)<=accuracy
fprintf(‘the root of the equation is %f’,c)
break;
elseif fa*fc<=0
b=c;
fb=fc;
else
a=c;
fa=fc;
end
end
fprintf(‘the value of c=%f’, c);
series1(x)=subs(series,m,c)
residualError=sym(zeros(1,1));
residual=sym(zeros(1,1));
residualError(x) = abs(diff(series1,x,2)+ B*phi^2*(1-(series1)/B)*exp((eta*series1)/(eta+series1)))
residual_error=double(subs(residualError,x,0.2))
var =double(residual_error);
x=0:0.1:1
error=zeros(1)
row=0;
for i=1:length(x)
row=row+1;
error(row)=(residualErrorx(i))
max_error=max(error)
end
fprintf(‘The residual error is %fn’, max_error);
%—————————————————————–
the error appear as Error using mupadengine/evalin2double
Unable to convert expression containing symbolic variables into double array. Apply ‘subs’ function first to substitute values for variables.
Error in mupadengine/feval2double
Error in sym/double (line 756)
X = feval2double(symengine, "symobj::doubleDirect", S);
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Related documentation
now i substutite the value of m using sysntax series1(x)=subs(series,m,c) but when i later on call series 1 in line residualError(x) = abs(diff(series1,x,2)+ B*phi^2*(1-(series1)/B)*exp((eta*series1)/(eta+series1))) the final expression is having m and y . That is symbolic and craet an errortic
syms x y m %alpha beta b lambda eta phi
phi=sqrt(0.5)
b=10
eta=1
alpha=2;
beta=1;
T=zeros(1,2,’sym’);
G=zeros(1,2,’sym’);
A=zeros(1,’sym’);
B=zeros(1,’sym’);
C=zeros(1,’sym’);
D=zeros(1,’sym’);
E=zeros(1,’sym’);
F=zeros(1,’sym’);
G_val=zeros(1,’sym’);
series(x)=sym(zeros(1,1));
series1(x)=sym(zeros(1,1));
% Transform Initial condition
T(1)=m;
T(2)=0;
% Initial transform value of exp function
for i=1:4
G(i)=y;
if i==1
E(1)=exp((eta*T(1))/(eta+T(1)));
else
A(1)=0;
for j=1:i-1
E(i)=A(1)+(j/(i-1))*G(j)*E(i-j);
end
B(1)=0;
for j=1:i
B(1)=B(1)+T(j)*G(i-j+1);
end
eq1=G(i)-T(i)+(1/eta)*B(1);
G_val=simplify(solve(eq1,y));
G(i)=simplify(G_val);
E_val=subs(E(i),y,G_val);
E(i)=E_val
end
C(1)=0
for r=1:i
C(1)=C(1)+T(r)*E(i-r+1);
end
T(i + alpha*beta) = (phi^2*C(1)-b*phi^2*E(i))*(gamma(1+(sym(i-1)/beta))/gamma(1+alpha+(sym(i-1)/beta)));
%T(i+2)=simplify((1/(i*(i+1)))*(phi^2*C(1)-b*phi^2*E(i)));
end
for k=1:3
series(x)=simplify(series(x)+T(k)*(power(x,((k-1)*beta))));
end
series
e1=subs(series,x,1);
format long
accuracy=input(‘enter the accuracy’)
f=e1(x)
g=inline(f)
a=input(‘enter the ist approximation=’)
b=input(‘enter the 2nd approximation=’)
fa=feval(g,a)
fb=feval(g,b)
while fa*fb>0
a=input(‘enter the ist approximation=’)
b=input(‘enter the 2nd approximation=’)
fa=feval(g,a)
fb=feval(g,b)
end
for i=1:50
c=(a+b)/2;
fc=feval(g,c);
disp([i a fa b fb c fc abs(b-a)])
if fc==accuracy
fprintf(‘the root of the equation is %f’,c)
break;
elseif abs(b-a)<=accuracy
fprintf(‘the root of the equation is %f’,c)
break;
elseif fa*fc<=0
b=c;
fb=fc;
else
a=c;
fa=fc;
end
end
fprintf(‘the value of c=%f’, c);
series1(x)=subs(series,m,c)
residualError=sym(zeros(1,1));
residual=sym(zeros(1,1));
residualError(x) = abs(diff(series1,x,2)+ B*phi^2*(1-(series1)/B)*exp((eta*series1)/(eta+series1)))
residual_error=double(subs(residualError,x,0.2))
var =double(residual_error);
x=0:0.1:1
error=zeros(1)
row=0;
for i=1:length(x)
row=row+1;
error(row)=(residualErrorx(i))
max_error=max(error)
end
fprintf(‘The residual error is %fn’, max_error);
%—————————————————————–
the error appear as Error using mupadengine/evalin2double
Unable to convert expression containing symbolic variables into double array. Apply ‘subs’ function first to substitute values for variables.
Error in mupadengine/feval2double
Error in sym/double (line 756)
X = feval2double(symengine, "symobj::doubleDirect", S);
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Related documentation
now i substutite the value of m using sysntax series1(x)=subs(series,m,c) but when i later on call series 1 in line residualError(x) = abs(diff(series1,x,2)+ B*phi^2*(1-(series1)/B)*exp((eta*series1)/(eta+series1))) the final expression is having m and y . That is symbolic and craet an error tic
syms x y m %alpha beta b lambda eta phi
phi=sqrt(0.5)
b=10
eta=1
alpha=2;
beta=1;
T=zeros(1,2,’sym’);
G=zeros(1,2,’sym’);
A=zeros(1,’sym’);
B=zeros(1,’sym’);
C=zeros(1,’sym’);
D=zeros(1,’sym’);
E=zeros(1,’sym’);
F=zeros(1,’sym’);
G_val=zeros(1,’sym’);
series(x)=sym(zeros(1,1));
series1(x)=sym(zeros(1,1));
% Transform Initial condition
T(1)=m;
T(2)=0;
% Initial transform value of exp function
for i=1:4
G(i)=y;
if i==1
E(1)=exp((eta*T(1))/(eta+T(1)));
else
A(1)=0;
for j=1:i-1
E(i)=A(1)+(j/(i-1))*G(j)*E(i-j);
end
B(1)=0;
for j=1:i
B(1)=B(1)+T(j)*G(i-j+1);
end
eq1=G(i)-T(i)+(1/eta)*B(1);
G_val=simplify(solve(eq1,y));
G(i)=simplify(G_val);
E_val=subs(E(i),y,G_val);
E(i)=E_val
end
C(1)=0
for r=1:i
C(1)=C(1)+T(r)*E(i-r+1);
end
T(i + alpha*beta) = (phi^2*C(1)-b*phi^2*E(i))*(gamma(1+(sym(i-1)/beta))/gamma(1+alpha+(sym(i-1)/beta)));
%T(i+2)=simplify((1/(i*(i+1)))*(phi^2*C(1)-b*phi^2*E(i)));
end
for k=1:3
series(x)=simplify(series(x)+T(k)*(power(x,((k-1)*beta))));
end
series
e1=subs(series,x,1);
format long
accuracy=input(‘enter the accuracy’)
f=e1(x)
g=inline(f)
a=input(‘enter the ist approximation=’)
b=input(‘enter the 2nd approximation=’)
fa=feval(g,a)
fb=feval(g,b)
while fa*fb>0
a=input(‘enter the ist approximation=’)
b=input(‘enter the 2nd approximation=’)
fa=feval(g,a)
fb=feval(g,b)
end
for i=1:50
c=(a+b)/2;
fc=feval(g,c);
disp([i a fa b fb c fc abs(b-a)])
if fc==accuracy
fprintf(‘the root of the equation is %f’,c)
break;
elseif abs(b-a)<=accuracy
fprintf(‘the root of the equation is %f’,c)
break;
elseif fa*fc<=0
b=c;
fb=fc;
else
a=c;
fa=fc;
end
end
fprintf(‘the value of c=%f’, c);
series1(x)=subs(series,m,c)
residualError=sym(zeros(1,1));
residual=sym(zeros(1,1));
residualError(x) = abs(diff(series1,x,2)+ B*phi^2*(1-(series1)/B)*exp((eta*series1)/(eta+series1)))
residual_error=double(subs(residualError,x,0.2))
var =double(residual_error);
x=0:0.1:1
error=zeros(1)
row=0;
for i=1:length(x)
row=row+1;
error(row)=(residualErrorx(i))
max_error=max(error)
end
fprintf(‘The residual error is %fn’, max_error);
%—————————————————————–
the error appear as Error using mupadengine/evalin2double
Unable to convert expression containing symbolic variables into double array. Apply ‘subs’ function first to substitute values for variables.
Error in mupadengine/feval2double
Error in sym/double (line 756)
X = feval2double(symengine, "symobj::doubleDirect", S);
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Related documentation
now i substutite the value of m using sysntax series1(x)=subs(series,m,c) but when i later on call series 1 in line residualError(x) = abs(diff(series1,x,2)+ B*phi^2*(1-(series1)/B)*exp((eta*series1)/(eta+series1))) the final expression is having m and y . That is symbolic and craet an error symbolic compuational MATLAB Answers — New Questions









