mathematica-frontend

What is the minimal difference in RGB color values which Mathematica renders and exports as different colors?

笑着哭i 提交于 2020-02-02 03:57:05
问题 I was amazed when I found that Mathematica gives True for the following code (on 32 bit Windows XP with Mathematica 8.0.1): Rasterize[Graphics[{RGBColor[0, 0, 0], Disk[]}]] === Rasterize[Graphics[{RGBColor[0, 0, 1/257], Disk[]}]] What is the minimal difference in RGB color values which Mathematica renders and exports as different colors? Is it machine-dependent? 回答1: I believe this behaviour is machine dependent, but I do not know how exactly it depends on the OS. On my machine, it evaluates

How to abort evaluation of a sequence of inputs?

自闭症网瘾萝莉.ら 提交于 2020-01-09 10:55:48
问题 By default pressing Alt + . or calling Abort[] within the evaluation causes abort of the currently evaluating input. But when working in the FrontEnd we usually send to the kernel a sequence of inputs. For example, if we type the following three expressions on separate lines in one Cell and then press Shift + Enter we get infinite evaluation: f := CheckAbort[Pause[.1], Abort[]] While[True, f] While[True, f] While[True, f] To stop this infinite evaluation we must to press Alt + . three times.

Remap Caps lock key to Esc in Mma 7

倾然丶 夕夏残阳落幕 提交于 2020-01-01 02:10:56
问题 TLDR : How do I get CapsLock to translate to "ShortNameDelimiter" in Mma 7? I like pretty text in my mma notebooks, and often define functions as f[\[Alpha]_] =... so as to match the exact equation that I'm working with. As such, it involves a lot of Esc - letter - Esc sequences, and reaching for Esc every other stroke breaks my flow of typing. Now, the CapsLock key is seldom used (I can't remember the last time I needed it), but conveniently placed (your pinky is right there!). Remapping it

Command-line arguments of Mathematica Kernel and FrontEnd

风流意气都作罢 提交于 2019-12-23 09:47:22
问题 I still know nothing on usage of such command-line options of MathKernel as -lmverbose -run cmd -password "pw" -pwfile "file" How are they working and what they are needed for? Are there other potentially useful command-line options of the MathKernel and the FrontEnd? P.S. Related answer. 回答1: Please consult the following reference pages: MathKernel and Mathematica. Opening "More Information" section you will see documented options. Its says -pwfile "file" ------- read passwords from file

How to redefine FrontEndEventActions?

戏子无情 提交于 2019-12-22 06:56:23
问题 Good day, This question comes from the question on aborting evaluation of the full sequence of inputs. I think it is probably possible to achieve the desired behavior by redefining FrontEndEventActions for two events: "EvaluateCells" (or pressing Shift + Enter ) and for pressing Alt + . . It should be something like: SetOptions[$FrontEndSession, FrontEndEventActions -> {"EvaluateCells" :> Last$PreRead, {{"Alt", "."} :> AbortAllNextInputs}}] or SetOptions[$FrontEndSession, FrontEndEventActions

Understanding Kernel-FrontEnd communication — Why does my Front End freeze?

霸气de小男生 提交于 2019-12-22 04:46:17
问题 EDIT: Just a confirmation whether you can reproduce this or not would be useful. Only a single computer is needed to try this (no remote connection necessary). Update It seems other can't reproduce this on Mac or Win7, so it's either WinXP-specific or specific to my machine. At this point I'm giving up. It would be good to have a tutorial on how the Front End and the Kernel communicate, so we can debug remote kernel issues. Any such general answers (or links to tutorials elsewhere) are most

How to create a notebook with a properly formatted expression

∥☆過路亽.° 提交于 2019-12-19 10:03:02
问题 I have a Mathematica expression generated by another program, which I would like to open in a notebook, properly formatted. For instance, the other program generates this: Plot[{Exp[x],Interpolation[Table[{k/5,Exp[(k-1/2)/5]},{k,0,5}], InterpolationOrder->0][x]},{x,0,1},Filling->{1->{{2},{Yellow,Orange}}}, PlotLabel->Style["Formatting",Blue,FontFamily->"Courier"]] The text is written into a file, crudely suffixed ".nb", and launched, and the expression opens in a notebook without formatting.

How to create a notebook with a properly formatted expression

假装没事ソ 提交于 2019-12-19 10:01:48
问题 I have a Mathematica expression generated by another program, which I would like to open in a notebook, properly formatted. For instance, the other program generates this: Plot[{Exp[x],Interpolation[Table[{k/5,Exp[(k-1/2)/5]},{k,0,5}], InterpolationOrder->0][x]},{x,0,1},Filling->{1->{{2},{Yellow,Orange}}}, PlotLabel->Style["Formatting",Blue,FontFamily->"Courier"]] The text is written into a file, crudely suffixed ".nb", and launched, and the expression opens in a notebook without formatting.

How to Autonumber Cell Tags in Mathematica Notebooks?

╄→尐↘猪︶ㄣ 提交于 2019-12-19 03:57:00
问题 I tried to follow the directions on autonumbering cells in a Mathematica-8 notebook, here http://reference.wolfram.com/mathematica/tutorial/AutomaticNumbering.html I created a tiny notebook with four text cells foo qux blancmange bar Placing the cursor just before foo , I then used the Insert menu, Automatic numbering item, giving me the Create Automatic Numbering Object dialog box. I chose in the Counter dropdown then item Text , clicked This counter object radio button, and Huzzah! got the

mathematica start front end and eval notebook from command line

妖精的绣舞 提交于 2019-12-18 15:46:54
问题 Is there a way to start up a mathematica front end (GUI) from a (Windows) command prompt and have it eval a notebook without further user action? even though mathematica.exe takes the -run and -initfile options they dont work the same as they do with math.exe. (-run ''<<file.m'' wants to open a file named ''<<file.m'' for example) Thanks. The first answer looks promising, however I get FrontEndObject::notavail A front end is not available (per docs it is "UseFrontEnd" by the way.) Perhaps a