NAME

copy_vector_segment - Copies part of a vector

SYNOPSIS

#include "m/m_vec_basic.h"

Example compile flags (system dependent):
  -DLINUX_386 -DLINUX_386_P4  
   -I/home/kobus/include
   -L/home/kobus/load/linux_386_p4 -L/usr/local/lib -L/usr/lib
  -lKJB         -llapack -lblas -lg2c          -lXext -lX11 


int copy_vector_segment
(
	Vector **target_vpp,
	const Vector *source_vp,
	int start_index,
	int length
);

DESCRIPTION

This routine copies part of the vector pointed to by source_vp to the vector pointer to by *target_vp. If *target_vp is NULL, then it is created. If it is the wrong size, it is resized. The copying begins at start_index, and goes on for the specified length.

RETURNS

On success, this routine returns a pointer to a newly created vector which is a copy of the input vector. On failure, it returns NULL, and sets an error message. Currently this routine can only fail if storage allocation fails.

DISCLAIMER

This software is not adequatedly tested. It is recomended that results are checked independantly where appropriate.

AUTHOR

Kobus Barnard

DOCUMENTOR

Kobus Barnard

SEE ALSO

split_v4 , split_vector_vector , split_vector , copy_v4 , copy_v3 , copy_indexed_vector , create_vector_copy , select_from_vector_vector , copy_vector_vector , copy_vector , ow_copy_vector