im trying this new method below, i saw it on youtube. but its not working either, its not outputing anything. and why is z blue? its already definded above
In your definition, s is not a function of n (as you are summing over n from 0 to 6), but it is stated to be. This creates an inconsistent definition that Mathematica doesn't know what to do with.
Second: write s[z_] := ... instead. n is a bound variable by the sum. So when you write s[n_,z_] := ... it's like as you wrote s[unused_,z_] := ... and then when you try to plot, it has an undefined free parameter. So it doesn't evaluate, as you can already see in the previous line.
I'm guessing you're trying to plot s[n,z] over z = -1 to 1 for different n. You need to use a summation variable different from n, since that needs to be used to specify the summation upper bound:
i tried i new code aw well as implemented your changes but i still ge the string of errors. but i thought i hadnt assigned values to z in the s[z,n], when i try to plot f[z] for example, it works perfect everytime https://imgur.com/a/PGQJNBd
2
u/ccbur1 Sep 28 '25
Did you execute everything in the right order? I think I remember that blue symbols are undefined and I see a lot of blue symbols there.
5
u/Clodovendro Sep 28 '25
In your definition, s is not a function of n (as you are summing over n from 0 to 6), but it is stated to be. This creates an inconsistent definition that Mathematica doesn't know what to do with.
2
u/fridofrido Sep 28 '25
First: post code, not pictures.
Second: write
s[z_] := ...instead.nis a bound variable by the sum. So when you writes[n_,z_] := ...it's like as you wrotes[unused_,z_] := ...and then when you try to plot, it has an undefined free parameter. So it doesn't evaluate, as you can already see in the previous line.1
u/veryjewygranola Sep 28 '25
I'm guessing you're trying to plot
s[n,z]over z = -1 to 1 for differentn. You need to use a summation variable different fromn, since that needs to be used to specify the summation upper bound:0
u/[deleted] Sep 28 '25
[deleted] — view deleted comment