function spF=yspSRhlin(baasi0,x,EA)
# fransfer matrix F(4,4) of the of the first order analysis 
# for a truss (Sign Convention 2)
#  Zx=F*Z0+F0
# Z0'=[U0 W0 Fi0 N0]
#  EA - axial stiffness of the element
#  baasi0 -- scaling multiplier for the displacements (i = EJ/l)
#
##=========================================================================
## This Program is written by Andres Lahe,   2009-02-14
##                    e-mail: andres.lahe@ttu.ee
## LAST MODIFIED: Andres Lahe,    2011-03-12
## Copyright (c)  2009  by Tallinn University of Technology 
##                Department of Mechanics
##                http://www.ttu.ee/
##
## This program is free software; you can redistribute it and/or
## modify it under the terms of the GNU General Public License
## as published by the Free Software Foundation; either version 2
## of the License, or (at your option) any later version.

## This program is distributed in the hope that it will be useful,
## but WITHOUT ANY WARRANTY; without even the implied warranty of
## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
## GNU General Public License for more details.

## You should have received a copy of the GNU General Public License
## along with this program; if not, write to the Free Software
## Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA.
## http://www.gnu.org/licenses/old-licenses/gpl-2.0.html
##=========================================================================
#
  i0=baasi0;
  xx=x;
 F=eye(4);
 F(1,4)=-i0*x/EA;
 F(2,3)=-xx;
 F(4,4)=-1;
#  Fsisse=[1  1  1;
#2  2  1;
#2  3  -x;
#3  3  1;
#1  4  -i0*x/EA;
#4  4  -1];
#spF=spconvert(Fsisse);
spF=sparse(F);
#
endfunction

