QPALM 1.1.2
Proximal Augmented Lagrangian method for Quadratic Programs
Functions
util.h File Reference

Detailed Description

Utility functions.

Author
Ben Hermans

This file contains some utility functions, to copy the settings, to update the solver status, to print information and to time the algorithm.

Definition in file util.h.

#include "types.h"
#include "constants.h"
+ Include dependency graph for util.h:
+ This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Functions

QPALMSettingscopy_settings (const QPALMSettings *settings)
 Copy settings creating a new settings structure. More...
 
void c_strcpy (char dest[], const char source[])
 Custom string copy to avoid string.h library. More...
 
void update_status (QPALMInfo *info, c_int status_val)
 Update solver status (value and string). More...
 
void print_header (void)
 Print the header with QPALM version number and fields. More...
 
void print_iteration (c_int iter, QPALMWorkspace *work)
 Print information about the current iteration. More...
 
void print_final_message (QPALMWorkspace *work)
 Print final message as a box with info. More...
 
void qpalm_tic (QPALMTimer *t)
 Start timer. More...
 
c_float qpalm_toc (QPALMTimer *t)
 Report time in seconds since last call to qpalm_tic. More...
 

Function Documentation

◆ c_strcpy()

void c_strcpy ( char  dest[],
const char  source[] 
)

Custom string copy to avoid string.h library.

Parameters
destDestination string
sourceSource string

Definition at line 19 of file util.c.

+ Here is the caller graph for this function:

◆ copy_settings()

QPALMSettings * copy_settings ( const QPALMSettings settings)

Copy settings creating a new settings structure.

Warning
This function uses malloc.
Parameters
settingsSettings to be copied
Returns
New settings structure

Definition at line 25 of file util.c.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ print_final_message()

void print_final_message ( QPALMWorkspace work)

Print final message as a box with info.

(Final residuals, objective function, runtime)

Parameters
workWorkspace

Definition at line 122 of file util.c.

+ Here is the call graph for this function:

◆ print_header()

void print_header ( void  )

Print the header with QPALM version number and fields.

Definition at line 108 of file util.c.

◆ print_iteration()

void print_iteration ( c_int  iter,
QPALMWorkspace work 
)

Print information about the current iteration.

(Residuals, stepsize and objective value)

Parameters
iterThe current iteration number
workWorkspace

Definition at line 114 of file util.c.

◆ qpalm_tic()

void qpalm_tic ( QPALMTimer t)

Start timer.

Parameters
tTimer object
+ Here is the caller graph for this function:

◆ qpalm_toc()

c_float qpalm_toc ( QPALMTimer t)

Report time in seconds since last call to qpalm_tic.

Parameters
tTimer object
Returns
Reported time in seconds
+ Here is the caller graph for this function:

◆ update_status()

void update_status ( QPALMInfo info,
c_int  status_val 
)

Update solver status (value and string).

Parameters
infoQPALMInfo
status_valNew status value

Definition at line 62 of file util.c.

+ Here is the call graph for this function:
+ Here is the caller graph for this function: