plotting complicated function
I would like to approximate the sum h(a,x)=−2nn−1∑n=0log|Tna(x)|
By fixing x to be a value x0∈(0,1), e.g. x0=1/π, h(a,x0)=h(a,1/π)
I figure how to calculate the value at one given a using SageMath, for example, when a=1,
T(x) = 1/x - floor(1/x)
s = 0
for k in xrange(0, 1000):
a = 0
a = nest(T, k, 0.79)
b = abs(a)
c = log(b)
s = s + c
Then −21000s give the approximation for the sum when x=0.79, n=1000, a=1.
But for plotting, I think I need to define the function h(a,x) which is a summation over composition of functions. I tried to use sum
and symbolic_sum
but failed.
Any help how to achieve this please?
I suspect that you want to write |Ta(x)|k instead of Tna(x), right? Otherwsie, what means Tn here?
@Masacroso: it means the function Ta is applied n times. For example, T2a(x)=Ta(Ta(x)).
well, in first place note that Ta(x)=x−1−⌊⌊x−1⌋+{x−1}−r⌋={x−1}−⌊{x−1}−r⌋={x−1}+[r>{x−1}]
In that branch of mathematics, it's usual to study functions that are defined only almost everywhere. The set of measure zero where they are not defined is just disregarded and "does not matter". Of course, when experimenting with a computer, it can turn out to matter.