How can I sell independently created software to my university? I am in a situation that I think is not uncommon nowadays. 

I wrote software on my own time, by my own decision, and with my own resources during my undergrad career at a university in the US, and now I want to be monetarily compensated for it because my software is used on a regular basis by a department in the university. I have heard of a couple cases where a student wrote a program that he/she thought would be helpful to the university in some way, after which they purchased it because they also thought it was valuable. 

I want to go through the same thing, but the head of the department seems to refuse to pay (or at least say they are unable to pay for it). They claim it was a "senior project" even though that is not true, but somehow that means they can't pay for it. I think the intellectual property and my work that went into the software is worth money, so I feel I should be compensated. 

Since that department is already using it and finds it valuable, shouldn't they pay for the product? If they completely refuse, is it smart to take the software away? 

EDIT for clarification:
Nothing has been signed. There have been no agreements written on paper that determine who has ownership. We have only spoken about this. 

As a "trial period" I gave them the software's source so they could use it while I was away (because I graduated and moved away) and so I could make updates to the code. This was not a senior project. My work on this project had nothing to do with the university while I was writing it. The only relevance was that I intended to have it be used by the people at the university once it was finished.
I would suggest a different tactic altogether:
Give them a license to use the software as well as any and all updates for free. Support should not be free but done by others under your instruction. In return ask them to sign over any previously perceived ownership of intellectual property. Next ask that they help you by providing suggestions for improvements to your software. Sell it to every other university in the world.