Category: News
Windows Explorer Fails to Load Correctly After (Re)Starting the Computer
I have a desktop setup primarily used for Blue Iris and IP cameras. While it operates efficiently overall, it encounters persistent startup issues that are challenging to diagnose.
Upon booting Windows 11, the system frequently encounters a failure to load Windows Explorer. Typically, the taskbar remains inaccessible, leaving just a blank space at the bottom of the screen. However, desktop icons appear correctly. Resolving this issue involves pressing ctrl+shift+esc to force close explorer.exe and then restarting it.
Alternatively, when the taskbar does load, the initial start menu functions intermittently, displaying the pinned apps menu but failing to execute further commands. Attempting to search for and open an app results in an endless search that never completes. Sometimes, after a delay of 15-20 minutes, the system finally functions smoothly without glitches.
After the system successfully boots up, operations run smoothly without any hindrances. I have a setup with 16 cameras continuously recording without any performance issues. Despite attempting to reformat my system multiple times, the problematic startup behavior persists. Monitoring through the task manager shows CPU utilization around 20% and memory usage at 45%.
For a detailed list of my system specifications, please refer to my profile. Thank you.
I have a desktop setup primarily used for Blue Iris and IP cameras. While it operates efficiently overall, it encounters persistent startup issues that are challenging to diagnose. Upon booting Windows 11, the system frequently encounters a failure to load Windows Explorer. Typically, the taskbar remains inaccessible, leaving just a blank space at the bottom of the screen. However, desktop icons appear correctly. Resolving this issue involves pressing ctrl+shift+esc to force close explorer.exe and then restarting it. Alternatively, when the taskbar does load, the initial start menu functions intermittently, displaying the pinned apps menu but failing to execute further commands. Attempting to search for and open an app results in an endless search that never completes. Sometimes, after a delay of 15-20 minutes, the system finally functions smoothly without glitches. After the system successfully boots up, operations run smoothly without any hindrances. I have a setup with 16 cameras continuously recording without any performance issues. Despite attempting to reformat my system multiple times, the problematic startup behavior persists. Monitoring through the task manager shows CPU utilization around 20% and memory usage at 45%. For a detailed list of my system specifications, please refer to my profile. Thank you. Read More
Copying speed plummets by a staggering 90% – Unexpected Change Detected
Initially, both of my office desktop computers were performing well. They were reliable machines for my tasks.
However, today, I encountered an issue with System 2. It experienced a significant decrease in copying speed when transferring data from the internal NVMe to an external SSD. Normally, both System 1 and System 2 were able to copy large files at a speed of 350+ MB/s from internal storage to an external device. But today, System 2 started copying at a disappointing rate of only 35+ MB/s.
I vaguely remember complaining about a similar issue in the past where System 2’s copying speed dropped suddenly after initially performing well. However, the problem seemed to resolve itself back then. Yet, today, the slow copying speed persisted throughout a ten-minute process of copying a 17 GB file.
I tried troubleshooting by checking the external connections, swapping SSD disks, and testing different USB3 ports on System 2. Interestingly, when I tested System 1’s performance in copying the same file to an external device, it maintained the high speed of 350+ MB/s. But when I attempted to copy the same file from System 1 to System 2 and then to an external device, the speed dropped to 35+ MB/s again.
Furthermore, transferring a slow-copying file from System 2 to System 1 resulted in no speed issues. It was only when copying from System 2 to an external device that the slow speed persisted. System 2’s overall performance seems comparable to that of System 1, except for this sudden copying problem.
Despite the setback, I am optimistic that with the support of my friends, I will be able to tackle this issue. The lightning-fast speeds observed when transferring files over Wi-Fi and between internal drives suggest that the problem may lie with the USB3 ports on System 2.
Initially, both of my office desktop computers were performing well. They were reliable machines for my tasks. However, today, I encountered an issue with System 2. It experienced a significant decrease in copying speed when transferring data from the internal NVMe to an external SSD. Normally, both System 1 and System 2 were able to copy large files at a speed of 350+ MB/s from internal storage to an external device. But today, System 2 started copying at a disappointing rate of only 35+ MB/s. I vaguely remember complaining about a similar issue in the past where System 2’s copying speed dropped suddenly after initially performing well. However, the problem seemed to resolve itself back then. Yet, today, the slow copying speed persisted throughout a ten-minute process of copying a 17 GB file. I tried troubleshooting by checking the external connections, swapping SSD disks, and testing different USB3 ports on System 2. Interestingly, when I tested System 1’s performance in copying the same file to an external device, it maintained the high speed of 350+ MB/s. But when I attempted to copy the same file from System 1 to System 2 and then to an external device, the speed dropped to 35+ MB/s again. Furthermore, transferring a slow-copying file from System 2 to System 1 resulted in no speed issues. It was only when copying from System 2 to an external device that the slow speed persisted. System 2’s overall performance seems comparable to that of System 1, except for this sudden copying problem. Despite the setback, I am optimistic that with the support of my friends, I will be able to tackle this issue. The lightning-fast speeds observed when transferring files over Wi-Fi and between internal drives suggest that the problem may lie with the USB3 ports on System 2. Read More
File Explorer in Windows 11
Hello everyone,
I have successfully recovered deleted and formatted files from multiple small disks onto a single large disk. I am now looking to organize and categorize them into different sub-directories so that I can access these files with various programs.
Issue: The File Explorer is constantly searching, indexing, and attempting to open these files, creating a challenge due to the immense volume of over 8TB.
Resolution: I am seeking guidance on how to prevent File Explorer from constantly engaging with these files. Any suggestions or advice would be greatly appreciated.
Hello everyone, I have successfully recovered deleted and formatted files from multiple small disks onto a single large disk. I am now looking to organize and categorize them into different sub-directories so that I can access these files with various programs. Issue: The File Explorer is constantly searching, indexing, and attempting to open these files, creating a challenge due to the immense volume of over 8TB. Resolution: I am seeking guidance on how to prevent File Explorer from constantly engaging with these files. Any suggestions or advice would be greatly appreciated. Read More
Boot Error: Black Screen Instead of Graphics Menu
I prefer a graphics boot menu on my new laptop that includes only the essential host PC and Macrium Reflect boot entries. Unfortunately, my new laptop does not display these options, showing only a blank black screen instead.
I do not care for the old text style menu as it only appears in low resolution.
After some troubleshooting, I discovered a partial solution. By enabling hibernation, the graphics boot menu displays properly when starting from a shutdown (not from a hibernated state).
Although I haven’t used hibernation much in the past, I was pleasantly surprised to find that my new laptop starts up from a hibernated state in around 5 seconds. Sleep mode, on the other hand, is nearly instantaneous (<1 second) but uses minimal power.
It seems there may be a BIOS bug at play here, particularly since this issue only arose after updating to the latest BIOS version!
For now, I am not using Insider versions as a native boot option on my new laptop, reserving that functionality for my older device.
I prefer a graphics boot menu on my new laptop that includes only the essential host PC and Macrium Reflect boot entries. Unfortunately, my new laptop does not display these options, showing only a blank black screen instead. I do not care for the old text style menu as it only appears in low resolution. After some troubleshooting, I discovered a partial solution. By enabling hibernation, the graphics boot menu displays properly when starting from a shutdown (not from a hibernated state). Although I haven’t used hibernation much in the past, I was pleasantly surprised to find that my new laptop starts up from a hibernated state in around 5 seconds. Sleep mode, on the other hand, is nearly instantaneous (<1 second) but uses minimal power. It seems there may be a BIOS bug at play here, particularly since this issue only arose after updating to the latest BIOS version! For now, I am not using Insider versions as a native boot option on my new laptop, reserving that functionality for my older device. Read More
Windows 11 Frequent Freezing Issues
Greetings to all! As a software developer, I’ve come across a persisting issue with hangs on my system recently. While occasional crashes are somewhat expected in Windows 11, lasting only about a second or so, my system has been freezing up during daily tasks, particularly when working on projects in Visual Studio. Curiously, the audio continues playing smoothly even after the system becomes unresponsive.
Oddly enough, my high-end PC doesn’t encounter these freezes when running graphics-intensive games like GTA5 or Valorant on ultra settings, only during regular use. Despite checking the event viewer, the cause of these hangs remains elusive, ruling out malware, hardware issues, or system overload as potential culprits.
One workaround I’ve employed in the past for a taskbar-related glitch was using ExplorerPatcher. Nevertheless, the recurring system freezes persist, forcing me to resort to a hard reset as the only solution to regain control.
Greetings to all! As a software developer, I’ve come across a persisting issue with hangs on my system recently. While occasional crashes are somewhat expected in Windows 11, lasting only about a second or so, my system has been freezing up during daily tasks, particularly when working on projects in Visual Studio. Curiously, the audio continues playing smoothly even after the system becomes unresponsive. Oddly enough, my high-end PC doesn’t encounter these freezes when running graphics-intensive games like GTA5 or Valorant on ultra settings, only during regular use. Despite checking the event viewer, the cause of these hangs remains elusive, ruling out malware, hardware issues, or system overload as potential culprits. One workaround I’ve employed in the past for a taskbar-related glitch was using ExplorerPatcher. Nevertheless, the recurring system freezes persist, forcing me to resort to a hard reset as the only solution to regain control. Read More
Disable autofill feature on the webmail login page
I am currently experiencing an issue with my local internet service provider’s web-based email account. Previously, when logging in, the email address field would autofill upon clicking. However, this feature has stopped working recently, requiring me to manually type in my email address every time. This issue persists across both Edge and Chrome browsers, despite no apparent changes to my settings.
One suggestion was that my Bitdefender antivirus software may have altered something, though I am unsure. I plan to reach out to Bitdefender for clarification.
Any insights or solutions to this problem would be greatly appreciated.
Thank you,
D.
I am currently experiencing an issue with my local internet service provider’s web-based email account. Previously, when logging in, the email address field would autofill upon clicking. However, this feature has stopped working recently, requiring me to manually type in my email address every time. This issue persists across both Edge and Chrome browsers, despite no apparent changes to my settings. One suggestion was that my Bitdefender antivirus software may have altered something, though I am unsure. I plan to reach out to Bitdefender for clarification. Any insights or solutions to this problem would be greatly appreciated. Thank you, D. Read More
Windows 11 – Repairable Component Store
It is highly probable that the solution is available in this forum. Despite conducting thorough searches, I am still seeking assistance in understanding how to address the issue of receiving the “The component store is repairable.” message following the execution of DISM /Online /Cleanup-Image /RestoreHealth.
I have reviewed various posts and potential solutions both in this forum and on the Microsoft Community platform. While I grasp the core concept, I am struggling to piece together the necessary steps to resolve the issue. I require straightforward instructions.
My laptop, which is three months old, features an Intel CPU (13900HX), Nvidia 3040-4060 GPU, WD Black SSD, and runs on Windows 11 23H2.
Any guidance provided would be greatly appreciated.
It is highly probable that the solution is available in this forum. Despite conducting thorough searches, I am still seeking assistance in understanding how to address the issue of receiving the “The component store is repairable.” message following the execution of DISM /Online /Cleanup-Image /RestoreHealth. I have reviewed various posts and potential solutions both in this forum and on the Microsoft Community platform. While I grasp the core concept, I am struggling to piece together the necessary steps to resolve the issue. I require straightforward instructions. My laptop, which is three months old, features an Intel CPU (13900HX), Nvidia 3040-4060 GPU, WD Black SSD, and runs on Windows 11 23H2. Any guidance provided would be greatly appreciated. Read More
How does Windows 11 perform for dual booting and sharing drives with Windows 10?
I have a customized Windows 10 Pro setup on my current machine, and I’m interested in adding Windows 11 Pro on a different SSD drive while ensuring both operating systems can access a third SSD drive. For instance, I plan to use Windows 10 for photo editing with files on drive 3, and Windows 11 for video editing with the same drive 3 files.
Is it possible to achieve this without encountering issues such as ‘drive access denied’ when accessing drive 3 from either Windows 10 or Windows 11? Additionally, do you have any other tips or recommendations for this setup?
Thank you.
I have a customized Windows 10 Pro setup on my current machine, and I’m interested in adding Windows 11 Pro on a different SSD drive while ensuring both operating systems can access a third SSD drive. For instance, I plan to use Windows 10 for photo editing with files on drive 3, and Windows 11 for video editing with the same drive 3 files. Is it possible to achieve this without encountering issues such as ‘drive access denied’ when accessing drive 3 from either Windows 10 or Windows 11? Additionally, do you have any other tips or recommendations for this setup? Thank you. Read More
Help Please
I have a spreadsheet where The date is in one column and whether the item has been actioned is another column.
I currently use a COUNTIF formula to show a total for each category (Not Started / In Progress / Completed), however the data goes back over three years.
I am looking for a formula where I can show each categories number value for each year.
I have a spreadsheet where The date is in one column and whether the item has been actioned is another column.I currently use a COUNTIF formula to show a total for each category (Not Started / In Progress / Completed), however the data goes back over three years.I am looking for a formula where I can show each categories number value for each year. Read More
Compare data- plz help asap
hi all,
im new to excel and need help very urgently with my data
I have 2 sets of data open on 2 separate tabs and i must combine them to compare –>through a chart then make a graph, however when i tried to paste data set #1 to data set #2 as a second sheet it does not do anything other than say “pasting in progress” (it has been about an hour) please advise. I followed some basic steps given from a microsoft rep but it also didnt work out
hi all,im new to excel and need help very urgently with my dataI have 2 sets of data open on 2 separate tabs and i must combine them to compare –>through a chart then make a graph, however when i tried to paste data set #1 to data set #2 as a second sheet it does not do anything other than say “pasting in progress” (it has been about an hour) please advise. I followed some basic steps given from a microsoft rep but it also didnt work out Read More
Graphic display problem after using normalized coordinates in Matlab
Hi,guys.
I encountered a problem. That is, when I use normalized coordinates, no matter how I adjust the diameter of my target circle, there is no change in the image. I can feel the change in the coordinates. But I don’t need this. I want the entire image to change after adjusting the diameter.
Here are the codes:
function startTask()
targetCenters = zeros(8, 2);
angles = linspace(0, 2*pi, 9);
angles = angles(1:end-1);
radii = 0.3;
waitingForNextTarget = false;
firstMove = true;
resetPosition = [0, 0];
targetSequence = [1,3,5,7,2,4,6,8,8,6,4,2,7,5,3,1];
currentSequenceIndex = 1;
for i = 1:length(angles)
targetCenters(i, 1) = radii * cos(angles(i));
targetCenters(i, 2) = radii * sin(angles(i));
end
targetActivated = false;
currentTarget = 0;
hoverStartTime = [];
cyclesCompleted = 0;
maxCycles = 64;
mousePath = [];
mouseDot = [];
x = 0;
y = 0;
timerObj = timer(‘TimerFcn’, @recordMousePos, ‘Period’, 0.02 , ‘ExecutionMode’, ‘fixedRate’);
checkTargetTimer = timer(‘TimerFcn’, @checkAndActivateTarget, ‘Period’, 0.02 , ‘ExecutionMode’, ‘fixedRate’);
start(checkTargetTimer);
fig = figure(‘Color’, ‘black’, ‘Pointer’, ‘custom’, ‘Units’, ‘normalized’, ‘Position’, [0 0 1 1], ‘MenuBar’, ‘none’, ‘ToolBar’, ‘none’);
ax = axes(‘Color’, ‘black’, ‘Units’, ‘normalized’, ‘Position’, [0 0 1 1], ‘DataAspectRatio’, [1 1 1]);
axis off;
hold on;
drawCircles();
set(fig, ‘WindowButtonMotionFcn’, @mouseMoved);
setInvisibleCursor();
showBlackPanelScreen(2)
resetMouseAndDotPositionToCenter();
activateRandomTarget();
function setInvisibleCursor()
transparentCursor = NaN(16, 16);
hotspot = [8, 8];
set(fig, ‘Pointer’, ‘custom’, ‘PointerShapeCData’, transparentCursor, ‘PointerShapeHotSpot’, hotspot);
end
function drawCircles()
angles = linspace(0, 2*pi, 9);
angles = angles(1:end-1);
circleDiameter = radii * 0.2;
%axis equal;
for i = 1:length(angles)
x = radii * cos(angles(i));
y = radii * sin(angles(i));
rectangle(‘Position’, [x – circleDiameter/2, y – circleDiameter/2, circleDiameter, circleDiameter], ‘Curvature’, [1, 1], ‘EdgeColor’, ‘w’, ‘FaceColor’, ‘k’, ‘LineStyle’, ‘–‘, ‘LineWidth’, 3, ‘UserData’, i);
end
end
SichengHi,guys.
I encountered a problem. That is, when I use normalized coordinates, no matter how I adjust the diameter of my target circle, there is no change in the image. I can feel the change in the coordinates. But I don’t need this. I want the entire image to change after adjusting the diameter.
Here are the codes:
function startTask()
targetCenters = zeros(8, 2);
angles = linspace(0, 2*pi, 9);
angles = angles(1:end-1);
radii = 0.3;
waitingForNextTarget = false;
firstMove = true;
resetPosition = [0, 0];
targetSequence = [1,3,5,7,2,4,6,8,8,6,4,2,7,5,3,1];
currentSequenceIndex = 1;
for i = 1:length(angles)
targetCenters(i, 1) = radii * cos(angles(i));
targetCenters(i, 2) = radii * sin(angles(i));
end
targetActivated = false;
currentTarget = 0;
hoverStartTime = [];
cyclesCompleted = 0;
maxCycles = 64;
mousePath = [];
mouseDot = [];
x = 0;
y = 0;
timerObj = timer(‘TimerFcn’, @recordMousePos, ‘Period’, 0.02 , ‘ExecutionMode’, ‘fixedRate’);
checkTargetTimer = timer(‘TimerFcn’, @checkAndActivateTarget, ‘Period’, 0.02 , ‘ExecutionMode’, ‘fixedRate’);
start(checkTargetTimer);
fig = figure(‘Color’, ‘black’, ‘Pointer’, ‘custom’, ‘Units’, ‘normalized’, ‘Position’, [0 0 1 1], ‘MenuBar’, ‘none’, ‘ToolBar’, ‘none’);
ax = axes(‘Color’, ‘black’, ‘Units’, ‘normalized’, ‘Position’, [0 0 1 1], ‘DataAspectRatio’, [1 1 1]);
axis off;
hold on;
drawCircles();
set(fig, ‘WindowButtonMotionFcn’, @mouseMoved);
setInvisibleCursor();
showBlackPanelScreen(2)
resetMouseAndDotPositionToCenter();
activateRandomTarget();
function setInvisibleCursor()
transparentCursor = NaN(16, 16);
hotspot = [8, 8];
set(fig, ‘Pointer’, ‘custom’, ‘PointerShapeCData’, transparentCursor, ‘PointerShapeHotSpot’, hotspot);
end
function drawCircles()
angles = linspace(0, 2*pi, 9);
angles = angles(1:end-1);
circleDiameter = radii * 0.2;
%axis equal;
for i = 1:length(angles)
x = radii * cos(angles(i));
y = radii * sin(angles(i));
rectangle(‘Position’, [x – circleDiameter/2, y – circleDiameter/2, circleDiameter, circleDiameter], ‘Curvature’, [1, 1], ‘EdgeColor’, ‘w’, ‘FaceColor’, ‘k’, ‘LineStyle’, ‘–‘, ‘LineWidth’, 3, ‘UserData’, i);
end
end
Sicheng Hi,guys.
I encountered a problem. That is, when I use normalized coordinates, no matter how I adjust the diameter of my target circle, there is no change in the image. I can feel the change in the coordinates. But I don’t need this. I want the entire image to change after adjusting the diameter.
Here are the codes:
function startTask()
targetCenters = zeros(8, 2);
angles = linspace(0, 2*pi, 9);
angles = angles(1:end-1);
radii = 0.3;
waitingForNextTarget = false;
firstMove = true;
resetPosition = [0, 0];
targetSequence = [1,3,5,7,2,4,6,8,8,6,4,2,7,5,3,1];
currentSequenceIndex = 1;
for i = 1:length(angles)
targetCenters(i, 1) = radii * cos(angles(i));
targetCenters(i, 2) = radii * sin(angles(i));
end
targetActivated = false;
currentTarget = 0;
hoverStartTime = [];
cyclesCompleted = 0;
maxCycles = 64;
mousePath = [];
mouseDot = [];
x = 0;
y = 0;
timerObj = timer(‘TimerFcn’, @recordMousePos, ‘Period’, 0.02 , ‘ExecutionMode’, ‘fixedRate’);
checkTargetTimer = timer(‘TimerFcn’, @checkAndActivateTarget, ‘Period’, 0.02 , ‘ExecutionMode’, ‘fixedRate’);
start(checkTargetTimer);
fig = figure(‘Color’, ‘black’, ‘Pointer’, ‘custom’, ‘Units’, ‘normalized’, ‘Position’, [0 0 1 1], ‘MenuBar’, ‘none’, ‘ToolBar’, ‘none’);
ax = axes(‘Color’, ‘black’, ‘Units’, ‘normalized’, ‘Position’, [0 0 1 1], ‘DataAspectRatio’, [1 1 1]);
axis off;
hold on;
drawCircles();
set(fig, ‘WindowButtonMotionFcn’, @mouseMoved);
setInvisibleCursor();
showBlackPanelScreen(2)
resetMouseAndDotPositionToCenter();
activateRandomTarget();
function setInvisibleCursor()
transparentCursor = NaN(16, 16);
hotspot = [8, 8];
set(fig, ‘Pointer’, ‘custom’, ‘PointerShapeCData’, transparentCursor, ‘PointerShapeHotSpot’, hotspot);
end
function drawCircles()
angles = linspace(0, 2*pi, 9);
angles = angles(1:end-1);
circleDiameter = radii * 0.2;
%axis equal;
for i = 1:length(angles)
x = radii * cos(angles(i));
y = radii * sin(angles(i));
rectangle(‘Position’, [x – circleDiameter/2, y – circleDiameter/2, circleDiameter, circleDiameter], ‘Curvature’, [1, 1], ‘EdgeColor’, ‘w’, ‘FaceColor’, ‘k’, ‘LineStyle’, ‘–‘, ‘LineWidth’, 3, ‘UserData’, i);
end
end
Sicheng graphics,, normalized coordinates MATLAB Answers — New Questions
obtaining single polynomial equation using Heun’s method from 4 second order differential equations
I get this error when trying to solve these 4 second order differential equations using a program that solves them using Heun’s method and then Gaussian elimination to get a polynomial equation the represents the system. Previsouly posted for help, but the soluitions have symbolics and I need a singular soluition that represents all 4 equations. Does any one have a suggestion on how I can slove this? Is using the "function" with all 4 equations the best way to do this, or is there a nicer method for doing this?
clear,close,clc
%______________________________________________________________SOLUITION_2_Heun’s_Method_(for second order differential equations)_&__Least-Square_Nethod____________________________________________________________%
%4 Equations representing the system working with
% MfXf"=Ksf([Xb-(L1*theta)]-Xf)+Bsf([Xb’-(L1*theta’)-Xf’)-(Kf*Xf);
% MrXr"=Ksr([Xb+(L2*theta)]-Xr)+Bsr([Xb’+(L2*theta’)]-Xr’)-(Kr*Xr) ;
% MbXb"=Ksf([Xb-(L1*theta)]-Xf)+Bsf([Xb’-(L1*theta’)]-Xf’)+Ksr([Xb+(L2*theta)]-Xr)+Bsr([Xb’+(L2*theta’)]-Xr’)+fa(t);
% Ic*theta"={-[Ksf(Xf-(L1*theta))*L1]-[Bsf(Xf’-(L1*theta’))*L1]+[Ksr(Xr+(L2*theta))*L2]+[Bsr(Xr’+(L2*theta’))*L2]+[fa(t)*L3]};
%————————————————-SYSTEM_PARAMETERS———————————————————————————————————————————————————-
Ic=1356; %kg-m^2
Mb=730; %kg
Mf=59; %kg
Mr=45; %kg
Kf=23000; %N/m
Ksf=18750; %N/m
Kr=16182; %N/m
Ksr=12574; %N/m
Bsf=100; %N*s/m
Bsr=100; %N*s/m
L1=1.45; %m
L2=1.39; %m
L3=0.67; %m
t0=0; %time at the start
tm=20; %what value of (t time) you are ending at
t=t0:tm; % time from time start to time finish seconds
n=4; %order of the polynomial
%Initial Conditions-system at rest therefore x(0)=0 dXf/dt(0)=0 dXr/dt(0)=0 dXb/dt(0)=0 dtheta/dt(0)=0 ;
%time from 0 to 20 h=dx=5;
x0=0; %x at initial condition
y0=0; %y at initial condition
dx=5; %delta(x) or h
h=dx;
%==INPUT SECTION for Euler’s and Heun’s==%
fx=@(x,y,t)y;
fy=@(x,y,t)Projectfunction;
%==CALCULATIONS SECTION==%
tn=t0:h:tm;
xn(1) = x0;
yn(1) = y0;
for i=1:length(tn)
%==EULER’S METHOD
xn(i+1)=xn(i)+fx(xn(i),yn(i),tn(i))*h;
yn(i+1)=yn(i)+fy(xn(i),yn(i),tn(i))*h;
%==NEXT 3 LINES ARE FOR HEUN’S METHOD
tn(i+1)=tn(i)+h;
xn(i+1)=xn(i)+0.5*(fx(xn(i),yn(i),tn(i))+fx(xn(i+1),yn(i+1),tn(i+1)))*h;
yn(i+1)=yn(i)+0.5*(fy(xn(i),yn(i),tn(i))+fy(xn(i+1),yn(i+1),tn(i+1)))*h;
fprintf(‘t=%0.2ft y=%0.3ft z=%0.3fn’,tn(i),xn(i),yn(i))
end
%%%LEAST SQUARE METHOD-FINDS POLYNOMIAL FOR GIVEN DATA SET%%%%%
%INPUT SECTION for Least-Square
X=xn;
Y=yn;
%%__CALCULATIONS SECTION__%%
k=length(X); %NUMBER OF AVAILABLE DATA POINTS
m=n+1; %SIZE OF THE COEFFICENT MATRIX
A=zeros(m,m); %COEFFICENT MATRIX
for j=1:m
for i=1:m
A(j,i)=sum(X.^(i+j-2));
end
end
B=zeros(m,1); %FORCING FUNCTION VECTOR
for i=1:m;
B(i)=sum(Y.*X.^(i-1));
end
a1=AB %COEFFICIENTS FOR THE POLYNOMINAL–> y=a0+a1*x+a2*x^2….an*x^n CAN BE REPLACED BY GAUSSIAN ELIMINATION
%%%%%=========GAUSSIAN ELIMINATION TO FIND "a"========%%%%%%
%%%INPUT SECTION
%CALCULATION SECTION
AB=[A B]; %Augumentent matrix
R=size(AB,1); %# OF ROWS IN AB
C=size(AB,2); %# OF COLUMNS IN AB
%%%%FOWARD ELIMINATION SECTION
for J=1:R-1
[M,I]=max(abs(AB(J:R,J))); %M=MAXIMUM VALUE, I=LOCATION OF THE MAXIMUM VALUE IN THE 1ST ROW
temp=AB(J,:);
AB(J,:)=AB(I+(J-1),:);
AB(I+(J-1),:)=temp;
for i=(J+1):R;
if AB(i,J)~=0;
AB(i,:)=AB(i,:)-(AB(i,J)/AB(J,J))*AB(J,:);
end
end
end
%%%%BACKWARDS SUBSTITUTION
a(R)=AB(R,C)/AB(R,R);
for i=R-1:-1:1
a(i)=(AB(i,C)-AB(i,i+1:R)*a(i+1:R)’)/AB(i,i);
end
disp(a)
syms X
P=0;
for i=1:m;
TT=a(i)*X^(i-1); %T=INDIVIDUAL POLYNOMIAL TERMS
P=P+TT;
end
display(P)
%========END OF GAUSSIAN ELIMINATION=======%%%%%%%%
%STANDARD DEVIATION
Y_bar=mean(Y); %ADVERAGE OF y
St=sum((Y-Y_bar).^2);
SD=sqrt(St/(k-1)); %STANDARD DEVIATION
%STANDARD ERROR
for i=1:m;
T(:,i)=a(i)*X.^(i-1); %T=INDIVIDUAL POLYNOMIAL TERMS
end
for i=1:k
y_hat(i)=sum(T(i,:));
end
Sr=sum((Y-y_hat).^2);
Se=sqrt(Sr/(k-(n+1))); %STANDARD ERROR-Se
%COEFFICIENT OF DETERMINATION
Cd=(St-Sr)/St %COEFFICIENT OF DETERMINATION (r^2)
Cd = 1.0000
fprintf(‘For n=%d. Coefficient of Determination=%0.5fn’,n,Cd)
function [dydt] = Projectfunction(t,x,y)
Ic=1356; %kg-m^2
Mb=730; %kg
Mf=59; %kg
Mr=45; %kg
Kf=23000; %N/m
Ksf=18750; %N/m
Kr=16182; %N/m
Ksr=12574; %N/m
Bsf=100; %N*s/m
Bsr=100; %N*s/m
L1=1.45; %m
L2=1.39; %m
L3=0.67; %m
x1 = x(1); %x1=Xf
x2 = x(2); %x2=Xr
x3 = x(3); %x3=Xb
x4 = x(4); %x4=theta
y1 = y(1); %y1=Xf’=dXf/dt
y2 = y(2); %y2=Xr’=dXr/dt
y3 = y(3); %y3=Xb’=dXb/dt
y4 = y(4); %y4=theta’=dtheta/dt
dydt1 = (Ksf*((x3-(L1*x4)))-x1)+Bsf*((y3-(L1*y4)-y1)-(Kf*x1))/Mf;
dydt2 = (Ksr*((x3+(L2*x4))-x2)+Bsr*((y3+(L2*y4))-y2)-(Kr*x2))/Mr;
dydt3 = (Ksf*((x3-(L1*x4))-x1)+Bsf*((y3-(L1*y4))-y1)+Ksr*((x3+(L2*x4))-x2)+Bsr*((y3+(L2*y4))-y2)-(10*exp(-(5*t))))/Mb;
dydt4 = ((-(Ksf*(x1-(L1*x4))*L1)-(Bsf*(y1-(L1*y4))*L1)+(Ksr*(x2+(L2*x4))*L2)+(Bsr*(y2+(L2*y4))*L2)+((10*exp(-(5*t)))*L3)))/Ic;
[dydt] = [dydt1; dydt2; dydt3; dydt4];
end
% MfXf"=Ksf([Xb-(L1*theta)]-Xf)+Bsf([Xb’-(L1*theta’)-Xf’)-(Kf*Xf);
% MrXr"=Ksr([Xb+(L2*theta)]-Xr)+Bsr([Xb’+(L2*theta’)]-Xr’)-(Kr*Xr) ;
% MbXb"=Ksf([Xb-(L1*theta)]-Xf)+Bsf([Xb’-(L1*theta’)]-Xf’)+Ksr([Xb+(L2*theta)]-Xr)+Bsr([Xb’+(L2*theta’)]-Xr’)+fa(t);
% Ic*theta"={-[Ksf(Xf-(L1*theta))*L1]-[Bsf(Xf’-(L1*theta’))*L1]+[Ksr(Xr+(L2*theta))*L2]+[Bsr(Xr’+(L2*theta’))*L2]+[fa(t)*L3]};I get this error when trying to solve these 4 second order differential equations using a program that solves them using Heun’s method and then Gaussian elimination to get a polynomial equation the represents the system. Previsouly posted for help, but the soluitions have symbolics and I need a singular soluition that represents all 4 equations. Does any one have a suggestion on how I can slove this? Is using the "function" with all 4 equations the best way to do this, or is there a nicer method for doing this?
clear,close,clc
%______________________________________________________________SOLUITION_2_Heun’s_Method_(for second order differential equations)_&__Least-Square_Nethod____________________________________________________________%
%4 Equations representing the system working with
% MfXf"=Ksf([Xb-(L1*theta)]-Xf)+Bsf([Xb’-(L1*theta’)-Xf’)-(Kf*Xf);
% MrXr"=Ksr([Xb+(L2*theta)]-Xr)+Bsr([Xb’+(L2*theta’)]-Xr’)-(Kr*Xr) ;
% MbXb"=Ksf([Xb-(L1*theta)]-Xf)+Bsf([Xb’-(L1*theta’)]-Xf’)+Ksr([Xb+(L2*theta)]-Xr)+Bsr([Xb’+(L2*theta’)]-Xr’)+fa(t);
% Ic*theta"={-[Ksf(Xf-(L1*theta))*L1]-[Bsf(Xf’-(L1*theta’))*L1]+[Ksr(Xr+(L2*theta))*L2]+[Bsr(Xr’+(L2*theta’))*L2]+[fa(t)*L3]};
%————————————————-SYSTEM_PARAMETERS———————————————————————————————————————————————————-
Ic=1356; %kg-m^2
Mb=730; %kg
Mf=59; %kg
Mr=45; %kg
Kf=23000; %N/m
Ksf=18750; %N/m
Kr=16182; %N/m
Ksr=12574; %N/m
Bsf=100; %N*s/m
Bsr=100; %N*s/m
L1=1.45; %m
L2=1.39; %m
L3=0.67; %m
t0=0; %time at the start
tm=20; %what value of (t time) you are ending at
t=t0:tm; % time from time start to time finish seconds
n=4; %order of the polynomial
%Initial Conditions-system at rest therefore x(0)=0 dXf/dt(0)=0 dXr/dt(0)=0 dXb/dt(0)=0 dtheta/dt(0)=0 ;
%time from 0 to 20 h=dx=5;
x0=0; %x at initial condition
y0=0; %y at initial condition
dx=5; %delta(x) or h
h=dx;
%==INPUT SECTION for Euler’s and Heun’s==%
fx=@(x,y,t)y;
fy=@(x,y,t)Projectfunction;
%==CALCULATIONS SECTION==%
tn=t0:h:tm;
xn(1) = x0;
yn(1) = y0;
for i=1:length(tn)
%==EULER’S METHOD
xn(i+1)=xn(i)+fx(xn(i),yn(i),tn(i))*h;
yn(i+1)=yn(i)+fy(xn(i),yn(i),tn(i))*h;
%==NEXT 3 LINES ARE FOR HEUN’S METHOD
tn(i+1)=tn(i)+h;
xn(i+1)=xn(i)+0.5*(fx(xn(i),yn(i),tn(i))+fx(xn(i+1),yn(i+1),tn(i+1)))*h;
yn(i+1)=yn(i)+0.5*(fy(xn(i),yn(i),tn(i))+fy(xn(i+1),yn(i+1),tn(i+1)))*h;
fprintf(‘t=%0.2ft y=%0.3ft z=%0.3fn’,tn(i),xn(i),yn(i))
end
%%%LEAST SQUARE METHOD-FINDS POLYNOMIAL FOR GIVEN DATA SET%%%%%
%INPUT SECTION for Least-Square
X=xn;
Y=yn;
%%__CALCULATIONS SECTION__%%
k=length(X); %NUMBER OF AVAILABLE DATA POINTS
m=n+1; %SIZE OF THE COEFFICENT MATRIX
A=zeros(m,m); %COEFFICENT MATRIX
for j=1:m
for i=1:m
A(j,i)=sum(X.^(i+j-2));
end
end
B=zeros(m,1); %FORCING FUNCTION VECTOR
for i=1:m;
B(i)=sum(Y.*X.^(i-1));
end
a1=AB %COEFFICIENTS FOR THE POLYNOMINAL–> y=a0+a1*x+a2*x^2….an*x^n CAN BE REPLACED BY GAUSSIAN ELIMINATION
%%%%%=========GAUSSIAN ELIMINATION TO FIND "a"========%%%%%%
%%%INPUT SECTION
%CALCULATION SECTION
AB=[A B]; %Augumentent matrix
R=size(AB,1); %# OF ROWS IN AB
C=size(AB,2); %# OF COLUMNS IN AB
%%%%FOWARD ELIMINATION SECTION
for J=1:R-1
[M,I]=max(abs(AB(J:R,J))); %M=MAXIMUM VALUE, I=LOCATION OF THE MAXIMUM VALUE IN THE 1ST ROW
temp=AB(J,:);
AB(J,:)=AB(I+(J-1),:);
AB(I+(J-1),:)=temp;
for i=(J+1):R;
if AB(i,J)~=0;
AB(i,:)=AB(i,:)-(AB(i,J)/AB(J,J))*AB(J,:);
end
end
end
%%%%BACKWARDS SUBSTITUTION
a(R)=AB(R,C)/AB(R,R);
for i=R-1:-1:1
a(i)=(AB(i,C)-AB(i,i+1:R)*a(i+1:R)’)/AB(i,i);
end
disp(a)
syms X
P=0;
for i=1:m;
TT=a(i)*X^(i-1); %T=INDIVIDUAL POLYNOMIAL TERMS
P=P+TT;
end
display(P)
%========END OF GAUSSIAN ELIMINATION=======%%%%%%%%
%STANDARD DEVIATION
Y_bar=mean(Y); %ADVERAGE OF y
St=sum((Y-Y_bar).^2);
SD=sqrt(St/(k-1)); %STANDARD DEVIATION
%STANDARD ERROR
for i=1:m;
T(:,i)=a(i)*X.^(i-1); %T=INDIVIDUAL POLYNOMIAL TERMS
end
for i=1:k
y_hat(i)=sum(T(i,:));
end
Sr=sum((Y-y_hat).^2);
Se=sqrt(Sr/(k-(n+1))); %STANDARD ERROR-Se
%COEFFICIENT OF DETERMINATION
Cd=(St-Sr)/St %COEFFICIENT OF DETERMINATION (r^2)
Cd = 1.0000
fprintf(‘For n=%d. Coefficient of Determination=%0.5fn’,n,Cd)
function [dydt] = Projectfunction(t,x,y)
Ic=1356; %kg-m^2
Mb=730; %kg
Mf=59; %kg
Mr=45; %kg
Kf=23000; %N/m
Ksf=18750; %N/m
Kr=16182; %N/m
Ksr=12574; %N/m
Bsf=100; %N*s/m
Bsr=100; %N*s/m
L1=1.45; %m
L2=1.39; %m
L3=0.67; %m
x1 = x(1); %x1=Xf
x2 = x(2); %x2=Xr
x3 = x(3); %x3=Xb
x4 = x(4); %x4=theta
y1 = y(1); %y1=Xf’=dXf/dt
y2 = y(2); %y2=Xr’=dXr/dt
y3 = y(3); %y3=Xb’=dXb/dt
y4 = y(4); %y4=theta’=dtheta/dt
dydt1 = (Ksf*((x3-(L1*x4)))-x1)+Bsf*((y3-(L1*y4)-y1)-(Kf*x1))/Mf;
dydt2 = (Ksr*((x3+(L2*x4))-x2)+Bsr*((y3+(L2*y4))-y2)-(Kr*x2))/Mr;
dydt3 = (Ksf*((x3-(L1*x4))-x1)+Bsf*((y3-(L1*y4))-y1)+Ksr*((x3+(L2*x4))-x2)+Bsr*((y3+(L2*y4))-y2)-(10*exp(-(5*t))))/Mb;
dydt4 = ((-(Ksf*(x1-(L1*x4))*L1)-(Bsf*(y1-(L1*y4))*L1)+(Ksr*(x2+(L2*x4))*L2)+(Bsr*(y2+(L2*y4))*L2)+((10*exp(-(5*t)))*L3)))/Ic;
[dydt] = [dydt1; dydt2; dydt3; dydt4];
end
% MfXf"=Ksf([Xb-(L1*theta)]-Xf)+Bsf([Xb’-(L1*theta’)-Xf’)-(Kf*Xf);
% MrXr"=Ksr([Xb+(L2*theta)]-Xr)+Bsr([Xb’+(L2*theta’)]-Xr’)-(Kr*Xr) ;
% MbXb"=Ksf([Xb-(L1*theta)]-Xf)+Bsf([Xb’-(L1*theta’)]-Xf’)+Ksr([Xb+(L2*theta)]-Xr)+Bsr([Xb’+(L2*theta’)]-Xr’)+fa(t);
% Ic*theta"={-[Ksf(Xf-(L1*theta))*L1]-[Bsf(Xf’-(L1*theta’))*L1]+[Ksr(Xr+(L2*theta))*L2]+[Bsr(Xr’+(L2*theta’))*L2]+[fa(t)*L3]}; I get this error when trying to solve these 4 second order differential equations using a program that solves them using Heun’s method and then Gaussian elimination to get a polynomial equation the represents the system. Previsouly posted for help, but the soluitions have symbolics and I need a singular soluition that represents all 4 equations. Does any one have a suggestion on how I can slove this? Is using the "function" with all 4 equations the best way to do this, or is there a nicer method for doing this?
clear,close,clc
%______________________________________________________________SOLUITION_2_Heun’s_Method_(for second order differential equations)_&__Least-Square_Nethod____________________________________________________________%
%4 Equations representing the system working with
% MfXf"=Ksf([Xb-(L1*theta)]-Xf)+Bsf([Xb’-(L1*theta’)-Xf’)-(Kf*Xf);
% MrXr"=Ksr([Xb+(L2*theta)]-Xr)+Bsr([Xb’+(L2*theta’)]-Xr’)-(Kr*Xr) ;
% MbXb"=Ksf([Xb-(L1*theta)]-Xf)+Bsf([Xb’-(L1*theta’)]-Xf’)+Ksr([Xb+(L2*theta)]-Xr)+Bsr([Xb’+(L2*theta’)]-Xr’)+fa(t);
% Ic*theta"={-[Ksf(Xf-(L1*theta))*L1]-[Bsf(Xf’-(L1*theta’))*L1]+[Ksr(Xr+(L2*theta))*L2]+[Bsr(Xr’+(L2*theta’))*L2]+[fa(t)*L3]};
%————————————————-SYSTEM_PARAMETERS———————————————————————————————————————————————————-
Ic=1356; %kg-m^2
Mb=730; %kg
Mf=59; %kg
Mr=45; %kg
Kf=23000; %N/m
Ksf=18750; %N/m
Kr=16182; %N/m
Ksr=12574; %N/m
Bsf=100; %N*s/m
Bsr=100; %N*s/m
L1=1.45; %m
L2=1.39; %m
L3=0.67; %m
t0=0; %time at the start
tm=20; %what value of (t time) you are ending at
t=t0:tm; % time from time start to time finish seconds
n=4; %order of the polynomial
%Initial Conditions-system at rest therefore x(0)=0 dXf/dt(0)=0 dXr/dt(0)=0 dXb/dt(0)=0 dtheta/dt(0)=0 ;
%time from 0 to 20 h=dx=5;
x0=0; %x at initial condition
y0=0; %y at initial condition
dx=5; %delta(x) or h
h=dx;
%==INPUT SECTION for Euler’s and Heun’s==%
fx=@(x,y,t)y;
fy=@(x,y,t)Projectfunction;
%==CALCULATIONS SECTION==%
tn=t0:h:tm;
xn(1) = x0;
yn(1) = y0;
for i=1:length(tn)
%==EULER’S METHOD
xn(i+1)=xn(i)+fx(xn(i),yn(i),tn(i))*h;
yn(i+1)=yn(i)+fy(xn(i),yn(i),tn(i))*h;
%==NEXT 3 LINES ARE FOR HEUN’S METHOD
tn(i+1)=tn(i)+h;
xn(i+1)=xn(i)+0.5*(fx(xn(i),yn(i),tn(i))+fx(xn(i+1),yn(i+1),tn(i+1)))*h;
yn(i+1)=yn(i)+0.5*(fy(xn(i),yn(i),tn(i))+fy(xn(i+1),yn(i+1),tn(i+1)))*h;
fprintf(‘t=%0.2ft y=%0.3ft z=%0.3fn’,tn(i),xn(i),yn(i))
end
%%%LEAST SQUARE METHOD-FINDS POLYNOMIAL FOR GIVEN DATA SET%%%%%
%INPUT SECTION for Least-Square
X=xn;
Y=yn;
%%__CALCULATIONS SECTION__%%
k=length(X); %NUMBER OF AVAILABLE DATA POINTS
m=n+1; %SIZE OF THE COEFFICENT MATRIX
A=zeros(m,m); %COEFFICENT MATRIX
for j=1:m
for i=1:m
A(j,i)=sum(X.^(i+j-2));
end
end
B=zeros(m,1); %FORCING FUNCTION VECTOR
for i=1:m;
B(i)=sum(Y.*X.^(i-1));
end
a1=AB %COEFFICIENTS FOR THE POLYNOMINAL–> y=a0+a1*x+a2*x^2….an*x^n CAN BE REPLACED BY GAUSSIAN ELIMINATION
%%%%%=========GAUSSIAN ELIMINATION TO FIND "a"========%%%%%%
%%%INPUT SECTION
%CALCULATION SECTION
AB=[A B]; %Augumentent matrix
R=size(AB,1); %# OF ROWS IN AB
C=size(AB,2); %# OF COLUMNS IN AB
%%%%FOWARD ELIMINATION SECTION
for J=1:R-1
[M,I]=max(abs(AB(J:R,J))); %M=MAXIMUM VALUE, I=LOCATION OF THE MAXIMUM VALUE IN THE 1ST ROW
temp=AB(J,:);
AB(J,:)=AB(I+(J-1),:);
AB(I+(J-1),:)=temp;
for i=(J+1):R;
if AB(i,J)~=0;
AB(i,:)=AB(i,:)-(AB(i,J)/AB(J,J))*AB(J,:);
end
end
end
%%%%BACKWARDS SUBSTITUTION
a(R)=AB(R,C)/AB(R,R);
for i=R-1:-1:1
a(i)=(AB(i,C)-AB(i,i+1:R)*a(i+1:R)’)/AB(i,i);
end
disp(a)
syms X
P=0;
for i=1:m;
TT=a(i)*X^(i-1); %T=INDIVIDUAL POLYNOMIAL TERMS
P=P+TT;
end
display(P)
%========END OF GAUSSIAN ELIMINATION=======%%%%%%%%
%STANDARD DEVIATION
Y_bar=mean(Y); %ADVERAGE OF y
St=sum((Y-Y_bar).^2);
SD=sqrt(St/(k-1)); %STANDARD DEVIATION
%STANDARD ERROR
for i=1:m;
T(:,i)=a(i)*X.^(i-1); %T=INDIVIDUAL POLYNOMIAL TERMS
end
for i=1:k
y_hat(i)=sum(T(i,:));
end
Sr=sum((Y-y_hat).^2);
Se=sqrt(Sr/(k-(n+1))); %STANDARD ERROR-Se
%COEFFICIENT OF DETERMINATION
Cd=(St-Sr)/St %COEFFICIENT OF DETERMINATION (r^2)
Cd = 1.0000
fprintf(‘For n=%d. Coefficient of Determination=%0.5fn’,n,Cd)
function [dydt] = Projectfunction(t,x,y)
Ic=1356; %kg-m^2
Mb=730; %kg
Mf=59; %kg
Mr=45; %kg
Kf=23000; %N/m
Ksf=18750; %N/m
Kr=16182; %N/m
Ksr=12574; %N/m
Bsf=100; %N*s/m
Bsr=100; %N*s/m
L1=1.45; %m
L2=1.39; %m
L3=0.67; %m
x1 = x(1); %x1=Xf
x2 = x(2); %x2=Xr
x3 = x(3); %x3=Xb
x4 = x(4); %x4=theta
y1 = y(1); %y1=Xf’=dXf/dt
y2 = y(2); %y2=Xr’=dXr/dt
y3 = y(3); %y3=Xb’=dXb/dt
y4 = y(4); %y4=theta’=dtheta/dt
dydt1 = (Ksf*((x3-(L1*x4)))-x1)+Bsf*((y3-(L1*y4)-y1)-(Kf*x1))/Mf;
dydt2 = (Ksr*((x3+(L2*x4))-x2)+Bsr*((y3+(L2*y4))-y2)-(Kr*x2))/Mr;
dydt3 = (Ksf*((x3-(L1*x4))-x1)+Bsf*((y3-(L1*y4))-y1)+Ksr*((x3+(L2*x4))-x2)+Bsr*((y3+(L2*y4))-y2)-(10*exp(-(5*t))))/Mb;
dydt4 = ((-(Ksf*(x1-(L1*x4))*L1)-(Bsf*(y1-(L1*y4))*L1)+(Ksr*(x2+(L2*x4))*L2)+(Bsr*(y2+(L2*y4))*L2)+((10*exp(-(5*t)))*L3)))/Ic;
[dydt] = [dydt1; dydt2; dydt3; dydt4];
end
% MfXf"=Ksf([Xb-(L1*theta)]-Xf)+Bsf([Xb’-(L1*theta’)-Xf’)-(Kf*Xf);
% MrXr"=Ksr([Xb+(L2*theta)]-Xr)+Bsr([Xb’+(L2*theta’)]-Xr’)-(Kr*Xr) ;
% MbXb"=Ksf([Xb-(L1*theta)]-Xf)+Bsf([Xb’-(L1*theta’)]-Xf’)+Ksr([Xb+(L2*theta)]-Xr)+Bsr([Xb’+(L2*theta’)]-Xr’)+fa(t);
% Ic*theta"={-[Ksf(Xf-(L1*theta))*L1]-[Bsf(Xf’-(L1*theta’))*L1]+[Ksr(Xr+(L2*theta))*L2]+[Bsr(Xr’+(L2*theta’))*L2]+[fa(t)*L3]}; polynomial from heun’s method, solving 4 2nd ode MATLAB Answers — New Questions
HOW TO GENERATE XLSX files from .prn files
Post Content Post Content the above pic is in .prn format, i want to convert these .prn file to xlsx file MATLAB Answers — New Questions
SharePoint List Hyperlink Column Formatting
I have created a hyperlink column in a SharePoint list. Each cell when populated, allows for two items. A Link (URL) and Display Text. Every time I try to edit the JSON code for column formatting, the Display Text property for the cell changes to the hyperlink. I am missing something in my JSON Code and can’t find an example or much on the topic. I am simply looking to change the color and size of the display text, while maintaining the underline. Any thoughts?
Thanks,
John
I have created a hyperlink column in a SharePoint list. Each cell when populated, allows for two items. A Link (URL) and Display Text. Every time I try to edit the JSON code for column formatting, the Display Text property for the cell changes to the hyperlink. I am missing something in my JSON Code and can’t find an example or much on the topic. I am simply looking to change the color and size of the display text, while maintaining the underline. Any thoughts? Thanks,John Read More
Data Validation – editing in any of the input boxes – why does it not behave
Can someone help me understand why when I use normal editing gestures in any of the input boxes within the Data Validation popup, that it behaves so badly. For example, I have the following formula: =AND(LEN(A1)=8, ISNUMBER(VALUE(MID(A1,1,7))), RIGHT(A1,1)=”B”). I go to the Formula box and change the B to a Q. The B remains there despite typing over it. However, when I close it and re-open, the Q is there. Or if I try to use an arrow key to move within the text, it starts adding cell references.
I just don’t understand why it behaves so differently from any other input box.
Can someone help me understand why when I use normal editing gestures in any of the input boxes within the Data Validation popup, that it behaves so badly. For example, I have the following formula: =AND(LEN(A1)=8, ISNUMBER(VALUE(MID(A1,1,7))), RIGHT(A1,1)=”B”). I go to the Formula box and change the B to a Q. The B remains there despite typing over it. However, when I close it and re-open, the Q is there. Or if I try to use an arrow key to move within the text, it starts adding cell references. I just don’t understand why it behaves so differently from any other input box. Read More
matrix normalization in matlab
hi.. i want normalize a matrix (129 x 128)..please help me with matlab codeshi.. i want normalize a matrix (129 x 128)..please help me with matlab codes hi.. i want normalize a matrix (129 x 128)..please help me with matlab codes normalization, matrix MATLAB Answers — New Questions
Determining optimal cut off frequency
Hello,
I have some motion capture data that I need to filter before differentiating to get velocity and acceleration. I have been told to filter at a range of frequencies and then calculate the RMSD between the original and filtered data. I want to used a forth order low pass butterworth filter. I have managed to do so but do not understand how I then interpret the plot to decide on my optimal filtering frequency. I have seen some previous posts mention ‘fft’ but do not understand what this does and if I should be using it.
This is my function:
function plot_rmsd_vs_cutoff(data, fs, f_min, f_max, num_points)
% Plot RMSD against cut-off frequency for given data
% Data and sampling frequency
% data: input data
% fs: sampling frequency
% Frequency range
% f_min: minimum cut-off frequency
% f_max: maximum cut-off frequency
% num_points: number of points in the frequency range
% Create a vector of cut-off frequencies
cutoff_freqs = linspace(f_min, f_max, num_points);
% Initialize RMSD vector
rmsd_values = zeros(size(cutoff_freqs));
for i = 1:length(cutoff_freqs)
% Filter data
[b, a] = butter(4, cutoff_freqs(i)/(fs/2), ‘low’); % Example: 4th order lowpass Butterworth
filtered_data = filtfilt(b, a, data);
% Calculate RMSD
rmsd_values(i) = rms(data – filtered_data);
end
% Plot RMSD against cut-off frequency
plot(cutoff_freqs, rmsd_values);
xlabel(‘Cut-off Frequency (Hz)’);
ylabel(‘RMSD’);
title(‘RMSD vs Cut-off Frequency’);
end
This is how I have used it in my code:
% Call the function
plot_rmsd_vs_cutoff(data, fs, 1, 50, 50);
I have attached my data and the output I have got.
Many thanks for any help.Hello,
I have some motion capture data that I need to filter before differentiating to get velocity and acceleration. I have been told to filter at a range of frequencies and then calculate the RMSD between the original and filtered data. I want to used a forth order low pass butterworth filter. I have managed to do so but do not understand how I then interpret the plot to decide on my optimal filtering frequency. I have seen some previous posts mention ‘fft’ but do not understand what this does and if I should be using it.
This is my function:
function plot_rmsd_vs_cutoff(data, fs, f_min, f_max, num_points)
% Plot RMSD against cut-off frequency for given data
% Data and sampling frequency
% data: input data
% fs: sampling frequency
% Frequency range
% f_min: minimum cut-off frequency
% f_max: maximum cut-off frequency
% num_points: number of points in the frequency range
% Create a vector of cut-off frequencies
cutoff_freqs = linspace(f_min, f_max, num_points);
% Initialize RMSD vector
rmsd_values = zeros(size(cutoff_freqs));
for i = 1:length(cutoff_freqs)
% Filter data
[b, a] = butter(4, cutoff_freqs(i)/(fs/2), ‘low’); % Example: 4th order lowpass Butterworth
filtered_data = filtfilt(b, a, data);
% Calculate RMSD
rmsd_values(i) = rms(data – filtered_data);
end
% Plot RMSD against cut-off frequency
plot(cutoff_freqs, rmsd_values);
xlabel(‘Cut-off Frequency (Hz)’);
ylabel(‘RMSD’);
title(‘RMSD vs Cut-off Frequency’);
end
This is how I have used it in my code:
% Call the function
plot_rmsd_vs_cutoff(data, fs, 1, 50, 50);
I have attached my data and the output I have got.
Many thanks for any help. Hello,
I have some motion capture data that I need to filter before differentiating to get velocity and acceleration. I have been told to filter at a range of frequencies and then calculate the RMSD between the original and filtered data. I want to used a forth order low pass butterworth filter. I have managed to do so but do not understand how I then interpret the plot to decide on my optimal filtering frequency. I have seen some previous posts mention ‘fft’ but do not understand what this does and if I should be using it.
This is my function:
function plot_rmsd_vs_cutoff(data, fs, f_min, f_max, num_points)
% Plot RMSD against cut-off frequency for given data
% Data and sampling frequency
% data: input data
% fs: sampling frequency
% Frequency range
% f_min: minimum cut-off frequency
% f_max: maximum cut-off frequency
% num_points: number of points in the frequency range
% Create a vector of cut-off frequencies
cutoff_freqs = linspace(f_min, f_max, num_points);
% Initialize RMSD vector
rmsd_values = zeros(size(cutoff_freqs));
for i = 1:length(cutoff_freqs)
% Filter data
[b, a] = butter(4, cutoff_freqs(i)/(fs/2), ‘low’); % Example: 4th order lowpass Butterworth
filtered_data = filtfilt(b, a, data);
% Calculate RMSD
rmsd_values(i) = rms(data – filtered_data);
end
% Plot RMSD against cut-off frequency
plot(cutoff_freqs, rmsd_values);
xlabel(‘Cut-off Frequency (Hz)’);
ylabel(‘RMSD’);
title(‘RMSD vs Cut-off Frequency’);
end
This is how I have used it in my code:
% Call the function
plot_rmsd_vs_cutoff(data, fs, 1, 50, 50);
I have attached my data and the output I have got.
Many thanks for any help. cut off frequency, butterworth filter, filter, rmsd MATLAB Answers — New Questions
MATLAB crashes on macOS Sonoma when clearing a figure.
I am repeatedly plotting on the same figure object (so that a long-running code doesn’t continuously steal focus for each new figure) and using clf(fig) to clear the figure each time. However, this consistently causes MATLAB to crash on my Mac.
I’ve seen many forum posts on this type of behavior when the figure closes, but nothing on clf specifically. I tried a few solutions:
Adding a line to my startup.m file (https://www.mathworks.com/matlabcentral/answers/2039461-matlab-freezes-i-am-using-mac-apple-m2-max-osx-sonoma, https://www.mathworks.com/matlabcentral/answers/1808195-matlab-r2022a-freezes-on-macos-monterey-12-5-1-when-closing-a-figure#answer_1324680)
Changing clf(fig) to delete(fig) or reset(fig)
Adding pause(0.1) or pause(1) before the clf (this resulted in a crash after ~20 and ~30 figures, respectively, instead of just 1 without it).
I set figure visibility to ‘off’. This tentatively seems to allow me to plot without crashing, but obviously with the limitation of not being able to see the plots as they’re generated! For some plots this is ok for me, for others it is not, such as when I’m plotting movies and want to verify that they’re accurate before wasting time plotting each frame.
I am on an M1 Mac 16GB RAM running MacOS Sonoma 14.5. Is there anything to be done so I can view my figures while plotting them?I am repeatedly plotting on the same figure object (so that a long-running code doesn’t continuously steal focus for each new figure) and using clf(fig) to clear the figure each time. However, this consistently causes MATLAB to crash on my Mac.
I’ve seen many forum posts on this type of behavior when the figure closes, but nothing on clf specifically. I tried a few solutions:
Adding a line to my startup.m file (https://www.mathworks.com/matlabcentral/answers/2039461-matlab-freezes-i-am-using-mac-apple-m2-max-osx-sonoma, https://www.mathworks.com/matlabcentral/answers/1808195-matlab-r2022a-freezes-on-macos-monterey-12-5-1-when-closing-a-figure#answer_1324680)
Changing clf(fig) to delete(fig) or reset(fig)
Adding pause(0.1) or pause(1) before the clf (this resulted in a crash after ~20 and ~30 figures, respectively, instead of just 1 without it).
I set figure visibility to ‘off’. This tentatively seems to allow me to plot without crashing, but obviously with the limitation of not being able to see the plots as they’re generated! For some plots this is ok for me, for others it is not, such as when I’m plotting movies and want to verify that they’re accurate before wasting time plotting each frame.
I am on an M1 Mac 16GB RAM running MacOS Sonoma 14.5. Is there anything to be done so I can view my figures while plotting them? I am repeatedly plotting on the same figure object (so that a long-running code doesn’t continuously steal focus for each new figure) and using clf(fig) to clear the figure each time. However, this consistently causes MATLAB to crash on my Mac.
I’ve seen many forum posts on this type of behavior when the figure closes, but nothing on clf specifically. I tried a few solutions:
Adding a line to my startup.m file (https://www.mathworks.com/matlabcentral/answers/2039461-matlab-freezes-i-am-using-mac-apple-m2-max-osx-sonoma, https://www.mathworks.com/matlabcentral/answers/1808195-matlab-r2022a-freezes-on-macos-monterey-12-5-1-when-closing-a-figure#answer_1324680)
Changing clf(fig) to delete(fig) or reset(fig)
Adding pause(0.1) or pause(1) before the clf (this resulted in a crash after ~20 and ~30 figures, respectively, instead of just 1 without it).
I set figure visibility to ‘off’. This tentatively seems to allow me to plot without crashing, but obviously with the limitation of not being able to see the plots as they’re generated! For some plots this is ok for me, for others it is not, such as when I’m plotting movies and want to verify that they’re accurate before wasting time plotting each frame.
I am on an M1 Mac 16GB RAM running MacOS Sonoma 14.5. Is there anything to be done so I can view my figures while plotting them? mac, sonoma, plot, plotting, figure, crash MATLAB Answers — New Questions
How do I copy figure properties from one to another?
I would like to copy the properties from Fig 1 to Fig 2. How can that be done?I would like to copy the properties from Fig 1 to Fig 2. How can that be done? I would like to copy the properties from Fig 1 to Fig 2. How can that be done? star strider, walter roberson, torsten, dyuman joshi MATLAB Answers — New Questions