function urate=raw2user(rawrate) %% =========================================================================== %raw2user - Calculates the user bit-rate for ADSL given the "raw" % line rate % Parameter: rawrate The line rate before overhead in % coding and transport % % Returns: urate User bitrate % Example(s): % % Algorithmic details: % % Reference: % ETSI TM6 ADSL-EED4 %% =========================================================================== %% =========================================================================== % Copyright (C) % 2001-2002 by Forschungszentrum Telekommunikation Wien, Austria; % All rights reserved. % Description : ADSL performance simulations % % Project : B1, FTW % Author(s) : Tomas Nordstrom (Tomas.Nordstrom@FTW.at) % % CVS: $Id: raw2user.m,v 1.2 2002/06/05 15:25:33 tono Exp $ %% =========================================================================== % Change History % 2001-08-24 (ToNo) Created % 2002-03-21 (ToNo) Do not allow the rate to become negative %% =========================================================================== framingoh = 0.032; % Framing overhead of 32kbit/s rsoh = 1.13; % Read-Solomon overhead of 16% lowrateoh = 0.064; % R-S overhead of 32kbit/s + framingoh rnorm = rawrate/rsoh-framingoh; rlow = rawrate-lowrateoh; urate=min(rnorm,rlow); urate=max(0,urate);