Advertisement
Guest User

Untitled

a guest
Oct 15th, 2019
108
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Java 0.99 KB | None | 0 0
  1. import functions.*;
  2.  
  3. public class Main {
  4.  
  5.     public static void main(String[] args) throws InappropriateFunctionPointException {
  6.         TabulatedFunction Function;
  7.         double[] arr = {1, 0, 1, 3, 0, 4, 7};
  8.  
  9.         Function = new LinkedListTabulatedFunction(-3, 3, 3);
  10.         System.out.println("Левая граница " + Function.getLeftDomainBorder());
  11.         System.out.println("Правая граница " + Function.getRightDomainBorder());
  12.         Function.addPoint(new FunctionPoint(1.5, 5));
  13.         for (int i = 0; i < 4; i++) {
  14.             System.out.print("Точка " + (i + 1) + " x = " + Function.getPointX(i));
  15.             System.out.println("\n       " + " y = " + Function.getPointY(i));
  16.         }
  17.         Function.deletePoint(11);
  18.         for (int i = 0; i < 3; i++) {
  19.             System.out.print("Точка " + (i + 1) + " x = " + Function.getPointX(11));
  20.             System.out.println("\n       " + " y = " + Function.getPointY(i));
  21.         }
  22.  
  23.     }
  24.  
  25. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement