Month: June 2024
The input was too complicated or too big for MATLAB to parse.
hi, i’ve a long code and i receive this error..
To fix it i want to reduce code using vectorialization
for i=1:c
if STR_type(i)==1 %%se sono aggregate
SumCTR_color(b(i),:)= col(i,:); %%cosi nel draw del SumCTR_strum gli do il colore uguale
end
legend_lines(i)=plot(Ax_Eq,XDates,TE_strum(:,i)’,’DisplayName’,STR_name{i},’Color’,col(i,:),’LineWidth’,width_arr(i));
text(Ax_Eq,r-2,TE_strum(end,i),strcat({‘ ‘},num2str(i)),’Color’,col(i,:),’Interpreter’,’none’);
%%******** COLORA OOS *********
if app.OOScolorCheckBox.Value %%mi colora di nero da dove inizia solo l’OOS (se ci sono 4 sistemi prende l’OOS piu’ recente!!)!
if isdatetime(OOS_strum(i))
[~,xx_]=find(OOS_strum(i)<=XDates,1,’first’); %%max perche prendo l’OOS piu’ recente!
plot(Ax_Eq,XDates(xx_:end),TE_strum(xx_:end,i)’,’Color’,"black",’LineWidth’,width_arr(i));
end
end
%%******************************
end
how can i do it? this is a small piece of a big codehi, i’ve a long code and i receive this error..
To fix it i want to reduce code using vectorialization
for i=1:c
if STR_type(i)==1 %%se sono aggregate
SumCTR_color(b(i),:)= col(i,:); %%cosi nel draw del SumCTR_strum gli do il colore uguale
end
legend_lines(i)=plot(Ax_Eq,XDates,TE_strum(:,i)’,’DisplayName’,STR_name{i},’Color’,col(i,:),’LineWidth’,width_arr(i));
text(Ax_Eq,r-2,TE_strum(end,i),strcat({‘ ‘},num2str(i)),’Color’,col(i,:),’Interpreter’,’none’);
%%******** COLORA OOS *********
if app.OOScolorCheckBox.Value %%mi colora di nero da dove inizia solo l’OOS (se ci sono 4 sistemi prende l’OOS piu’ recente!!)!
if isdatetime(OOS_strum(i))
[~,xx_]=find(OOS_strum(i)<=XDates,1,’first’); %%max perche prendo l’OOS piu’ recente!
plot(Ax_Eq,XDates(xx_:end),TE_strum(xx_:end,i)’,’Color’,"black",’LineWidth’,width_arr(i));
end
end
%%******************************
end
how can i do it? this is a small piece of a big code hi, i’ve a long code and i receive this error..
To fix it i want to reduce code using vectorialization
for i=1:c
if STR_type(i)==1 %%se sono aggregate
SumCTR_color(b(i),:)= col(i,:); %%cosi nel draw del SumCTR_strum gli do il colore uguale
end
legend_lines(i)=plot(Ax_Eq,XDates,TE_strum(:,i)’,’DisplayName’,STR_name{i},’Color’,col(i,:),’LineWidth’,width_arr(i));
text(Ax_Eq,r-2,TE_strum(end,i),strcat({‘ ‘},num2str(i)),’Color’,col(i,:),’Interpreter’,’none’);
%%******** COLORA OOS *********
if app.OOScolorCheckBox.Value %%mi colora di nero da dove inizia solo l’OOS (se ci sono 4 sistemi prende l’OOS piu’ recente!!)!
if isdatetime(OOS_strum(i))
[~,xx_]=find(OOS_strum(i)<=XDates,1,’first’); %%max perche prendo l’OOS piu’ recente!
plot(Ax_Eq,XDates(xx_:end),TE_strum(xx_:end,i)’,’Color’,"black",’LineWidth’,width_arr(i));
end
end
%%******************************
end
how can i do it? this is a small piece of a big code the input was too complicated or too big for matla MATLAB Answers — New Questions
Set Column width of Excel through Matlab
Hi, I tried to set the width of a column but i don’t try..
i found a hint here:
http://www.mathworks.com/matlabcentral/fileexchange/23270-set-columns-in-excel-to-auto-fit/content/xlsAutoFitCol.m
and i simply call it (in another file which I open excel) with xlsAutoFitCol(‘myfile.xls’,’Sheet1′,’A:S’); but nothing change…
that’s what appears to me…
http://imageshack.us/photo/my-images/402/catturahi.png/
and what i want…
http://imageshack.us/photo/my-images/689/cattura1yw.png/
Someone can help me?Hi, I tried to set the width of a column but i don’t try..
i found a hint here:
http://www.mathworks.com/matlabcentral/fileexchange/23270-set-columns-in-excel-to-auto-fit/content/xlsAutoFitCol.m
and i simply call it (in another file which I open excel) with xlsAutoFitCol(‘myfile.xls’,’Sheet1′,’A:S’); but nothing change…
that’s what appears to me…
http://imageshack.us/photo/my-images/402/catturahi.png/
and what i want…
http://imageshack.us/photo/my-images/689/cattura1yw.png/
Someone can help me? Hi, I tried to set the width of a column but i don’t try..
i found a hint here:
http://www.mathworks.com/matlabcentral/fileexchange/23270-set-columns-in-excel-to-auto-fit/content/xlsAutoFitCol.m
and i simply call it (in another file which I open excel) with xlsAutoFitCol(‘myfile.xls’,’Sheet1′,’A:S’); but nothing change…
that’s what appears to me…
http://imageshack.us/photo/my-images/402/catturahi.png/
and what i want…
http://imageshack.us/photo/my-images/689/cattura1yw.png/
Someone can help me? column, excel MATLAB Answers — New Questions
Poll Pay Referral Code {D2QQSUPD3R}: Get $25 Sign up Bonus And 15% Referral Commission
Join Poll Pay and use our Referral Code “D2QQSUPD3R” and Complete Surveys from your Smart Phone and get more rewards and you can also earn more money through Refer and Earn in it. When your friend uses your Poll Pay referral code during registration, your friend will receive a starting bonus of $25. As the referrer, you will receive a 15% commission on your friend’s survey rewards as a bonus.
Join Poll Pay and use our Referral Code “D2QQSUPD3R” and Complete Surveys from your Smart Phone and get more rewards and you can also earn more money through Refer and Earn in it. When your friend uses your Poll Pay referral code during registration, your friend will receive a starting bonus of $25. As the referrer, you will receive a 15% commission on your friend’s survey rewards as a bonus. Read More
How can I accelerate deep learning training using GPU?
I’ve made a simple neural network
It classifies MNIST handwritten digit using fully-connected layers
lgraph_2 = [ …
imageInputLayer([28 28 1])
fullyConnectedLayer(512)
reluLayer
fullyConnectedLayer(256)
reluLayer
fullyConnectedLayer(128)
reluLayer
fullyConnectedLayer(10)
softmaxLayer
classificationLayer];
And the options in the neural network is
miniBatchSize = 10;
valFrequency = 5;
options = trainingOptions(‘sgdm’, …
‘MiniBatchSize’,miniBatchSize, …
‘MaxEpochs’,5, …
‘InitialLearnRate’,3e-4, …
‘Shuffle’,’every-epoch’, …
‘ValidationData’,augimdsValidation, …
‘ValidationFrequency’,valFrequency, …
‘Verbose’,true, …
‘Plots’,’training-progress’, …
‘ExecutionEnvironment’, ‘parallel’);
I expected when i use a GPU, it’s training speed will be high
But when I train this network using Macbook(sigle CPU)
it takes 1 hour for around 2500 iterations
And when I use my desktop using RTX 2080Ti,
It takes much longer time to train.
MATLAB detects my GPU properly(I checked the GPU information using gpuDevice)
I don’t know how can I accelerate the training proess.
Thank you in advanceI’ve made a simple neural network
It classifies MNIST handwritten digit using fully-connected layers
lgraph_2 = [ …
imageInputLayer([28 28 1])
fullyConnectedLayer(512)
reluLayer
fullyConnectedLayer(256)
reluLayer
fullyConnectedLayer(128)
reluLayer
fullyConnectedLayer(10)
softmaxLayer
classificationLayer];
And the options in the neural network is
miniBatchSize = 10;
valFrequency = 5;
options = trainingOptions(‘sgdm’, …
‘MiniBatchSize’,miniBatchSize, …
‘MaxEpochs’,5, …
‘InitialLearnRate’,3e-4, …
‘Shuffle’,’every-epoch’, …
‘ValidationData’,augimdsValidation, …
‘ValidationFrequency’,valFrequency, …
‘Verbose’,true, …
‘Plots’,’training-progress’, …
‘ExecutionEnvironment’, ‘parallel’);
I expected when i use a GPU, it’s training speed will be high
But when I train this network using Macbook(sigle CPU)
it takes 1 hour for around 2500 iterations
And when I use my desktop using RTX 2080Ti,
It takes much longer time to train.
MATLAB detects my GPU properly(I checked the GPU information using gpuDevice)
I don’t know how can I accelerate the training proess.
Thank you in advance I’ve made a simple neural network
It classifies MNIST handwritten digit using fully-connected layers
lgraph_2 = [ …
imageInputLayer([28 28 1])
fullyConnectedLayer(512)
reluLayer
fullyConnectedLayer(256)
reluLayer
fullyConnectedLayer(128)
reluLayer
fullyConnectedLayer(10)
softmaxLayer
classificationLayer];
And the options in the neural network is
miniBatchSize = 10;
valFrequency = 5;
options = trainingOptions(‘sgdm’, …
‘MiniBatchSize’,miniBatchSize, …
‘MaxEpochs’,5, …
‘InitialLearnRate’,3e-4, …
‘Shuffle’,’every-epoch’, …
‘ValidationData’,augimdsValidation, …
‘ValidationFrequency’,valFrequency, …
‘Verbose’,true, …
‘Plots’,’training-progress’, …
‘ExecutionEnvironment’, ‘parallel’);
I expected when i use a GPU, it’s training speed will be high
But when I train this network using Macbook(sigle CPU)
it takes 1 hour for around 2500 iterations
And when I use my desktop using RTX 2080Ti,
It takes much longer time to train.
MATLAB detects my GPU properly(I checked the GPU information using gpuDevice)
I don’t know how can I accelerate the training proess.
Thank you in advance deep learning MATLAB Answers — New Questions
how to change the font size in simulink?
how to change the font size of task pane while i am doing the onramp course for simulink?
The font size of Task Pane (where we are assigned various tasks to do) is very small. How to change it .
Zooming options?how to change the font size of task pane while i am doing the onramp course for simulink?
The font size of Task Pane (where we are assigned various tasks to do) is very small. How to change it .
Zooming options? how to change the font size of task pane while i am doing the onramp course for simulink?
The font size of Task Pane (where we are assigned various tasks to do) is very small. How to change it .
Zooming options? font size in simulink task pane MATLAB Answers — New Questions
MDE DeviceNetworkEvents missing full URL for HTTPS traffic
Hiall ,
I’ve integrated Sentinel with some external TI feeds (like Phishtank, etc) and collected MDE DeviceNetworkEvents.
It seems that most (if not all) HTTPS traffic (URL) is not fully logged.
Example: https://cloudflare-ipfs.com instead of https://cloudflare-ipfs.com/xxx.dat.
PS: with HTTP traffic I got the full URL with path, etc.
It means that the URL doesn’t match when trying to compare URL TI source (full URL) and URL (partial) generated by the browser.
The goal is to push the IOC (in this case the URL) into the Indicators list.
I don’t want to populate the indicator with domain list because it can blacklist a full domain.
Example :
https://docs.google.com/presentation/d/e/2
It could be a phishing URL, but don’t want to blacklist docs.google.com domain because it can contains valid URL…
Any idea ?
Regards,
HA
Hiall , I’ve integrated Sentinel with some external TI feeds (like Phishtank, etc) and collected MDE DeviceNetworkEvents.It seems that most (if not all) HTTPS traffic (URL) is not fully logged.Example: https://cloudflare-ipfs.com instead of https://cloudflare-ipfs.com/xxx.dat.PS: with HTTP traffic I got the full URL with path, etc. It means that the URL doesn’t match when trying to compare URL TI source (full URL) and URL (partial) generated by the browser.The goal is to push the IOC (in this case the URL) into the Indicators list.I don’t want to populate the indicator with domain list because it can blacklist a full domain.Example :https://docs.google.com/presentation/d/e/2It could be a phishing URL, but don’t want to blacklist docs.google.com domain because it can contains valid URL… Any idea ? Regards, HA Read More
Attapoll Referral Code {CNUCL} Get $25 Sign up Bonus And 30% Referral Commission
Use Attapoll referral bonus code {CNUCL} to get $25 sign up bonus and 20% referral commission, when your referred ones do survey and earn you will get 20% of their earning, it’s a win-on-win game. Download the Attapoll App now and use code {CNUCL} during sign up to get welcome bonus and additional rewards.
Use Attapoll referral bonus code {CNUCL} to get $25 sign up bonus and 20% referral commission, when your referred ones do survey and earn you will get 20% of their earning, it’s a win-on-win game. Download the Attapoll App now and use code {CNUCL} during sign up to get welcome bonus and additional rewards. Read More
Can the MATLAB Engine API implement interactive operations in the MATLAB Command Window?
In the MATLAB interface window, when running some programs or scripts, some interactive instructions are required, such as giving a prompt in the command window and asking the user to enter some numbers ,Y or N, and pressing the enter key, then the program will continue to execute based on the input content. Can the above operation be achieved using Python through the Matlab Engine API interface without opening the Matlab interface now?The following is a function that requires interactive operations in the command window of Matlab:
function my_function()
disp(‘Step 1: Please enter a number:’);
x = input(”);
disp([‘You entered: ‘, num2str(x)]);
disp(‘Step 2: Please enter another number:’);
y = input(”);
disp([‘You entered: ‘, num2str(y)]);
end
How to use Python to call the above function through the Matlab Engine API and achieve its normal operation? The prompt words and input content are completed through programming or input in Python.In the MATLAB interface window, when running some programs or scripts, some interactive instructions are required, such as giving a prompt in the command window and asking the user to enter some numbers ,Y or N, and pressing the enter key, then the program will continue to execute based on the input content. Can the above operation be achieved using Python through the Matlab Engine API interface without opening the Matlab interface now?The following is a function that requires interactive operations in the command window of Matlab:
function my_function()
disp(‘Step 1: Please enter a number:’);
x = input(”);
disp([‘You entered: ‘, num2str(x)]);
disp(‘Step 2: Please enter another number:’);
y = input(”);
disp([‘You entered: ‘, num2str(y)]);
end
How to use Python to call the above function through the Matlab Engine API and achieve its normal operation? The prompt words and input content are completed through programming or input in Python. In the MATLAB interface window, when running some programs or scripts, some interactive instructions are required, such as giving a prompt in the command window and asking the user to enter some numbers ,Y or N, and pressing the enter key, then the program will continue to execute based on the input content. Can the above operation be achieved using Python through the Matlab Engine API interface without opening the Matlab interface now?The following is a function that requires interactive operations in the command window of Matlab:
function my_function()
disp(‘Step 1: Please enter a number:’);
x = input(”);
disp([‘You entered: ‘, num2str(x)]);
disp(‘Step 2: Please enter another number:’);
y = input(”);
disp([‘You entered: ‘, num2str(y)]);
end
How to use Python to call the above function through the Matlab Engine API and achieve its normal operation? The prompt words and input content are completed through programming or input in Python. matlab engine api for python, interactive operations, command window MATLAB Answers — New Questions
Taylor Series Derivative Approximations
This is what I am trying to achieve:
Write a MATLAB algorithm that evaluates
y′(t) = f(y,t)
y(a) = yo
using a first order Taylor series to approximate the derivative. Test your code by setting
f(y,t) = y − t^2 + 1, with y(0) = 0.5,
and comparing your results to the analytical solution. For your records, in 150 words or less as
comments in the code, report the key steps in the code and the step size
used to achieve a reasonably accurate answer.
This is what I have:
syms x y t;
a=input(‘central point: ‘);
f=input(‘f(x)=’);
v1=input(‘variable 1: ‘);
v2=input(‘variable 2: ‘);
taylor(f,[v1,v2],a,’Order’,2)
So I’ve written an algorithm that gives the first order taylor series of an input function. I don’t know how to use this to approximate the derivative. Any direction would be helpful.This is what I am trying to achieve:
Write a MATLAB algorithm that evaluates
y′(t) = f(y,t)
y(a) = yo
using a first order Taylor series to approximate the derivative. Test your code by setting
f(y,t) = y − t^2 + 1, with y(0) = 0.5,
and comparing your results to the analytical solution. For your records, in 150 words or less as
comments in the code, report the key steps in the code and the step size
used to achieve a reasonably accurate answer.
This is what I have:
syms x y t;
a=input(‘central point: ‘);
f=input(‘f(x)=’);
v1=input(‘variable 1: ‘);
v2=input(‘variable 2: ‘);
taylor(f,[v1,v2],a,’Order’,2)
So I’ve written an algorithm that gives the first order taylor series of an input function. I don’t know how to use this to approximate the derivative. Any direction would be helpful. This is what I am trying to achieve:
Write a MATLAB algorithm that evaluates
y′(t) = f(y,t)
y(a) = yo
using a first order Taylor series to approximate the derivative. Test your code by setting
f(y,t) = y − t^2 + 1, with y(0) = 0.5,
and comparing your results to the analytical solution. For your records, in 150 words or less as
comments in the code, report the key steps in the code and the step size
used to achieve a reasonably accurate answer.
This is what I have:
syms x y t;
a=input(‘central point: ‘);
f=input(‘f(x)=’);
v1=input(‘variable 1: ‘);
v2=input(‘variable 2: ‘);
taylor(f,[v1,v2],a,’Order’,2)
So I’ve written an algorithm that gives the first order taylor series of an input function. I don’t know how to use this to approximate the derivative. Any direction would be helpful. tayorseries, differentialequation, homework MATLAB Answers — New Questions
I have an error in this code and the error is () Is there anyone who can help me I would be grateful for that
% إضافة مسار مكتبة WFDB Toolbox إلى Matlab
addpath("C:wfdbwfdb-app-toolbox-0-10-0mcode"); % استبدل هذا المسار بموقع مكتبة WFDB على جهازك
% قائمة بالتسجيلات من قاعدة البيانات
records = {‘100’, ‘101’, ‘102’, ‘103’, ‘104’, ‘105’, ‘106’, ‘107’, ‘108’, ‘109’, …
‘111’, ‘112’, ‘113’, ‘114’, ‘115’, ‘116’, ‘117’, ‘118’, ‘119’, ‘121’, …
‘122’, ‘123’, ‘124’, ‘200’, ‘201’, ‘202’, ‘203’, ‘205’, ‘207’, ‘208’, …
‘209’, ‘210’, ‘212’, ‘213’, ‘214’, ‘215’, ‘217’, ‘219’, ‘220’, ‘221’, …
‘222’, ‘223’, ‘228’, ‘230’, ‘231’, ‘232’, ‘233’, ‘234’};
% تحديد نسبة البيانات للتدريب
train_ratio = 0.7;
% ترتيب السجلات عشوائيًا لضمان توزيع عشوائي
shuffled_indices = randperm(length(records));
records = records(shuffled_indices);
% حساب عدد السجلات للتدريب والاختبار
num_train = round(train_ratio * length(records));
num_test = length(records) – num_train;
% تقسيم السجلات إلى مجموعتي التدريب والاختبار
train_records = records(1:num_train);
test_records = records(num_train+1:end);
% دالة لقراءة ومعالجة بيانات ECG
function data = read_and_process_ecg(recordName)
[ECG, Fs] = rdsamp(recordName, 1); % قراءة البيانات
ECG = ECG – mean(ECG); % إزالة ضوضاء التيار المستمر
[b, a] = butter(4, [0.5 45] / (Fs / 2), ‘bandpass’); % مرشح رقمي
filtered_ECG = filtfilt(b, a, ECG); % تطبيق المرشح بتمرير صفري
normalized_ECG = 2 * (filtered_ECG – min(filtered_ECG)) / (max(filtered_ECG) – min(filtered_ECG)) – 1; % تطبيع
qrs_peaks = panTompkinsQRS(normalized_ECG, Fs); % اكتشاف قمم QRS
data.segments = segmentHeartBeats(normalized_ECG, qrs_peaks, Fs); % تجزئة نبضات القلب
data.Fs = Fs;
end
% معالجة بيانات التدريب
train_data = cell(length(train_records), 1);
for i = 1:length(train_records)
recordName = train_records{i};
fprintf(‘Processing training record %s…n’, recordName);
train_data{i} = read_and_process_ecg(recordName);
end
% معالجة بيانات الاختبار
test_data = cell(length(test_records), 1);
for i = 1:length(test_records)
recordName = test_records{i};
fprintf(‘Processing test record %s…n’, recordName);
test_data{i} = read_and_process_ecg(recordName);
end
% توحيد البيانات في مصفوفة 3D (عينات، ميزات، قنوات)
function [X, Y] = prepare_data(data, fixed_segment_length)
% حساب عدد العينات
num_samples = sum(cellfun(@(d) length(d.segments), data));
% تهيئة مصفوفة البيانات
X = zeros(num_samples, fixed_segment_length, 1); % إضافة بُعد القنوات
Y = zeros(num_samples, 1);
sample_idx = 1;
for i = 1:length(data)
for j = 1:length(data{i}.segments)
segment = data{i}.segments{j};
segment_length = length(segment);
% إذا كان المقطع أطول من الطول الثابت، نقوم بتقليمه
if segment_length > fixed_segment_length
segment = segment(1:fixed_segment_length);
% إذا كان المقطع أقصر، نقوم بتعبئته بالأصفار
elseif segment_length < fixed_segment_length
segment = [segment; zeros(fixed_segment_length – segment_length, 1)];
end
% تعيين المقطع إلى مصفوفة X
X(sample_idx, :, 1) = segment’; % تعيين مع إضافة بُعد القناة
% تعيين التسمية
Y(sample_idx) = i; % استخدام رقم السجل كتصنيف مبدئي
sample_idx = sample_idx + 1;
end
end
% تحويل X إلى الشكل المطلوب (طول السلسلة، عدد العينات، عدد القنوات)
% X = permute(X, [2, 3, 1]); % ليس هناك حاجة لإعادة الترتيب هنا
end
% تعيين الطول الثابت للمقاطع
fixed_segment_length = 625; % يمكنك ضبط هذا الطول بناءً على تحليل البيانات
% تجهيز بيانات التدريب والاختبار
[xTrain, yTrain] = prepare_data(train_data, fixed_segment_length);
[xTest, yTest] = prepare_data(test_data, fixed_segment_length);
disp([‘Size of xTrain: ‘, num2str(size(xTrain))]);
disp([‘Size of xTest: ‘, num2str(size(xTest))]);
% تحويل التسميات إلى مصفوفات دلالية (Categorical)
numClasses = numel(unique(yTrain));
yTrain = categorical(yTrain);
yTest = categorical(yTest);
% % تحويل التسميات إلى مصفوفات دلالية (Categorical)
% yTrain = cellfun(@(x) categorical(x, 1:length(train_records)), num2cell(yTrain), ‘UniformOutput’, false);
% yTest = cellfun(@(x) categorical(x, 1:length(test_records)), num2cell(yTest), ‘UniformOutput’, false);
% حصول على القيم الممكنة للتصنيفات
labels = unique(yTrain);
% تحويل `yTrain` و `yTest` إلى مصفوفة خلية من المتجهات النمطية
yTrain = cellfun(@(x) categorical(x, labels), num2cell(yTrain), ‘UniformOutput’, false);
yTest = cellfun(@(x) categorical(x, labels), num2cell(yTest), ‘UniformOutput’, false);
% تحويل الأبعاد إلى الصيغة الصحيحة إذا لزم الأمر
xTrain = permute(xTrain, [2, 3, 1]);
xTest = permute(xTest, [2, 3, 1]);
% 2. بناء نموذج 1D-CNN
layers = [
sequenceInputLayer([fixed_segment_length 1]) % طبقة الإدخال مع حجم البيانات وعدد القنوات
convolution1dLayer(3, 32, ‘Padding’, ‘same’) % طبقة الالتفاف
batchNormalizationLayer % طبقة تطبيع الدفعات
reluLayer % طبقة التنشيط ReLU
maxPooling1dLayer(2, ‘Stride’, 2) % طبقة التجميع
dropoutLayer(0.5) % طبقة الإسقاط لتقليل الإفراط في التكيف
convolution1dLayer(3, 64, ‘Padding’, ‘same’)
batchNormalizationLayer
reluLayer
maxPooling1dLayer(2, ‘Stride’, 2)
dropoutLayer(0.5)
flattenLayer % تحويل البيانات إلى مصفوفة مسطحة
fullyConnectedLayer(128) % طبقة الاتصال الكاملة
reluLayer
dropoutLayer(0.5)
fullyConnectedLayer(numClasses) % طبقة الخرج بعدد الفئات
softmaxLayer % طبقة سوفت ماكس
classificationLayer]; % طبقة التصنيف
% 3. تجميع النموذج
options = trainingOptions(‘adam’, …
‘InitialLearnRate’, 0.001, …
‘MaxEpochs’, 20, …
‘MiniBatchSize’, 32, …
‘ValidationData’, {xTest, yTest}, …
‘Plots’, ‘training-progress’, …
‘Verbose’, false);
% 4. تدريب النموذج
net = trainNetwork(xTrain, yTrain, layers, options);
% 5. تقييم النموذج
yPred = classify(net, xTest);
accuracy = sum(yPred == yTest) / numel(yTest);
disp([‘Test Accuracy: ‘, num2str(accuracy * 100), ‘%’]);
% طباعة تقرير التصنيف
confusionchart(yTest, yPred);
% الدالة: تطبيق خوارزمية Pan-Tompkins لاكتشاف قمم QRS
function qrs_peaks = panTompkinsQRS(ecg, fs)
% تطبيق خوارزمية Pan-Tompkins لاكتشاف قمم QRS في إشارات ECG
% سيتم تنفيذ عدة خطوات: الاشتقاق، التربيع، التنعيم، وإيجاد القمم
% المشتقة
diff_ecg = diff(ecg);
% التربيع
squared_ecg = diff_ecg .^ 2;
% التنعيم باستخدام نافذة متحركة
window_size = round(0.12 * fs); % 120ms نافذة
smoothed_ecg = conv(squared_ecg, ones(1, window_size) / window_size, ‘same’);
% إيجاد القمم
max_value = max(smoothed_ecg); % الحصول على القيمة العظمى للإشارة المربعة المنعمة
min_peak_height = 0.02 * max_value; % تعيين MinPeakHeight كنسبة مئوية من القيمة العظمى
[~, qrs_peaks] = findpeaks(smoothed_ecg, ‘MinPeakHeight’, min_peak_height, ‘MinPeakDistance’, round(0.6 * fs));
end
% الدالة: تجزئة إشارات نبضات القلب الفردية بناءً على مواقع قمم QRS
function segments = segmentHeartBeats(ecg, qrs_peaks, fs)
% تجزئة إشارات نبضات القلب الفردية بناءً على مواقع قمم QRS
% سنقوم بتحديد أجزاء الإشارة حول كل قمة QRS
num_beats = length(qrs_peaks);
segments = cell(num_beats, 1);
% طول كل مقطع حول QRS (مثلاً 0.6 ثانية)
segment_length = round(0.6 * fs);
for i = 1:num_beats
start_idx = max(qrs_peaks(i) – segment_length, 1);
end_idx = min(qrs_peaks(i) + segment_length, length(ecg));
segments{i} = ecg(start_idx:end_idx);
end
end% إضافة مسار مكتبة WFDB Toolbox إلى Matlab
addpath("C:wfdbwfdb-app-toolbox-0-10-0mcode"); % استبدل هذا المسار بموقع مكتبة WFDB على جهازك
% قائمة بالتسجيلات من قاعدة البيانات
records = {‘100’, ‘101’, ‘102’, ‘103’, ‘104’, ‘105’, ‘106’, ‘107’, ‘108’, ‘109’, …
‘111’, ‘112’, ‘113’, ‘114’, ‘115’, ‘116’, ‘117’, ‘118’, ‘119’, ‘121’, …
‘122’, ‘123’, ‘124’, ‘200’, ‘201’, ‘202’, ‘203’, ‘205’, ‘207’, ‘208’, …
‘209’, ‘210’, ‘212’, ‘213’, ‘214’, ‘215’, ‘217’, ‘219’, ‘220’, ‘221’, …
‘222’, ‘223’, ‘228’, ‘230’, ‘231’, ‘232’, ‘233’, ‘234’};
% تحديد نسبة البيانات للتدريب
train_ratio = 0.7;
% ترتيب السجلات عشوائيًا لضمان توزيع عشوائي
shuffled_indices = randperm(length(records));
records = records(shuffled_indices);
% حساب عدد السجلات للتدريب والاختبار
num_train = round(train_ratio * length(records));
num_test = length(records) – num_train;
% تقسيم السجلات إلى مجموعتي التدريب والاختبار
train_records = records(1:num_train);
test_records = records(num_train+1:end);
% دالة لقراءة ومعالجة بيانات ECG
function data = read_and_process_ecg(recordName)
[ECG, Fs] = rdsamp(recordName, 1); % قراءة البيانات
ECG = ECG – mean(ECG); % إزالة ضوضاء التيار المستمر
[b, a] = butter(4, [0.5 45] / (Fs / 2), ‘bandpass’); % مرشح رقمي
filtered_ECG = filtfilt(b, a, ECG); % تطبيق المرشح بتمرير صفري
normalized_ECG = 2 * (filtered_ECG – min(filtered_ECG)) / (max(filtered_ECG) – min(filtered_ECG)) – 1; % تطبيع
qrs_peaks = panTompkinsQRS(normalized_ECG, Fs); % اكتشاف قمم QRS
data.segments = segmentHeartBeats(normalized_ECG, qrs_peaks, Fs); % تجزئة نبضات القلب
data.Fs = Fs;
end
% معالجة بيانات التدريب
train_data = cell(length(train_records), 1);
for i = 1:length(train_records)
recordName = train_records{i};
fprintf(‘Processing training record %s…n’, recordName);
train_data{i} = read_and_process_ecg(recordName);
end
% معالجة بيانات الاختبار
test_data = cell(length(test_records), 1);
for i = 1:length(test_records)
recordName = test_records{i};
fprintf(‘Processing test record %s…n’, recordName);
test_data{i} = read_and_process_ecg(recordName);
end
% توحيد البيانات في مصفوفة 3D (عينات، ميزات، قنوات)
function [X, Y] = prepare_data(data, fixed_segment_length)
% حساب عدد العينات
num_samples = sum(cellfun(@(d) length(d.segments), data));
% تهيئة مصفوفة البيانات
X = zeros(num_samples, fixed_segment_length, 1); % إضافة بُعد القنوات
Y = zeros(num_samples, 1);
sample_idx = 1;
for i = 1:length(data)
for j = 1:length(data{i}.segments)
segment = data{i}.segments{j};
segment_length = length(segment);
% إذا كان المقطع أطول من الطول الثابت، نقوم بتقليمه
if segment_length > fixed_segment_length
segment = segment(1:fixed_segment_length);
% إذا كان المقطع أقصر، نقوم بتعبئته بالأصفار
elseif segment_length < fixed_segment_length
segment = [segment; zeros(fixed_segment_length – segment_length, 1)];
end
% تعيين المقطع إلى مصفوفة X
X(sample_idx, :, 1) = segment’; % تعيين مع إضافة بُعد القناة
% تعيين التسمية
Y(sample_idx) = i; % استخدام رقم السجل كتصنيف مبدئي
sample_idx = sample_idx + 1;
end
end
% تحويل X إلى الشكل المطلوب (طول السلسلة، عدد العينات، عدد القنوات)
% X = permute(X, [2, 3, 1]); % ليس هناك حاجة لإعادة الترتيب هنا
end
% تعيين الطول الثابت للمقاطع
fixed_segment_length = 625; % يمكنك ضبط هذا الطول بناءً على تحليل البيانات
% تجهيز بيانات التدريب والاختبار
[xTrain, yTrain] = prepare_data(train_data, fixed_segment_length);
[xTest, yTest] = prepare_data(test_data, fixed_segment_length);
disp([‘Size of xTrain: ‘, num2str(size(xTrain))]);
disp([‘Size of xTest: ‘, num2str(size(xTest))]);
% تحويل التسميات إلى مصفوفات دلالية (Categorical)
numClasses = numel(unique(yTrain));
yTrain = categorical(yTrain);
yTest = categorical(yTest);
% % تحويل التسميات إلى مصفوفات دلالية (Categorical)
% yTrain = cellfun(@(x) categorical(x, 1:length(train_records)), num2cell(yTrain), ‘UniformOutput’, false);
% yTest = cellfun(@(x) categorical(x, 1:length(test_records)), num2cell(yTest), ‘UniformOutput’, false);
% حصول على القيم الممكنة للتصنيفات
labels = unique(yTrain);
% تحويل `yTrain` و `yTest` إلى مصفوفة خلية من المتجهات النمطية
yTrain = cellfun(@(x) categorical(x, labels), num2cell(yTrain), ‘UniformOutput’, false);
yTest = cellfun(@(x) categorical(x, labels), num2cell(yTest), ‘UniformOutput’, false);
% تحويل الأبعاد إلى الصيغة الصحيحة إذا لزم الأمر
xTrain = permute(xTrain, [2, 3, 1]);
xTest = permute(xTest, [2, 3, 1]);
% 2. بناء نموذج 1D-CNN
layers = [
sequenceInputLayer([fixed_segment_length 1]) % طبقة الإدخال مع حجم البيانات وعدد القنوات
convolution1dLayer(3, 32, ‘Padding’, ‘same’) % طبقة الالتفاف
batchNormalizationLayer % طبقة تطبيع الدفعات
reluLayer % طبقة التنشيط ReLU
maxPooling1dLayer(2, ‘Stride’, 2) % طبقة التجميع
dropoutLayer(0.5) % طبقة الإسقاط لتقليل الإفراط في التكيف
convolution1dLayer(3, 64, ‘Padding’, ‘same’)
batchNormalizationLayer
reluLayer
maxPooling1dLayer(2, ‘Stride’, 2)
dropoutLayer(0.5)
flattenLayer % تحويل البيانات إلى مصفوفة مسطحة
fullyConnectedLayer(128) % طبقة الاتصال الكاملة
reluLayer
dropoutLayer(0.5)
fullyConnectedLayer(numClasses) % طبقة الخرج بعدد الفئات
softmaxLayer % طبقة سوفت ماكس
classificationLayer]; % طبقة التصنيف
% 3. تجميع النموذج
options = trainingOptions(‘adam’, …
‘InitialLearnRate’, 0.001, …
‘MaxEpochs’, 20, …
‘MiniBatchSize’, 32, …
‘ValidationData’, {xTest, yTest}, …
‘Plots’, ‘training-progress’, …
‘Verbose’, false);
% 4. تدريب النموذج
net = trainNetwork(xTrain, yTrain, layers, options);
% 5. تقييم النموذج
yPred = classify(net, xTest);
accuracy = sum(yPred == yTest) / numel(yTest);
disp([‘Test Accuracy: ‘, num2str(accuracy * 100), ‘%’]);
% طباعة تقرير التصنيف
confusionchart(yTest, yPred);
% الدالة: تطبيق خوارزمية Pan-Tompkins لاكتشاف قمم QRS
function qrs_peaks = panTompkinsQRS(ecg, fs)
% تطبيق خوارزمية Pan-Tompkins لاكتشاف قمم QRS في إشارات ECG
% سيتم تنفيذ عدة خطوات: الاشتقاق، التربيع، التنعيم، وإيجاد القمم
% المشتقة
diff_ecg = diff(ecg);
% التربيع
squared_ecg = diff_ecg .^ 2;
% التنعيم باستخدام نافذة متحركة
window_size = round(0.12 * fs); % 120ms نافذة
smoothed_ecg = conv(squared_ecg, ones(1, window_size) / window_size, ‘same’);
% إيجاد القمم
max_value = max(smoothed_ecg); % الحصول على القيمة العظمى للإشارة المربعة المنعمة
min_peak_height = 0.02 * max_value; % تعيين MinPeakHeight كنسبة مئوية من القيمة العظمى
[~, qrs_peaks] = findpeaks(smoothed_ecg, ‘MinPeakHeight’, min_peak_height, ‘MinPeakDistance’, round(0.6 * fs));
end
% الدالة: تجزئة إشارات نبضات القلب الفردية بناءً على مواقع قمم QRS
function segments = segmentHeartBeats(ecg, qrs_peaks, fs)
% تجزئة إشارات نبضات القلب الفردية بناءً على مواقع قمم QRS
% سنقوم بتحديد أجزاء الإشارة حول كل قمة QRS
num_beats = length(qrs_peaks);
segments = cell(num_beats, 1);
% طول كل مقطع حول QRS (مثلاً 0.6 ثانية)
segment_length = round(0.6 * fs);
for i = 1:num_beats
start_idx = max(qrs_peaks(i) – segment_length, 1);
end_idx = min(qrs_peaks(i) + segment_length, length(ecg));
segments{i} = ecg(start_idx:end_idx);
end
end % إضافة مسار مكتبة WFDB Toolbox إلى Matlab
addpath("C:wfdbwfdb-app-toolbox-0-10-0mcode"); % استبدل هذا المسار بموقع مكتبة WFDB على جهازك
% قائمة بالتسجيلات من قاعدة البيانات
records = {‘100’, ‘101’, ‘102’, ‘103’, ‘104’, ‘105’, ‘106’, ‘107’, ‘108’, ‘109’, …
‘111’, ‘112’, ‘113’, ‘114’, ‘115’, ‘116’, ‘117’, ‘118’, ‘119’, ‘121’, …
‘122’, ‘123’, ‘124’, ‘200’, ‘201’, ‘202’, ‘203’, ‘205’, ‘207’, ‘208’, …
‘209’, ‘210’, ‘212’, ‘213’, ‘214’, ‘215’, ‘217’, ‘219’, ‘220’, ‘221’, …
‘222’, ‘223’, ‘228’, ‘230’, ‘231’, ‘232’, ‘233’, ‘234’};
% تحديد نسبة البيانات للتدريب
train_ratio = 0.7;
% ترتيب السجلات عشوائيًا لضمان توزيع عشوائي
shuffled_indices = randperm(length(records));
records = records(shuffled_indices);
% حساب عدد السجلات للتدريب والاختبار
num_train = round(train_ratio * length(records));
num_test = length(records) – num_train;
% تقسيم السجلات إلى مجموعتي التدريب والاختبار
train_records = records(1:num_train);
test_records = records(num_train+1:end);
% دالة لقراءة ومعالجة بيانات ECG
function data = read_and_process_ecg(recordName)
[ECG, Fs] = rdsamp(recordName, 1); % قراءة البيانات
ECG = ECG – mean(ECG); % إزالة ضوضاء التيار المستمر
[b, a] = butter(4, [0.5 45] / (Fs / 2), ‘bandpass’); % مرشح رقمي
filtered_ECG = filtfilt(b, a, ECG); % تطبيق المرشح بتمرير صفري
normalized_ECG = 2 * (filtered_ECG – min(filtered_ECG)) / (max(filtered_ECG) – min(filtered_ECG)) – 1; % تطبيع
qrs_peaks = panTompkinsQRS(normalized_ECG, Fs); % اكتشاف قمم QRS
data.segments = segmentHeartBeats(normalized_ECG, qrs_peaks, Fs); % تجزئة نبضات القلب
data.Fs = Fs;
end
% معالجة بيانات التدريب
train_data = cell(length(train_records), 1);
for i = 1:length(train_records)
recordName = train_records{i};
fprintf(‘Processing training record %s…n’, recordName);
train_data{i} = read_and_process_ecg(recordName);
end
% معالجة بيانات الاختبار
test_data = cell(length(test_records), 1);
for i = 1:length(test_records)
recordName = test_records{i};
fprintf(‘Processing test record %s…n’, recordName);
test_data{i} = read_and_process_ecg(recordName);
end
% توحيد البيانات في مصفوفة 3D (عينات، ميزات، قنوات)
function [X, Y] = prepare_data(data, fixed_segment_length)
% حساب عدد العينات
num_samples = sum(cellfun(@(d) length(d.segments), data));
% تهيئة مصفوفة البيانات
X = zeros(num_samples, fixed_segment_length, 1); % إضافة بُعد القنوات
Y = zeros(num_samples, 1);
sample_idx = 1;
for i = 1:length(data)
for j = 1:length(data{i}.segments)
segment = data{i}.segments{j};
segment_length = length(segment);
% إذا كان المقطع أطول من الطول الثابت، نقوم بتقليمه
if segment_length > fixed_segment_length
segment = segment(1:fixed_segment_length);
% إذا كان المقطع أقصر، نقوم بتعبئته بالأصفار
elseif segment_length < fixed_segment_length
segment = [segment; zeros(fixed_segment_length – segment_length, 1)];
end
% تعيين المقطع إلى مصفوفة X
X(sample_idx, :, 1) = segment’; % تعيين مع إضافة بُعد القناة
% تعيين التسمية
Y(sample_idx) = i; % استخدام رقم السجل كتصنيف مبدئي
sample_idx = sample_idx + 1;
end
end
% تحويل X إلى الشكل المطلوب (طول السلسلة، عدد العينات، عدد القنوات)
% X = permute(X, [2, 3, 1]); % ليس هناك حاجة لإعادة الترتيب هنا
end
% تعيين الطول الثابت للمقاطع
fixed_segment_length = 625; % يمكنك ضبط هذا الطول بناءً على تحليل البيانات
% تجهيز بيانات التدريب والاختبار
[xTrain, yTrain] = prepare_data(train_data, fixed_segment_length);
[xTest, yTest] = prepare_data(test_data, fixed_segment_length);
disp([‘Size of xTrain: ‘, num2str(size(xTrain))]);
disp([‘Size of xTest: ‘, num2str(size(xTest))]);
% تحويل التسميات إلى مصفوفات دلالية (Categorical)
numClasses = numel(unique(yTrain));
yTrain = categorical(yTrain);
yTest = categorical(yTest);
% % تحويل التسميات إلى مصفوفات دلالية (Categorical)
% yTrain = cellfun(@(x) categorical(x, 1:length(train_records)), num2cell(yTrain), ‘UniformOutput’, false);
% yTest = cellfun(@(x) categorical(x, 1:length(test_records)), num2cell(yTest), ‘UniformOutput’, false);
% حصول على القيم الممكنة للتصنيفات
labels = unique(yTrain);
% تحويل `yTrain` و `yTest` إلى مصفوفة خلية من المتجهات النمطية
yTrain = cellfun(@(x) categorical(x, labels), num2cell(yTrain), ‘UniformOutput’, false);
yTest = cellfun(@(x) categorical(x, labels), num2cell(yTest), ‘UniformOutput’, false);
% تحويل الأبعاد إلى الصيغة الصحيحة إذا لزم الأمر
xTrain = permute(xTrain, [2, 3, 1]);
xTest = permute(xTest, [2, 3, 1]);
% 2. بناء نموذج 1D-CNN
layers = [
sequenceInputLayer([fixed_segment_length 1]) % طبقة الإدخال مع حجم البيانات وعدد القنوات
convolution1dLayer(3, 32, ‘Padding’, ‘same’) % طبقة الالتفاف
batchNormalizationLayer % طبقة تطبيع الدفعات
reluLayer % طبقة التنشيط ReLU
maxPooling1dLayer(2, ‘Stride’, 2) % طبقة التجميع
dropoutLayer(0.5) % طبقة الإسقاط لتقليل الإفراط في التكيف
convolution1dLayer(3, 64, ‘Padding’, ‘same’)
batchNormalizationLayer
reluLayer
maxPooling1dLayer(2, ‘Stride’, 2)
dropoutLayer(0.5)
flattenLayer % تحويل البيانات إلى مصفوفة مسطحة
fullyConnectedLayer(128) % طبقة الاتصال الكاملة
reluLayer
dropoutLayer(0.5)
fullyConnectedLayer(numClasses) % طبقة الخرج بعدد الفئات
softmaxLayer % طبقة سوفت ماكس
classificationLayer]; % طبقة التصنيف
% 3. تجميع النموذج
options = trainingOptions(‘adam’, …
‘InitialLearnRate’, 0.001, …
‘MaxEpochs’, 20, …
‘MiniBatchSize’, 32, …
‘ValidationData’, {xTest, yTest}, …
‘Plots’, ‘training-progress’, …
‘Verbose’, false);
% 4. تدريب النموذج
net = trainNetwork(xTrain, yTrain, layers, options);
% 5. تقييم النموذج
yPred = classify(net, xTest);
accuracy = sum(yPred == yTest) / numel(yTest);
disp([‘Test Accuracy: ‘, num2str(accuracy * 100), ‘%’]);
% طباعة تقرير التصنيف
confusionchart(yTest, yPred);
% الدالة: تطبيق خوارزمية Pan-Tompkins لاكتشاف قمم QRS
function qrs_peaks = panTompkinsQRS(ecg, fs)
% تطبيق خوارزمية Pan-Tompkins لاكتشاف قمم QRS في إشارات ECG
% سيتم تنفيذ عدة خطوات: الاشتقاق، التربيع، التنعيم، وإيجاد القمم
% المشتقة
diff_ecg = diff(ecg);
% التربيع
squared_ecg = diff_ecg .^ 2;
% التنعيم باستخدام نافذة متحركة
window_size = round(0.12 * fs); % 120ms نافذة
smoothed_ecg = conv(squared_ecg, ones(1, window_size) / window_size, ‘same’);
% إيجاد القمم
max_value = max(smoothed_ecg); % الحصول على القيمة العظمى للإشارة المربعة المنعمة
min_peak_height = 0.02 * max_value; % تعيين MinPeakHeight كنسبة مئوية من القيمة العظمى
[~, qrs_peaks] = findpeaks(smoothed_ecg, ‘MinPeakHeight’, min_peak_height, ‘MinPeakDistance’, round(0.6 * fs));
end
% الدالة: تجزئة إشارات نبضات القلب الفردية بناءً على مواقع قمم QRS
function segments = segmentHeartBeats(ecg, qrs_peaks, fs)
% تجزئة إشارات نبضات القلب الفردية بناءً على مواقع قمم QRS
% سنقوم بتحديد أجزاء الإشارة حول كل قمة QRS
num_beats = length(qrs_peaks);
segments = cell(num_beats, 1);
% طول كل مقطع حول QRS (مثلاً 0.6 ثانية)
segment_length = round(0.6 * fs);
for i = 1:num_beats
start_idx = max(qrs_peaks(i) – segment_length, 1);
end_idx = min(qrs_peaks(i) + segment_length, length(ecg));
segments{i} = ecg(start_idx:end_idx);
end
end ecg, 1d-cnn, proprocessing MATLAB Answers — New Questions
Change Shared Booking Page (URL) UPN/SMTP to non-default Tenant Domain URL
I have already posted this question in the general forum (https://learn.microsoft.com/en-us/answers/questions/1725035/change-shared-booking-page-(url)-upn-smtp-to-non-d) under EXO tag, but I was told this might be a better place. So, here again:
Sometimes it might be desired to modify the Shared Bookings-Page URL in terms of using a different UPN/SMTP in the URL.
By default setting up a shared booking page it uses (as long as it’s free) the page name + default Tenant domain to build the url, like a page called “my TestPage” might result into email address removed for privacy reasons, e.g. https://outlook.office365.com/owa/calendar/email address removed for privacy reasons/bookings/.
Now we have several companies covered by the same tenant within our holding, and it might be a better approach to have a page like https://outlook.office365.com/owa/calendar/mytestpage@**custom-domain.com/**bookings/ or even https://outlook.office365.com/owa/calendar/**email address removed for privacy reasons**/bookings/
There are a few posts online, but somehow none reliable really leads me to success. I managed it once to get my address changed (entirely – including sharing link), but honestly I don’t know which peace from all what I’ve done was the key to success. And from there I get my desired URL to make it work by changing the UPN/SMTPAddress to what I need, but it never becomes also the official URL I see under https://book.ms for this page. Like now https://outlook.office365.com/owa/calendar/email address removed for privacy reasons/bookings/ also works after a few minutes, but the initial https://outlook.office365.com/owa/calendar/email address removed for privacy reasons/bookings/ keeps being official and my change only works due to some redirection made behind the scene when I change UPN in Azure or O365 Admin.
I basically followed this page https://blog.markdepalma.com/?p=681 – but the only one shared booking page I managed to get modified official url I did it by my intuition.
I also had this https://www.exchangemaster.ch/faq-000178-how-to-change-the-sender-and-reply-e-mail-addresses-in-microsoft-bookings/# – but somehow that makes no sense because I only can run this command successfully if I use the already assigned UPN), which from what I was told is in the same time also the smtp address of this mailbox/calendar), otherwise it says “WARNING: Proxy address “email address removed for privacy reasons” is used as WindowsLiveId. So it can’t be removed from list of email addresses. To remove it, first change the WindowsLiveId.”. If I change the Windows LiveID, which I consider being UPN, it implicitely changes the smtp address anyway too, though.
And I also have to mention, running “Get-mailbox -RecipientTypeDetails SchedulingMailbox | Select-Object DisplayName, Alias, PrimarySMTPAddress” shows me the expected PrimarySMTPAddress, just the official URL provided to share does never reflect this.
Hope someone can give me a hint, how I can get the official sharing url for a shared booking page to become modified too.
kind regards,
Dieter
I have already posted this question in the general forum (https://learn.microsoft.com/en-us/answers/questions/1725035/change-shared-booking-page-(url)-upn-smtp-to-non-d) under EXO tag, but I was told this might be a better place. So, here again: Sometimes it might be desired to modify the Shared Bookings-Page URL in terms of using a different UPN/SMTP in the URL.By default setting up a shared booking page it uses (as long as it’s free) the page name + default Tenant domain to build the url, like a page called “my TestPage” might result into email address removed for privacy reasons, e.g. https://outlook.office365.com/owa/calendar/email address removed for privacy reasons/bookings/.Now we have several companies covered by the same tenant within our holding, and it might be a better approach to have a page like https://outlook.office365.com/owa/calendar/mytestpage@**custom-domain.com/**bookings/ or even https://outlook.office365.com/owa/calendar/**email address removed for privacy reasons**/bookings/There are a few posts online, but somehow none reliable really leads me to success. I managed it once to get my address changed (entirely – including sharing link), but honestly I don’t know which peace from all what I’ve done was the key to success. And from there I get my desired URL to make it work by changing the UPN/SMTPAddress to what I need, but it never becomes also the official URL I see under https://book.ms for this page. Like now https://outlook.office365.com/owa/calendar/email address removed for privacy reasons/bookings/ also works after a few minutes, but the initial https://outlook.office365.com/owa/calendar/email address removed for privacy reasons/bookings/ keeps being official and my change only works due to some redirection made behind the scene when I change UPN in Azure or O365 Admin.I basically followed this page https://blog.markdepalma.com/?p=681 – but the only one shared booking page I managed to get modified official url I did it by my intuition.I also had this https://www.exchangemaster.ch/faq-000178-how-to-change-the-sender-and-reply-e-mail-addresses-in-microsoft-bookings/# – but somehow that makes no sense because I only can run this command successfully if I use the already assigned UPN), which from what I was told is in the same time also the smtp address of this mailbox/calendar), otherwise it says “WARNING: Proxy address “email address removed for privacy reasons” is used as WindowsLiveId. So it can’t be removed from list of email addresses. To remove it, first change the WindowsLiveId.”. If I change the Windows LiveID, which I consider being UPN, it implicitely changes the smtp address anyway too, though.And I also have to mention, running “Get-mailbox -RecipientTypeDetails SchedulingMailbox | Select-Object DisplayName, Alias, PrimarySMTPAddress” shows me the expected PrimarySMTPAddress, just the official URL provided to share does never reflect this.Hope someone can give me a hint, how I can get the official sharing url for a shared booking page to become modified too.kind regards,Dieter Read More
STM32 NUCLEO fatal error: No such file or directory #include “main.h”
When I connect NUCLEO-F411RE and try to create code, the compiler gives me an error:
C:/ST_simulink/test_ert_rtw/test.h:21:18: fatal error: main.h: No such file or directory
#include "main.h"
Indeed, such a file is not created. I repeat as shown in the examples, but I can’t even start code generation. What’s my problem?When I connect NUCLEO-F411RE and try to create code, the compiler gives me an error:
C:/ST_simulink/test_ert_rtw/test.h:21:18: fatal error: main.h: No such file or directory
#include "main.h"
Indeed, such a file is not created. I repeat as shown in the examples, but I can’t even start code generation. What’s my problem? When I connect NUCLEO-F411RE and try to create code, the compiler gives me an error:
C:/ST_simulink/test_ert_rtw/test.h:21:18: fatal error: main.h: No such file or directory
#include "main.h"
Indeed, such a file is not created. I repeat as shown in the examples, but I can’t even start code generation. What’s my problem? stm32 nucleo fatal error main. MATLAB Answers — New Questions
متجر المتابعين | زيادة متابعين تيك توك
في عالم اليوم الرقمي، أصبح التفاعل على منصات التواصل الاجتماعي عاملًا حاسمًا في بناء العلامات التجارية وزيادة الوعي بالخدمات والمنتجات. هنا يأتي دور متجر المتابعين، الموقع الرائد في تقديم خدمات زيادة التفاعل والمشاركة على مختلف منصات التواصل الاجتماعي. سنستعرض في هذه المقالة الخدمات المتنوعة التي يقدمها الموقع وكيف يمكن أن تساهم في تعزيز حضورك الرقمي.
متجر المتابعين: حلول مبتكرة لزيادة التفاعل عبر السوشيال ميديا
مقدمة
في عالم اليوم الرقمي، أصبح التفاعل على منصات التواصل الاجتماعي عاملًا حاسمًا في بناء العلامات التجارية وزيادة الوعي بالخدمات والمنتجات. هنا يأتي دور متجر المتابعين، الموقع الرائد في تقديم خدمات زيادة التفاعل والمشاركة على مختلف منصات التواصل الاجتماعي. سنستعرض في هذه المقالة الخدمات المتنوعة التي يقدمها الموقع وكيف يمكن أن تساهم في تعزيز حضورك الرقمي.
خدمات متجر المتابعين
شراء المتابعين
يعتبر شراء المتابعين من أسرع الطرق لزيادة عدد المتابعين على حساباتك الاجتماعية. يقدم متجر المتابعين باقات متنوعة تناسب جميع الاحتياجات والميزانيات. سواء كنت تبحث عن زيادة متابعيك على إنستغرام، تويتر، فيسبوك، أو تيك توك، ستجد الباقة المثالية لك.
زيادة اللايكات
تؤثر اللايكات بشكل كبير على رؤية منشوراتك. يقدم الموقع خدمات زيادة اللايكات لمنشوراتك، مما يعزز من احتمالية ظهورها في خوارزميات منصات التواصل الاجتماعي. هذا يمكن أن يساهم في جذب المزيد من التفاعل الحقيقي على محتواك.
التعليقات والتفاعل
التفاعل مع المتابعين من خلال التعليقات يمكن أن يعزز من علاقتك بهم. يقدم متجر المتابعين خدمة زيادة التعليقات الإيجابية على منشوراتك، مما يعطي انطباعًا بأن محتواك يحظى باهتمام كبير ويزيد من مصداقيتك أمام جمهورك.
المشاهدات
زيادة عدد المشاهدات على الفيديوهات الخاصة بك على يوتيوب، إنستغرام، تيك توك، أو أي منصة أخرى يمكن أن يعزز من وصولها إلى جمهور أوسع. يوفر الموقع باقات متنوعة لزيادة عدد المشاهدات بشكل طبيعي وآمن.
فوائد استخدام خدمات متجر المتابعين
تعزيز المصداقية
وجود عدد كبير من المتابعين واللايكات والتعليقات على حساباتك يعزز من مصداقيتك في أعين جمهورك المستهدف. هذا يمكن أن يساهم في بناء ثقة أكبر بينك وبين متابعيك.
زيادة الوصول
زيادة التفاعل على منشوراتك يعزز من ظهورها في خوارزميات منصات التواصل الاجتماعي، مما يزيد من احتمالية وصولها إلى جمهور أكبر.
توفير الوقت والجهد
بدلاً من الانتظار لفترات طويلة لزيادة التفاعل بشكل طبيعي، يمكنك من خلال متجر المتابعين تحقيق نتائج سريعة وفعالة، مما يوفر لك الوقت والجهد للتركيز على إنشاء محتوى عالي الجودة.
كيفية الاستفادة القصوى من خدمات متجر المتابعين
اختيار الباقات المناسبة
من المهم اختيار الباقات التي تناسب احتياجاتك وأهدافك. يمكن أن يساعدك فريق دعم العملاء في متجر المتابعين في اختيار الباقة المثلى بناءً على أهدافك التسويقية.
متابعة التحليلات
بعد استخدام خدمات المتجر، من المهم متابعة تحليلات حساباتك لمعرفة التأثير الحقيقي لزيادة التفاعل. هذا يمكن أن يساعدك في تعديل استراتيجياتك المستقبلية لتحقيق نتائج أفضل.
خاتمة
يعتبر متجر المتابعين الخيار الأمثل لمن يسعون إلى تعزيز تواجدهم الرقمي بسرعة وفعالية. من خلال مجموعة متنوعة من الخدمات المخصصة لزيادة التفاعل على منصات التواصل الاجتماعي، يمكن للموقع أن يساعدك في تحقيق أهدافك التسويقية بسهولة. جرب خدمات متجر المتابعين اليوم وابدأ في بناء حضور رقمي قوي ومؤثر.
في عالم اليوم الرقمي، أصبح التفاعل على منصات التواصل الاجتماعي عاملًا حاسمًا في بناء العلامات التجارية وزيادة الوعي بالخدمات والمنتجات. هنا يأتي دور متجر المتابعين، الموقع الرائد في تقديم خدمات زيادة التفاعل والمشاركة على مختلف منصات التواصل الاجتماعي. سنستعرض في هذه المقالة الخدمات المتنوعة التي يقدمها الموقع وكيف يمكن أن تساهم في تعزيز حضورك الرقمي.متجر المتابعين: حلول مبتكرة لزيادة التفاعل عبر السوشيال ميديامقدمةفي عالم اليوم الرقمي، أصبح التفاعل على منصات التواصل الاجتماعي عاملًا حاسمًا في بناء العلامات التجارية وزيادة الوعي بالخدمات والمنتجات. هنا يأتي دور متجر المتابعين، الموقع الرائد في تقديم خدمات زيادة التفاعل والمشاركة على مختلف منصات التواصل الاجتماعي. سنستعرض في هذه المقالة الخدمات المتنوعة التي يقدمها الموقع وكيف يمكن أن تساهم في تعزيز حضورك الرقمي.خدمات متجر المتابعينشراء المتابعينيعتبر شراء المتابعين من أسرع الطرق لزيادة عدد المتابعين على حساباتك الاجتماعية. يقدم متجر المتابعين باقات متنوعة تناسب جميع الاحتياجات والميزانيات. سواء كنت تبحث عن زيادة متابعيك على إنستغرام، تويتر، فيسبوك، أو تيك توك، ستجد الباقة المثالية لك.زيادة اللايكاتتؤثر اللايكات بشكل كبير على رؤية منشوراتك. يقدم الموقع خدمات زيادة اللايكات لمنشوراتك، مما يعزز من احتمالية ظهورها في خوارزميات منصات التواصل الاجتماعي. هذا يمكن أن يساهم في جذب المزيد من التفاعل الحقيقي على محتواك.التعليقات والتفاعلالتفاعل مع المتابعين من خلال التعليقات يمكن أن يعزز من علاقتك بهم. يقدم متجر المتابعين خدمة زيادة التعليقات الإيجابية على منشوراتك، مما يعطي انطباعًا بأن محتواك يحظى باهتمام كبير ويزيد من مصداقيتك أمام جمهورك.المشاهداتزيادة عدد المشاهدات على الفيديوهات الخاصة بك على يوتيوب، إنستغرام، تيك توك، أو أي منصة أخرى يمكن أن يعزز من وصولها إلى جمهور أوسع. يوفر الموقع باقات متنوعة لزيادة عدد المشاهدات بشكل طبيعي وآمن.فوائد استخدام خدمات متجر المتابعينتعزيز المصداقيةوجود عدد كبير من المتابعين واللايكات والتعليقات على حساباتك يعزز من مصداقيتك في أعين جمهورك المستهدف. هذا يمكن أن يساهم في بناء ثقة أكبر بينك وبين متابعيك.زيادة الوصولزيادة التفاعل على منشوراتك يعزز من ظهورها في خوارزميات منصات التواصل الاجتماعي، مما يزيد من احتمالية وصولها إلى جمهور أكبر.توفير الوقت والجهدبدلاً من الانتظار لفترات طويلة لزيادة التفاعل بشكل طبيعي، يمكنك من خلال متجر المتابعين تحقيق نتائج سريعة وفعالة، مما يوفر لك الوقت والجهد للتركيز على إنشاء محتوى عالي الجودة.كيفية الاستفادة القصوى من خدمات متجر المتابعيناختيار الباقات المناسبةمن المهم اختيار الباقات التي تناسب احتياجاتك وأهدافك. يمكن أن يساعدك فريق دعم العملاء في متجر المتابعين في اختيار الباقة المثلى بناءً على أهدافك التسويقية.متابعة التحليلاتبعد استخدام خدمات المتجر، من المهم متابعة تحليلات حساباتك لمعرفة التأثير الحقيقي لزيادة التفاعل. هذا يمكن أن يساعدك في تعديل استراتيجياتك المستقبلية لتحقيق نتائج أفضل.خاتمةيعتبر متجر المتابعين الخيار الأمثل لمن يسعون إلى تعزيز تواجدهم الرقمي بسرعة وفعالية. من خلال مجموعة متنوعة من الخدمات المخصصة لزيادة التفاعل على منصات التواصل الاجتماعي، يمكن للموقع أن يساعدك في تحقيق أهدافك التسويقية بسهولة. جرب خدمات متجر المتابعين اليوم وابدأ في بناء حضور رقمي قوي ومؤثر.زيادة متابعين تيك توك Read More
Web Job with Queue Trigger Aborting Abnormally without any reason
It is noticed that Web job(having Queue trigger) deployed on App Service plan p1v2 is aborting abnormally without reason.
Checked code as well and nothing wrong is appeared.
Please suggest if any one encountered such issue.
Thanks,
It is noticed that Web job(having Queue trigger) deployed on App Service plan p1v2 is aborting abnormally without reason.Checked code as well and nothing wrong is appeared.Please suggest if any one encountered such issue.Thanks, Read More
Estimating Area Enclosed by Multiple Arcs and Discrete Points in 3D
Hello MATLAB Community,
I am working on a problem where I need to estimate the area enclosed by multiple arcs and a set of discrete points in a 3D space using MATLAB. Each arc is defined by its center, radius, orientation vectors, and rotation angle. The goal is to compute the cumulative minimum distance between each discrete point and these arcs, and use this information to estimate the enclosed area formed by the points and arcs.
Is it valid to compute the cumulative sum of minimum distances between each point and the arcs? Would this approach provide an estimation of the area enclosed by the points and arcs? Any insights or alternative approaches would be greatly appreciated.
Thank you!Hello MATLAB Community,
I am working on a problem where I need to estimate the area enclosed by multiple arcs and a set of discrete points in a 3D space using MATLAB. Each arc is defined by its center, radius, orientation vectors, and rotation angle. The goal is to compute the cumulative minimum distance between each discrete point and these arcs, and use this information to estimate the enclosed area formed by the points and arcs.
Is it valid to compute the cumulative sum of minimum distances between each point and the arcs? Would this approach provide an estimation of the area enclosed by the points and arcs? Any insights or alternative approaches would be greatly appreciated.
Thank you! Hello MATLAB Community,
I am working on a problem where I need to estimate the area enclosed by multiple arcs and a set of discrete points in a 3D space using MATLAB. Each arc is defined by its center, radius, orientation vectors, and rotation angle. The goal is to compute the cumulative minimum distance between each discrete point and these arcs, and use this information to estimate the enclosed area formed by the points and arcs.
Is it valid to compute the cumulative sum of minimum distances between each point and the arcs? Would this approach provide an estimation of the area enclosed by the points and arcs? Any insights or alternative approaches would be greatly appreciated.
Thank you! biarc curve fitting MATLAB Answers — New Questions
why this error? >> Untitledyasir Error using bvp4c (line 251) Unable to solve the collocation equations — a singular Jacobian encountered. Error in Untitledyasir (line 55) s
function slipflow
format long g
%Define all parameters
% Boundary layer thickness & stepsize
etaMin = 0;
etaMax1 = 15;
etaMax2 = 15; %15, 10
stepsize1 = etaMax1;
stepsize2 = etaMax2;
% Input for the parameters
A=1; %velocity slip
B=0.2; %thermal slip
S=2.4; %suction(2.3,2.4,2.5)
Pr=6.2; %prandtl number
lambda=-1; %stretching shrinking
a=0.01; %phil-1st nanoparticle concentration
b=0.01; %(0.01,0.05)phi2-2nd nanoparticle concentration
c=a+b; %phi-hnf concentration of hybrid nanoparticle
%%%%%%%%%%% 1st nanoparticle properties (Al2O3)%%%%%%%%%%%%
C1=765;
P1=3970;
K1=40;
B1=0.85/((10)^5);
s1=35*(10)^6; %MHD
%%%%%%%%%%% 2nd nanoparticle properties (Cu)%%%%%%%%%%%%
C2=385; %specific heat
P2=8933; %density
K2=400; %thermal conductivity
B2=1.67/((10)^5); %thermal expansion
s2=(59.6)*(10)^6; %MHD
%%%%%%%%%%% Base fluid properties %%%%%%%%%%%%
C3=4179; %specific heat
P3=997.1; %density
K3=0.613; %thermal conductivity
B3=21/((10)^5); %thermal expansion
s3=0.05; %MHD
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%multiplier%%%%%%%%%%%%%%%%%%%
H1=P1*C1; %pho*cp nanoparticle 1
H2=P2*C2; %pho*cp nanoparticle 2
H3=P3*C3; %pho*cp base fluid
H4=a*H1+b*H2+(1-c)*H3; %pho*cp hybrid nanofluid
H5=a*P1+b*P2+(1-c)*P3; %pho hybrid nanofluid
H6=1/((1-c)^2.5); % mu hybrid nanofluid / mu base fluid
H7=a*(P1*B1)+b*(P2*B2)+(1-c)*(P3*B3); % thermal expansion of hybrid nanofluid
%Kn=K3*(K1+2*K3-2*a*(K3-K1))/(K1+2*K3+a*(K3-K1)); %thermal conductivity of nanofluid
Kh=(((a*K1+b*K2)/c)+2*K3+2*(a*K1+b*K2)-2*c*K3)/(((a*K1+b*K2)/c)+2*K3-(a*K1+b*K2)-2*c*K3); %khnf/kf
H8=(((a*s1+b*s2)/c)+2*s3+2*(a*s1+b*s2)-2*c*s3)/(((a*s1+b*s2)/c)+2*s3-(a*s1+b*s2)-2*c*s3); % sigma hnf/ sigma f
D1=(H5/P3)/H6;
D3=(H7/(P3*B3))/(H5/P3); % multiplier of boundary parameter
D2= Pr*((H4/H3)/Kh);
D4=H8/(H5/P3); %multiplier MHD
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% First solution %%%%%%%%%%%%%%%%%%%
options = bvpset(‘stats’,’off’,’RelTol’,1e-10);
solinit = bvpinit (linspace (etaMin, etaMax1, stepsize1),@(x)OdeInit1(x,A,S,lambda));
sol = bvp4c(@(x,y)OdeBVP(x,y,Pr,D1,Kh,H4,H3,S), @(ya,yb)OdeBC(ya, yb, A, S, B, lambda), solinit, options);
eta = linspace (etaMin, etaMax1, stepsize1);
y= deval (sol,eta);
figure(1) %velocity profile
plot(sol.x,sol.y(2,:),’-‘)
xlabel(‘eta’)
ylabel(‘f`(eta)’)
hold on
figure(2) %temperature profile
plot(sol.x,sol.y(4,:),’-‘)
xlabel(‘eta’)
ylabel(‘theta(eta)’)
hold on
% saving the out put in text file for first solution
descris =[sol.x; sol.y];
save ‘sliphybrid_upper.txt’ descris -ascii
% Displaying the output for first solution
fprintf(‘n First solution:n’);
fprintf(‘f"(0)=%7.9fn’,y(3)); % reduced skin friction
fprintf(‘-theta(0)=%7.9fn’,-y(5)); %reduced local nusselt number
fprintf(‘Cfx=%7.9fn’,H6*(y(3))); % skin friction
fprintf(‘Nux=%7.9fn’,-Kh*y(5)); % local nusselt number
fprintf(‘n’);
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% second solution %%%%%%%%%%%%%%%%%%%
options = bvpset(‘stats’,’off’,’RelTol’,1e-10);
solinit = bvpinit (linspace (etaMin, etaMax2, stepsize2),@(x)OdeInit2(x,A,S,lambda));
sol = bvp4c(@(x,y)OdeBVP(x,y,Pr,D1,Kh,H4,H3,S), @(ya,yb)OdeBC(ya, yb, A, S, B, lambda), solinit, options);
eta= linspace (etaMin, etaMax2, stepsize2);
y = deval (sol,eta);
figure(1) %velocity profile
plot(sol.x,sol.y(2,:),’–‘)
xlabel(‘eta’)
ylabel(‘f`(eta)’)
hold on
figure(2) %temperature profile
plot(sol.x,sol.y(4,:),’–‘)
xlabel(‘eta’)
ylabel(‘theta(eta)’)
hold on
% saving the out put in text file for second solution
descris=[sol.x; sol.y];
save ‘sliphybrid_lower.txt’descris -ascii
% Displaying the output for first solution
fprintf(‘nSecond solution:n’);
fprintf(‘f"(0)=%7.9fn’,y(3)); % reduced skin friction
fprintf(‘-theta(0)=%7.9fn’,-y(5)); %reduced local nusselt number
fprintf(‘Cfx=%7.9fn’,H6*(y(3))); % skin friction
fprintf(‘Nux=%7.9fn’,-Kh*y(5)); % local nusselt number
fprintf(‘n’);
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
end
% Define the ODE function
function f = OdeBVP(x,y,Pr,D1,Kh,H4,H3,S)
f =[y(2);y(3);(1/3)*D1*((y(2)^2)-2*(y(1)*y(3))+2*S);y(5);-2/3*(Pr*((H4/H3)/Kh)*y(1)*y(5))];
end
% Define the boundary conditions
function res = OdeBC(ya, yb, A, S, B, lambda)
res= [ya(1)-S;ya(2)-lambda;ya(4)-1;yb(3)-1;yb(4)];
end
% setting the initial guess for first solution
function v = OdeInit1(x,A,S,lambda)
v=[S+0.56;0;0;0;0];
end
% setting the initial guess for second solution
function v1 =OdeInit2(x, A, S,lambda)
v1 = [exp(-x);exp(-x);-exp(-x);-exp(-x);-exp(-x)];
endfunction slipflow
format long g
%Define all parameters
% Boundary layer thickness & stepsize
etaMin = 0;
etaMax1 = 15;
etaMax2 = 15; %15, 10
stepsize1 = etaMax1;
stepsize2 = etaMax2;
% Input for the parameters
A=1; %velocity slip
B=0.2; %thermal slip
S=2.4; %suction(2.3,2.4,2.5)
Pr=6.2; %prandtl number
lambda=-1; %stretching shrinking
a=0.01; %phil-1st nanoparticle concentration
b=0.01; %(0.01,0.05)phi2-2nd nanoparticle concentration
c=a+b; %phi-hnf concentration of hybrid nanoparticle
%%%%%%%%%%% 1st nanoparticle properties (Al2O3)%%%%%%%%%%%%
C1=765;
P1=3970;
K1=40;
B1=0.85/((10)^5);
s1=35*(10)^6; %MHD
%%%%%%%%%%% 2nd nanoparticle properties (Cu)%%%%%%%%%%%%
C2=385; %specific heat
P2=8933; %density
K2=400; %thermal conductivity
B2=1.67/((10)^5); %thermal expansion
s2=(59.6)*(10)^6; %MHD
%%%%%%%%%%% Base fluid properties %%%%%%%%%%%%
C3=4179; %specific heat
P3=997.1; %density
K3=0.613; %thermal conductivity
B3=21/((10)^5); %thermal expansion
s3=0.05; %MHD
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%multiplier%%%%%%%%%%%%%%%%%%%
H1=P1*C1; %pho*cp nanoparticle 1
H2=P2*C2; %pho*cp nanoparticle 2
H3=P3*C3; %pho*cp base fluid
H4=a*H1+b*H2+(1-c)*H3; %pho*cp hybrid nanofluid
H5=a*P1+b*P2+(1-c)*P3; %pho hybrid nanofluid
H6=1/((1-c)^2.5); % mu hybrid nanofluid / mu base fluid
H7=a*(P1*B1)+b*(P2*B2)+(1-c)*(P3*B3); % thermal expansion of hybrid nanofluid
%Kn=K3*(K1+2*K3-2*a*(K3-K1))/(K1+2*K3+a*(K3-K1)); %thermal conductivity of nanofluid
Kh=(((a*K1+b*K2)/c)+2*K3+2*(a*K1+b*K2)-2*c*K3)/(((a*K1+b*K2)/c)+2*K3-(a*K1+b*K2)-2*c*K3); %khnf/kf
H8=(((a*s1+b*s2)/c)+2*s3+2*(a*s1+b*s2)-2*c*s3)/(((a*s1+b*s2)/c)+2*s3-(a*s1+b*s2)-2*c*s3); % sigma hnf/ sigma f
D1=(H5/P3)/H6;
D3=(H7/(P3*B3))/(H5/P3); % multiplier of boundary parameter
D2= Pr*((H4/H3)/Kh);
D4=H8/(H5/P3); %multiplier MHD
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% First solution %%%%%%%%%%%%%%%%%%%
options = bvpset(‘stats’,’off’,’RelTol’,1e-10);
solinit = bvpinit (linspace (etaMin, etaMax1, stepsize1),@(x)OdeInit1(x,A,S,lambda));
sol = bvp4c(@(x,y)OdeBVP(x,y,Pr,D1,Kh,H4,H3,S), @(ya,yb)OdeBC(ya, yb, A, S, B, lambda), solinit, options);
eta = linspace (etaMin, etaMax1, stepsize1);
y= deval (sol,eta);
figure(1) %velocity profile
plot(sol.x,sol.y(2,:),’-‘)
xlabel(‘eta’)
ylabel(‘f`(eta)’)
hold on
figure(2) %temperature profile
plot(sol.x,sol.y(4,:),’-‘)
xlabel(‘eta’)
ylabel(‘theta(eta)’)
hold on
% saving the out put in text file for first solution
descris =[sol.x; sol.y];
save ‘sliphybrid_upper.txt’ descris -ascii
% Displaying the output for first solution
fprintf(‘n First solution:n’);
fprintf(‘f"(0)=%7.9fn’,y(3)); % reduced skin friction
fprintf(‘-theta(0)=%7.9fn’,-y(5)); %reduced local nusselt number
fprintf(‘Cfx=%7.9fn’,H6*(y(3))); % skin friction
fprintf(‘Nux=%7.9fn’,-Kh*y(5)); % local nusselt number
fprintf(‘n’);
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% second solution %%%%%%%%%%%%%%%%%%%
options = bvpset(‘stats’,’off’,’RelTol’,1e-10);
solinit = bvpinit (linspace (etaMin, etaMax2, stepsize2),@(x)OdeInit2(x,A,S,lambda));
sol = bvp4c(@(x,y)OdeBVP(x,y,Pr,D1,Kh,H4,H3,S), @(ya,yb)OdeBC(ya, yb, A, S, B, lambda), solinit, options);
eta= linspace (etaMin, etaMax2, stepsize2);
y = deval (sol,eta);
figure(1) %velocity profile
plot(sol.x,sol.y(2,:),’–‘)
xlabel(‘eta’)
ylabel(‘f`(eta)’)
hold on
figure(2) %temperature profile
plot(sol.x,sol.y(4,:),’–‘)
xlabel(‘eta’)
ylabel(‘theta(eta)’)
hold on
% saving the out put in text file for second solution
descris=[sol.x; sol.y];
save ‘sliphybrid_lower.txt’descris -ascii
% Displaying the output for first solution
fprintf(‘nSecond solution:n’);
fprintf(‘f"(0)=%7.9fn’,y(3)); % reduced skin friction
fprintf(‘-theta(0)=%7.9fn’,-y(5)); %reduced local nusselt number
fprintf(‘Cfx=%7.9fn’,H6*(y(3))); % skin friction
fprintf(‘Nux=%7.9fn’,-Kh*y(5)); % local nusselt number
fprintf(‘n’);
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
end
% Define the ODE function
function f = OdeBVP(x,y,Pr,D1,Kh,H4,H3,S)
f =[y(2);y(3);(1/3)*D1*((y(2)^2)-2*(y(1)*y(3))+2*S);y(5);-2/3*(Pr*((H4/H3)/Kh)*y(1)*y(5))];
end
% Define the boundary conditions
function res = OdeBC(ya, yb, A, S, B, lambda)
res= [ya(1)-S;ya(2)-lambda;ya(4)-1;yb(3)-1;yb(4)];
end
% setting the initial guess for first solution
function v = OdeInit1(x,A,S,lambda)
v=[S+0.56;0;0;0;0];
end
% setting the initial guess for second solution
function v1 =OdeInit2(x, A, S,lambda)
v1 = [exp(-x);exp(-x);-exp(-x);-exp(-x);-exp(-x)];
end function slipflow
format long g
%Define all parameters
% Boundary layer thickness & stepsize
etaMin = 0;
etaMax1 = 15;
etaMax2 = 15; %15, 10
stepsize1 = etaMax1;
stepsize2 = etaMax2;
% Input for the parameters
A=1; %velocity slip
B=0.2; %thermal slip
S=2.4; %suction(2.3,2.4,2.5)
Pr=6.2; %prandtl number
lambda=-1; %stretching shrinking
a=0.01; %phil-1st nanoparticle concentration
b=0.01; %(0.01,0.05)phi2-2nd nanoparticle concentration
c=a+b; %phi-hnf concentration of hybrid nanoparticle
%%%%%%%%%%% 1st nanoparticle properties (Al2O3)%%%%%%%%%%%%
C1=765;
P1=3970;
K1=40;
B1=0.85/((10)^5);
s1=35*(10)^6; %MHD
%%%%%%%%%%% 2nd nanoparticle properties (Cu)%%%%%%%%%%%%
C2=385; %specific heat
P2=8933; %density
K2=400; %thermal conductivity
B2=1.67/((10)^5); %thermal expansion
s2=(59.6)*(10)^6; %MHD
%%%%%%%%%%% Base fluid properties %%%%%%%%%%%%
C3=4179; %specific heat
P3=997.1; %density
K3=0.613; %thermal conductivity
B3=21/((10)^5); %thermal expansion
s3=0.05; %MHD
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%multiplier%%%%%%%%%%%%%%%%%%%
H1=P1*C1; %pho*cp nanoparticle 1
H2=P2*C2; %pho*cp nanoparticle 2
H3=P3*C3; %pho*cp base fluid
H4=a*H1+b*H2+(1-c)*H3; %pho*cp hybrid nanofluid
H5=a*P1+b*P2+(1-c)*P3; %pho hybrid nanofluid
H6=1/((1-c)^2.5); % mu hybrid nanofluid / mu base fluid
H7=a*(P1*B1)+b*(P2*B2)+(1-c)*(P3*B3); % thermal expansion of hybrid nanofluid
%Kn=K3*(K1+2*K3-2*a*(K3-K1))/(K1+2*K3+a*(K3-K1)); %thermal conductivity of nanofluid
Kh=(((a*K1+b*K2)/c)+2*K3+2*(a*K1+b*K2)-2*c*K3)/(((a*K1+b*K2)/c)+2*K3-(a*K1+b*K2)-2*c*K3); %khnf/kf
H8=(((a*s1+b*s2)/c)+2*s3+2*(a*s1+b*s2)-2*c*s3)/(((a*s1+b*s2)/c)+2*s3-(a*s1+b*s2)-2*c*s3); % sigma hnf/ sigma f
D1=(H5/P3)/H6;
D3=(H7/(P3*B3))/(H5/P3); % multiplier of boundary parameter
D2= Pr*((H4/H3)/Kh);
D4=H8/(H5/P3); %multiplier MHD
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% First solution %%%%%%%%%%%%%%%%%%%
options = bvpset(‘stats’,’off’,’RelTol’,1e-10);
solinit = bvpinit (linspace (etaMin, etaMax1, stepsize1),@(x)OdeInit1(x,A,S,lambda));
sol = bvp4c(@(x,y)OdeBVP(x,y,Pr,D1,Kh,H4,H3,S), @(ya,yb)OdeBC(ya, yb, A, S, B, lambda), solinit, options);
eta = linspace (etaMin, etaMax1, stepsize1);
y= deval (sol,eta);
figure(1) %velocity profile
plot(sol.x,sol.y(2,:),’-‘)
xlabel(‘eta’)
ylabel(‘f`(eta)’)
hold on
figure(2) %temperature profile
plot(sol.x,sol.y(4,:),’-‘)
xlabel(‘eta’)
ylabel(‘theta(eta)’)
hold on
% saving the out put in text file for first solution
descris =[sol.x; sol.y];
save ‘sliphybrid_upper.txt’ descris -ascii
% Displaying the output for first solution
fprintf(‘n First solution:n’);
fprintf(‘f"(0)=%7.9fn’,y(3)); % reduced skin friction
fprintf(‘-theta(0)=%7.9fn’,-y(5)); %reduced local nusselt number
fprintf(‘Cfx=%7.9fn’,H6*(y(3))); % skin friction
fprintf(‘Nux=%7.9fn’,-Kh*y(5)); % local nusselt number
fprintf(‘n’);
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% second solution %%%%%%%%%%%%%%%%%%%
options = bvpset(‘stats’,’off’,’RelTol’,1e-10);
solinit = bvpinit (linspace (etaMin, etaMax2, stepsize2),@(x)OdeInit2(x,A,S,lambda));
sol = bvp4c(@(x,y)OdeBVP(x,y,Pr,D1,Kh,H4,H3,S), @(ya,yb)OdeBC(ya, yb, A, S, B, lambda), solinit, options);
eta= linspace (etaMin, etaMax2, stepsize2);
y = deval (sol,eta);
figure(1) %velocity profile
plot(sol.x,sol.y(2,:),’–‘)
xlabel(‘eta’)
ylabel(‘f`(eta)’)
hold on
figure(2) %temperature profile
plot(sol.x,sol.y(4,:),’–‘)
xlabel(‘eta’)
ylabel(‘theta(eta)’)
hold on
% saving the out put in text file for second solution
descris=[sol.x; sol.y];
save ‘sliphybrid_lower.txt’descris -ascii
% Displaying the output for first solution
fprintf(‘nSecond solution:n’);
fprintf(‘f"(0)=%7.9fn’,y(3)); % reduced skin friction
fprintf(‘-theta(0)=%7.9fn’,-y(5)); %reduced local nusselt number
fprintf(‘Cfx=%7.9fn’,H6*(y(3))); % skin friction
fprintf(‘Nux=%7.9fn’,-Kh*y(5)); % local nusselt number
fprintf(‘n’);
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
end
% Define the ODE function
function f = OdeBVP(x,y,Pr,D1,Kh,H4,H3,S)
f =[y(2);y(3);(1/3)*D1*((y(2)^2)-2*(y(1)*y(3))+2*S);y(5);-2/3*(Pr*((H4/H3)/Kh)*y(1)*y(5))];
end
% Define the boundary conditions
function res = OdeBC(ya, yb, A, S, B, lambda)
res= [ya(1)-S;ya(2)-lambda;ya(4)-1;yb(3)-1;yb(4)];
end
% setting the initial guess for first solution
function v = OdeInit1(x,A,S,lambda)
v=[S+0.56;0;0;0;0];
end
% setting the initial guess for second solution
function v1 =OdeInit2(x, A, S,lambda)
v1 = [exp(-x);exp(-x);-exp(-x);-exp(-x);-exp(-x)];
end matlab MATLAB Answers — New Questions
Diagnostic Feature Designer Computation Error
Hello colleagues,
I plan to use Diagnostic Feature Designer for some data analysis for a predictive maintenance framework. I have an acoustic emission signal that can be imported with no issues into the Diagnostic Feature Designer, yet computation of different values is not possible. When I try to use the "Auto Feature" function, I get the following error:
The signal looks like this:
The data seems to be ok, as the same error results even if I generate a sinewave and try to use the Diagnostic Feature Deisgner with it.
Do you have any solution for this situation ?
Thank you!Hello colleagues,
I plan to use Diagnostic Feature Designer for some data analysis for a predictive maintenance framework. I have an acoustic emission signal that can be imported with no issues into the Diagnostic Feature Designer, yet computation of different values is not possible. When I try to use the "Auto Feature" function, I get the following error:
The signal looks like this:
The data seems to be ok, as the same error results even if I generate a sinewave and try to use the Diagnostic Feature Deisgner with it.
Do you have any solution for this situation ?
Thank you! Hello colleagues,
I plan to use Diagnostic Feature Designer for some data analysis for a predictive maintenance framework. I have an acoustic emission signal that can be imported with no issues into the Diagnostic Feature Designer, yet computation of different values is not possible. When I try to use the "Auto Feature" function, I get the following error:
The signal looks like this:
The data seems to be ok, as the same error results even if I generate a sinewave and try to use the Diagnostic Feature Deisgner with it.
Do you have any solution for this situation ?
Thank you! diagnostic feature designer, computation error, predictive maintenance MATLAB Answers — New Questions
[Noob here] I need help with a file exchange which uses MATLAB function
I need help with a File exchange NREL’s Solar Position Algorithm (SPA). I understand the code, but I am new to MATLAB funcitons and I do not know how to extract values from this file exchange to my program. If someone could post a simple main.m example showcasing how to extract the values (for eg. azimuth) into the main.m, it would be helpful.
Thanks in advance.I need help with a File exchange NREL’s Solar Position Algorithm (SPA). I understand the code, but I am new to MATLAB funcitons and I do not know how to extract values from this file exchange to my program. If someone could post a simple main.m example showcasing how to extract the values (for eg. azimuth) into the main.m, it would be helpful.
Thanks in advance. I need help with a File exchange NREL’s Solar Position Algorithm (SPA). I understand the code, but I am new to MATLAB funcitons and I do not know how to extract values from this file exchange to my program. If someone could post a simple main.m example showcasing how to extract the values (for eg. azimuth) into the main.m, it would be helpful.
Thanks in advance. functions MATLAB Answers — New Questions
Why step respose don’t work for first input of a MIMO? And how to use correctly feedback function for pole placement?
Hi!
I’m trying to make a step response for an unstable MIMO system. When I’m using the step function it’s only work for the second input and the first one doesn’t to anything. And also, I’m trying to make a feedback control of the system with pole placement, but I don’t really know how to write correctly the feedback function. Does anyone know what to do?
The model it’s from this study: https://www.mdpi.com/2079-9292/13/3/514#B17-electronics-13-00514
Step response:
Matlab code:
clc
clear all
close all
%% Model parameters
Mp = 0.272;
dM = 0.071;
g = 9.81;
J = 0.002;
Jw = 3.941*10^-5;
b_theta = 0.82*10^-3;
b_altha_kmke_Ra = 1.202*10^-4;
km_Ra = 1.837*10^-4;
%% Matrices for the state space model
A = [0 1 0 0;
(Mp*dM*g)/J -(b_theta)/J 0 1/J*b_altha_kmke_Ra;
0 0 0 1;
-(Mp*g*dM)/J b_theta/J 0 -(J+Jw)/(J*Jw)*b_altha_kmke_Ra];
B = [0 0;
-1/J*km_Ra 1/J;
0 0;
(J+Jw)/(J*Jw)*km_Ra -1/J];
C = [1 0 0 0;
0 1 0 0;
0 0 1 0;
0 0 0 1];
D = [0 0; 0 0;0 0;0 0];
%% Build system
sys = ss(A,B,C,0);
step(sys);
Sc = ctrb(sys);
So = obsv(sys);
%% Control
P = [-1;-2;-3;-4]*10;
K = place(A,B,P);
Alc = A-B*K;
sys_cl = ss(Alc,B,C,D);
closeLoop = feedback(sys*Alc,1);
%% Simulation
t = 0:0.001:10;
u = [ones(length(t),1) zeros(length(t),1) zeros(length(t),1) zeros(length(t),1)];
lsim(closeLoop,u,t)Hi!
I’m trying to make a step response for an unstable MIMO system. When I’m using the step function it’s only work for the second input and the first one doesn’t to anything. And also, I’m trying to make a feedback control of the system with pole placement, but I don’t really know how to write correctly the feedback function. Does anyone know what to do?
The model it’s from this study: https://www.mdpi.com/2079-9292/13/3/514#B17-electronics-13-00514
Step response:
Matlab code:
clc
clear all
close all
%% Model parameters
Mp = 0.272;
dM = 0.071;
g = 9.81;
J = 0.002;
Jw = 3.941*10^-5;
b_theta = 0.82*10^-3;
b_altha_kmke_Ra = 1.202*10^-4;
km_Ra = 1.837*10^-4;
%% Matrices for the state space model
A = [0 1 0 0;
(Mp*dM*g)/J -(b_theta)/J 0 1/J*b_altha_kmke_Ra;
0 0 0 1;
-(Mp*g*dM)/J b_theta/J 0 -(J+Jw)/(J*Jw)*b_altha_kmke_Ra];
B = [0 0;
-1/J*km_Ra 1/J;
0 0;
(J+Jw)/(J*Jw)*km_Ra -1/J];
C = [1 0 0 0;
0 1 0 0;
0 0 1 0;
0 0 0 1];
D = [0 0; 0 0;0 0;0 0];
%% Build system
sys = ss(A,B,C,0);
step(sys);
Sc = ctrb(sys);
So = obsv(sys);
%% Control
P = [-1;-2;-3;-4]*10;
K = place(A,B,P);
Alc = A-B*K;
sys_cl = ss(Alc,B,C,D);
closeLoop = feedback(sys*Alc,1);
%% Simulation
t = 0:0.001:10;
u = [ones(length(t),1) zeros(length(t),1) zeros(length(t),1) zeros(length(t),1)];
lsim(closeLoop,u,t) Hi!
I’m trying to make a step response for an unstable MIMO system. When I’m using the step function it’s only work for the second input and the first one doesn’t to anything. And also, I’m trying to make a feedback control of the system with pole placement, but I don’t really know how to write correctly the feedback function. Does anyone know what to do?
The model it’s from this study: https://www.mdpi.com/2079-9292/13/3/514#B17-electronics-13-00514
Step response:
Matlab code:
clc
clear all
close all
%% Model parameters
Mp = 0.272;
dM = 0.071;
g = 9.81;
J = 0.002;
Jw = 3.941*10^-5;
b_theta = 0.82*10^-3;
b_altha_kmke_Ra = 1.202*10^-4;
km_Ra = 1.837*10^-4;
%% Matrices for the state space model
A = [0 1 0 0;
(Mp*dM*g)/J -(b_theta)/J 0 1/J*b_altha_kmke_Ra;
0 0 0 1;
-(Mp*g*dM)/J b_theta/J 0 -(J+Jw)/(J*Jw)*b_altha_kmke_Ra];
B = [0 0;
-1/J*km_Ra 1/J;
0 0;
(J+Jw)/(J*Jw)*km_Ra -1/J];
C = [1 0 0 0;
0 1 0 0;
0 0 1 0;
0 0 0 1];
D = [0 0; 0 0;0 0;0 0];
%% Build system
sys = ss(A,B,C,0);
step(sys);
Sc = ctrb(sys);
So = obsv(sys);
%% Control
P = [-1;-2;-3;-4]*10;
K = place(A,B,P);
Alc = A-B*K;
sys_cl = ss(Alc,B,C,D);
closeLoop = feedback(sys*Alc,1);
%% Simulation
t = 0:0.001:10;
u = [ones(length(t),1) zeros(length(t),1) zeros(length(t),1) zeros(length(t),1)];
lsim(closeLoop,u,t) matlab, equation, matrices, control MATLAB Answers — New Questions
Microsoft Edge forces Bing on me, I quit Microsoft Edge
I’ve tried Bing. Many, many, many times. Months, years. It hasn’t given me the search results that I wanted. Unlike another search engine I’ve used. So I’ve tried to replace Bing with another search engine for a long time. But no, Microsoft Edge just keep coming back to Bing. God knows how many suggestions I’ve read and tried on removing/replacing Bing. None have worked.
I’m using Windows 11 now. Edge gives me the permission to remove any other search engine, but not Edge. So today, I’ve decided not to use Edge again. I understand why Microsoft needed to do that. But I’ve had enough.
Goodbye, Edge and whoever have been forcing Edge down my throat for so long. Cheers.
I’ve tried Bing. Many, many, many times. Months, years. It hasn’t given me the search results that I wanted. Unlike another search engine I’ve used. So I’ve tried to replace Bing with another search engine for a long time. But no, Microsoft Edge just keep coming back to Bing. God knows how many suggestions I’ve read and tried on removing/replacing Bing. None have worked. I’m using Windows 11 now. Edge gives me the permission to remove any other search engine, but not Edge. So today, I’ve decided not to use Edge again. I understand why Microsoft needed to do that. But I’ve had enough. Goodbye, Edge and whoever have been forcing Edge down my throat for so long. Cheers. Read More