Tag Archives: multi-threading

Use BeginInvoke and callbacks to perform tasks asynchronously in C#

The example Use BeginInvoke and EndInvoke to perform tasks asynchronously in C# explains one way to call a method asynchronously so it can run on a separate core or CPU. In that example, the program calls BeginInvoke several times to … Continue reading

Posted in algorithms, graphics, image processing, threading | Tagged , , , , , , , , , , , , , , , , | Leave a comment

Use BeginInvoke and EndInvoke to perform tasks asynchronously in C#

This example uses the Emboss method to create embossed images. How that method works isn’t important to the discussion of working asynchronously so it isn’t covered here. Download the example to see how it works. The only thing about that … Continue reading

Posted in algorithms, graphics, image processing, threading | Tagged , , , , , , , , , , , , , | Leave a comment

Let a thread call a form’s methods in C#

When the user clicks the Start Thread button, this program runs a counter on a separate thread. Every second the counter updates the form’s Value variable. It then displays the thread’s number and the new Value in the ListBox at … Continue reading

Posted in algorithms, programs, system, threading | Tagged , , , , , , , , , , , , , , , , | Leave a comment

Use branch and bound with an initial heuristic to solve the partition problem in C#

The post Use exhaustive search to solve the partition problem in C# explains the partition problem and how you can use an exhaustive search to find solutions for it. The post Use branch and bound to solve the partition problem … Continue reading

Posted in algorithms, mathematics | Tagged , , , , , , , , , , , , , , , , , , , , | 1 Comment

Use branch and bound to solve the partition problem in C#

The post Use exhaustive search to solve the partition problem in C# explains the partition problem and how you can use an exhaustive search to find solutions for it. Unfortunately the number of possible solutions is enormous. If you are … Continue reading

Posted in algorithms, mathematics | Tagged , , , , , , , , , , , , , , , , , , , , | 6 Comments

Use exhaustive search to solve the partition problem in C#

In the partition problem, the goal is to divide a set of numbers into two subsets that have the same total. My favorite story for the partition problem is the “booty division problem.” Suppose you and a friend find a … Continue reading

Posted in algorithms, mathematics | Tagged , , , , , , , , , , , , , , , , , , , , | 4 Comments

Use multiple threads to draw a graph in C#

This example shows how you can use multiple threads to let a program draw a graph and perform other tasks at the same time. A thread is a path of execution through a single process. Multi-threading allows an application to … Continue reading

Posted in graphics, programs, threading | Tagged , , , , , , , , , , , | 2 Comments