Finally getting the hang of Dynamic and DynamicModule, I think. But I’m puzzled why the local variable for the angle, theta, gets updated when I move a slider which is inside a DynamicModule. I’m trying to see how we can “grow our own” interfaces from the ground up in order to have a little more flexibility that Manipulator panes, etc. might give.
I manage to streamline things a little bit by just putting all my vertices into matrices, one for a unit square aligned to the axes, and the other for whatever transformations we want to apply.
Just want to have something where everything is “WYSIWYG” (“what-you-see-is-what-you-get”) for purposes of connecting the diagrams and the matrix algebra better.
The only drawback is that I have to remember to take the transposes if I want to be able index the points directly.
Is there any way to delete a post when you’ve made an extra copy by mistake? I guess it can just have it’s content removed via editing, but I don’t see any way to delete the whole post.
I’ve got to say that IMHO there ought to be a way to have the degree sign right next to the angle variable without a space the way it is in every math, physics, engineering, etc. book. Any opinions? Is there a way to type a small space or other nearly invisible separator?
Finally got the WYSIWYG kind of plotting I wanted, using “roll-your-own” packaging of controls instead of a Manipulator pane. Just want to see how things can be done with the most flexibility, e.g. switching to shared globals and using separate windows simultaneously when one doesn’t have too much screen space.
I just wish that ParametricPlot would automatically accept column- or row-vectors, instead of having to use the less-readable and less-intuitive list-format, or a kludgy-looking conversion rule. I have to use the rule right on the column-vector, instead of at the end of the call to ParametricPlot the way I’d like to.
At any rate, I’m really glad that with just a little tweaking, I can use traditional matrices and vectors without any problems. The user can just directly enter in any combination of transformations, adding more sliders if needed, and immediately see the result.
One other important thing: You have to put an initial value in for the angle value somewhere in your code. Am I missing something, or is there a way to do that in the Slider[ ] call itself?
I’ve got to say that IMHO there ought to be a way to have the degree sign right next to the angle variable without a space …
FYI: ° is not a “degree sign”, it is a - quite intuitive - constant:
therefore there must be a white space character between this and some symbol to denote “multiplication”. If you do not like this you can write it as a quantity:
The rules explain how to format your code properly. If you do not format code, it may become corrupted and useless to other members. Please EDIT your post and make sure code blocks start on a new paragraph and look framed and colored like this.
int = Integrate[1/(x^3 - 1), x];
Map[Framed, int, Infinity]
Thanks. I’m still trying to understand if this Quantity[ ] function is giving an actual number, or what. But it looks useful for physics problems and that kind of thing.
Meanwhile, I guess I’ll just use a narrow space (via Esc-space-space-Esc) between an angle and a degree mark.
Thanks very much, that does just what I want, initializing the value if the file is being use for the first time (since last modification, I guess) but saves the last value set via the slider from the last session.