Question: Edit : I need the program to do computational faster, the update process is needed to be real time (calculating 100.000 to 200.000 records for about 0-5 seconds), this process will be doing in multi threading (about 2-8 thread)

---

I will create program that will update data in database. The update process will be triggered if I do insert data in table. The update process will computational costly. This is the idea of my update process :

1. I will have 3 tables (A,B,C) and each of it will have data aroud 100.000-200.000 records
2. I will have table D to save table A, B, C record count
3. I will have table E to save table A, B, C, D calculation, the calculation including multiplication, division and log base 2
4. I will insert data to table A, B, C and after that data in table D and E must be updated
5. This process can be repeated 3-5 times in every update

Which one is computationally faster, doing update programmatically or using trigger?

Answer: 
Computational cycles in your database server are a scarce resource. You can have as many server instances running your Java program as you can afford, and as your application scales up (adds users, for example) you can distribute the computationally intensive operation to multiple servers.

If you perform the computationally expensive stuff on your MySQL server, you are deciding to do it all on a central machine.

Plus, in my experience, it is easier to unit test and maintain Java code than it is to do the same for trigger / stored procedure code.

That being said, MySQL's floating-point math operations (log, multiplication) exploit the server's math instruction set and are reasonably efficient.
A trigger will be faster as it will work closest to the data and you will not have to transfer data between the database and the program layer. The problem with a trigger is that it will be triggered for every insert. Is that something that you want or would you prefer to only do the computation once a lot of data (ie many inserts) has been inserted.