function [ icc, ccc, acc, ncc, n ] = ccs_read ( prefix )

%*****************************************************************************80
%
%% ccs_read() reads data about a sparse matrix in CCS format.
%
%  Discussion:
%
%    Three files are presumed to exist:
%    * prefix_icc.txt contains NCC ICC values;
%    * prefix_ccc.txt contains N+1 CCC values;
%    * prefix_acc.txt contains NCC ACC values.
%
%  Licensing:
%
%    This code is distributed under the MIT license.
%
%  Modified:
%
%    08 June 2022
%
%  Author:
%
%    John Burkardt
%
%  Input:
%
%    string PREFIX, a common prefix for the filenames.
%
%  Output:
%
%    integer ICC(NCC), the rows.
%
%    integer CCC(N+1), the compressed columns.
%
%    real ACC(NCC), the values.
%
%    integer NCC, the number of elements.
%
%    integer N, the number of columns in the matrix.
%
  filename_icc = strcat ( prefix, '_icc.txt' );
  icc = load ( filename_icc );

  filename_ccc = strcat ( prefix, '_ccc.txt' );
  ccc = load ( filename_ccc );

  filename_acc = strcat ( prefix, '_acc.txt' );
  acc = load ( filename_acc );

  ncc = length ( icc );
  n = length ( ccc ) - 1;

  return
end
