Package com.nr.la

Examples of com.nr.la.Bandec


    // Test banmul and bandec
    System.out.println("Testing bandec and banmul");
    double[][] c = new double[50][17];
    ranmat(c);
    Bandec clu = new Bandec(c,9,7);
    ranvec(r);
    clu.solve(r,y);
    Bandec.banmul(c,9,7,y,rr);
    sbeps = 5.e15;
    localflag = maxel(vecsub(r,rr)) > sbeps;
    globalflag = globalflag || localflag;
    if (localflag) {
View Full Code Here


  public static void main(String[] args) {
    double[] a = new double[]{1.0, 2.0,2.0,4.0, -4.0, -3.0, 2.0, 4.0,5.0, 1,2,3,4,3,2,1};
    double[][] aa = NRUtil.buildMatrix(4,4, a);
    int mm1=1;
    int mm2=2;
    Bandec bdc = new  Bandec(aa, mm1,mm2);
   
    double[] b = new double[]{4.0, -4.0, -3.0,1.0};
    double[] x = new double[4];
    bdc.solve(b, x);
    System.out.println(NRUtil.toString(x));
    System.out.println(bdc.det());
   
  }
View Full Code Here

TOP

Related Classes of com.nr.la.Bandec

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.