Ask Your Question

ajk_birdman's profile - activity

2016-10-05 20:51:45 +0200 received badge  Notable Question (source)
2016-10-05 20:51:45 +0200 received badge  Popular Question (source)
2015-04-16 09:43:38 +0200 commented question Plotting issue, number of arguments error

Thanks calc314 and sorry for the slow response.

Yep. Sagecell worked well. Soon as I deleted the brackets in "Area" it worked fine in other environments too. Not sure why they were there in the first place.

2015-04-02 19:19:22 +0200 asked a question Plotting issue, number of arguments error

Hey all,

I have a question that's probably been asked before (tough I couldn't find it here)

I'm trying to plot these two functions of d. Area is a function of d and some other functions of d. I could swear I had this code working a few months ago but now I get the error:

*File "", line 1, in <module>

  File "/tmp/tmp0fBGGb/", line 21, in <module>
    plot1 = plot(Area, R1-R2, limit, color='red')
  File "sage/symbolic/expression.pyx", line 4382, in sage.symbolic.expression.Expression.__call__ (build/cythonized/sage/symbolic/expression.cpp:24669)
  File "sage/symbolic/ring.pyx", line 760, in sage.symbolic.ring.SymbolicRing._call_element_ (build/cythonized/sage/symbolic/ring.cpp:8970)
ValueError: the number of arguments must be less than or equal to 1*

Does anyone have any ideas what this could be? (Using sageNB and 6.4.1)

var('x, y, z, R1, R2, d, a, s1, s2, Area, limit, Area2')

R1 = 6
R2 = 4

a = (1/d)*sqrt( (-d+R1+R2)*(d-R1+R2)*(d+R1-R2)*(d+R1+R2) )

s1 = (a + 2*R1)/2
s2 = (a + 2*R2)/2

limit = sqrt(R1**2 - (R2/2)**2) + (R1 - R2)

Area = [((R1**2)*arcsin(a/(2*R1))) - sqrt(s1*(s1-a)*((s1-R1)^2)) + (R2**2)*(pi - arcsin(a/(2*R2))) + sqrt(s2*(s2-a)*((s2-R2)**2))]

plot1 = plot(Area, d, R1-R2, limit, color='red')

Area2 = ((R1**2)*arcsin(a/(2*R1))) - sqrt(s1*(s1-a)*((s1-R1)^2)) + (R2**2)*(arcsin(a/(2*R2))) - sqrt(s2*(s2-a)*((s2-R2)**2))

plot2 = plot(Area2, d, limit, R1+R2, color='green')
2013-03-10 21:57:08 +0200 received badge  Supporter (source)
2013-03-10 21:39:34 +0200 asked a question Integral help cos and exp

I'm sure this integral has been seen before. I'm trying to do a convolution for optics homework. No answer returns

sage: var('x1, x2, y1, y2, L, z, r')
sage: integral(cos(x1/L)*exp(-i*(k/z)*(x1*x2 + y1*y2)), x1, -L/2, L/2)

thanks for any help!

2013-02-24 02:03:58 +0200 received badge  Editor (source)
2013-02-24 01:59:12 +0200 asked a question integral interpretation

I found an integral which sage doesn't much seem to like:

var('R, t') integral(((1/(Rt))exp(iRt)), t) it returns this: (essentially) (Ei(iRt))/R

But the two i's should just multiply out and the two R's simplify to 1. And what's 'E'? I realize the integral is divergent, and the indefinite serves my purposes, but I'm not quite sure what

Also, if anyone could point me to a thread on how to attach those nifty screenshot-like html images of a sage session (like those used in error reports, i have no idea what the right word is) into a text box like this, that would be be appreciated. Still new to computing.