Research Article
A Cost-Effective Smoothed Multigrid with Modified Neighborhood-Based Aggregation for Markov Chains
Algorithm 5
Cost-effective SAM for Markov chains (CESAM),
.
Input: | : problem matrix, | : iteration solution, | , : pre and post relaxation steps. | Output: | : iteration solution. | (1) if not on the coarsest level then | (2) Relax times. | (3) Construct according to (22). | (4) if in the first cycle then | (5) . | (6) Construct based on , and . | (7) else if then | (8) . | (9) else | (10) . | (11) Construct based on , and . | (12) end if | (13) and . | (14) smooth , smooth . | (15) lumping , . | (16) | (17) | (18) Relax times. | (19) else | (20) the solution of , , by a direct solver. | (21) end if | (22) return ; |
|