Question: IN JAVA PLEASE!!! IF u cant do it in french : Question 1 (40 points) In mathematics, matrices are arrays of elements that are used

 IN JAVA PLEASE!!! IF u cant do it in french :Question 1 (40 points) In mathematics, matrices are arrays of elements that

IN JAVA PLEASE!!! IF u cant do it in french :

Question 1 (40 points) In mathematics, matrices are arrays of elements that are used to interpret theoretical results of linear algebra. linear algebra. The matrices frequently used are matrices of dimension 2 that can be visually associated to a table with rows and columns. In this system, the size of the matrix is denoted by the notation m x n where m is the number of rows and n is the number of columns. In this assignment, we are going to implement in Java a 2D matrix, rather irregular, whose last elements of the last row may not exist (i.e., it is not possible to row may not exist (i.e. the last elements may be absent). Here are two examples. Here are the specifications of our implementation: - The elements are positive real numbers of type Double - The irregular matrix must be represented by a 1-dimensional array i.e. Double[] array. o To save memory, your array must just contain the existing elements. - The number of columns and the total number of elements are defined by the user o The number of rows will be sent to the command line and will be contained in args[0]. o The number of columns will be sent to the command line and will be contained in args[1] 2 o The elements will be entered one by one by the user until the user enters the number 0. For the sake of simplicity question of simplicity, Double elements will be processed with a precision of 1 digit after the comma i.e. DecimalFormat("#.0") - The toString() method of the class should return a visual representation of the matrix or empty cells should not be displayed. o Hint: You can use the StringBuffer class to hold and manipulate strings dynamically. dynamically. You are asked to complete - The MatrixRecorder class by adding : o additional attributes (if necessary) and o the required Class or Instance methods as well as the Constructor. - The TestMatrixIrreguliere class which contains the main(String[] args) function and which will construct and display the contents of our matrix. The execution of the program should "exactly" display like the model below. The result shows the execution of "java TestMatrix 3 4 " . (Other examples of executions will be attached to the assignment). You will notice the aesthetic aspect of the table where the cells have the same size and that the horizontal and vertical lines delimit the ends of the table properly. Of course, your program should work if the array contains just 1 single element, or is displayed only in one row or one column.

En mathmatiques, les matrices sont des tableaux d'lments qui servent interprter les rsultats thoriques de l'algbre linaire. Les matrices frquemment utilises sont des matrices de dimension 2 qu'on peut visuellement associer a un tableau muni de lignes et de colonnes. Dans ce systme, la taille de la matrice est dnote par la notation mn ou m est le nombre de lignes et n est le nombre de colonnes. [321540]12053846[1.60.21.0][2003.5]52232040310320001 Dans ce devoir, on va implmenter en Java une matrice en 2D, plutt irrgulire, dont les derniers lments de la dernire ligne peuvent ne pas exister (c'est--dire que les derniers lments peuvent tre absentes). En voici deux exemples. 322315420400300 Voici les spcifications de notre implmentation : - Les lments sont des nombres rels positifs de type Double - La matrice irrgulire doit tre obligatoirement reprsente par un tableau 1 dimension i.e. Double[] tableau. o Pour conomiser de la mmoire, votre tableau doit juste contenir les lments existants. - Le nombre de colonnes ainsi que le nombre total d'lments sont dfinis par l'usager o Le nombre de lignes sera envoy la ligne de commande et sera contenu dans args[0] o Le nombre de colonnes sera envoy la ligne de commande et sera contenu dans args[1] o Les lments seront saisis un par un par l'usager jusqu' ce que l'usager rentre le chiffre 0. Pour une question de simplicit, - Les lments Double seront traits avec une prcision de 1 chiffre aprs la virgule i.e DecimalFormat("\#.0") - La mthode toString() de la classe doit retourner une reprsentation visuelle de la matrice ou les cellules vides ne doivent pas tre affiches. o Hint : Vous pouvez utiliser la classe StringBuffer afin de contenir et manipuler des chaines de caractre de faon dynamique. On vous demande de complter - La classe Matricelrreguliere en y ajoutant : o les attributs additionnels (si ncessaire) et o les mthodes de Classe ou d'Instance requises ainsi que le Constructeur. - La classe TestMatricelrreguliere qui contient la fonction main(String[] args) et qui va construire et afficher le contenu de notre matrice. L'excution du programme doit exactement w s'afficher comme le modle ci-dessous. Le rsultat montre l'excution de java TestMatricelrreguliere 34%. (Des autres exemple d'excutions seront attachs au devoir). Vous noterez l'aspect esthtique du tableau o les cellules possdent la mme taille et que les tirs horizontaux et verticaux dlimitent convenablement les extrmits du tableau. Bien sr, votre programme doit marcher si le tableau contient juste 1 seul lment, ou s'affiche uniquement sur une seule ligne ou sur une seule colonne

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!