Changeset 786 in Sophya
- Timestamp:
- Mar 16, 2000, 7:37:04 PM (26 years ago)
- Location:
- trunk/SophyaProg/Tests
- Files:
-
- 1 added
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/SophyaProg/Tests/lpk.cc
r778 r786 29 29 for(j=0; j<n; j++) a(i,j,0) = GauRnd(0., 1.); 30 30 31 TArray<r_4> x(1,n), b( 1,n);31 TArray<r_4> x(1,n), b(n,n); 32 32 r_4 sum ; 33 33 for(i=0; i<n; i++) x(0,i,0) = GauRnd(2., 1.5); … … 57 57 } 58 58 59 try {60 cout << "\n -----> Testing TArray <---- " << endl;61 TArray<int_4> ia(6,4);62 TArray<int_4> ib(2,3);63 Sequence seq(10., 2.);64 ia = seq;65 ib = 5;66 cout << " ----- matrix IA = \n " << ia << endl;67 cout << " ----- matrix IB = \n " << ib << endl;68 uint_4 pos[5];69 uint_4 sz[5];70 pos[0] = 3; pos[1] = 1;71 sz[0] = 3; sz[1] = 2;72 TArray<int_4> ic = ia.SubArray(2, sz, pos);73 cout << " ----- matrix IC IA(3,2,3,1) = \n " << ic << endl;74 ic = 0;75 cout << " ----- matrix IA = \n " << ia << endl;76 }77 catch (PThrowable exc) {78 cerr << " catched Exception " << exc.Msg() << endl;79 }80 catch (...) {81 cerr << " catched unknown (...) exception " << endl;82 }83 59 cout << " --------------- END of Programme -------------- " << endl; 84 60 }
Note:
See TracChangeset
for help on using the changeset viewer.