after learning about thread in java, I realized that we cannot update UI in swing in another thread because components are not thread safe. So, you must use this code if you want to execute this program: replace your simulate method's code by //while(!Simulation.Finished){ new Thread(new Runnable() { public void run() { while(!Simulation.Finished){ // Runs inside of the Swing UI thread SwingUtilities.invokeLater(new Runnable() { public void run() { nextStepBttnActionPerformed(null); System.out.println("nguyen thanh tai"); } }); try { java.lang.Thread.sleep(1000); } catch(Exception e) { } }
Hi, I had downloaded the complete project from the description but when I try to run the program from Netbeans , the Gantt Chart & Ready Queue not running after 'Simulate' button pressed. However, if you press 'finish' button, the Gantt Chart only display. Any bugs on the program ?
i have the same problem, sir please could you help with this?? the Gantt Chart & Ready Queue not running after 'Simulate' button pressed. However, if you press 'finish' button, the Gantt Chart only display. Please help out sir.
Hi, the Simulate Button is not working, I tried to manipulate the simulation method but I got no luck. Can you please provide me what solutions for this? just like the video you have showed thanks a lot.
Hey your Code is well but my problem is there in main function "face" extends cpu but there is no show function there is only show method have there.? and the query face and AppData have main function but there is only exception i want to know where is main function actually calls.. any specific file..??
How can I solve this error? Exception in thread "main" java.lang.NullPointerException at javax.swing.ImageIcon.(Unknown Source) at cpu.Face.initComponents(Face.java:673) at cpu.Face.(Face.java:23) at cpu.CPU.main(CPU.java:11)
@@ahmed.elmowafy cpu.java like face.java, simulate button doesn't work like in the video. and I have downloaded the full java project in the description box. please the solution
Here in this program, we use the same data with all of the algorithms to be able to see the difference between them in action. so if RR doesn't need priority, it won't use it.
@@ahmed.elmowafy can you give me the complete java project jar file? I tried to enter the webpage. but the webpage has been blocked . Please send me the the java jar file. I need it for my OS project
hi..i just want to ask, i already downloaded the source code of this project and already run it at netbean. but the problem is when i try to execute it it will not run automatically. what do you think is the problem?? thank you in advance for answering this question.
Hi, thanks for sharing this :). I'm having problems adding my own data in the "job pool". I do the following: file->add my data->write some values between ur contraints->load. But it just assign random values. Is it possible to fix this? Thanks :)
Thanks for replying :). It doesn't work with any value at all; for example, after starting the program, i do the following: file, add my data, arrive burst priority 0 0 0 5 9 0 11 3 0 12 10 0 and then i press load, but the job pool remains empty. I'm using Linux Mint KDE, running the jar file via "Konsole", with this java version: java version "1.7.0_79" OpenJDK Runtime Environment (IcedTea 2.5.6) (7u79-2.5.6-0ubuntu1.14.04.1) Also, "Simulate" button doesn't do anything. Ps. I tried "sudo java -jar CPU.jar" and java on windows 8.1 but nothing changes. Going to recompile the whole project
salam, hello sir, i have a question can this program able to simulate more than 100 of jobs? where can i change the num job of task in the coding? thanks again sir.
As specified here : github.com/Mowafy/CPU-Schedualing-Algorithms-Simulator/blob/master/src/cpu/MainQueue.java number of jobs is an integer number so it can take up to 2 billion jobs (or what your RAM can hold) and the code will work fine with that (except it will take longer time). But, there is a constrain only in the GUI representation in this program that will arise if you raised the number of jobs more than 8, you will need to scroll in the job pool table, the gantt chart and the ready queue to view the hidden jobs, and you will need to assign a different color for every single job in the representation. If you have any question, please feel free to ask.
What are you trying to accomplish here? Obviously you can't change quantum value in the GUI unless you are using the RR algorithm, and the RR algorithm java class is taking quantum value as an argument, so no it's not fixed.
when i choose the RR algorithm from the gui and choose for example 7 as Quantum the result in the gantt chart shows as if the Quantum is equal to 2. i know the RR.java takes quantum value as an argument from Simulation but the Quantum value at Simulation was never changed from "2" even though i selected 7. idk if i am the only one facing this problem but i have solved it. if you don't have the same problem, don't bother.
Oh, i've got it now.. thank u but there's an error.. it could not find face, says CPU.java when i run it... It's error is in the constructor of Face face= new Face();
+Ahmed Elmowafy is this project open in netbeans or eclipse IDE? how to open this project on IDE When i run this project it is not respond that is shows in your video please help me out
Thank you for the source code. You just have save me from failing on my OS subject.
Hi Ynah :) can you pls send me to broombroomm@gmail.com the project of this program thank you :D
can you send me the source code ? please.... :( I really need it. I have to pass my project Round robin scheduling using vb.net
hi could you send me the project also? email is philathist@gmail.com thank you
please mail the the source code at mayasharmafc@gmail.com
plz mail and save me too from failing
maya sharma can u tell me where this source code run plss.even i also have project on this topic😄
after learning about thread in java, I realized that we cannot update UI in swing in another thread because components are not thread safe. So, you must use this code if you want to execute this program: replace your simulate method's code by
//while(!Simulation.Finished){
new Thread(new Runnable() {
public void run() {
while(!Simulation.Finished){
// Runs inside of the Swing UI thread
SwingUtilities.invokeLater(new Runnable() {
public void run() {
nextStepBttnActionPerformed(null);
System.out.println("nguyen thanh tai");
}
});
try {
java.lang.Thread.sleep(1000);
}
catch(Exception e) {
}
}
}
}).start();
// }
Simulation.Stoped = false; // start the simulation
simulateBttn.setEnabled(false);
stopBttn.setEnabled(true);
nextStepBttn.setEnabled(false);
what about c# CPU scheduling
الف شكر ي هندسة والله
تسلم ايدك وربنا يكرمك
How to test or present this application using src code link that you mentioned.
i have zero idea on java but i just wanna see how to simulate this so i downloaded the full java project but i dont know how to run it :-( plz help
You need to install java, then run the jar file
thanks for the response, do i have to download that separately from the full project?
www.java.com/en/download/
Ahmed Elmowafy how do i open the project in java? There are errors when i open the .java files from the project
You can download the full java project in the description
because the bars with the colors do not appear to me
Thanks so much
Hi, I had downloaded the complete project from the description but when I try to run the program from Netbeans , the Gantt Chart & Ready Queue not running after 'Simulate' button pressed. However, if you press 'finish' button, the Gantt Chart only display. Any bugs on the program ?
i have the same problem. @Ahmed Elmowafy please help us
does you got solution
hi u got solution?
then too it is not working
i have the same problem, sir please could you help with this?? the Gantt Chart & Ready Queue not running after 'Simulate' button pressed. However, if you press 'finish' button, the Gantt Chart only display. Please help out sir.
Why my gantt chart is stock and when i hit finish the simulation done
I think the multi-threading part doesn't work correctly on newer java versions.
Hi, the Simulate Button is not working, I tried to manipulate the simulation method but I got no luck. Can you please provide me what solutions for this? just like the video you have showed thanks a lot.
Bhayi kese bnaye ho help chahiye project me
Hey your Code is well but my problem is there in main function "face" extends cpu but there is no show function there is only show method have there.? and the query face and AppData have main function but there is only exception i want to know where is main function actually calls.. any specific file..??
How can I solve this error?
Exception in thread "main" java.lang.NullPointerException
at javax.swing.ImageIcon.(Unknown Source)
at cpu.Face.initComponents(Face.java:673)
at cpu.Face.(Face.java:23)
at cpu.CPU.main(CPU.java:11)
Did you download the complete java project?
www.mediafire.com/download/8atbafplo17drl1/CPU.rar
what is the main class set
omg it's working thank you... :)
maybe i didn't download it right
Ynah Carrielle Umayam
CPU.Face
+Ahmed Elmowafy, excuse me sir, where could i find Cpu.Face?
Good Evening everybody I noticed that when I clicked Simulate Gantt Chart and the ready queue doesn't run ...do you have any idea how to fix it?
u got solution?
Nice work Sir! Just wondering if you have a program simulation in Disk Scheduling? Thanks for your time!
flixportal :P
I want to ask, I have already run the face.java, but it doesn't work as in the video, what the solution?
thank in advanve
I think CPU.java is the project entry point. I recommend downloading the complete java project.
@@ahmed.elmowafy cpu.java like face.java, simulate button doesn't work like in the video. and I have downloaded the full java project in the description box. please the solution
@@safiratanty537 It seems that you need to debug it. For its worth, the simulate button acts like pushing the "next step" button repeatedly.
Can you please tell me why isn't the simulation animation coming.. After I select finish it shows the entire gnatt chart together!
رائع جدااااااااااااااااااااا
Good day!
I just ask, why in RR need to input the priority? Coz in our lesson it is just the burst time, arrival time and quantum slice.
Here in this program, we use the same data with all of the algorithms to be able to see the difference between them in action. so if RR doesn't need priority, it won't use it.
@@ahmed.elmowafy can you give me the complete java project jar file? I tried to enter the webpage. but the webpage has been blocked . Please send me the the java jar file. I need it for my OS project
i dont undestnd how to do my job.... it is tough to undstnd for me ....whr to write the code nd whr to run on simulator plxx xplain
u got solution?
can u help me to show which part that i should change, if i have 10 process
Sorry, the code is hard coded to have 8 jobs.
you can change that in "Items/Cell.java" though
hello sir im not getting the source code the link you provided is disabled.
plz help me out.....
simulate button doesn't work. how can i fix it?
u got solution
i got nothing
hi..i just want to ask, i already downloaded the source code of this project and already run it at netbean. but the problem is when i try to execute it it will not run automatically. what do you think is the problem??
thank you in advance for answering this question.
did you fix it? when i click smilation button it don't run but when i click finish button it shows the gantt chart result.
I have a question if the quantum is fake ? No use bruh
I think the multi-threading part doesn't work correctly on newer java versions.
:( how can i solve it?
I open it on netbeans but the gant chart didnt run pls reply..
Did you download the full java project from the description?
@@ahmed.elmowafy yes it didnt run..
Dear Ahmed, Can you help me with the Round Robin programming in Matlab?
Sorry, l've never used Matlab
Hi, thanks for sharing this :). I'm having problems adding my own data in the "job pool". I do the following: file->add my data->write some values between ur contraints->load. But it just assign random values. Is it possible to fix this? Thanks :)
+Ap0c4 I tried it and it works normally for me.
Could you please give me the data you're trying to use?
Thanks for replying :). It doesn't work with any value at all; for example, after starting the program, i do the following: file, add my data,
arrive burst priority
0 0 0
5 9 0
11 3 0
12 10 0
and then i press load, but the job pool remains empty. I'm using Linux Mint KDE, running the jar file via "Konsole", with this java version:
java version "1.7.0_79"
OpenJDK Runtime Environment (IcedTea 2.5.6) (7u79-2.5.6-0ubuntu1.14.04.1)
Also, "Simulate" button doesn't do anything.
Ps. I tried "sudo java -jar CPU.jar" and java on windows 8.1 but nothing changes. Going to recompile the whole project
+Ap0c4
program doesn't accept 0 in priority
+Ahmed Elmowafy oh okay, thanks :)
+Ap0c4
if job has one or more invalid data it will be ignored by the program :(
it's a program not a software so don't expect it to be user friendly.
salam,
hello sir, i have a question can this program able to simulate more than 100 of jobs?
where can i change the num job of task in the coding?
thanks again sir.
As specified here : github.com/Mowafy/CPU-Schedualing-Algorithms-Simulator/blob/master/src/cpu/MainQueue.java number of jobs is an integer number so it can take up to 2 billion jobs (or what your RAM can hold) and the code will work fine with that (except it will take longer time).
But, there is a constrain only in the GUI representation in this program that will arise if you raised the number of jobs more than 8, you will need to scroll in the job pool table, the gantt chart and the ready queue to view the hidden jobs, and you will need to assign a different color for every single job in the representation.
If you have any question, please feel free to ask.
full java code please.
links in description
sir simulate key is not working please help
turns out the Quantum was fixed at 2 in the code in the RR.java file. Thanks though
I've just checked the RR.java file, and there is no "2" written there in the file!
i'm sorry. it was the Simulation.java
What are you trying to accomplish here?
Obviously you can't change quantum value in the GUI unless you are using the RR algorithm, and the RR algorithm java class is taking quantum value as an argument, so no it's not fixed.
when i choose the RR algorithm from the gui and choose for example 7 as Quantum the result in the gantt chart shows as if the Quantum is equal to 2. i know the RR.java takes quantum value as an argument from Simulation but the Quantum value at Simulation was never changed from "2" even though i selected 7. idk if i am the only one facing this problem but i have solved it. if you don't have the same problem, don't bother.
You must restart the simulation for the quantum change to take effect, as its value is sent to the algorithm class at the creation of the object.
sir, may i know where could i find cpu.face? It says here "Error: Could not find or load main class cpu.Face"
+gogeous mystique
Did you download the complete java project from the link in the description?
yes... i've tried downloading and extracting it again but every time i open its folder, i really couldn't find the cpu.face.. i only find cpu.java
CPU is the namespace
so the file is "face.java"
you could open the project by NetBeans and it'll save you all the hard work.
Oh, i've got it now.. thank u but there's an error.. it could not find face, says CPU.java when i run it... It's error is in the constructor of Face face= new Face();
I use JCreatorLE to open it
may i know how to run this java project?
Where can I edit the title "CPU scheduale" to "CPU scheduling"? Thanks. :D Forever grateful to your program.
sir do you have another link for the jar version of this application? cuz goo.gl/xYM5xM has been disabled. thanks
www.mediafire.com/download/dwfn1vdmz4b2hzj/dist.rar
thank you very much sir. I really appreciate it, =)
how to compile this project in cmd
+Danish Khan It's a java project, it need java virtual machine to run.
+Ahmed Elmowafy is this project open in netbeans or eclipse IDE? how to open this project on IDE
When i run this project it is not respond that is shows in your video please help me out
+Ahmed Elmowafy Thanks i got it
Sir can you send me the source code for round robin ? please....?
Source code links are in the description
thanks :) I hope I can do my project properly haha
Is there C# version?
السلام عليكم أخي من فضلك ممكن use caese للبرنامج او
functional requirements للبرنامج
You're avoiding questions on how to fix the simulate button i bet you also don't know the solution
:D :D :D
If there is a problem, You can solve it and do a PR
Nah. I'm noob
can you do that on PHP sir?? hehe thanks :)
I can, but I won't :D
full java project please :)
Sir how I can open this in Netbeans?
download the complete java project and open as a project in netbeans
Thank you for replying Sir, but I already download it but when I open in Netbeans It cannot find the code
Do you see the code in the files you have downloaded?
Yes. CPU.jar
You've to download the source code not the the compiled version
Full Java Project : www.mediafire.com/download/8atbafplo17drl1/CPU.rar
Nice program bro, can you pls save me with the source code for my project. thank you in advance
link is in the description
Sir can i input numbers manually?
yes you can, it's in the file menu
+Ahmed Elmowafy what file menu. on the jar ? or the java project . sorry for newbie question
File menu of the program when u run the jar
I have problems in the execution you can help me please
Can i have the project using python if u have please
Sorry, It's in Java.
may be Mr Kavhu can help you
kkkkkk lol
Source code please.
Source Code is now available in the description
can you please send the source code? please?
Bayan Abed
Links are available in the description
Pls can you send me the source code to my email.
Download links are in the description
بس ممكن يا اخوي تضع الكود
الكود عبارة عن برميل اسباجيتى
هاظبطه وهاحطه على github قريباً ان شاء الله
Source Code is now available in the description
how to contact you
It depends, What do you want?
Badly needed to talk to you
@@playlists5635 Email is in "About" page.
Why the mail can't be delivered?please any way communication, what about Facebook
Talk to me