First off, total abuse of the paragraph element <p>. Instead, use the folling:
HTML
<div id="subtotal-and-taxes">
<var id="subtotal">15000</var>
<var id="tax">10</var> // In percentage
<var id="discount">1000</var>
<var id="grandtotal"></var> // Grandtotal will be calculated and displayed here using jquery
<!-- or use span elements -->
</div>
CSS
#subtotal-and-taxes var {
display:block
margin-top:5px;
margin-bottom:5px;
}
Next, you can use jQeury to get references to those elements and read their contents with the html() function:
var subtotal = $("#subtotal-and-taxes #subtotal").html();
var tax = $("#subtotal-and-taxes #tax").html();
var discount = $("#subtotal-and-taxes #discount").html();
and then use non-jQuery JavaScript to calculate the value for grandtotal. Unfortunately, your equation is a little confusing so I won't spell it out for you.