From 6360bb932c0386ba3e3aa313827283db6175f085 Mon Sep 17 00:00:00 2001 From: Michael Orlitzky Date: Wed, 14 Nov 2012 20:36:09 -0500 Subject: [PATCH] Add docs for the c_inner_product function. --- c_inner_product.m | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/c_inner_product.m b/c_inner_product.m index ca98008..0ff7f96 100644 --- a/c_inner_product.m +++ b/c_inner_product.m @@ -1,4 +1,24 @@ function ip = c_inner_product(w, a, b, v1, v2) + ## + ## The usual inner product defined on the space of continuous + ## functions over the interval [a,b]. + ## + ## INPUT: + ## + ## * ``w`` -- The weight function. + ## + ## * ``a`` -- The left endpoint of the interval. + ## + ## * ``b`` -- The right endpoint of the interval. + ## + ## * ``v1`` -- The first vector. + ## + ## * ``v2`` -- The second vector. + ## + ## OUTPUT: + ## + ## The inner product . + ## integrand = @(x) w(x)*v1(x)*v2(x) ip = quad(integrand, a, b) end -- 2.43.2