File numerics/src/FrictionContact/FrictionContactProblem.h#

Go to the source code of this file

Definition of a structure to handle friction-contact (2D or 3D) problems.

Functions

FrictionContactProblem *frictionContactProblem_new(void)#
FrictionContactProblem *frictionContactProblem_new_with_data(int dim, int nc, NumericsMatrix *M, double *q, double *mu)#

new FrictionContactProblem from minimal set of data

Parameters:
  • dim[in] the problem dimension

  • nc[in] the number of contact

  • M[in] the NumericsMatrix

  • q[in] the q vector

  • mu[in] the mu vector

Returns:

a pointer to a FrictionContactProblem structure

void frictionContactProblem_free(FrictionContactProblem *problem)#

free a FrictionContactProblem

Parameters:

problem – the problem to free

void frictionContact_display(FrictionContactProblem *problem)#

display a FrictionContactProblem

Parameters:

problem – the problem to display

int frictionContact_printInFile(FrictionContactProblem *problem, FILE *file)#

print a FrictionContactProblem in a file (numerics .dat format)

Parameters:
  • problem – the problem to print out

  • file – the dest file

Returns:

0 if successfull

int frictionContact_printInFilename(FrictionContactProblem *problem, char *filename)#

print a FrictionContactProblem in a file (numerics dat format)

Parameters:
  • problem – the problem to print out

  • filename – the dest file

Returns:

0 if successfull

FrictionContactProblem *frictionContact_newFromFile(FILE *file)#

read a FrictionContactProblem from a file descriptor

Parameters:

file – descriptor

Returns:

problem the problem to read

FrictionContactProblem *frictionContact_new_from_filename(const char *filename)#

read a FrictionContactProblem from a file (.dat or hdf5 if fclib is on) from its filename

Parameters:

filename – the name of the input file

Returns:

problem the problem to read

void createSplittedFrictionContactProblem(FrictionContactProblem *problem, SplittedFrictionContactProblem *splitted_problem)#
void frictionContactProblem_compute_statistics(FrictionContactProblem *problem, double *reaction, double *velocity, double tol, int do_print)#
FrictionContactProblem *frictionContact_copy(FrictionContactProblem *problem)#

Creates a new FrictionContact problem and initialize its content by copying an existing problem.

Parameters:

problem – the source problem to be copied

Returns:

a pointer to a new FrictionContactProblem

void frictionContact_rescaling(FrictionContactProblem *problem, double alpha, double gamma)#

Rescales M matrix and q vector of a given FrictionContactProblem.

\[ :math:`M = \alpha\gamma^2 M, q=\alpha\gamma q` \]

Parameters:
  • problem – to be rescaled

  • alpha – rescaling factor

  • gamma – rescaling factor

struct FrictionContactProblem#
#include <FrictionContactProblem.h>

The structure that defines a (reduced or dual) Friction-Contact (3D or 2D) problem.

Public Members

int dimension#

dimension of the contact space (3D or 2D )

int numberOfContacts#

the number of contacts \( n_c \)

RawNumericsMatrix *M#

\( {M} \in {{\mathrm{I\!R}}}^{n \times n} \), a matrix with \( n = d n_c \) stored in NumericsMatrix structure

double *q#

\( {q} \in {{\mathrm{I\!R}}}^{n} \)

double *mu#

\( {\mu} \in {{\mathrm{I\!R}}}^{n_c} \), vector of friction coefficients ( \( n_c = \) numberOfContacts)

struct SplittedFrictionContactProblem#

Public Members

FrictionContactProblem *fc3d#
NumericsMatrix *M_nn#
NumericsMatrix *M_tn#
NumericsMatrix *M_nt#
NumericsMatrix *M_tt#
double *q_n#
double *q_t#