Need C code for Least Squares Matrix, ODEs

Greetings-

I am looking for ANSI C code for two applications.

(1) Least Squares Matrix- takes a real matrix H and forms G=inverse(H'H)*H'

Ideally I would just pass the routine the matrix dimensions and pointers

to H and G.

(2) ODE solver- solves ordinary differential equations of the form

x'' + ax' + bx = u(t)

where a and b are constants and u(t) is an arbitrary function of time

OR

solves a system of 2 coupled first-order ODEs with constant coefficients

Since this is a pretty simple ODE I'm hoping there is a routine out

there which uses default values for step sizes and such, i.e. I don't

have to muck about with parameters too much. Of course, if I have to,

I have to...

I've poked around netlib.att.com some but haven't found anything that's

quite right. Maybe I need to look harder, but if anyone has any pointers,

especially to specific code, it would be a lifesaver. These are pretty

simple computations, so I'll bet there's good code out there somewhere, and

I'd like to avoid writing this myself. Thanks a million.

Bill Moore