I am starting my adventure with Mathematica. I would like to know if is there possibility to create function described by formula for example f(x):=1+2^n where 2^n < x. I have problem with this condition. I tried something like f[x_]:=(1+2^n) && (2^n< x) but probably it's wrong way. I'll be gratefull for any help
Edit:
Ok, let's take the function described by f(x)=1+2^n where n is solution of inequality 2^(-n) <= |x-1| < 2^(1-n) (n is integer) and we can define f(1)=1.
so for example f(3)=1+2^(-1) because n=-1 is solution of 2^(-n) <= |3-1| < 2^(1-n).
I'd like to create a plot of this or similar function. I tried something like: f[x_]:= 1 + 2^(n) /; n = Reduce[{2^(-n) <= Abs[ x - 1] < 2^(1 - n)}, k, Integers] but without success. I don't know how correctly put n value.
Comments
Post a Comment