#include "adaptivityt.h"#include "globalt.h"#include "globmatt.h"#include "elemswitcht.h"Go to the source code of this file.
Functions | |
| long | closest_node (gtopology *gt, long dim, double x, double y, double z) |
| !!!! toto narvat do gtopology pod dohledem JKTK !!!!!!!!!!!!!!! | |
| double | distance2 (double *a, double *b, long dim) |
| void | findout_parentel_nod (gtopology *gt_old, gtopology *gt_new, long dim, long *parentel) |
| void | give_valuesinpoints (gtopology *gt, long eid, long npoints, double *xx, double *yy, long nval, const double *nodvalues, double **pointval, bool pvmtrx) |
| bool | isnodonlhsof3pcurve (gnode &n1, gnode &n2, gnode &n3, double xx, double yy) |
| bool | isnodonlhsofline (gnode &n1, gnode &n2, double xx, double yy) |
| long | ispointinel (gnode *nod, long *elnod, double x, double y, long ndd) |
| void | transfvalues_nod (gtopology *gt_old, gtopology *gt_new, const double *r_old, double *r_new, long *parentel, long dim, long ndofn, bool spr) |
| long | whereispoint (gtopology *gt, long nsusel, long *susel, long *newsusel, long *passedel, double x, double y, long rep) |
| long | whereispoint_outpoint (gtopology *gt, long dim, double x, double y, double z) |
| long closest_node | ( | gtopology * | gt, | |
| long | dim, | |||
| double | x, | |||
| double | y, | |||
| double | z | |||
| ) |
!!!! toto narvat do gtopology pod dohledem JKTK !!!!!!!!!!!!!!!
Function finds closest node to 'point'. The point is defined by coordinates x,y.
| dim | - dimension of solved problem | |
| x,y | - coordinates of the 'point' |
| - | number of closest node |
created 11.12.2003, Ladislav Svoboda, termit@cml.fsv.cvut.cz
Definition at line 474 of file adaptivityt.cpp.
References dist(), gnode::distance2(), gtopology::gnodes, and gtopology::nn.
Referenced by findout_parentel_nod(), and whereispoint_outpoint().
| double distance2 | ( | double * | a, | |
| double * | b, | |||
| long | dim | |||
| ) |
Definition at line 645 of file adaptivityt.cpp.
References print_err().
Referenced by whereispoint_outpoint().
For every node (from new mesh) function finds out "parent" element (from old mesh), in which the "new" node lays.
| gt_old | - gtopology of old mesh | |
| gt_new | - gtopology of new mesh | |
| parentel | - answer = allocated array of parent elements, size is mt_new->nn |
created 4.12.2002, Ladislav Svoboda, termit@cml.fsv.cvut.cz
Definition at line 704 of file adaptivityt.cpp.
References ivector::a, imatrix::a, gtopology::adjelnod, allocm(), closest_node(), copyv(), fillv(), for(), gtopology::gelements, gtopology::gnodes, gtopology::nadjelnod, gtopology::ne, gtopology::nn, gelement::nne, nod, gelement::nodes, nullv(), whereispoint(), whereispoint_outpoint(), gnode::x, gnode::y, and gnode::z.
| void give_valuesinpoints | ( | gtopology * | gt, | |
| long | eid, | |||
| long | npoints, | |||
| double * | xx, | |||
| double * | yy, | |||
| long | nval, | |||
| const double * | nodvalues, | |||
| double ** | pointval, | |||
| bool | pvmtrx | |||
| ) |
Function approximates 'values' from nodes into 'points'. All the point lays in 'element', which is determined by 'gt' and 'eid'. Values in points are returned by array pointval.
| npoints | - number of points | |
| xx | - array of x-coordinates of points, size is npoints | |
| yy | - array of y-coordinates of points, size is npoints | |
| nval | - number of values | |
| nodvalues | - 1D array of values in nodes, size is nval*gt->nn, value position in array is (val[0] on nod[0] ... val[0] on nod[gt->nn] ... val[nval] on nod[0] ... val[nval] on nod[gt->nn]) | |
| pointval | - answer = 2D array, size is npoints*nval | |
| pvmtrx | - true == pointval is matrix; false == pointval is vector |
created 7.12.2002, Ladislav Svoboda, termit@cml.fsv.cvut.cz
Definition at line 765 of file adaptivityt.cpp.
References vector::a, allocv(), gelement::auxinf, bf_lin_3_2d(), bf_lin_4_2d(), bf_quad_3_2d(), bf_quad_4_2d(), gtopology::gelements, gtopology::give_node_coord2d(), gtopology::give_nodes(), nc_lin_3_2d(), nc_lin_4_2d(), nc_quad_3_2d(), nc_quad_4_2d(), gtopology::nn, gelement::nne, nodes, nodval(), print_err(), and scprd().
Function finds out, whether point (xx,yy) lays on the left hand side of the curve defined by three nodes n1,n2 and n3.
created 3.12.2002, Ladislav Svoboda, termit@cml.fsv.cvut.cz
Definition at line 515 of file adaptivityt.cpp.
References isnodonlhsofline(), gnode::x, and gnode::y.
Referenced by ispointinel().
Function finds out, whether point (xx,yy) lays on the left hand side of the line defined by two nodes n1 and n2.
created 3.12.2002, Ladislav Svoboda, termit@cml.fsv.cvut.cz
Definition at line 499 of file adaptivityt.cpp.
References gnode::x, and gnode::y.
Referenced by isnodonlhsof3pcurve(), and ispointinel().
| long ispointinel | ( | gnode * | nod, | |
| long * | elnod, | |||
| double | x, | |||
| double | y, | |||
| long | ndd | |||
| ) |
Function finds out, whether 'node' lays in 'element'. Node is defined by its coordinates - x,y. Element is defined by its node numbers - 'elnod' and dimdegnne - 'ndd'
| nod | - array of all gnodes | |
| elnod | - array of node numbers of element | |
| x,y | - coordinates of node | |
| ndd | - nnedimdeg of element |
created 3.12.2002, Ladislav Svoboda, termit@cml.fsv.cvut.cz
Definition at line 556 of file adaptivityt.cpp.
References isnodonlhsof3pcurve(), isnodonlhsofline(), and print_err().
Referenced by whereispoint(), and whereispoint_outpoint().
| void transfvalues_nod | ( | gtopology * | gt_old, | |
| gtopology * | gt_new, | |||
| const double * | r_old, | |||
| double * | r_new, | |||
| long * | parentel, | |||
| long | dim, | |||
| long | ndofn, | |||
| bool | spr | |||
| ) |
Function transforms values from nodes of old mesh into nodes of new mesh.
| po | - problem of old mesh | |
| pn | - problem of new mesh | |
| lcid | - id of load case | |
| dim | - dimension of solved problem | |
| ndofn | - number of DOFs in node | |
| parentel | - array of parent (old)elements of new mesh nodes, size is p_new->mt->nn | |
| spr | created 7.12.2002, Ladislav Svoboda, termit@cml.fsv.cvut.cz |
CHILD NODES AT OLD ELEMENTS
ALLOCATION
transformation from r_old to r_new
Definition at line 819 of file adaptivityt.cpp.
References vector::a, allocv(), destrm(), give_valuesinpoints(), gtopology::gnodes, memset(), gtopology::ne, gtopology::nn, print_err(), gnode::x, and gnode::y.
| long whereispoint | ( | gtopology * | gt, | |
| long | nsusel, | |||
| long * | susel, | |||
| long * | newsusel, | |||
| long * | passedel, | |||
| double | x, | |||
| double | y, | |||
| long | rep | |||
| ) |
Function finds out element including "point". First of all, the elements in 'susel' are investigated.
| gt | - gtopology, where the element is finding out | |
| nsusel | - number suspected elements | |
| susel | - array of suspected elements, size is gt->ne | |
| newsusel | - empty array, size is gt->ne | |
| passedel | - zero !!!!! array, size is gt->ne | |
| x,y | - coordinates of point |
created 3.12.2002, Ladislav Svoboda, termit@cml.fsv.cvut.cz
point is in susel array
Definition at line 613 of file adaptivityt.cpp.
References gtopology::adjelel, gelement::auxinf, gtopology::gelements, gtopology::gnodes, ispointinel(), gtopology::nadjelel, gelement::nodes, print_err(), and whereispoint().
| long whereispoint_outpoint | ( | gtopology * | gt, | |
| long | dim, | |||
| double | x, | |||
| double | y, | |||
| double | z | |||
| ) |
Function finds out element including "point" or element closest to "point" in case the point doesnot lay in domain.
| dim | - dimension of solved problem | |
| gt | - gtopology, where the element is finding out | |
| x,y | - coordinates of point |
created 11.12.2003, Ladislav Svoboda, termit@cml.fsv.cvut.cz
Definition at line 664 of file adaptivityt.cpp.
References gtopology::adjelnod, gelement::auxinf, gelement::centroid(), closest_node(), dist(), distance2(), gtopology::gelements, gtopology::gnodes, ispointinel(), gtopology::nadjelnod, and gelement::nodes.
Referenced by findout_parentel_nod().
1.6.2