|
3D-ICE 3.0.0
|
#include "types.h"#include "string_t.h"#include "floorplan_element_list.h"#include "dimensions.h"Go to the source code of this file.
Data Structures | |
| struct | FloorplanMatrix_t |
| Structure representing the matrix storing the coefficients of the floorplans tha scales power values to sources. More... | |
Typedefs | |
| typedef struct FloorplanMatrix_t | FloorplanMatrix_t |
Functions | |
| void | floorplan_matrix_init (FloorplanMatrix_t *flpmatrix) |
| void | floorplan_matrix_copy (FloorplanMatrix_t *dst, FloorplanMatrix_t *src) |
| Error_t | floorplan_matrix_build (FloorplanMatrix_t *flpmatrix, CellIndex_t nrows, CellIndex_t ncolumns, CellIndex_t nnz) |
| void | floorplan_matrix_destroy (FloorplanMatrix_t *flpmatrix) |
| void | floorplan_matrix_fill (FloorplanMatrix_t *flpmatrix, FloorplanElementList_t *list, Dimensions_t *dimensions) |
| void | floorplan_matrix_multiply (FloorplanMatrix_t *flpmatrix, Source_t *x, Source_t *b) |
| void | floorplan_matrix_print (FloorplanMatrix_t flpmatrix, String_t file_name) |
| typedef struct FloorplanMatrix_t FloorplanMatrix_t |
Definition of the type FloorplanMatrix_t
Definition at line 101 of file floorplan_matrix.h.
| Error_t floorplan_matrix_build | ( | FloorplanMatrix_t * | flpmatrix, |
| CellIndex_t | nrows, | ||
| CellIndex_t | ncolumns, | ||
| CellIndex_t | nnz | ||
| ) |
Allocates memory to store indexes and coefficients of a FloorplanMatrix
| flpmatrix | the address of the floorplan matrix |
| nrows | the number of rows of the matrix |
| ncolumns | the number of columns of the matrix |
| nnz | the number of nonzeroes coeffcients |
TDICE_SUCCESS if the memory allocation succeded TDICE_FAILURE if the memory allocation fails Definition at line 86 of file floorplan_matrix.c.
| void floorplan_matrix_copy | ( | FloorplanMatrix_t * | dst, |
| FloorplanMatrix_t * | src | ||
| ) |
Copies the structure src into dst , as an assignement
The function destroys the content of dst and then makes the copy
| dst | the address of the left term sructure (destination) |
| src | the address of the right term structure (source) |
Definition at line 58 of file floorplan_matrix.c.
| void floorplan_matrix_destroy | ( | FloorplanMatrix_t * | flpmatrix | ) |
Destroys the content of the fields of the structure flpmatrix
The function releases any dynamic memory used by the structure and resets its state calling floorplan_matrix_init .
| flpmatrix | the address of the structure to destroy |
Definition at line 126 of file floorplan_matrix.c.
| void floorplan_matrix_fill | ( | FloorplanMatrix_t * | flpmatrix, |
| FloorplanElementList_t * | list, | ||
| Dimensions_t * | dimensions | ||
| ) |
Fills the floorplan matrix
The function fills, floorplan element by floorplan element, all the columns of the floorplan matrix.
| flpmatrix | pointer to the floorplan matrix to fill |
| list | pointer to the list of floorplan elements |
| dimensions | the address of the dimension structure |
Definition at line 145 of file floorplan_matrix.c.
| void floorplan_matrix_init | ( | FloorplanMatrix_t * | flpmatrix | ) |
Inits the fields of the flpmatrix structure with default values
| flpmatrix | the address of the structure to initalize |
Definition at line 46 of file floorplan_matrix.c.
| void floorplan_matrix_multiply | ( | FloorplanMatrix_t * | flpmatrix, |
| Source_t * | x, | ||
| Source_t * | b | ||
| ) |
Performs a Matrix-Vector Multiplication x = Ab
The multiplication corresponds to the routine DGEMV y := alpha * A* x + beta * y where alpha = 1.0 and beta = 1.0 .
| flpmatrix | pointer to the (floorplan) matrix A |
| x | pointer to the output vector x |
| b | pointer to the input vector b |
Definition at line 227 of file floorplan_matrix.c.
| void floorplan_matrix_print | ( | FloorplanMatrix_t | flpmatrix, |
| String_t | file_name | ||
| ) |
Generates a text file storing the sparse matrix
The file will contain one row of the form row-column-value" for each zero coefficient (COO format). The first row (or column) has index 1 (matlab compatibile)
| flpmatrix | the floorplan matrix structure |
| file_name | the name of the file to create |
Definition at line 259 of file floorplan_matrix.c.