docs: public static double price(
  			java.util.Date settlementDate,
  			java.util.Date maturityDate,
  			double coupon,
  			double yield,
  			double redemption,
  			int frequency)
  	{
  		double price = 0.0;
  
  		if(maturityDate.after(settlementDate)) {
  			price += redemption;
  		}
  
  		Calendar paymentDate = Calendar.getInstance();
  		paymentDate.setTime(maturityDate);
  		while(paymentDate.after(settlementDate)) {
  			price += coupon;
  
  			// Discount back
  			price /= 1.0 + yield / frequency;
  			paymentDate.add(Calendar.MONTH, -12/frequency);
  		}
  
  		Calendar periodEndDate = (Calendar)paymentDate.clone();
  		periodEndDate.add(Calendar.MONTH, +12/frequency);
  
  		// Accrue running period
  		double accrualPeriod = (paymentDate.getTimeInMillis() - settlementDate.getTime()) / (periodEndDate.getTimeInMillis() - paymentDate.getTimeInMillis());
  		price *= Math.pow(1.0 + yield / frequency, accrualPeriod);
  		price -= coupon * accrualPeriod;
  
  		return price;
  	}