« first day (1864 days earlier)      last day (2610 days later) » 

3:23 AM
Hello -- I was wondering why this function isn't showing anything up in mathematica.
ParametricPlot3D[{(2.5+1.5 cos[v]) cos[v/2],(2.5+1.5 cos[v]) sin[v/2],1.5 sin[v]},{v,0,2 [Pi]}]
 
3:40 AM
@HighMans What is cos and sin?
 
The trig functions
Cosine and sine
 
@HighMans Nope, they are not.
 
Oh -- I see now.
They need to be captalized.
*capatalized
 
@HighMans :)
 
Thanks! :)
 
3:45 AM
@HighMans What is 2[Pi]?
 
That as well -- I didn't notice that...
 
@HighMans [..] are always for calling a function.
 
I got it now! Awesome :)
Thanks a lot.
 
@HighMans No problem.
 
4:00 AM
One last quick question. To calculate the arc length of the function I use this formula. ArcLength[{(2.5+1.5 Cos[v]) Cos[v/2],(2.5+1.5 Cos[v]) Sin[v/2],1.5 Sin[v]},{v,0,2*Pi}]/Pi

Is it possible to get an exact result instead of an approximation?
 
4:11 AM
@HighMans Yes, usually it is. The problem is that you used approximate numbers like 2.5
Unfortunately the integrals seem to be too complicated.
 
Erm. Do I need to use 3/2 instead?
Oh okay.
 
The way to do it is:
expr = Rationalize[{(2.5 + 1.5 Cos[v]) Cos[v/2], (2.5 + 1.5 Cos[v]) Sin[v/2], 1.5 Sin[v]}]
ArcLength[expr, {v, 0, 2*Pi}]/Pi
and you get:
 
Oh okay, thanks again!
 
Which is of no help because I'm sure you are interested in the analytical solution of this integral.
 
Yes haha
 
4:14 AM
Maybe you have luck with a coordinate transform.
 
Hm. Maybe let me try that out
 
@HighMans This looks very much like it could be better represented in spherical coordinates.
@HighMans Maybe, maybe not:
 
Er... Hahaha
 
4:43 AM
@HighMans Still here?
OK, too late...
 
5:19 AM
Yes I am
The question is whether or not you're still there @halirutan
 
@HighMans Yep.
 
What's up?
 
Look:
 
Where?
 
one sec.
need to copy everything
expr = Rationalize[{(2.5 + 1.5 Cos[v]) Cos[v/2], (2.5 + 1.5 Cos[v]) Sin[v/2], 1.5 Sin[v]}]
e1 = FullSimplify[#.# &@(D[#, v] & /@ expr), v > 0]
e1 is the expression that is under the root in arclength
 
5:26 AM
Okay, let me run it
 
I mean e1 is the sum of the squares in
 
e1 is the sum of the derivatives of the components squared?
 
After this, you can calculate the analytical integral with
int = Integrate[Sqrt[e1], v];
@HighMans Yes.
 
Okay one second here
It's running -- I plugged the bounds in
 
@HighMans No, don't plug in bounds. Calculating an indefinite integral is easier that calculating the definite one.
That is the problem as I will explain in a second.
 
5:31 AM
Well, it did calculate the indefinite integral -- it's a holy mess though
 
@HighMans Yes.
Usually you would now calculate int at 2Pi minus int at 0, right?
 
Yse
*Yes
 
@HighMans We have a problem here. Lets look at a plot of int (real and imaginary part)
 
Okay
 
As you see, the imaginary part is constant. so when we calculate int[2Pi]-int[0] it would vanish.
But, and this is a big but, because the real part is so messed up, you cannot simply calculate int[2Pi]-int[0]
 
5:34 AM
Yeah, it isn't defined between 0 and 2pi
 
I would just give the wrong result.
 
Analytically?
 
But we see that it is OK between 0 and 1.5, yes?
 
Yes
 
@HighMans Lets try this:
Subtract @@ (int /. {{v -> 1.5}, {v -> 0.}})
 
5:36 AM
Erm okay.
 
gives 3.46249 with a almost zero imaginary part.
Compare it to
In[11]:= ArcLength[expr, {v, 0, 1.5}]

Out[11]= 3.46249
@HighMans So the real problem is not integration, but calculating the definite integral.
 
Hm. I see now, I see how this is an issue.
 
This is why Mathematica chokes when you want to calculate this from 0 to 2Pi
 
When I use the arclength function in mathematica does it give me the correct result?
 
I don't know much about calculating definite integrals, but I know that it is one of the hardest tasks for a computer algebra system.
@HighMans Yes. This here
In[12]:= ArcLength[expr, {v, 0., 2 Pi}]

Out[12]= 12.5426
is correct.
 
5:39 AM
I'm assuming it doesn't use the definite integral to calculate the arc length then?
 
@HighMans We can easily show this:
In[13]:= NIntegrate[Sqrt[e1], {v, 0, 2 Pi}]

Out[13]= 12.5426
 
So it is using numerical analysis.
This is so interesting.
 
@HighMans You have to understand that calculating the integral with a numerical algorithm is very easy.
(in this case)
 
I have yet to take numerical analysis.
 
@HighMans Yes. NIntegrate uses a fancy numerical summing scheme.
 
5:41 AM
Hm. This is pretty cool!
 
@HighMans I guess such a large analytical expression wouldn't be of any use anyway.
 
Yeah... No... It serves no purpose to me other than to confuse me haha
Thanks so much for showing me this! It's really neat!
 
@HighMans The last thing you have to know is that this does not mean there is no easy analytical answer. Just finding it is pretty hard.
@HighMans Eric explains this very well here
@HighMans That's what I wanted to show you.
 
Thank you :)
 
@HighMans Again, no problem. Very interesting.
 
5:43 AM
Indeed.
 
6:07 AM
@halirutan Just one last quick question...
I'm trying to plot these two equations: p2 = ParametricPlot3D[{2.5 Cos[u] + (1.5 Cos[v]*Cos[u]),
2.5 Sin[u] + (1.5 Cos[v]*Sin[u]), 1.5 Sin[v]}, {v, 0, 2 Pi}, {u, 0,
2 Pi}]


ParametricPlot3D[{(2.5 + 1.5 Cos[v]) Cos[v/2], (2.5 + 1.5 Cos[v]) Sin[
v/2], 1.5 Sin[v]}, {v, 0, 2*Pi}]
In the same plot.
 
@HighMans Show[p1,p2]
 
I did, it's saying...
Skeleton is not a graphics3d primative or directive.
 
p1 = ParametricPlot3D[{2.5 Cos[u] + (1.5 Cos[v]*Cos[u]),
    2.5 Sin[u] + (1.5 Cos[v]*Sin[u]), 1.5 Sin[v]}, {v, 0, 2 Pi}, {u,
    0, 2 Pi}];
p2 = ParametricPlot3D[{(2.5 + 1.5 Cos[v]) Cos[
      v/2], (2.5 + 1.5 Cos[v]) Sin[v/2], 1.5 Sin[v]}, {v, 0, 2*Pi}];
Show[p1, p2]
 
I must have done something wrong.
Thank you again -- this is the last of it for my HW assignment.
 
@HighMans I'm off to bed anyway. See you later.
 
 
1 hour later…
MMM
7:40 AM
Hello Everyone,
How can I set different intervals in this setting?
sol1[A_?NumericQ, phi_?NumericQ] :=
sol1[#, #] & /@ Range[Pi/2, Pi, 0.2]
say for A (0,1) and phi (Pi/2,Pi)
 
 
5 hours later…
12:21 PM
@MMM what do you mean by different intervals in this setting?
@MMM sol1[#, (Pi/2. #) + Pi/2.] & /@ Range[0, 1, .1]?
 
MMM
1:12 PM
@Kuba I want to vary A and phi simultaneously. With A in (0,1) and phi in (Pi/2,Pi).
@Kuba By setting I mean the structure I am using currently.
 
It is really annoying when someone asks a question which appears clear enough, then after getting some answers changes a major details, rendering the answers useless. mathematica.stackexchange.com/q/138534/12
This is why I immediately vote to close when a question is not clearly stated. In this case it appeared clear enough, but it wasn't the full story ...
 
@Szabolcs maybe OP could leave the question in old form and ask another one linking to this?
 
1:28 PM
Well, the other answer should be easy enough to modify to fit the new constraint. I don't want to split it now.
 
 
3 hours later…
4:35 PM
Excuse me.Do anybody know how to get "\!\(\*StyleBox[\"x\",\"style\"]\)" form x in Mathematica?
 
boxed[x_String] := "\!\(\*StyleBox[" <> x <> ",\"Section\"]\)";
boxed["test"]
 
@halirutan I mean such as a built-in method?
 
@yode Then I don't understand your question. StyleBoxes are created with Style like this
Style["test", "Section"]
 
4:55 PM
@halirutan John Fultz make a magic here,but I don't know he how to get the string "\!\(\*StyleBox[\"x\",\"style\"]\)" or "\!\(\*StyleBox[\"x\",\"style\",StripOnInput->False]\)"
@halirutan John Fultz make a magic here,but I don't know he how to get the string "\!\(\*StyleBox[\"x\",\"style\"]\)" or "\!\(\*StyleBox[\"x\",\"style\",StripOnInput->False]\)"
Or he manually input that?
 
@yode Make a new input line. Create a string ".." and just write in it. Then you can change the color of some words or make it italic or or or...
After that, select the cell and copy it and you get
"Test \!\(\*
StyleBox[\"italic\",\nFontSlant->\"Italic\"]\) and \!\(\*
StyleBox[\"underlined\",\nFontVariations->{\"Underline\"->True}]\)"
 
Related question: Do you know how to change the height of OverBar using these strings? My overbars are way too close to the symbols (try a full-height symbol, or a number), and they're hard to see
 
@BenNiehoff Unfortunately not. If you look at this, you see how an OverBar is represented in low-level boxes:
OverscriptBox[
    RowBox[{
       SuperscriptBox["x", "2"], "+",
       SuperscriptBox["y", "2"]}], "_"] // DisplayForm
So the over bar is just the underscore as second parameter.
We could try to replace the underscore with a simple bar, but then it does not overbar the whole expression anymore.
 
Well, I'm only concerned with overbar-ing a single character
but if the height is not adjustable, then there is no way to make it look right
 
@BenNiehoff Then maybe
OverscriptBox["x", "\[LongDash]"] // DisplayForm
 
5:09 PM
I don't think there is a dash-like character that is like the underscore but maybe half a letter-height higher
I've tried that, it's too high :)
 
@BenNiehoff And
OverscriptBox["x", "\[HorizontalLine]"] // DisplayForm
 
does the standard OverBar look too low on your screen? On mine it literally touches the top of the characters, if they are full height
 
@BenNiehoff Yep, here too. I don't use Mathematica for typesetting. I don't like how it looks.
 
Yeah, I don't need to use it for typesetting so much...but I need to display some things with bars over them
fortunately, at my font size (the default one!), tildes look exactly how overbars should
 
Another difficulty for me.When I see a Tutorials in Mathematica.I can get its url in the right-up corner.
 
5:13 PM
i.e., not at all correct for tildes :P
 
But when I just know the url of the Tutorials page.How to find it in our Mathematica?
 
@yode Well, that is indeed very easy.
You just take the last part of the URL. This means, from
http://reference.wolfram.com/language/tutorial/GlobalSystemInformation.html
you select the part
tutorial/GlobalSystemInformation
and paste it into the documentation center.
 
Oh,how foolish I am.I'm trapped here very long time...
Thanks very very much~
 
@yode This sometimes happens. To everyone. No problem
@yode Btw, I have to say that your English improved very much.
 
Wow,that is good news to me. :)
I'm glad to hear that
 
5:22 PM
@yode Keep working on it.
 
5:38 PM
@Szabolcs The asynchronous file watcher works :)
 
6:18 PM
posted on February 24, 2017 by Jeffrey Bryant

The movie Hidden Figures was released in theaters recently and has been getting good reviews. It also deals with an important time in US history, touching on a number of topics, including civil rights and the Space Race. The movie details the hidden story of Katherine Johnson and her coworkers (Dorothy Vaughan and Mary Jackson) [...]

 
 
2 hours later…
8:39 PM
@halirutan I found a solution to my earlier problem, for creating prettier overlines:
NiceOverline[x_] := StringJoin["\!(", x, "\&*AdjustmentBox[(_),BoxBaselineShift->0.2])"];
looks like the chatroom ate some of the backslashes, but you get the idea
 
9:06 PM
Actually, even plain RowBox adds the right amount of space, and in fact the BoxBaselineShift option on AdjustmentBox does not seem to do anything at all
 
 
2 hours later…
11:03 PM
@BenNiehoff Excellent.
 

« first day (1864 days earlier)      last day (2610 days later) »