Home > manopt > manifolds > ttfixedrank > TTeMPS_1.1 > @TTeMPS_block > truncate.m

truncate

PURPOSE ^

ROUND Approximate TTeMPS tensor within a prescribed tolerance.

SYNOPSIS ^

function x = round( x, r )

DESCRIPTION ^

ROUND Approximate TTeMPS tensor within a prescribed tolerance.
   X = ROUND( X, tol ) truncates the given TTeMPS tensor X to a
   lower rank such that the error is in order of tol.

CROSS-REFERENCE INFORMATION ^

This function calls: This function is called by:

SOURCE CODE ^

0001 function x = round( x, r )
0002     %ROUND Approximate TTeMPS tensor within a prescribed tolerance.
0003     %   X = ROUND( X, tol ) truncates the given TTeMPS tensor X to a
0004     %   lower rank such that the error is in order of tol.
0005 
0006     %   TTeMPS Toolbox.
0007     %   Michael Steinlechner, 2013-2016
0008     %   Questions and contact: michael.steinlechner@epfl.ch
0009     %   BSD 2-clause license, see LICENSE.txt
0010     
0011     y = TTeMPS_block_to_TTeMPS( x );
0012     y = truncate(y , r);
0013     x = TTeMPS_block.TTeMPS_to_TTeMPS_block( y, x.mu, x.p );
0014 
0015 end

Generated on Fri 30-Sep-2022 13:18:25 by m2html © 2005