FrontISTR  5.9.0
Large-scale structural analysis program with finit element method
hecmw_matrix_misc.F90
Go to the documentation of this file.
1 !-------------------------------------------------------------------------------
2 ! Copyright (c) 2019 FrontISTR Commons
3 ! This software is released under the MIT License, see LICENSE.txt
4 !-------------------------------------------------------------------------------
5 
7  use hecmw_util
9  implicit none
10 
11  private
12  public :: hecmw_mat_clear
13  public :: hecmw_mat_clear_b
14  public :: hecmw_mat_init
15  public :: hecmw_mat_finalize
16  public :: hecmw_mat_copy_profile
17  public :: hecmw_mat_copy_val
18 
19  public :: hecmw_mat_set_iter
20  public :: hecmw_mat_get_iter
21  public :: hecmw_mat_set_method
22  public :: hecmw_mat_get_method
23  public :: hecmw_mat_set_precond
24  public :: hecmw_mat_get_precond
25  public :: hecmw_mat_set_nset
26  public :: hecmw_mat_get_nset
27  public :: hecmw_mat_set_iterpremax
28  public :: hecmw_mat_get_iterpremax
29  public :: hecmw_mat_set_nrest
30  public :: hecmw_mat_get_nrest
31  public :: hecmw_mat_set_nbfgs
32  public :: hecmw_mat_get_nbfgs
33  public :: hecmw_mat_set_scaling
34  public :: hecmw_mat_get_scaling
35  public :: hecmw_mat_set_penalized
36  public :: hecmw_mat_get_penalized
39  public :: hecmw_mat_set_mpc_method
40  public :: hecmw_mat_get_mpc_method
41  public :: hecmw_mat_set_estcond
42  public :: hecmw_mat_get_estcond
45  public :: hecmw_mat_set_iterlog
46  public :: hecmw_mat_get_iterlog
47  public :: hecmw_mat_set_timelog
48  public :: hecmw_mat_get_timelog
49  public :: hecmw_mat_set_dump
50  public :: hecmw_mat_get_dump
51  public :: hecmw_mat_set_dump_exit
52  public :: hecmw_mat_get_dump_exit
53  public :: hecmw_mat_set_usejad
54  public :: hecmw_mat_get_usejad
55  public :: hecmw_mat_set_ncolor_in
56  public :: hecmw_mat_get_ncolor_in
69 
70  public :: hecmw_mat_set_method2
71  public :: hecmw_mat_get_method2
78 
79  public :: hecmw_mat_set_solver_opt
80  public :: hecmw_mat_get_solver_opt
81 
82  public :: hecmw_mat_set_resid
83  public :: hecmw_mat_get_resid
84  public :: hecmw_mat_set_sigma_diag
85  public :: hecmw_mat_get_sigma_diag
86  public :: hecmw_mat_set_sigma
87  public :: hecmw_mat_get_sigma
88  public :: hecmw_mat_set_thresh
89  public :: hecmw_mat_get_thresh
90  public :: hecmw_mat_set_filter
91  public :: hecmw_mat_get_filter
92  public :: hecmw_mat_set_penalty
93  public :: hecmw_mat_get_penalty
96 
97  public :: hecmw_mat_diag_max
98  public :: hecmw_mat_diag
100  public :: hecmw_mat_substitute
101  public :: hecmw_mat_integrate
102 
103  integer, parameter :: IDX_I_ITER = 1
104  integer, parameter :: IDX_I_METHOD = 2
105  integer, parameter :: IDX_I_PRECOND = 3
106  integer, parameter :: IDX_I_NSET = 4
107  integer, parameter :: IDX_I_ITERPREMAX = 5
108  integer, parameter :: IDX_I_NREST = 6
109  integer, parameter :: IDX_I_NBFGS = 60
110  integer, parameter :: IDX_I_SCALING = 7
111  integer, parameter :: IDX_I_PENALIZED = 11
112  integer, parameter :: IDX_I_PENALIZED_B = 12
113  integer, parameter :: IDX_I_MPC_METHOD = 13
114  integer, parameter :: IDX_I_ESTCOND = 14
115  integer, parameter :: IDX_I_CONTACT_ELIM = 15
116  integer, parameter :: IDX_I_ITERLOG = 21
117  integer, parameter :: IDX_I_TIMELOG = 22
118  integer, parameter :: IDX_I_DUMP = 31
119  integer, parameter :: IDX_I_DUMP_EXIT = 32
120  integer, parameter :: IDX_I_USEJAD = 33
121  integer, parameter :: IDX_I_NCOLOR_IN = 34
122  integer, parameter :: IDX_I_MAXRECYCLE_PRECOND = 35
123  integer, parameter :: IDX_I_NRECYCLE_PRECOND = 96
124  integer, parameter :: IDX_I_FLAG_NUMFACT = 97
125  integer, parameter :: IDX_I_FLAG_SYMBFACT = 98
126  integer, parameter :: IDX_I_SOLVER_TYPE = 99
127 
128  integer, parameter :: IDX_I_METHOD2 = 8
129  integer, parameter :: IDX_I_FLAG_CONVERGED = 81
130  integer, parameter :: IDX_I_FLAG_DIVERGED = 82
131  integer, parameter :: IDX_I_FLAG_MPCMATVEC = 83
132 
133  integer, parameter :: IDX_I_SOLVER_OPT_S = 41
134  integer, parameter :: IDX_I_SOLVER_OPT_E = 50
135 
136  integer, parameter :: IDX_R_RESID = 1
137  integer, parameter :: IDX_R_SIGMA_DIAG = 2
138  integer, parameter :: IDX_R_SIGMA = 3
139  integer, parameter :: IDX_R_THRESH = 4
140  integer, parameter :: IDX_R_FILTER = 5
141  integer, parameter :: IDX_R_PENALTY = 11
142  integer, parameter :: IDX_R_PENALTY_ALPHA = 12
143 
144 contains
145 
146  subroutine hecmw_mat_clear( hecMAT )
147  type(hecmwst_matrix) :: hecmat
148 
149  hecmat%D = 0.0d0
150  hecmat%AL = 0.0d0
151  hecmat%AU = 0.0d0
152  call hecmw_mat_set_penalized( hecmat, 0 )
153  call hecmw_mat_set_penalty_alpha( hecmat, 0.d0 )
154  end subroutine hecmw_mat_clear
155 
156  subroutine hecmw_mat_clear_b( hecMAT )
157  type(hecmwst_matrix) :: hecmat
158 
159  hecmat%B = 0.0d0
160  call hecmw_mat_set_penalized_b( hecmat, 0 )
161  end subroutine hecmw_mat_clear_b
162 
163  subroutine hecmw_mat_init( hecMAT )
164  type(hecmwst_matrix) :: hecmat
165 
166  call hecmw_nullify_matrix( hecmat )
167 
168  hecmat%Iarray = 0
169  hecmat%Rarray = 0.d0
170 
171  call hecmw_mat_set_iter( hecmat, 100 )
172  call hecmw_mat_set_method( hecmat, 1 )
173  call hecmw_mat_set_precond( hecmat, 1 )
174  call hecmw_mat_set_nset( hecmat, 0 )
175  call hecmw_mat_set_iterpremax( hecmat, 1 )
176  call hecmw_mat_set_nrest( hecmat, 10 )
177  call hecmw_mat_set_nbfgs( hecmat, 0 )
178  call hecmw_mat_set_scaling( hecmat, 0 )
179  call hecmw_mat_set_iterlog( hecmat, 0 )
180  call hecmw_mat_set_timelog( hecmat, 0 )
181  call hecmw_mat_set_dump( hecmat, 0 )
182  call hecmw_mat_set_dump_exit( hecmat, 0 )
183  call hecmw_mat_set_usejad( hecmat, 0 )
184  call hecmw_mat_set_ncolor_in( hecmat, 10 )
185  call hecmw_mat_set_estcond( hecmat, 0 )
186  call hecmw_mat_set_maxrecycle_precond( hecmat, 3 )
187 
188  call hecmw_mat_set_resid( hecmat, 1.d-8 )
189  call hecmw_mat_set_sigma_diag( hecmat, 1.d0 )
190  call hecmw_mat_set_sigma( hecmat, 0.d0 )
191  call hecmw_mat_set_thresh( hecmat, 0.10d0 )
192  call hecmw_mat_set_filter( hecmat, 0.10d0 )
193 
194  call hecmw_mat_set_penalized( hecmat, 0 )
195  call hecmw_mat_set_penalty( hecmat, 1.d+4 )
196  call hecmw_mat_set_penalty_alpha( hecmat, 0.d0 )
197  call hecmw_mat_set_mpc_method( hecmat, 0 )
198 
199  call hecmw_mat_reset_nrecycle_precond( hecmat )
200  call hecmw_mat_set_flag_numfact( hecmat, 1 )
201  call hecmw_mat_set_flag_symbfact( hecmat, 1 )
202  call hecmw_mat_set_solver_type( hecmat, 1 )
203  end subroutine hecmw_mat_init
204 
205  subroutine hecmw_mat_finalize( hecMAT )
206  type(hecmwst_matrix) :: hecmat
207  if (associated(hecmat%D)) deallocate(hecmat%D)
208  if (associated(hecmat%B)) deallocate(hecmat%B)
209  if (associated(hecmat%X)) deallocate(hecmat%X)
210  if (associated(hecmat%AL)) deallocate(hecmat%AL)
211  if (associated(hecmat%AU)) deallocate(hecmat%AU)
212  if (associated(hecmat%indexL)) deallocate(hecmat%indexL)
213  if (associated(hecmat%indexU)) deallocate(hecmat%indexU)
214  if (associated(hecmat%itemL)) deallocate(hecmat%itemL)
215  if (associated(hecmat%itemU)) deallocate(hecmat%itemU)
216 #ifdef _OPENACC
217  if (associated(hecmat%A)) deallocate(hecmat%A)
218  if (associated(hecmat%indexA)) deallocate(hecmat%indexA)
219  if (associated(hecmat%itemA)) deallocate(hecmat%itemA)
220 #endif
221  end subroutine hecmw_mat_finalize
222 
223  subroutine hecmw_mat_copy_profile( hecMATorg, hecMAT )
224  type(hecmwst_matrix), intent(in) :: hecmatorg
225  type(hecmwst_matrix), intent(inout) :: hecmat
226  hecmat%N = hecmatorg%N
227  hecmat%NP = hecmatorg%NP
228  hecmat%NDOF = hecmatorg%NDOF
229  hecmat%NPL = hecmatorg%NPL
230  hecmat%NPU = hecmatorg%NPU
231  allocate(hecmat%indexL(0:size(hecmatorg%indexL)-1))
232  allocate(hecmat%indexU(0:size(hecmatorg%indexU)-1))
233  allocate(hecmat%itemL (size(hecmatorg%itemL )))
234  allocate(hecmat%itemU (size(hecmatorg%itemU )))
235  allocate(hecmat%D (size(hecmatorg%D )))
236  allocate(hecmat%AL(size(hecmatorg%AL)))
237  allocate(hecmat%AU(size(hecmatorg%AU)))
238  allocate(hecmat%B (size(hecmatorg%B )))
239  allocate(hecmat%X (size(hecmatorg%X )))
240  hecmat%indexL = hecmatorg%indexL
241  hecmat%indexU = hecmatorg%indexU
242  hecmat%itemL = hecmatorg%itemL
243  hecmat%itemU = hecmatorg%itemU
244  hecmat%D = 0.d0
245  hecmat%AL = 0.d0
246  hecmat%AU = 0.d0
247  hecmat%B = 0.d0
248  hecmat%X = 0.d0
249  end subroutine hecmw_mat_copy_profile
250 
251  subroutine hecmw_mat_copy_val( hecMATorg, hecMAT )
252  type(hecmwst_matrix), intent(in) :: hecmatorg
253  type(hecmwst_matrix), intent(inout) :: hecmat
254  integer(kind=kint) :: ierr
255  integer(kind=kint) :: i
256  ierr = 0
257  if (hecmat%N /= hecmatorg%N) ierr = 1
258  if (hecmat%NP /= hecmatorg%NP) ierr = 1
259  if (hecmat%NDOF /= hecmatorg%NDOF) ierr = 1
260  if (hecmat%NPL /= hecmatorg%NPL) ierr = 1
261  if (hecmat%NPU /= hecmatorg%NPU) ierr = 1
262  if (ierr /= 0) then
263  write(0,*) 'ERROR: hecmw_mat_copy_val: different profile'
264  stop
265  endif
266  do i = 1, size(hecmat%D)
267  hecmat%D(i) = hecmatorg%D(i)
268  enddo
269  do i = 1, size(hecmat%AL)
270  hecmat%AL(i) = hecmatorg%AL(i)
271  enddo
272  do i = 1, size(hecmat%AU)
273  hecmat%AU(i) = hecmatorg%AU(i)
274  enddo
275  end subroutine hecmw_mat_copy_val
276 
277  subroutine hecmw_mat_set_iter( hecMAT, iter )
278  type(hecmwst_matrix) :: hecmat
279  integer(kind=kint) :: iter
280 
281  hecmat%Iarray(idx_i_iter) = iter
282  end subroutine hecmw_mat_set_iter
283 
284  function hecmw_mat_get_iter( hecMAT )
285  integer(kind=kint) :: hecmw_mat_get_iter
286  type(hecmwst_matrix) :: hecmat
287 
288  hecmw_mat_get_iter = hecmat%Iarray(idx_i_iter)
289  end function hecmw_mat_get_iter
290 
291  subroutine hecmw_mat_set_method( hecMAT, method )
292  type(hecmwst_matrix) :: hecmat
293  integer(kind=kint) :: method
294 
295  hecmat%Iarray(idx_i_method) = method
296  end subroutine hecmw_mat_set_method
297 
298  function hecmw_mat_get_method( hecMAT )
299  integer(kind=kint) :: hecmw_mat_get_method
300  type(hecmwst_matrix) :: hecmat
301 
302  hecmw_mat_get_method = hecmat%Iarray(idx_i_method)
303  end function hecmw_mat_get_method
304 
305  subroutine hecmw_mat_set_method2( hecMAT, method2 )
306  type(hecmwst_matrix) :: hecmat
307  integer(kind=kint) :: method2
308 
309  hecmat%Iarray(idx_i_method2) = method2
310  end subroutine hecmw_mat_set_method2
311 
312  function hecmw_mat_get_method2( hecMAT )
313  integer(kind=kint) :: hecmw_mat_get_method2
314  type(hecmwst_matrix) :: hecmat
315 
316  hecmw_mat_get_method2 = hecmat%Iarray(idx_i_method2)
317  end function hecmw_mat_get_method2
318 
319  subroutine hecmw_mat_set_precond( hecMAT, precond )
320  type(hecmwst_matrix) :: hecmat
321  integer(kind=kint) :: precond
322 
323  hecmat%Iarray(idx_i_precond) = precond
324  end subroutine hecmw_mat_set_precond
325 
326  function hecmw_mat_get_precond( hecMAT )
327  integer(kind=kint) :: hecmw_mat_get_precond
328  type(hecmwst_matrix) :: hecmat
329 
330  hecmw_mat_get_precond = hecmat%Iarray(idx_i_precond)
331  end function hecmw_mat_get_precond
332 
333  subroutine hecmw_mat_set_nset( hecMAT, nset )
334  type(hecmwst_matrix) :: hecmat
335  integer(kind=kint) :: nset
336 
337  hecmat%Iarray(idx_i_nset) = nset
338  end subroutine hecmw_mat_set_nset
339 
340  function hecmw_mat_get_nset( hecMAT )
341  integer(kind=kint) :: hecmw_mat_get_nset
342  type(hecmwst_matrix) :: hecmat
343 
344  hecmw_mat_get_nset = hecmat%Iarray(idx_i_nset)
345  end function hecmw_mat_get_nset
346 
347  subroutine hecmw_mat_set_iterpremax( hecMAT, iterpremax )
348  type(hecmwst_matrix) :: hecmat
349  integer(kind=kint) :: iterpremax
350 
351  if (iterpremax.lt.0) iterpremax= 0
352  if (iterpremax.gt.4) iterpremax= 4
353 
354  hecmat%Iarray(idx_i_iterpremax) = iterpremax
355  end subroutine hecmw_mat_set_iterpremax
356 
357  function hecmw_mat_get_iterpremax( hecMAT )
358  integer(kind=kint) :: hecmw_mat_get_iterpremax
359  type(hecmwst_matrix) :: hecmat
360 
361  hecmw_mat_get_iterpremax = hecmat%Iarray(idx_i_iterpremax)
362  end function hecmw_mat_get_iterpremax
363 
364  subroutine hecmw_mat_set_nrest( hecMAT, nrest )
365  type(hecmwst_matrix) :: hecmat
366  integer(kind=kint) :: nrest
367 
368  hecmat%Iarray(idx_i_nrest) = nrest
369  end subroutine hecmw_mat_set_nrest
370 
371  function hecmw_mat_get_nrest( hecMAT )
372  integer(kind=kint) :: hecmw_mat_get_nrest
373  type(hecmwst_matrix) :: hecmat
374 
375  hecmw_mat_get_nrest = hecmat%Iarray(idx_i_nrest)
376  end function hecmw_mat_get_nrest
377 
378  subroutine hecmw_mat_set_nbfgs( hecMAT, nbfgs )
379  type(hecmwst_matrix) :: hecmat
380  integer(kind=kint) :: nbfgs
381 
382  hecmat%Iarray(idx_i_nbfgs) = nbfgs
383  end subroutine hecmw_mat_set_nbfgs
384 
385  function hecmw_mat_get_nbfgs( hecMAT )
386  integer(kind=kint) :: hecmw_mat_get_nbfgs
387  type(hecmwst_matrix) :: hecmat
388 
389  hecmw_mat_get_nbfgs = hecmat%Iarray(idx_i_nbfgs)
390  end function hecmw_mat_get_nbfgs
391 
392  subroutine hecmw_mat_set_scaling( hecMAT, scaling )
393  type(hecmwst_matrix) :: hecmat
394  integer(kind=kint) :: scaling
395 
396  hecmat%Iarray(idx_i_scaling) = scaling
397  end subroutine hecmw_mat_set_scaling
398 
399  function hecmw_mat_get_scaling( hecMAT )
400  integer(kind=kint) :: hecmw_mat_get_scaling
401  type(hecmwst_matrix) :: hecmat
402 
403  hecmw_mat_get_scaling = hecmat%Iarray(idx_i_scaling)
404  end function hecmw_mat_get_scaling
405 
406  subroutine hecmw_mat_set_penalized( hecMAT, penalized )
407  type(hecmwst_matrix) :: hecmat
408  integer(kind=kint) :: penalized
409 
410  hecmat%Iarray(idx_i_penalized) = penalized
411  end subroutine hecmw_mat_set_penalized
412 
413  function hecmw_mat_get_penalized( hecMAT )
414  integer(kind=kint) :: hecmw_mat_get_penalized
415  type(hecmwst_matrix) :: hecmat
416 
417  hecmw_mat_get_penalized = hecmat%Iarray(idx_i_penalized)
418  end function hecmw_mat_get_penalized
419 
420  subroutine hecmw_mat_set_penalized_b( hecMAT, penalized_b )
421  type(hecmwst_matrix) :: hecmat
422  integer(kind=kint) :: penalized_b
423 
424  hecmat%Iarray(idx_i_penalized_b) = penalized_b
425  end subroutine hecmw_mat_set_penalized_b
426 
427  function hecmw_mat_get_penalized_b( hecMAT )
428  integer(kind=kint) :: hecmw_mat_get_penalized_b
429  type(hecmwst_matrix) :: hecmat
430 
431  hecmw_mat_get_penalized_b = hecmat%Iarray(idx_i_penalized_b)
432  end function hecmw_mat_get_penalized_b
433 
434  subroutine hecmw_mat_set_mpc_method( hecMAT, mpc_method )
435  type(hecmwst_matrix) :: hecmat
436  integer(kind=kint) :: mpc_method
437 
438  hecmat%Iarray(idx_i_mpc_method) = mpc_method
439  end subroutine hecmw_mat_set_mpc_method
440 
441  function hecmw_mat_get_mpc_method( hecMAT )
442  integer(kind=kint) :: hecmw_mat_get_mpc_method
443  type(hecmwst_matrix) :: hecmat
444 
445  hecmw_mat_get_mpc_method = hecmat%Iarray(idx_i_mpc_method)
446  end function hecmw_mat_get_mpc_method
447 
448  function hecmw_mat_get_estcond( hecMAT )
449  integer(kind=kint) :: hecmw_mat_get_estcond
450  type(hecmwst_matrix) :: hecmat
451  hecmw_mat_get_estcond = hecmat%Iarray(idx_i_estcond)
452  end function hecmw_mat_get_estcond
453 
454  subroutine hecmw_mat_set_estcond( hecMAT, estcond )
455  type(hecmwst_matrix) :: hecmat
456  integer(kind=kint) :: estcond
457  hecmat%Iarray(idx_i_estcond) = estcond
458  end subroutine hecmw_mat_set_estcond
459 
460  function hecmw_mat_get_contact_elim( hecMAT )
461  integer(kind=kint) :: hecmw_mat_get_contact_elim
462  type(hecmwst_matrix) :: hecmat
463  hecmw_mat_get_contact_elim = hecmat%Iarray(idx_i_contact_elim)
464  end function hecmw_mat_get_contact_elim
465 
466  subroutine hecmw_mat_set_contact_elim( hecMAT, contact_elim )
467  type(hecmwst_matrix) :: hecmat
468  integer(kind=kint) :: contact_elim
469  hecmat%Iarray(idx_i_contact_elim) = contact_elim
470  end subroutine hecmw_mat_set_contact_elim
471 
472  subroutine hecmw_mat_set_iterlog( hecMAT, iterlog )
473  type(hecmwst_matrix) :: hecmat
474  integer(kind=kint) :: iterlog
475 
476  hecmat%Iarray(idx_i_iterlog) = iterlog
477  end subroutine hecmw_mat_set_iterlog
478 
479  function hecmw_mat_get_iterlog( hecMAT )
480  integer(kind=kint) :: hecmw_mat_get_iterlog
481  type(hecmwst_matrix) :: hecmat
482 
483  hecmw_mat_get_iterlog = hecmat%Iarray(idx_i_iterlog)
484  end function hecmw_mat_get_iterlog
485 
486  subroutine hecmw_mat_set_timelog( hecMAT, timelog )
487  type(hecmwst_matrix) :: hecmat
488  integer(kind=kint) :: timelog
489 
490  hecmat%Iarray(idx_i_timelog) = timelog
491  end subroutine hecmw_mat_set_timelog
492 
493  function hecmw_mat_get_timelog( hecMAT )
494  integer(kind=kint) :: hecmw_mat_get_timelog
495  type(hecmwst_matrix) :: hecmat
496 
497  hecmw_mat_get_timelog = hecmat%Iarray(idx_i_timelog)
498  end function hecmw_mat_get_timelog
499 
500  function hecmw_mat_get_dump( hecMAT )
501  integer(kind=kint) :: hecmw_mat_get_dump
502  type(hecmwst_matrix) :: hecmat
503  hecmw_mat_get_dump = hecmat%Iarray(idx_i_dump)
504  end function hecmw_mat_get_dump
505 
506  subroutine hecmw_mat_set_dump( hecMAT, dump_type )
507  type(hecmwst_matrix) :: hecmat
508  integer(kind=kint) :: dump_type
509  hecmat%Iarray(idx_i_dump) = dump_type
510  end subroutine hecmw_mat_set_dump
511 
512  function hecmw_mat_get_dump_exit( hecMAT )
513  integer(kind=kint) :: hecmw_mat_get_dump_exit
514  type(hecmwst_matrix) :: hecmat
515  hecmw_mat_get_dump_exit = hecmat%Iarray(idx_i_dump_exit)
516  end function hecmw_mat_get_dump_exit
517 
518  subroutine hecmw_mat_set_dump_exit( hecMAT, dump_exit )
519  type(hecmwst_matrix) :: hecmat
520  integer(kind=kint) :: dump_exit
521  hecmat%Iarray(idx_i_dump_exit) = dump_exit
522  end subroutine hecmw_mat_set_dump_exit
523 
524  function hecmw_mat_get_usejad( hecMAT )
525  integer(kind=kint) :: hecmw_mat_get_usejad
526  type(hecmwst_matrix) :: hecmat
527  hecmw_mat_get_usejad = hecmat%Iarray(idx_i_usejad)
528  end function hecmw_mat_get_usejad
529 
530  subroutine hecmw_mat_set_usejad( hecMAT, usejad )
531  type(hecmwst_matrix) :: hecmat
532  integer(kind=kint) :: usejad
533  hecmat%Iarray(idx_i_usejad) = usejad
534  end subroutine hecmw_mat_set_usejad
535 
536  function hecmw_mat_get_ncolor_in( hecMAT )
537  integer(kind=kint) :: hecmw_mat_get_ncolor_in
538  type(hecmwst_matrix) :: hecmat
539  hecmw_mat_get_ncolor_in = hecmat%Iarray(idx_i_ncolor_in)
540  end function hecmw_mat_get_ncolor_in
541 
542  subroutine hecmw_mat_set_ncolor_in( hecMAT, ncolor_in )
543  type(hecmwst_matrix) :: hecmat
544  integer(kind=kint) :: ncolor_in
545  hecmat%Iarray(idx_i_ncolor_in) = ncolor_in
546  end subroutine hecmw_mat_set_ncolor_in
547 
549  integer(kind=kint) :: hecmw_mat_get_maxrecycle_precond
550  type(hecmwst_matrix) :: hecmat
551  hecmw_mat_get_maxrecycle_precond = hecmat%Iarray(idx_i_maxrecycle_precond)
553 
554  subroutine hecmw_mat_set_maxrecycle_precond( hecMAT, maxrecycle_precond )
555  type(hecmwst_matrix) :: hecmat
556  integer(kind=kint) :: maxrecycle_precond
557  if (maxrecycle_precond > 100) maxrecycle_precond = 100
558  hecmat%Iarray(idx_i_maxrecycle_precond) = maxrecycle_precond
559  end subroutine hecmw_mat_set_maxrecycle_precond
560 
562  integer(kind=kint) :: hecmw_mat_get_nrecycle_precond
563  type(hecmwst_matrix) :: hecmat
564  hecmw_mat_get_nrecycle_precond = hecmat%Iarray(idx_i_nrecycle_precond)
565  end function hecmw_mat_get_nrecycle_precond
566 
567  subroutine hecmw_mat_reset_nrecycle_precond( hecMAT )
568  type(hecmwst_matrix) :: hecmat
569  hecmat%Iarray(idx_i_nrecycle_precond) = 0
570  end subroutine hecmw_mat_reset_nrecycle_precond
571 
572  subroutine hecmw_mat_incr_nrecycle_precond( hecMAT )
573  type(hecmwst_matrix) :: hecmat
574  hecmat%Iarray(idx_i_nrecycle_precond) = hecmat%Iarray(idx_i_nrecycle_precond) + 1
575  end subroutine hecmw_mat_incr_nrecycle_precond
576 
577  function hecmw_mat_get_flag_numfact( hecMAT )
578  integer(kind=kint) :: hecmw_mat_get_flag_numfact
579  type(hecmwst_matrix) :: hecmat
580  hecmw_mat_get_flag_numfact = hecmat%Iarray(idx_i_flag_numfact)
581  end function hecmw_mat_get_flag_numfact
582 
583  subroutine hecmw_mat_set_flag_numfact( hecMAT, flag_numfact )
584  type(hecmwst_matrix) :: hecmat
585  integer(kind=kint) :: flag_numfact
586  hecmat%Iarray(idx_i_flag_numfact) = flag_numfact
587  end subroutine hecmw_mat_set_flag_numfact
588 
589  function hecmw_mat_get_flag_symbfact( hecMAT )
590  integer(kind=kint) :: hecmw_mat_get_flag_symbfact
591  type(hecmwst_matrix) :: hecmat
592  hecmw_mat_get_flag_symbfact = hecmat%Iarray(idx_i_flag_symbfact)
593  end function hecmw_mat_get_flag_symbfact
594 
595  subroutine hecmw_mat_set_flag_symbfact( hecMAT, flag_symbfact )
596  type(hecmwst_matrix) :: hecmat
597  integer(kind=kint) :: flag_symbfact
598  hecmat%Iarray(idx_i_flag_symbfact) = flag_symbfact
599  end subroutine hecmw_mat_set_flag_symbfact
600 
601  subroutine hecmw_mat_clear_flag_symbfact( hecMAT )
602  type(hecmwst_matrix) :: hecmat
603  hecmat%Iarray(idx_i_flag_symbfact) = 0
604  end subroutine hecmw_mat_clear_flag_symbfact
605 
606  function hecmw_mat_get_solver_type( hecMAT )
607  integer(kind=kint) :: hecmw_mat_get_solver_type
608  type(hecmwst_matrix) :: hecmat
609  hecmw_mat_get_solver_type = hecmat%Iarray(idx_i_solver_type)
610  end function hecmw_mat_get_solver_type
611 
612  subroutine hecmw_mat_set_solver_type( hecMAT, solver_type )
613  type(hecmwst_matrix) :: hecmat
614  integer(kind=kint) :: solver_type
615  hecmat%Iarray(idx_i_solver_type) = solver_type
616  end subroutine hecmw_mat_set_solver_type
617 
618  subroutine hecmw_mat_set_flag_converged( hecMAT, flag_converged )
619  type(hecmwst_matrix) :: hecmat
620  integer(kind=kint) :: flag_converged
621  hecmat%Iarray(idx_i_flag_converged) = flag_converged
622  end subroutine hecmw_mat_set_flag_converged
623 
624  function hecmw_mat_get_flag_converged( hecMAT )
625  integer(kind=kint) :: hecmw_mat_get_flag_converged
626  type(hecmwst_matrix) :: hecmat
627  hecmw_mat_get_flag_converged = hecmat%Iarray(idx_i_flag_converged)
628  end function hecmw_mat_get_flag_converged
629 
630  subroutine hecmw_mat_set_flag_diverged( hecMAT, flag_diverged )
631  type(hecmwst_matrix) :: hecmat
632  integer(kind=kint) :: flag_diverged
633  hecmat%Iarray(idx_i_flag_diverged) = flag_diverged
634  end subroutine hecmw_mat_set_flag_diverged
635 
636  function hecmw_mat_get_flag_diverged( hecMAT )
637  integer(kind=kint) :: hecmw_mat_get_flag_diverged
638  type(hecmwst_matrix) :: hecmat
639  hecmw_mat_get_flag_diverged = hecmat%Iarray(idx_i_flag_diverged)
640  end function hecmw_mat_get_flag_diverged
641 
642  subroutine hecmw_mat_set_flag_mpcmatvec( hecMAT, flag_mpcmatvec )
643  type(hecmwst_matrix) :: hecmat
644  integer(kind=kint) :: flag_mpcmatvec
645  hecmat%Iarray(idx_i_flag_mpcmatvec) = flag_mpcmatvec
646  end subroutine hecmw_mat_set_flag_mpcmatvec
647 
648  function hecmw_mat_get_flag_mpcmatvec( hecMAT )
649  integer(kind=kint) :: hecmw_mat_get_flag_mpcmatvec
650  type(hecmwst_matrix) :: hecmat
651  hecmw_mat_get_flag_mpcmatvec = hecmat%Iarray(idx_i_flag_mpcmatvec)
652  end function hecmw_mat_get_flag_mpcmatvec
653 
654  subroutine hecmw_mat_set_solver_opt( hecMAT, solver_opt )
655  type(hecmwst_matrix) :: hecmat
656  integer(kind=kint) :: solver_opt(:)
657  integer(kind=kint) :: nopt
658  nopt = idx_i_solver_opt_e - idx_i_solver_opt_s + 1
659  hecmat%Iarray(idx_i_solver_opt_s:idx_i_solver_opt_e) = solver_opt(1:nopt)
660  end subroutine hecmw_mat_set_solver_opt
661 
662  subroutine hecmw_mat_get_solver_opt( hecMAT, solver_opt )
663  type(hecmwst_matrix) :: hecmat
664  integer(kind=kint) :: solver_opt(:)
665  integer(kind=kint) :: nopt
666  nopt = idx_i_solver_opt_e - idx_i_solver_opt_s + 1
667  solver_opt(1:nopt) = hecmat%Iarray(idx_i_solver_opt_s:idx_i_solver_opt_e)
668  end subroutine hecmw_mat_get_solver_opt
669 
670  subroutine hecmw_mat_set_resid( hecMAT, resid )
671  type(hecmwst_matrix) :: hecmat
672  real(kind=kreal) :: resid
673 
674  hecmat%Rarray(idx_r_resid) = resid
675  end subroutine hecmw_mat_set_resid
676 
677  function hecmw_mat_get_resid( hecMAT )
678  real(kind=kreal) :: hecmw_mat_get_resid
679  type(hecmwst_matrix) :: hecmat
680 
681  hecmw_mat_get_resid = hecmat%Rarray(idx_r_resid)
682  end function hecmw_mat_get_resid
683 
684  subroutine hecmw_mat_set_sigma_diag( hecMAT, sigma_diag )
685  type(hecmwst_matrix) :: hecmat
686  real(kind=kreal) :: sigma_diag
687 
688  if( sigma_diag < 0.d0 ) then
689  hecmat%Rarray(idx_r_sigma_diag) = -1.d0
690  elseif( sigma_diag < 1.d0 ) then
691  hecmat%Rarray(idx_r_sigma_diag) = 1.d0
692  elseif( sigma_diag > 2.d0 ) then
693  hecmat%Rarray(idx_r_sigma_diag) = 2.d0
694  else
695  hecmat%Rarray(idx_r_sigma_diag) = sigma_diag
696  endif
697  end subroutine hecmw_mat_set_sigma_diag
698 
699  function hecmw_mat_get_sigma_diag( hecMAT )
700  real(kind=kreal) :: hecmw_mat_get_sigma_diag
701  type(hecmwst_matrix) :: hecmat
702 
703  hecmw_mat_get_sigma_diag = hecmat%Rarray(idx_r_sigma_diag)
704  end function hecmw_mat_get_sigma_diag
705 
706  subroutine hecmw_mat_set_sigma( hecMAT, sigma )
707  type(hecmwst_matrix) :: hecmat
708  real(kind=kreal) :: sigma
709 
710  if (sigma < 0.d0) then
711  hecmat%Rarray(idx_r_sigma) = 0.d0
712  elseif (sigma > 1.d0) then
713  hecmat%Rarray(idx_r_sigma) = 1.d0
714  else
715  hecmat%Rarray(idx_r_sigma) = sigma
716  endif
717  end subroutine hecmw_mat_set_sigma
718 
719  function hecmw_mat_get_sigma( hecMAT )
720  real(kind=kreal) :: hecmw_mat_get_sigma
721  type(hecmwst_matrix) :: hecmat
722 
723  hecmw_mat_get_sigma = hecmat%Rarray(idx_r_sigma)
724  end function hecmw_mat_get_sigma
725 
726  subroutine hecmw_mat_set_thresh( hecMAT, thresh )
727  type(hecmwst_matrix) :: hecmat
728  real(kind=kreal) :: thresh
729 
730  hecmat%Rarray(idx_r_thresh) = thresh
731  end subroutine hecmw_mat_set_thresh
732 
733  function hecmw_mat_get_thresh( hecMAT )
734  real(kind=kreal) :: hecmw_mat_get_thresh
735  type(hecmwst_matrix) :: hecmat
736 
737  hecmw_mat_get_thresh = hecmat%Rarray(idx_r_thresh)
738  end function hecmw_mat_get_thresh
739 
740  subroutine hecmw_mat_set_filter( hecMAT, filter )
741  type(hecmwst_matrix) :: hecmat
742  real(kind=kreal) :: filter
743 
744  hecmat%Rarray(idx_r_filter) = filter
745  end subroutine hecmw_mat_set_filter
746 
747  function hecmw_mat_get_filter( hecMAT )
748  real(kind=kreal) :: hecmw_mat_get_filter
749  type(hecmwst_matrix) :: hecmat
750 
751  hecmw_mat_get_filter = hecmat%Rarray(idx_r_filter)
752  end function hecmw_mat_get_filter
753 
754  subroutine hecmw_mat_set_penalty( hecMAT, penalty )
755  type(hecmwst_matrix) :: hecmat
756  real(kind=kreal) :: penalty
757 
758  hecmat%Rarray(idx_r_penalty) = penalty
759  end subroutine hecmw_mat_set_penalty
760 
761  function hecmw_mat_get_penalty( hecMAT )
762  real(kind=kreal) :: hecmw_mat_get_penalty
763  type(hecmwst_matrix) :: hecmat
764 
765  hecmw_mat_get_penalty = hecmat%Rarray(idx_r_penalty)
766  end function hecmw_mat_get_penalty
767 
768  subroutine hecmw_mat_set_penalty_alpha( hecMAT, alpha )
769  type(hecmwst_matrix) :: hecmat
770  real(kind=kreal) :: alpha
771 
772  hecmat%Rarray(idx_r_penalty_alpha) = alpha
773  end subroutine hecmw_mat_set_penalty_alpha
774 
775  function hecmw_mat_get_penalty_alpha( hecMAT )
776  real(kind=kreal) :: hecmw_mat_get_penalty_alpha
777  type(hecmwst_matrix) :: hecmat
778 
779  hecmw_mat_get_penalty_alpha = hecmat%Rarray(idx_r_penalty_alpha)
780  end function hecmw_mat_get_penalty_alpha
781 
782  function hecmw_mat_diag_max(hecMAT, hecMESH)
783  real(kind=kreal) :: hecmw_mat_diag_max
784  type (hecmwst_matrix) :: hecmat
785  type (hecmwst_local_mesh) :: hecmesh
786  integer(kind=kint) :: ndiag, i
787 
788  hecmw_mat_diag_max = -1.0e20
789  ndiag = hecmat%NDOF**2 * hecmat%NP
790  do i = 1, ndiag
791  if( hecmat%D(i) > hecmw_mat_diag_max ) hecmw_mat_diag_max = hecmat%D(i)
792  enddo
794  end function hecmw_mat_diag_max
795 
799  function hecmw_mat_diag(hecMAT) result(diag)
800  type(hecmwst_matrix), intent(in), target :: hecmat
801  real(kind=kreal), pointer :: diag(:)
802  integer(kind=kint) :: i, k, idx, ndof, np
803 
804  ndof = hecmat%NDOF
805  np = hecmat%NP
806  allocate(diag(ndof * np))
807 
808  do i = 1, np
809  do k = 1, ndof
810  idx = ndof * ndof * (i - 1) + (k-1) * ndof + k
811  diag(ndof * (i - 1) + k) = hecmat%D(idx)
812  enddo
813  enddo
814  end function hecmw_mat_diag
815 
817  type (hecmwst_matrix) :: hecmat
818  integer(kind=kint) :: nrecycle, maxrecycle
819  if (hecmat%Iarray(idx_i_flag_symbfact) >= 1) then
820  hecmat%Iarray(idx_i_flag_numfact)=1
822  elseif (hecmat%Iarray(idx_i_flag_numfact) > 1) then
824  hecmat%Iarray(idx_i_flag_numfact) = 1
825  elseif (hecmat%Iarray(idx_i_flag_numfact) == 1) then
826  nrecycle = hecmw_mat_get_nrecycle_precond(hecmat)
827  maxrecycle = hecmw_mat_get_maxrecycle_precond(hecmat)
828  if ( nrecycle < maxrecycle ) then
829  hecmat%Iarray(idx_i_flag_numfact) = 0
831  else
833  endif
834  endif
835  end subroutine hecmw_mat_recycle_precond_setting
836 
837  subroutine hecmw_mat_substitute( dest, src )
838  type (hecmwst_matrix), intent(inout) :: dest
839  type (hecmwst_matrix), intent(inout) :: src
840  dest%N = src%N
841  dest%NP = src%NP
842  dest%NPL = src%NPL
843  dest%NPU = src%NPU
844  dest%NDOF = src%NDOF
845  if (associated(src%D)) dest%D => src%D
846  if (associated(src%B)) dest%B => src%B
847  if (associated(src%X)) dest%X => src%X
848  if (associated(src%AL)) dest%AL => src%AL
849  if (associated(src%AU)) dest%AU => src%AU
850  if (associated(src%indexL)) dest%indexL => src%indexL
851  if (associated(src%indexU)) dest%indexU => src%indexU
852  if (associated(src%itemL)) dest%itemL => src%itemL
853  if (associated(src%itemU)) dest%itemU => src%itemU
854  dest%Iarray(:) = src%Iarray(:)
855  dest%Rarray(:) = src%Rarray(:)
856  end subroutine hecmw_mat_substitute
857 
870  subroutine hecmw_mat_integrate( hecMAT )
871  type (hecmwst_matrix), intent(inout) :: hecmat
872 #ifdef _OPENACC
873  integer(kind=kint) :: i, j, k, nn, pre, pp, js, je
874 
875  nn = hecmat%NDOF * hecmat%NDOF
876  hecmat%NPA = hecmat%NP + hecmat%NPL + hecmat%NPU
877  if (associated(hecmat%A)) deallocate(hecmat%A)
878  if (associated(hecmat%indexA)) deallocate(hecmat%indexA)
879  if (associated(hecmat%itemA)) deallocate(hecmat%itemA)
880  allocate (hecmat%A(nn * hecmat%NPA))
881  allocate (hecmat%indexA(0:hecmat%NP))
882  allocate (hecmat%itemA(hecmat%NPA))
883  hecmat%indexA(0) = 0
884 
885  pre = 0
886  pp = 0
887  !$acc parallel loop private(i, j, k, pre, pp, jS, jE)
888  do i = 1, hecmat%NP
889  hecmat%indexA(i) = i + hecmat%indexL(i) + hecmat%indexU(i)
890 
891  pre = i - 1 + hecmat%indexU(i - 1)
892  js= hecmat%indexL(i - 1) + 1
893  je= hecmat%indexL(i )
894  do j = js, je
895  pp = pre + j
896  hecmat%itemA(pp) = hecmat%itemL(j)
897  do k = -nn+1, 0
898  hecmat%A(nn * pp + k) = hecmat%AL(nn * j + k)
899  enddo
900  enddo
901 
902  pp = i + hecmat%indexU(i - 1) + hecmat%indexL(i)
903  hecmat%itemA(pp) = i
904  do k = -nn+1, 0
905  hecmat%A(nn * pp + k) = hecmat%D(nn * i + k)
906  enddo
907 
908  pre = i + hecmat%indexL(i)
909  js= hecmat%indexU(i - 1) + 1
910  je= hecmat%indexU(i )
911  do j = js, je
912  pp = pre + j
913  hecmat%itemA(pp) = hecmat%itemU(j)
914  do k = -nn+1, 0
915  hecmat%A(nn * pp + k) = hecmat%AU(nn * j + k)
916  enddo
917  enddo
918  enddo
919  !$acc end parallel
920 #endif
921  end subroutine hecmw_mat_integrate
922 
923 end module hecmw_matrix_misc
integer(kind=kint) function, public hecmw_mat_get_solver_type(hecMAT)
integer(kind=kint) function, public hecmw_mat_get_flag_mpcmatvec(hecMAT)
subroutine, public hecmw_mat_set_usejad(hecMAT, usejad)
real(kind=kreal) function, dimension(:), pointer, public hecmw_mat_diag(hecMAT)
Extract diagonal components from matrix D into a 1D vector Returns: diag(i) = D(ndof*ndof*(node-1) + ...
subroutine, public hecmw_mat_set_ncolor_in(hecMAT, ncolor_in)
integer(kind=kint) function, public hecmw_mat_get_flag_diverged(hecMAT)
subroutine, public hecmw_mat_integrate(hecMAT)
Integrate matrix components into a single array for efficient access.
subroutine, public hecmw_mat_clear_flag_symbfact(hecMAT)
real(kind=kreal) function, public hecmw_mat_get_sigma_diag(hecMAT)
real(kind=kreal) function, public hecmw_mat_diag_max(hecMAT, hecMESH)
integer(kind=kint) function, public hecmw_mat_get_iterpremax(hecMAT)
subroutine, public hecmw_mat_set_sigma(hecMAT, sigma)
subroutine, public hecmw_mat_set_contact_elim(hecMAT, contact_elim)
integer(kind=kint) function, public hecmw_mat_get_dump_exit(hecMAT)
integer(kind=kint) function, public hecmw_mat_get_nrest(hecMAT)
subroutine, public hecmw_mat_init(hecMAT)
subroutine, public hecmw_mat_set_iter(hecMAT, iter)
subroutine, public hecmw_mat_set_iterlog(hecMAT, iterlog)
subroutine, public hecmw_mat_finalize(hecMAT)
integer(kind=kint) function, public hecmw_mat_get_nrecycle_precond(hecMAT)
integer(kind=kint) function, public hecmw_mat_get_penalized(hecMAT)
subroutine, public hecmw_mat_copy_val(hecMATorg, hecMAT)
subroutine, public hecmw_mat_set_flag_diverged(hecMAT, flag_diverged)
subroutine, public hecmw_mat_set_penalized_b(hecMAT, penalized_b)
real(kind=kreal) function, public hecmw_mat_get_resid(hecMAT)
subroutine, public hecmw_mat_set_estcond(hecMAT, estcond)
integer(kind=kint) function, public hecmw_mat_get_maxrecycle_precond(hecMAT)
subroutine, public hecmw_mat_set_thresh(hecMAT, thresh)
subroutine, public hecmw_mat_set_flag_converged(hecMAT, flag_converged)
integer(kind=kint) function, public hecmw_mat_get_flag_converged(hecMAT)
integer(kind=kint) function, public hecmw_mat_get_penalized_b(hecMAT)
integer(kind=kint) function, public hecmw_mat_get_dump(hecMAT)
real(kind=kreal) function, public hecmw_mat_get_penalty_alpha(hecMAT)
subroutine, public hecmw_mat_get_solver_opt(hecMAT, solver_opt)
integer(kind=kint) function, public hecmw_mat_get_nbfgs(hecMAT)
subroutine, public hecmw_mat_substitute(dest, src)
real(kind=kreal) function, public hecmw_mat_get_penalty(hecMAT)
subroutine, public hecmw_mat_recycle_precond_setting(hecMAT)
subroutine, public hecmw_mat_incr_nrecycle_precond(hecMAT)
subroutine, public hecmw_mat_set_sigma_diag(hecMAT, sigma_diag)
subroutine, public hecmw_mat_set_penalty_alpha(hecMAT, alpha)
subroutine, public hecmw_mat_clear_b(hecMAT)
subroutine, public hecmw_mat_set_dump_exit(hecMAT, dump_exit)
integer(kind=kint) function, public hecmw_mat_get_iterlog(hecMAT)
subroutine, public hecmw_mat_set_flag_symbfact(hecMAT, flag_symbfact)
integer(kind=kint) function, public hecmw_mat_get_timelog(hecMAT)
subroutine, public hecmw_mat_set_nset(hecMAT, nset)
subroutine, public hecmw_mat_set_flag_numfact(hecMAT, flag_numfact)
subroutine, public hecmw_mat_copy_profile(hecMATorg, hecMAT)
subroutine, public hecmw_mat_set_method(hecMAT, method)
subroutine, public hecmw_mat_set_filter(hecMAT, filter)
integer(kind=kint) function, public hecmw_mat_get_method2(hecMAT)
integer(kind=kint) function, public hecmw_mat_get_flag_numfact(hecMAT)
subroutine, public hecmw_mat_set_penalized(hecMAT, penalized)
subroutine, public hecmw_mat_set_penalty(hecMAT, penalty)
subroutine, public hecmw_mat_set_maxrecycle_precond(hecMAT, maxrecycle_precond)
subroutine, public hecmw_mat_clear(hecMAT)
integer(kind=kint) function, public hecmw_mat_get_contact_elim(hecMAT)
subroutine, public hecmw_mat_set_timelog(hecMAT, timelog)
subroutine, public hecmw_mat_set_resid(hecMAT, resid)
real(kind=kreal) function, public hecmw_mat_get_thresh(hecMAT)
integer(kind=kint) function, public hecmw_mat_get_flag_symbfact(hecMAT)
subroutine, public hecmw_mat_set_flag_mpcmatvec(hecMAT, flag_mpcmatvec)
integer(kind=kint) function, public hecmw_mat_get_method(hecMAT)
integer(kind=kint) function, public hecmw_mat_get_precond(hecMAT)
integer(kind=kint) function, public hecmw_mat_get_nset(hecMAT)
subroutine, public hecmw_mat_set_iterpremax(hecMAT, iterpremax)
real(kind=kreal) function, public hecmw_mat_get_filter(hecMAT)
integer(kind=kint) function, public hecmw_mat_get_estcond(hecMAT)
subroutine, public hecmw_mat_set_nrest(hecMAT, nrest)
integer(kind=kint) function, public hecmw_mat_get_usejad(hecMAT)
subroutine, public hecmw_mat_set_solver_type(hecMAT, solver_type)
subroutine, public hecmw_mat_set_method2(hecMAT, method2)
integer(kind=kint) function, public hecmw_mat_get_mpc_method(hecMAT)
integer(kind=kint) function, public hecmw_mat_get_ncolor_in(hecMAT)
real(kind=kreal) function, public hecmw_mat_get_sigma(hecMAT)
subroutine, public hecmw_mat_set_nbfgs(hecMAT, nbfgs)
integer(kind=kint) function, public hecmw_mat_get_iter(hecMAT)
subroutine, public hecmw_mat_set_precond(hecMAT, precond)
subroutine, public hecmw_mat_set_solver_opt(hecMAT, solver_opt)
integer(kind=kint) function, public hecmw_mat_get_scaling(hecMAT)
subroutine, public hecmw_mat_reset_nrecycle_precond(hecMAT)
subroutine, public hecmw_mat_set_scaling(hecMAT, scaling)
subroutine, public hecmw_mat_set_mpc_method(hecMAT, mpc_method)
subroutine, public hecmw_mat_set_dump(hecMAT, dump_type)
I/O and Utility.
Definition: hecmw_util_f.F90:7
integer(kind=kint), parameter hecmw_max
integer(kind=4), parameter kreal
subroutine hecmw_nullify_matrix(P)
subroutine hecmw_allreduce_r1(hecMESH, s, ntag)