/
flapack_sym_herm.pyf.src
1372 lines (1089 loc) · 63.8 KB
/
flapack_sym_herm.pyf.src
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
! Signatures for f2py-wrappers of FORTRAN LAPACK Symmetric/Hermitian Matrix functions.
!
subroutine <prefix2>syev(compute_v,lower,n,w,a,lda,work,lwork,info)
! w,v,info = syev(a,compute_v=1,lower=0,lwork=3*n-1,overwrite_a=0)
! Compute all eigenvalues and, optionally, eigenvectors of a
! real symmetric matrix A.
!
! Performance tip:
! If compute_v=0 then set also overwrite_a=1.
callstatement (*f2py_func)((compute_v?"V":"N"),(lower?"L":"U"),&n,a,&lda,w,work,&lwork,&info)
callprotoargument char*,char*,F_INT*,<ctype2>*,F_INT*,<ctype2>*,<ctype2>*,F_INT*,F_INT*
integer optional,intent(in):: compute_v = 1
check(compute_v==1||compute_v==0) compute_v
integer optional,intent(in),check(lower==0||lower==1) :: lower = 0
integer intent(hide),depend(a):: n = shape(a,0)
integer intent(hide),depend(a):: lda = MAX(1,shape(a,0))
<ftype2> dimension(n,n),check(shape(a,0)==shape(a,1)) :: a
intent(in,copy,out,out=v) :: a
<ftype2> dimension(n),intent(out),depend(n) :: w
integer optional,intent(in),depend(n) :: lwork=max(3*n-1,1)
check(lwork>=3*n-1) :: lwork
<ftype2> dimension(lwork),intent(hide),depend(lwork) :: work
integer intent(out) :: info
end subroutine <prefix2>syev
subroutine <prefix2>syev_lwork(lower,n,w,a,lda,work,lwork,info)
! LWORK routines for syev
fortranname <prefix2>syev
callstatement (*f2py_func)("N",(lower?"L":"U"),&n,&a,&lda,&w,&work,&lwork,&info)
callprotoargument char*,char*,F_INT*,<ctype2>*,F_INT*,<ctype2>*,<ctype2>*,F_INT*,F_INT*
integer intent(in):: n
integer optional,intent(in),check(lower==0||lower==1) :: lower = 0
integer intent(hide),depend(n):: lda = MAX(1, n)
<ftype2> intent(hide):: a
<ftype2> intent(hide):: w
integer intent(hide):: lwork = -1
<ftype2> intent(out):: work
integer intent(out):: info
end subroutine <prefix2>syev_lwork
subroutine <prefix2c>heev(compute_v,lower,n,w,a,lda,work,lwork,rwork,info)
! w,v,info = syev(a,compute_v=1,lower=0,lwork=3*n-1,overwrite_a=0)
! Compute all eigenvalues and, optionally, eigenvectors of a
! complex Hermitian matrix A.
!
! Warning:
! If compute_v=0 and overwrite_a=1, the contents of a is destroyed.
callstatement (*f2py_func)((compute_v?"V":"N"),(lower?"L":"U"),&n,a,&lda,w,work,&lwork,rwork,&info)
callprotoargument char*,char*,F_INT*,<ctype2c>*,F_INT*,<ctype2>*,<ctype2c>*,F_INT*,<ctype2>*,F_INT*
integer optional,intent(in),check(compute_v==1||compute_v==0) :: compute_v = 1
integer optional,intent(in),check(lower==0||lower==1) :: lower = 0
integer intent(hide),depend(a):: n = shape(a,0)
integer intent(hide),depend(a):: lda = MAX(1,shape(a,0))
<ftype2c> dimension(n,n),check(shape(a,0)==shape(a,1)) :: a
intent(in,copy,out,out=v) :: a
<ftype2> dimension(n),intent(out),depend(n) :: w
integer optional,intent(in),depend(n) :: lwork=max(2*n-1,1)
check(lwork>=2*n-1) :: lwork
<ftype2c> dimension(lwork),intent(hide),depend(lwork) :: work
<ftype2> dimension(3*n-1),intent(hide),depend(n) :: rwork
integer intent(out) :: info
end subroutine <prefix2c>heev
subroutine <prefix2c>heev_lwork(lower,n,w,a,lda,work,lwork,rwork,info)
! LWORK routines for heev
fortranname <prefix2c>heev
callstatement (*f2py_func)("N",(lower?"L":"U"),&n,&a,&lda,&w,&work,&lwork,&rwork,&info)
callprotoargument char*,char*,F_INT*,<ctype2c>*,F_INT*,<ctype2>*,<ctype2c>*,F_INT*,<ctype2>*,F_INT*
integer intent(in):: n
integer optional,intent(in),check(lower==0||lower==1) :: lower = 0
integer intent(hide),depend(n):: lda = MAX(1, n)
<ftype2c> intent(hide):: a
<ftype2> intent(hide):: w
<ftype2> intent(hide):: rwork
integer intent(hide):: lwork = -1
<ftype2c> intent(out):: work
integer intent(out):: info
end subroutine <prefix2c>heev_lwork
subroutine <prefix2>syevd(compute_v,lower,n,w,a,lda,work,lwork,iwork,liwork,info)
! w,v,info = syevd(a,compute_v=1,lower=0,lwork=min_lwork,overwrite_a=0)
! Compute all eigenvalues and, optionally, eigenvectors of a
! real symmetric matrix A using D&C.
!
! Performance tip:
! If compute_v=0 then set also overwrite_a=1.
callstatement (*f2py_func)((compute_v?"V":"N"),(lower?"L":"U"),&n,a,&lda,w,work,&lwork,iwork,&liwork,&info)
callprotoargument char*,char*,F_INT*,<ctype2>*,F_INT*,<ctype2>*,<ctype2>*,F_INT*,F_INT*,F_INT*,F_INT*
integer optional,intent(in),check(compute_v==1||compute_v==0) :: compute_v = 1
integer optional,intent(in),check(lower==0||lower==1) :: lower = 0
integer intent(hide),depend(a):: n = shape(a,0)
<ftype2> dimension(n,n),check(shape(a,0)==shape(a,1)) :: a
intent(in,copy,out,out=v) :: a
integer intent(hide),depend(n) :: lda = MAX(1,n)
<ftype2> dimension(n),intent(out),depend(n) :: w
integer optional,intent(in),depend(n,compute_v) :: lwork=max((compute_v?1+6*n+2*n*n:2*n+1),1)
check(lwork>=(compute_v?1+6*n+2*n*n:2*n+1)) :: lwork
<ftype2> dimension(lwork),intent(hide,cache),depend(lwork) :: work
integer optional,intent(in),depend(n,compute_v) :: liwork = (compute_v?3+5*n:1)
integer dimension(liwork),intent(hide,cache),depend(liwork) :: iwork
integer intent(out) :: info
end subroutine <prefix2>syevd
subroutine <prefix2>syevd_lwork(compute_v,lower,n,w,a,lda,work,lwork,iwork,liwork,info)
! LWORK routines for syevd
fortranname <prefix2>syevd
callstatement (*f2py_func)((compute_v?"V":"N"),(lower?"L":"U"),&n,&a,&lda,&w,&work,&lwork,&iwork,&liwork,&info)
callprotoargument char*,char*,F_INT*,<ctype2>*,F_INT*,<ctype2>*,<ctype2>*,F_INT*,F_INT*,F_INT*,F_INT*
integer intent(in):: n
integer optional,intent(in),check(lower==0||lower==1) :: lower = 0
integer optional,intent(in),check(compute_v==0||compute_v==1) :: compute_v = 1
integer intent(hide):: lda = MAX(1,n)
<ftype2> intent(hide):: a
<ftype2> intent(hide):: w
integer intent(hide):: lwork = -1
integer intent(hide):: liwork = -1
<ftype2> intent(out):: work
integer intent(out):: iwork
integer intent(out):: info
end subroutine <prefix2>syevd_lwork
subroutine <prefix2c>heevd(compute_v,lower,n,w,a,lda,work,lwork,iwork,liwork,rwork,lrwork,info)
! w,v,info = heevd(a,compute_v=1,lower=0,lwork=min_lwork,overwrite_a=0)
! Compute all eigenvalues and, optionally, eigenvectors of a
! complex Hermitian matrix A using D&C.
!
! Warning:
! If compute_v=0 and overwrite_a=1, the contents of a is destroyed.
callstatement (*f2py_func)((compute_v?"V":"N"),(lower?"L":"U"),&n,a,&lda,w,work,&lwork,rwork,&lrwork,iwork,&liwork,&info)
callprotoargument char*,char*,F_INT*,<ctype2c>*,F_INT*,<ctype2>*,<ctype2c>*,F_INT*,<ctype2>*,F_INT*,F_INT*,F_INT*,F_INT*
integer optional,intent(in):: compute_v = 1
check(compute_v==1||compute_v==0) compute_v
integer optional,intent(in),check(lower==0||lower==1) :: lower = 0
integer intent(hide),depend(a):: n = shape(a,0)
<ftype2c> dimension(n,n),check(shape(a,0)==shape(a,1)) :: a
intent(in,copy,out,out=v) :: a
integer intent(hide),depend(n) :: lda = MAX(1,n)
<ftype2> dimension(n),intent(out),depend(n) :: w
integer optional,intent(in),depend(n,compute_v) :: lwork=max((compute_v?2*n+n*n:n+1),1)
check(lwork>=(compute_v?2*n+n*n:n+1)) :: lwork
<ftype2c> dimension(lwork),intent(hide,cache),depend(lwork) :: work
integer optional,intent(in),depend(n,compute_v) :: liwork = (compute_v?3+5*n:1)
integer dimension(liwork),intent(hide,cache),depend(liwork) :: iwork
integer optional,intent(in),depend(n,compute_v) :: lrwork = (compute_v?1+5*n+2*n*n:n)
<ftype2> dimension(lrwork),intent(hide,cache),depend(n,lrwork) :: rwork
integer intent(out) :: info
end subroutine <prefix2c>heevd
subroutine <prefix2c>heevd_lwork(compute_v,lower,n,w,a,lda,work,lwork,iwork,liwork,rwork,lrwork,info)
! LWORK routines for heevd
fortranname <prefix2c>heevd
callstatement (*f2py_func)((compute_v?"V":"N"),(lower?"L":"U"),&n,&a,&lda,&w,&work,&lwork,&rwork,&lrwork,&iwork,&liwork,&info)
callprotoargument char*,char*,F_INT*,<ctype2c>*,F_INT*,<ctype2>*,<ctype2c>*,F_INT*,<ctype2>*,F_INT*,F_INT*,F_INT*,F_INT*
integer intent(in):: n
integer optional,intent(in),check(lower==0||lower==1) :: lower = 0
integer optional,intent(in),check(compute_v==0||compute_v==1) :: compute_v = 1
integer intent(hide):: lda=MAX(1,n)
<ftype2c> intent(hide):: a
<ftype2> intent(hide):: w
integer intent(hide):: lwork=-1
integer intent(hide):: liwork=-1
integer intent(hide):: lrwork=-1
<ftype2c> intent(out):: work
<ftype2> intent(out):: rwork
integer intent(out):: iwork
integer intent(out):: info
end subroutine <prefix2c>heevd_lwork
subroutine <prefix>sytf2(lower,n,a,lda,ipiv,info)
! Compute the factorization of a symmetric matrix such that
! A = L * D * L^T if lower = 1
! A = U * D * U^T if lower = 0
callstatement (*f2py_func)((lower?"L":"U"),&n,a,&lda,ipiv,&info)
callprotoargument char*,F_INT*,<ctype>*,F_INT*,F_INT*,F_INT*
integer optional,intent(in),check(lower==0||lower==1):: lower = 0
integer depend(a),intent(hide):: n = shape(a,0)
<ftype> dimension(n,n),intent(in,out,copy,out=ldu):: a
integer depend(a),intent(hide):: lda = max(shape(a,0),1)
integer dimension(n),depend(n),intent(out):: ipiv
integer intent(out):: info
end subroutine<prefix>sytf2
subroutine <prefix2>sygst(n,a,lda,b,ldb,info,itype,lower)
! c, info = sygst(a,b)
! Transforms the generalized symmetric eigenvalue problem to standard.
! A = inv(U^T) * A * inv(U), if itype == 1
! A = U^T * A * U or L^T * A * L, if itype == 2 or 3, respectively
! B must contain the factorized U and L from potrf
callstatement (*f2py_func)(&itype,(lower?"L":"U"),&n,a,&lda,b,&ldb,&info)
callprotoargument F_INT*,char*,F_INT*,<ctype2>*,F_INT*,<ctype2>*,F_INT*,F_INT*
integer optional,intent(in),check(itype==1||itype==2||itype==3):: itype = 1
integer optional,intent(in),check(lower==0||lower==1):: lower = 0
integer depend(a),intent(hide):: n = shape(a,0)
<ftype2> dimension(n,n),intent(in,out,copy,out=c):: a
integer depend(a),intent(hide):: lda = max(shape(a,0),1)
<ftype2> dimension(n,n),intent(in):: b
integer depend(b),intent(hide):: ldb = max(shape(b,0),1)
integer intent(out):: info
end subroutine <prefix2>sygst
subroutine <prefix>sytrf(lower,n,a,lda,ipiv,work,lwork,info)
! Compute the factorization of a symmetric matrix such that
! A = L * D * L^T if lower = 1
! A = U * D * U^T if lower = 0
! This is similar to ?SYTF2 but uses BLAS3 blocked calls
callstatement (*f2py_func)((lower?"L":"U"),&n,a,&lda,ipiv,work,&lwork,&info)
callprotoargument char*,F_INT*,<ctype>*,F_INT*,F_INT*,<ctype>*,F_INT*,F_INT*
integer optional,intent(in),check(lower==0||lower==1):: lower = 0
integer depend(a),intent(hide):: n = shape(a,0)
<ftype> dimension(n,n),intent(in,out,copy,out=ldu):: a
integer depend(a),intent(hide):: lda = max(shape(a,0),1)
integer dimension(n),depend(n),intent(out):: ipiv
integer optional,intent(in),depend(n),check(lwork>=n||lwork==-1):: lwork = max(n,1)
<ftype> depend(lwork),dimension(MAX(lwork,1)),intent(hide,cache):: work
integer intent(out):: info
end subroutine <prefix>sytrf
subroutine <prefix>sytrf_lwork(lower,n,a,lda,ipiv,work,lwork,info)
! lwork computation for ?SYTRF
fortranname <prefix>sytrf
callstatement (*f2py_func)((lower?"L":"U"),&n,&a,&lda,&ipiv,&work,&lwork,&info)
callprotoargument char*,F_INT*,<ctype>*,F_INT*,F_INT*,<ctype>*,F_INT*,F_INT*
integer intent(in):: n
integer optional,intent(in),check(lower==0||lower==1) :: lower = 0
<ftype> intent(hide):: a
integer depend(n),intent(hide):: lda = max(n,1)
integer intent(hide):: ipiv
integer intent(hide):: lwork = -1
<ftype> intent(out):: work
integer intent(out):: info
end subroutine <prefix>sytrf_lwork
subroutine <prefix>sysv(n,nrhs,a,lda,ipiv,b,ldb,work,lwork,info,lower)
! Solve A * X = B for symmetric A matrix
callstatement (*f2py_func)((lower?"L":"U"),&n,&nrhs,a,&lda,ipiv,b,&ldb,work,&lwork,&info)
callprotoargument char*,F_INT*,F_INT*,<ctype>*,F_INT*,F_INT*,<ctype>*,F_INT*,<ctype>*,F_INT*,F_INT*
integer optional,intent(in),check(lower==0||lower==1) :: lower = 0
integer depend(a),intent(hide):: n = shape(a,0)
integer depend(b),intent(hide):: nrhs = shape(b,1)
<ftype> dimension(n,n),check(shape(a,0)==shape(a,1)),intent(in,out,copy,out=udut):: a
integer depend(a),intent(hide):: lda = shape(a,0)
integer dimension(n),depend(n),intent(out):: ipiv
<ftype> dimension(n,nrhs),check(shape(b,0)==n),depend(n),intent(in,out,copy,out=x):: b
integer depend(b),intent(hide):: ldb = shape(b,0)
integer optional,intent(in),depend(n),check(lwork>=1||lwork==-1):: lwork = max(n,1)
<ftype> depend(lwork),dimension(MAX(lwork,1)),intent(hide,cache):: work
integer intent(out):: info
end subroutine <prefix>sysv
subroutine <prefix>sysv_lwork(n,nrhs,a,lda,ipiv,b,ldb,work,lwork,info,lower)
! lwork computation for ?SYSV
fortranname <prefix>sysv
callstatement (*f2py_func)((lower?"L":"U"),&n,&nrhs,&a,&lda,&ipiv,&b,&ldb,&work,&lwork,&info)
callprotoargument char*,F_INT*,F_INT*,<ctype>*,F_INT*,F_INT*,<ctype>*,F_INT*,<ctype>*,F_INT*,F_INT*
integer intent(in):: n
integer optional,intent(in),check(lower==0||lower==1) :: lower = 0
integer intent(hide):: nrhs = 1
<ftype> intent(hide):: a
integer depend(n),intent(hide):: lda = n
integer intent(hide):: ipiv
<ftype> intent(hide):: b
integer depend(n),intent(hide):: ldb = n
integer intent(hide):: lwork = -1
<ftype> intent(out):: work
integer intent(out):: info
end subroutine <prefix>sysv_lwork
subroutine <prefix>sysvx(n,nrhs,a,lda,af,ldaf,ipiv,b,ldb,x,ldx,rcond,ferr,berr,work,lwork,irwork,info,factored,lower)
! Solve A * X = B for symmetric A matrix
! The expert driver of ?SYSV with condition number, backward,forward error estimates and iterative refinement
! The (c,z) versions assume only symmetric complex matrices. For Hermitian matrices, routine (c,z)HESVX is used
threadsafe
callstatement (*f2py_func)((factored?"F":"N"),(lower?"L":"U"),&n,&nrhs,a,&lda,af,&ldaf,ipiv,b,&ldb,x,&ldx,&rcond,ferr,berr,work,&lwork,irwork,&info)
callprotoargument char*,char*,F_INT*,F_INT*,<ctype>*,F_INT*,<ctype>*,F_INT*,F_INT*,<ctype>*,F_INT*,<ctype>*,F_INT*,<ctypereal>*,<ctypereal>*,<ctypereal>*,<ctype>*,F_INT*,<F_INT,F_INT,float,double>*,F_INT*
integer optional,intent(in),check(factored==0||factored==1) :: factored = 0
integer optional,intent(in),check(lower==0||lower==1) :: lower = 0
integer depend(a),intent(hide):: n = shape(a,0)
integer depend(b),intent(hide):: nrhs = shape(b,1)
<ftype> dimension(n,n),check(shape(a,0)==shape(a,1)),intent(in,copy,out,out=a_s):: a
integer depend(a),intent(hide):: lda = shape(a,0)
<ftype> optional,dimension(n,n),depend(n),intent(in,out,out=udut):: af
integer optional,depend(af),intent(hide):: ldaf = shape(af,0)
integer optional,dimension(n),depend(n),intent(in,out):: ipiv
<ftype> depend(n),dimension(n,nrhs),intent(in,copy,out,out=b_s):: b
integer depend(b),intent(hide):: ldb = shape(b,0)
<ftype> dimension(n,nrhs),intent(out):: x
integer depend(b),intent(hide):: ldx = n
<ftypereal> intent(out):: rcond
<ftypereal> intent(out),dimension(nrhs),depend(nrhs):: ferr
<ftypereal> intent(out),dimension(nrhs),depend(nrhs):: berr
integer optional,intent(in),check(lwork>=<3*n,3*n,2*n,2*n>||lwork==-1):: lwork = max(3*n,1)
<ftype> dimension(MAX(lwork,1)),intent(hide,cache),depend(lwork) :: work
<integer,integer,real,double precision> intent(hide,cache),dimension(n),depend(n) :: irwork
integer intent(out):: info
end subroutine <prefix>sysvx
subroutine <prefix>sysvx_lwork(n,nrhs,a,lda,af,ldaf,ipiv,b,ldb,x,ldx,rcond,ferr,berr,work,lwork,irwork,info,factored,lower)
! lwork computation for ?SYSVX
fortranname <prefix>sysvx
callstatement (*f2py_func)((factored?"F":"N"),(lower?"L":"U"),&n,&nrhs,&a,&lda,&af,&ldaf,&ipiv,&b,&ldb,&x,&ldx,&rcond,&ferr,&berr,&work,&lwork,&irwork,&info)
callprotoargument char*,char*,F_INT*,F_INT*,<ctype>*,F_INT*,<ctype>*,F_INT*,F_INT*,<ctype>*,F_INT*,<ctype>*,F_INT*,<ctypereal>*,<ctypereal>*,<ctypereal>*,<ctype>*,F_INT*,<F_INT,F_INT,float,double>*,F_INT*
integer intent(in):: n
integer optional,intent(in),check(lower==0||lower==1) :: lower = 0
integer intent(hide) :: factored = 0
integer intent(hide):: nrhs = 1
<ftype> intent(hide):: a
integer depend(n),intent(hide):: lda = n
<ftype> intent(hide):: af
integer depend(n),intent(hide):: ldaf = n
integer intent(hide):: ipiv
<ftype> intent(hide):: b
integer depend(n),intent(hide):: ldb = n
<ftype> intent(hide):: x
integer depend(n),intent(hide):: ldx = n
<ftypereal> intent(hide):: rcond
<ftypereal> intent(hide):: ferr
<ftypereal> intent(hide):: berr
integer intent(hide):: lwork = -1
<integer,integer,real,double precision> intent(hide):: irwork
<ftype> intent(out) :: work
integer intent(out):: info
end subroutine <prefix>sysvx_lwork
subroutine <prefix2>sycon(n,a,lda,ipiv,anorm,rcond,work,iwork,info,lower)
! Estimates the reciprocal of the condition number (in the
! 1-norm) of a real symmetric matrix A using the factorization
! A = U*D*U**T or A = L*D*L**T computed by (S/D)SYTRF.
!
! An estimate is obtained for norm(inv(A)), and the reciprocal of the
! condition number is computed as RCOND = 1 / (ANORM * norm(inv(A)))
callstatement (*f2py_func)((lower?"L":"U"),&n,a,&lda,ipiv,&anorm,&rcond,work,iwork,&info)
callprotoargument char*,F_INT*,<ctype2>*,F_INT*,F_INT*,<ctype2>*,<ctype2>*,<ctype2>*,F_INT*,F_INT*
integer optional,intent(in),check(lower==0||lower==1) :: lower = 0
integer depend(a),intent(hide):: n = shape(a,0)
<ftype2> dimension(n,n),check(shape(a,0)==shape(a,1)),intent(in):: a
integer intent(hide),depend(a) :: lda = max(shape(a,0),1)
integer intent(in),dimension(n),depend(n) :: ipiv
<ftype2> intent(in) :: anorm
<ftype2> intent(out) :: rcond
<ftype2> intent(hide),dimension(2*n),depend(n) :: work
integer intent(hide),dimension(n),depend(n) :: iwork
integer intent(out) :: info
end subroutine <prefix2>sycon
subroutine <c,z,c,z><sy,\0,he,\2>con(n,a,lda,ipiv,anorm,rcond,work,info,lower)
! Estimates the reciprocal of the condition number (in the
! 1-norm) of a complex symmetric matrix A using the factorization
! A = U*D*U**T or A = L*D*L**T computed by (C/Z)SYTRF.
!
! An estimate is obtained for norm(inv(A)), and the reciprocal of the
! condition number is computed as RCOND = 1 / (ANORM * norm(inv(A)))
callstatement (*f2py_func)((lower?"L":"U"),&n,a,&lda,ipiv,&anorm,&rcond,work,&info)
callprotoargument char*,F_INT*,<ctypecomplex>*,F_INT*,F_INT*,<ctypereal>*,<ctypereal>*,<ctypecomplex>*,F_INT*
integer optional,intent(in),check(lower==0||lower==1) :: lower = 0
integer depend(a),intent(hide):: n = shape(a,0)
<ftypecomplex> dimension(n,n),check(shape(a,0)==shape(a,1)),intent(in):: a
integer intent(hide),depend(a) :: lda = max(shape(a,0),1)
integer intent(in),dimension(n),depend(n) :: ipiv
<ftypereal> intent(in) :: anorm
<ftypereal> intent(out) :: rcond
<ftypecomplex> intent(hide),dimension(2*n),depend(n) :: work
integer intent(out) :: info
end subroutine <c,z,c,z><sy,\0,he,\2>con
subroutine <prefix>syconv(lower,way,n,a,lda,ipiv,e,info)
! ?SYCONV converts A given by ???TRF into L and D and vice-versa.
! Get Non-diag elements of D (returned in workspace) and apply or reverse permutation done in TRF.
callstatement (*f2py_func)((lower?"L":"U"),(way?"R":"C"),&n,a,&lda,ipiv,e,&info)
callprotoargument char*,char*,F_INT*,<ctype>*,F_INT*,F_INT*,<ctype>*,F_INT*
integer optional,intent(in),check(lower==0||lower==1) :: lower = 0
integer optional,intent(in),check(way==0||way==1) :: way = 0
integer depend(a),intent(hide):: n = shape(a,0)
<ftype> dimension(n,n),check(shape(a,0)==shape(a,1)),intent(in,out,copy,out=a):: a
integer intent(hide),depend(a) :: lda = max(shape(a,0),1)
integer intent(in),dimension(n),depend(n) :: ipiv
<ftype> intent(out),dimension(n),depend(n):: e
integer intent(out) :: info
end subroutine <prefix>syconv
subroutine <prefix2c>hegst(n,a,lda,b,ldb,info,itype,lower)
! c, info = hegst(a,b)
! Transforms the generalized Hermitian eigenvalue problem to standard.
! A = inv(U^H) * A * inv(U), if itype == 1
! A = U^H * A * U or L^H * A * L, if itype == 2 or 3, respectively
! B must contain the factorized U and L from potrf
callstatement (*f2py_func)(&itype,(lower?"L":"U"),&n,a,&lda,b,&ldb,&info)
callprotoargument F_INT*,char*,F_INT*,<ctype2c>*,F_INT*,<ctype2c>*,F_INT*,F_INT*
integer optional,intent(in),check(itype==1||itype==2||itype==3):: itype = 1
integer optional,intent(in),check(lower==0||lower==1):: lower = 0
integer depend(a),intent(hide):: n = shape(a,0)
<ftype2c> dimension(n,n),intent(in,out,copy,out=c):: a
integer depend(a),intent(hide):: lda = max(shape(a,0),1)
<ftype2c> dimension(n,n),intent(in):: b
integer depend(b),intent(hide):: ldb = max(shape(b,0),1)
integer intent(out):: info
end subroutine <prefix2c>hegst
subroutine <prefix2c>hetrf(lower,n,a,lda,ipiv,work,lwork,info)
! Compute the factorization of a hermitian matrix such that
! A = L * D * L^T if lower = 1
! A = U * D * U^T if lower = 0
! This is similar to ?HETF2 but uses BLAS3 blocked calls
callstatement (*f2py_func)((lower?"L":"U"),&n,a,&lda,ipiv,work,&lwork,&info)
callprotoargument char*,F_INT*,<ctype2c>*,F_INT*,F_INT*,<ctype2c>*,F_INT*,F_INT*
integer optional,intent(in),check(lower==0||lower==1):: lower = 0
integer depend(a),intent(hide):: n = shape(a,0)
<ftype2c> dimension(n,n),intent(in,out,copy,out=ldu):: a
integer depend(a),intent(hide):: lda = max(shape(a,0),1)
integer dimension(n),depend(n),intent(out):: ipiv
integer optional,intent(in),depend(n),check(lwork>=n||lwork==-1):: lwork = max(n,1)
<ftype2c> depend(lwork),dimension(MAX(lwork,1)),intent(hide,cache):: work
integer intent(out):: info
end subroutine <prefix2c>hetrf
subroutine <prefix2c>hetrf_lwork(lower,n,a,lda,ipiv,work,lwork,info)
! lwork computation for ?HETRF
fortranname <prefix2c>hetrf
callstatement (*f2py_func)((lower?"L":"U"),&n,&a,&lda,&ipiv,&work,&lwork,&info)
callprotoargument char*,F_INT*,<ctype2c>*,F_INT*,F_INT*,<ctype2c>*,F_INT*,F_INT*
integer intent(in):: n
integer optional,intent(in),check(lower==0||lower==1) :: lower = 0
<ftype2c> intent(hide):: a
integer depend(n),intent(hide):: lda = max(n,1)
integer intent(hide):: ipiv
integer intent(hide):: lwork = -1
<ftype2c> intent(out):: work
integer intent(out):: info
end subroutine <prefix2c>hetrf_lwork
subroutine <prefix2c>hesv(n,nrhs,a,lda,ipiv,b,ldb,work,lwork,info,lower)
! Solves A * X = B for X
! A is hermitian. For symmetric A see ?SYSV
! A = U * D * U**H if lower = 0
! A = L * D * L**H if lower = 1
threadsafe
callstatement (*f2py_func)((lower?"L":"U"),&n,&nrhs,a,&lda,ipiv,b,&ldb,work,&lwork,&info)
callprotoargument char*,F_INT*,F_INT*,<ctype2c>*,F_INT*,F_INT*,<ctype2c>*,F_INT*,<ctype2c>*,F_INT*,F_INT*
integer optional,intent(in),check(lower==0||lower==1) :: lower = 0
integer depend(a),intent(hide):: n = shape(a,0)
integer depend(b),intent(hide):: nrhs = shape(b,1)
<ftype2c> dimension(n,n),check(shape(a,0)==shape(a,1)),intent(in,out,copy,out=uduh):: a
integer depend(a),intent(hide):: lda = shape(a,0)
integer dimension(n),depend(n),intent(out):: ipiv
<ftype2c> dimension(n,nrhs),check(shape(b,0)==n),depend(n),intent(in,out,copy,out=x):: b
integer depend(b),intent(hide):: ldb = shape(b,0)
integer optional,intent(in),depend(n),check(lwork>=1||lwork==-1):: lwork = max(n,1)
<ftype2c> depend(lwork),dimension(MAX(lwork,1)),intent(hide,cache):: work
integer intent(out):: info
end subroutine <prefix2c>hesv
subroutine <prefix2c>hesv_lwork(n,nrhs,a,lda,ipiv,b,ldb,work,lwork,info,lower)
! lwork computation for C/ZHESV
fortranname <prefix2c>hesv
callstatement (*f2py_func)((lower?"L":"U"),&n,&nrhs,&a,&lda,&ipiv,&b,&ldb,&work,&lwork,&info)
callprotoargument char*,F_INT*,F_INT*,<ctype2c>*,F_INT*,F_INT*,<ctype2c>*,F_INT*,<ctype2c>*,F_INT*,F_INT*
integer optional,intent(in),check(lower==0||lower==1) :: lower = 0
integer intent(in):: n
integer intent(hide):: nrhs = 1
<ftype2c> intent(hide):: a
integer intent(hide),depend(n):: lda = n
integer intent(hide):: ipiv
<ftype2c> intent(hide):: b
integer intent(hide),depend(n):: ldb = n
integer intent(hide):: lwork = -1
<ftype2c> intent(out):: work
integer intent(out):: info
end subroutine <prefix2c>hesv_lwork
subroutine <prefix2c>hesvx(n,nrhs,a,lda,af,ldaf,ipiv,b,ldb,x,ldx,rcond,ferr,berr,work,lwork,rwork,info,factored,lower)
! Solves A * X = B for X
! Expert driver for ?HESV
! A is hermitian. For symmetric A see ?SYSVX
! A = U * D * U**H if lower = 0
! A = L * D * L**H if lower = 1
threadsafe
callstatement (*f2py_func)((factored?"F":"N"),(lower?"L":"U"),&n,&nrhs,a,&lda,af,&ldaf,ipiv,b,&ldb,x,&ldx,&rcond,ferr,berr,work,&lwork,rwork,&info)
callprotoargument char*,char*,F_INT*,F_INT*,<ctype2c>*,F_INT*,<ctype2c>*,F_INT*,F_INT*,<ctype2c>*,F_INT*,<ctype2c>*,F_INT*,<ctype2>*,<ctype2>*,<ctype2>*,<ctype2c>*,F_INT*,<ctype2>*,F_INT*
integer optional,intent(in),check(factored==0||factored==1) :: factored = 0
integer optional,intent(in),check(lower==0||lower==1) :: lower = 0
integer depend(a),intent(hide):: n = shape(a,0)
integer depend(b),intent(hide):: nrhs = shape(b,1)
<ftype2c> dimension(n,n),check(shape(a,0)==shape(a,1)),intent(in,copy) :: a
integer depend(a),intent(hide):: lda = shape(a,0)
<ftype2c> optional,dimension(n,n),depend(n),intent(in,out,out=uduh) :: af
integer optional,depend(af),intent(hide):: ldaf = shape(af,0)
integer optional,depend(n),dimension(n),intent(in,out):: ipiv
<ftype2c> depend(n),dimension(n,nrhs),intent(in,copy) :: b
integer depend(b),intent(hide):: ldb = shape(b,0)
<ftype2c> depend(n,nrhs),dimension(n,nrhs),intent(out) :: x
integer depend(x),intent(hide):: ldx = shape(x,0)
<ftype2> intent(out):: rcond
<ftype2> intent(out),dimension(nrhs),depend(nrhs):: ferr
<ftype2> intent(out),dimension(nrhs),depend(nrhs):: berr
<ftype2c> dimension(MAX(1,lwork)),depend(lwork),intent(hide,cache):: work
integer optional,intent(in),depend(n),check(lwork>=1||lwork==-1):: lwork = max(2*n,1)
<ftype2> intent(hide,cache),dimension(n),depend(n) :: rwork
integer intent(out):: info
end subroutine <prefix2c>hesvx
subroutine <prefix2c>hesvx_lwork(n,nrhs,a,lda,af,ldaf,ipiv,b,ldb,x,ldx,rcond,ferr,berr,work,lwork,rwork,info,factored,lower)
! lwork computation for ?HESVX
fortranname <prefix2c>hesvx
callstatement (*f2py_func)((factored?"F":"N"),(lower?"L":"U"),&n,&nrhs,&a,&lda,&af,&ldaf,&ipiv,&b,&ldb,&x,&ldx,&rcond,&ferr,&berr,&work,&lwork,&rwork,&info)
callprotoargument char*,char*,F_INT*,F_INT*,<ctype2c>*,F_INT*,<ctype2c>*,F_INT*,F_INT*,<ctype2c>*,F_INT*,<ctype2c>*,F_INT*,<ctype2>*,<ctype2>*,<ctype2>*,<ctype2c>*,F_INT*,<ctype2>*,F_INT*
integer optional,intent(in),check(lower==0||lower==1) :: lower = 0
integer intent(in):: n
integer intent(hide) :: factored = 0
integer depend(b),intent(hide):: nrhs = 1
<ftype2c> intent(hide) :: a
integer depend(n),intent(hide):: lda = n
<ftype2c> intent(hide) :: af
integer depend(n),intent(hide):: ldaf = n
integer intent(hide):: ipiv
<ftype2c> intent(hide) :: b
integer depend(n),intent(hide):: ldb = n
<ftype2c> intent(hide) :: x
integer depend(n),intent(hide):: ldx = n
<ftype2> intent(hide):: rcond
<ftype2> intent(hide):: ferr
<ftype2> intent(hide):: berr
integer intent(hide):: lwork = -1
<ftype2> intent(hide):: rwork
<ftype2c> intent(out):: work
integer intent(out):: info
end subroutine <prefix2c>hesvx_lwork
subroutine <prefix2>sytrd(lower,n,a,lda,d,e,tau,work,lwork,info)
! Reduce a real symmetric matrix A to real symmetric
! tridiagonal form T by an orthogonal similarity transformation:
! Q**T * A * Q = T.
callstatement (*f2py_func)((lower?"L":"U"),&n,a,&lda,d,e,tau,work,&lwork,&info);
callprotoargument char*,F_INT*,<ctype2>*,F_INT*,<ctype2>*,<ctype2>*,<ctype2>*,<ctype2>*,F_INT*,F_INT*
integer intent(hide),depend(a) :: lda=MAX(shape(a,0),1)
integer intent(hide),depend(a) :: n=shape(a,1)
integer optional,intent(in),check(lower==0||lower==1) :: lower = 0
<ftype2> dimension(lda,n),check(shape(a,0)==shape(a,1)),intent(in,out,copy,out=c) :: a
<ftype2> dimension(n),intent(out),depend(n) :: d
<ftype2> dimension(n-1),intent(out),depend(n) :: e
<ftype2> dimension(n-1),intent(out),depend(n) :: tau
integer intent(in),optional,depend(n),check(lwork>=1||lwork==-1) :: lwork = MAX(n,1)
<ftype2> dimension(lwork),intent(cache,hide),depend(lwork) :: work
integer intent(out) :: info
end subroutine <prefix2>sytrd
subroutine <prefix2>sytrd_lwork(lower,n,a,lda,d,e,tau,work,lwork,info)
! lwork computation for sytrd
fortranname <prefix2>sytrd
callstatement (*f2py_func)((lower?"L":"U"),&n,&a,&lda,&d,&e,&tau,&work,&lwork,&info);
callprotoargument char*,F_INT*,<ctype2>*,F_INT*,<ctype2>*,<ctype2>*,<ctype2>*,<ctype2>*,F_INT*,F_INT*
integer intent(in) :: n
integer optional,intent(in),check(lower==0||lower==1) :: lower = 0
integer intent(hide),depend(n) :: lda=MAX(n,1)
<ftype2> intent(hide) :: a
<ftype2> intent(hide) :: d
<ftype2> intent(hide) :: e
<ftype2> intent(hide) :: tau
<ftype2> intent(out) :: work
integer intent(hide) :: lwork = -1
integer intent(out) :: info
end subroutine <prefix2>sytrd_lwork
subroutine <prefix2c>hetrd(lower,n,a,lda,d,e,tau,work,lwork,info)
! Reduce a complex hermitian matrix A to real symmetric
! tridiagonal form T by an orthogonal similarity transformation:
! Q**H * A * Q = T.
callstatement (*f2py_func)((lower?"L":"U"),&n,a,&lda,d,e,tau,work,&lwork,&info);
callprotoargument char*,F_INT*,<ctype2c>*,F_INT*,<ctype2>*,<ctype2>*,<ctype2c>*,<ctype2c>*,F_INT*,F_INT*
integer intent(hide),depend(a) :: lda=MAX(shape(a,0),1)
integer intent(hide),depend(a) :: n=shape(a,1)
integer optional,intent(in),check(lower==0||lower==1) :: lower = 0
<ftype2c> dimension(lda,n),check(shape(a,0)==shape(a,1)),intent(in,out,copy,out=c) :: a
<ftype2> dimension(n),intent(out),depend(n) :: d
<ftype2> dimension(n-1),intent(out),depend(n) :: e
<ftype2c> dimension(n-1),intent(out),depend(n) :: tau
integer intent(in),optional,depend(n),check(lwork>=1||lwork==-1) :: lwork = MAX(n,1)
<ftype2c> dimension(lwork),intent(cache,hide),depend(lwork) :: work
integer intent(out) :: info
end subroutine <prefix2c>hetrd
subroutine <prefix2c>hetrd_lwork(lower,n,a,lda,d,e,tau,work,lwork,info)
! lwork computation for hetrd
fortranname <prefix2c>hetrd
callstatement (*f2py_func)((lower?"L":"U"),&n,&a,&lda,&d,&e,&tau,&work,&lwork,&info);
callprotoargument char*,F_INT*,<ctype2c>*,F_INT*,<ctype2>*,<ctype2>*,<ctype2c>*,<ctype2c>*,F_INT*,F_INT*
integer intent(in) :: n
integer optional,intent(in),check(lower==0||lower==1) :: lower = 0
integer intent(hide),depend(n) :: lda=MAX(n,1)
<ftype2c> intent(hide) :: a
<ftype2> intent(hide) :: d
<ftype2> intent(hide) :: e
<ftype2c> intent(hide) :: tau
<ftype2c> intent(out) :: work
integer intent(hide) :: lwork = -1
integer intent(out) :: info
end subroutine <prefix2c>hetrd_lwork
subroutine <prefix2>syevr(compute_v,range,lower,n,a,lda,vl,vu,il,iu,abstol,w,z,m,ldz,isuppz,work,lwork,iwork,liwork,info)
! Standard Symmetric/HermitianEigenvalue Problem
! Real - Single precision / Double precision
!
! if jobz = 'N' there are no eigvecs hence 0x0 'z' returned
! if jobz = 'V' and range = 'A', z is (nxn)
! if jobz = 'V' and range = 'V', z is (nxn) since returned number of eigs is unknown beforehand
! if jobz = 'V' and range = 'I', z is (nx(iu-il+1))
callstatement (*f2py_func)((compute_v?"V":"N"),range,(lower?"L":"U"),&n,a,&lda,&vl,&vu,&il,&iu,&abstol,&m,w,z,&ldz,isuppz,work,&lwork,iwork,&liwork,&info)
callprotoargument char*,char*,char*,F_INT*,<ctype2>*,F_INT*,<ctype2>*,<ctype2>*,F_INT*,F_INT*,<ctype2>*,F_INT*,<ctype2>*,<ctype2>*,F_INT*,F_INT*,<ctype2>*,F_INT*,F_INT*,F_INT*,F_INT*
<ftype2> intent(in,copy,aligned8),check(shape(a,0)==shape(a,1)),dimension(n,n) :: a
integer optional,intent(in),check(compute_v==1||compute_v==0):: compute_v = 1
character optional,intent(in),check(*range=='A'||*range=='V' ||*range=='I') :: range='A'
integer optional,intent(in),check(lower==0||lower==1) :: lower = 0
integer optional,intent(in),check(il>=1&&il<=n),depend(n) :: il=1
integer optional,intent(in),check(n>=iu&&iu>=il),depend(n,il) :: iu=n
<ftype2> optional,intent(in) :: vl=0.0
<ftype2> optional,intent(in),check(vu>=vl),depend(vl) :: vu=1.0
<ftype2> intent(in) :: abstol=0.0
integer optional,intent(in),depend(n),check(lwork>=max(1,26*n)||lwork==-1) :: lwork=max(26*n,1)
integer optional,intent(in),depend(n),check(liwork>=max(1,10*n)||liwork==-1):: liwork= max(1,10*n)
integer intent(hide),depend(a) :: n=shape(a,0)
integer intent(hide),depend(n) :: lda=max(1,n)
integer intent(hide),depend(z) :: ldz=max(1,shape(z,0))
<ftype2> intent(hide),dimension(lwork),depend(lwork) :: work
integer intent(hide),dimension(liwork),depend(liwork) :: iwork
<ftype2> intent(out),dimension(n),depend(n) :: w
<ftype2> intent(out),dimension((compute_v?MAX(0,n):0),(compute_v?(*range=='I'?iu-il+1:MAX(1,n)):0)),depend(n,compute_v,range,iu,il) :: z
integer intent(out) :: m
! Only returned if range=='A' or range=='I' and il, iu = 1, n
integer intent(out),dimension((compute_v?(2*(*range=='A'||(*range=='I' && iu-il+1==n)?n:0)):0)),depend(n,iu,il,compute_v,range) :: isuppz
integer intent(out) :: info
end subroutine <prefix2>syevr
subroutine <prefix2>syevr_lwork(lower,n,a,lda,vl,vu,il,iu,abstol,m,w,z,ldz,isuppz,work,lwork,iwork,liwork,info)
! LWORK routines for (s/d)syevr
fortranname <prefix2>syevr
callstatement (*f2py_func)("N","A",(lower?"L":"U"),&n,&a,&lda,&vl,&vu,&il,&iu,&abstol,&m,&w,&z,&ldz,&isuppz,&work,&lwork,&iwork,&liwork,&info)
callprotoargument char*,char*,char*,F_INT*,<ctype2>*,F_INT*,<ctype2>*,<ctype2>*,F_INT*,F_INT*,<ctype2>*,F_INT*,<ctype2>*,<ctype2>*,F_INT*,F_INT*,<ctype2>*,F_INT*,F_INT*,F_INT*,F_INT*
! Inputs
integer intent(in):: n
integer optional,intent(in),check(lower==0||lower==1) :: lower = 0
! Not referenced
<ftype2> intent(hide) :: a
integer intent(hide),depend(n) :: lda = max(1,n)
<ftype2> intent(hide) :: vl=0.
<ftype2> intent(hide) :: vu=1.
integer intent(hide) :: il=1
integer intent(hide) :: iu=2
<ftype2> intent(hide) :: abstol=0.
integer intent(hide) :: m=1
<ftype2> intent(hide) :: w
<ftype2> intent(hide) :: z
integer intent(hide),depend(n):: ldz = max(1,n)
integer intent(hide) :: isuppz
integer intent(hide) :: lwork = -1
integer intent(hide) :: liwork = -1
! Outputs
<ftype2> intent(out) :: work
integer intent(out) :: iwork
integer intent(out) :: info
end subroutine <prefix2>syevr_lwork
subroutine <prefix2c>heevr(compute_v,range,lower,n,a,lda,vl,vu,il,iu,abstol,w,z,m,ldz,isuppz,work,lwork,rwork,lrwork,iwork,liwork,info)
! Standard Symmetric/HermitianEigenvalue Problem
! Complex - Single precision / Double precision
!
! if jobz = 'N' there are no eigvecs hence 0x0 'z' returned
! if jobz = 'V' and range = 'A', z is (nxn)
! if jobz = 'V' and range = 'V', z is (nxn) since returned number of eigs is unknown beforehand
! if jobz = 'V' and range = 'I', z is (nx(iu-il+1))
callstatement (*f2py_func)((compute_v?"V":"N"),range,(lower?"L":"U"),&n,a,&lda,&vl,&vu,&il,&iu,&abstol,&m,w,z,&ldz,isuppz,work,&lwork,rwork,&lrwork,iwork,&liwork,&info)
callprotoargument char*,char*,char*,F_INT*,<ctype2c>*,F_INT*,<ctype2>*,<ctype2>*,F_INT*,F_INT*,<ctype2>*,F_INT*,<ctype2>*,<ctype2c>*,F_INT*,F_INT*,<ctype2c>*,F_INT*,<ctype2>*,F_INT*,F_INT*,F_INT*,F_INT*
<ftype2c> intent(in,copy,aligned8),check(shape(a,0)==shape(a,1)),dimension(n,n) :: a
integer optional,intent(in),check(compute_v==1||compute_v==0):: compute_v = 1
character optional,intent(in),check(*range=='A'||*range=='V' ||*range=='I') :: range='A'
integer optional,intent(in),check(lower==0||lower==1) :: lower = 0
integer optional,intent(in),check(il>=1&&il<=n),depend(n) :: il=1
integer optional,intent(in),check(n>=iu&&iu>=il),depend(n,il) :: iu=n
<ftype2> optional,intent(in) :: vl=0.0
<ftype2> optional,intent(in),check(vu>vl),depend(vl) :: vu=1.0
<ftype2> intent(in) :: abstol=0.0
integer optional,intent(in),depend(n),check(lwork>=max(2*n,1)||lwork==-1) :: lwork=max(2*n,1)
integer optional,intent(in),depend(n),check(lrwork>=max(24*n,1)||lrwork==-1) :: lrwork=max(24*n,1)
integer optional,intent(in),depend(n),check(liwork>=max(1,10*n)||liwork==-1):: liwork= max(1,10*n)
integer intent(hide),depend(a) :: n=shape(a,0)
integer intent(hide),depend(n) :: lda=max(1,n)
integer intent(hide),depend(z) :: ldz=max(1,shape(z,0))
<ftype2c> intent(hide),dimension(lwork),depend(lwork) :: work
<ftype2> intent(hide),dimension(lrwork),depend(lrwork) :: rwork
integer intent(hide),dimension(liwork),depend(liwork) :: iwork
<ftype2> intent(out),dimension(n),depend(n) :: w
<ftype2c> intent(out),dimension((compute_v?MAX(0,n):0),(compute_v?(*range=='I'?iu-il+1:MAX(1,n)):0)),depend(n,compute_v,range,iu,il) :: z
integer intent(out) :: m
! MKL implementation has a bug that still accesses isuppz array even if
! range=='A' or range=='I' and il, iu = 1, n which is not the case for
! the reference implementation. Hence here isuppz is allocated regardless
! of the settings. It is wasteful but necessary. The bug is fixed in
! mkl 2020 update 2 and when time comes change this line with
!
! integer intent(out),dimension((compute_v?(2*(*range=='A'||(*range=='I' && iu-il+1==n)?n:0)):0)),depend(n,iu,il,range,compute_v) :: isuppz
!
integer intent(out),dimension(2*max(1,n)),depend(n) :: isuppz
integer intent(out) :: info
end subroutine <prefix2c>heevr
subroutine <prefix2c>heevr_lwork(n,lower,a,lda,vl,vu,il,iu,abstol,m,w,z,ldz,isuppz,work,lwork,rwork,lrwork,iwork,liwork,info)
! LWORK routines for (c/z)heevr
fortranname <prefix2c>heevr
callstatement (*f2py_func)("N","A",(lower?"L":"U"),&n,&a,&lda,&vl,&vu,&il,&iu,&abstol,&m,&w,&z,&ldz,&isuppz,&work,&lwork,&rwork,&lrwork,&iwork,&liwork,&info)
callprotoargument char*,char*,char*,F_INT*,<ctype2c>*,F_INT*,<ctype2>*,<ctype2>*,F_INT*,F_INT*,<ctype2>*,F_INT*,<ctype2>*,<ctype2c>*,F_INT*,F_INT*,<ctype2c>*,F_INT*,<ctype2>*,F_INT*,F_INT*,F_INT*,F_INT*
! Inputs
integer intent(in):: n
integer optional,intent(in),check(lower==0||lower==1) :: lower = 0
! Not referenced
<ftype2c> intent(hide) :: a
integer intent(hide),depend(n) :: lda = max(1,n)
<ftype2> intent(hide) :: vl=0.
<ftype2> intent(hide) :: vu=1.
integer intent(hide) :: il=1
integer intent(hide) :: iu=2
<ftype2> intent(hide) :: abstol=0.
integer intent(hide) :: m=1
<ftype2> intent(hide) :: w
<ftype2c> intent(hide) :: z
integer intent(hide),depend(n):: ldz = max(1,n)
integer intent(hide) :: isuppz
integer intent(hide) :: lwork = -1
integer intent(hide) :: lrwork = -1
integer intent(hide) :: liwork = -1
! Outputs
<ftype2c> intent(out) :: work
<ftype2> intent(out) :: rwork
integer intent(out) :: iwork
integer intent(out) :: info
end subroutine <prefix2c>heevr_work
subroutine <prefix2>syevx(compute_v,range,lower,n,a,lda,vl,vu,il,iu,abstol,w,z,m,ldz,work,lwork,iwork,ifail,info)
! DSYEVX computes selected eigenvalues and, optionally, eigenvectors
! of a real symmetric matrix A. Eigenvalues and eigenvectors can be
! selected by specifying either a range of values or a range of indices
! for the desired eigenvalues.
callstatement (*f2py_func)((compute_v?"V":"N"),range,(lower?"L":"U"),&n,a,&lda,&vl,&vu,&il,&iu,&abstol,&m,w,z,&ldz,work,&lwork,iwork,ifail,&info)
callprotoargument char*,char*,char*,F_INT*,<ctype2>*,F_INT*,<ctype2>*,<ctype2>*,F_INT*,F_INT*,<ctype2>*,F_INT*,<ctype2>*,<ctype2>*,F_INT*,<ctype2>*,F_INT*,F_INT*,F_INT*,F_INT*
integer optional,intent(in),check(compute_v==1||compute_v==0):: compute_v = 1
character optional,intent(in),check(*range=='A'||*range=='V' ||*range=='I') :: range='A'
integer optional,intent(in),check(lower==0||lower==1) :: lower = 0
integer intent(hide),depend(a) :: n=shape(a,0)
integer optional,intent(in),check(il>=1&&il<=n),depend(n) :: il=1
integer optional,intent(in),check(n>=iu&&iu>=il),depend(n,il) :: iu=n
<ftype2> optional,intent(in) :: vl=0.0
<ftype2> optional,intent(in),check(vu>vl),depend(vl) :: vu=1.0
<ftype2> optional,intent(in) :: abstol=0.0
integer optional,intent(in),depend(n),check(lwork>=1||lwork==-1) :: lwork=max(8*n,1)
<ftype2> intent(in,copy),check(shape(a,0)==shape(a,1)),dimension(n,n) :: a
integer intent(hide),depend(a) :: lda=max(1,shape(a,0))
integer intent(hide),depend(z) :: ldz=max(1,shape(z,0))
<ftype2> intent(hide),dimension(lwork),depend(lwork) :: work
integer intent(hide),dimension(5*n),depend(n) :: iwork
<ftype2> intent(out),dimension(n),depend(n) :: w
<ftype2> intent(out),dimension((compute_v?MAX(0,n):0),(compute_v?(*range=='I'?iu-il+1:MAX(1,n)):0)),depend(n,compute_v,range,iu,il) :: z
integer intent(out) :: m
integer intent(out),dimension((compute_v?n:0)),depend(compute_v,n):: ifail
integer intent(out) :: info
end subroutine <prefix2>syevx
subroutine <prefix2>syevx_lwork(lower,n,a,lda,vl,vu,il,iu,abstol,m,w,z,ldz,work,lwork,iwork,ifail,info)
! LWORK routines for (d/s)syevx
fortranname <prefix2>syevx
callstatement (*f2py_func)("N","A",(lower?"L":"U"),&n,&a,&lda,&vl,&vu,&il,&iu,&abstol,&m,&w,&z,&ldz,&work,&lwork,&iwork,&ifail,&info)
callprotoargument char*,char*,char*,F_INT*,<ctype2>*,F_INT*,<ctype2>*,<ctype2>*,F_INT*,F_INT*,<ctype2>*,F_INT*,<ctype2>*,<ctype2>*,F_INT*,<ctype2>*,F_INT*,F_INT*,F_INT*,F_INT*
integer intent(in):: n
integer optional,intent(in),check(lower==0||lower==1) :: lower = 0
<ftype2> intent(hide):: a
integer intent(hide),depend(n):: lda = MAX(1,n)
integer intent(hide):: il = 1
integer intent(hide):: iu = 0
<ftype2> intent(hide):: vl = 0.0
<ftype2> intent(hide):: vu = 1.0
<ftype2> intent(hide):: abstol = 0.0
integer intent(hide):: m
<ftype2> intent(hide):: w
<ftype2> intent(hide):: z
integer intent(hide),depend(n):: ldz = MAX(1,n)
integer intent(hide):: lwork = -1
integer intent(hide):: iwork
integer intent(hide):: ifail
<ftype2> intent(out):: work
integer intent(out):: info
end subroutine <prefix2>syevx_lwork
subroutine <prefix2c>heevx(compute_v,range,lower,n,a,lda,vl,vu,il,iu,abstol,w,z,m,ldz,work,lwork,rwork,iwork,ifail,info)
! (C/Z)HEEVX computes selected eigenvalues and, optionally, eigenvectors
! of a complex Hermitian matrix A. Eigenvalues and eigenvectors can
! be selected by specifying either a range of values or a range of
! indices for the desired eigenvalues.
callstatement (*f2py_func)((compute_v?"V":"N"),range,(lower?"L":"U"),&n,a,&lda,&vl,&vu,&il,&iu,&abstol,&m,w,z,&ldz,work,&lwork,rwork,iwork,ifail,&info)
callprotoargument char*,char*,char*,F_INT*,<ctype2c>*,F_INT*,<ctype2>*,<ctype2>*,F_INT*,F_INT*,<ctype2>*,F_INT*,<ctype2>*,<ctype2c>*,F_INT*,<ctype2c>*,F_INT*,<ctype2>*,F_INT*,F_INT*,F_INT*
integer optional,intent(in),check(compute_v==1||compute_v==0):: compute_v = 1
character optional,intent(in),check(*range=='A'||*range=='V' ||*range=='I') :: range='A'
integer optional,intent(in),check(lower==0||lower==1) :: lower = 0
integer optional,intent(in),check(il>=1&&il<=n),depend(n) :: il=1
integer optional,intent(in),check(n>=iu&&iu>=il),depend(n,il) :: iu=n
<ftype2> optional,intent(in) :: vl=0.0
<ftype2> optional,intent(in),check(vu>vl),depend(vl) :: vu=1.0
<ftype2> optional,intent(in) :: abstol=0.0
integer optional,intent(in),depend(n),check(lwork>=1||lwork==-1) :: lwork=max(2*n,1)
<ftype2c> intent(in,copy),check(shape(a,0)==shape(a,1)),dimension(n,n) :: a
integer intent(hide),depend(a) :: n=shape(a,0)
integer intent(hide),depend(a) :: lda=max(1,shape(a,0))
integer intent(hide),depend(z) :: ldz=max(1,shape(z,0))
<ftype2c> intent(hide),dimension(lwork),depend(lwork) :: work
integer intent(hide),dimension(5*n),depend(n) :: iwork
<ftype2> intent(hide),dimension(7*n),depend(n) :: rwork
<ftype2> intent(out),dimension(n),depend(n) :: w
<ftype2c> intent(out),dimension((compute_v*n),(compute_v?(*range=='I'?iu-il+1:MAX(1,n)):0)),depend(compute_v,range,n,iu,il) :: z
integer intent(out) :: m
integer intent(out),dimension(compute_v*n),depend(compute_v,n):: ifail
integer intent(out) :: info
end subroutine <prefix2c>heevx
subroutine <prefix2c>heevx_lwork(lower,n,a,lda,vl,vu,il,iu,abstol,m,w,z,ldz,work,lwork,rwork,iwork,ifail,info)
! LWORK routines for (c/z)heevx
fortranname <prefix2c>heevx
callstatement (*f2py_func)("N","A",(lower?"L":"U"),&n,&a,&lda,&vl,&vu,&il,&iu,&abstol,&m,&w,&z,&ldz,&work,&lwork,&rwork,&iwork,&ifail,&info)
callprotoargument char*,char*,char*,F_INT*,<ctype2c>*,F_INT*,<ctype2>*,<ctype2>*,F_INT*,F_INT*,<ctype2>*,F_INT*,<ctype2>*,<ctype2c>*,F_INT*,<ctype2c>*,F_INT*,<ctype2>*,F_INT*,F_INT*,F_INT*