使用 Mathematica 构建演示文稿和文档 [英] Using Mathematica to build presentations and documents

查看:57
本文介绍了使用 Mathematica 构建演示文稿和文档的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我主要使用Mma来解决相对较小的问题.

我也想开始使用它来准备我的演示文稿和文档,但我无法从嵌入式帮助中学习如何使用它,我想其他地方可能有一些好的资源.

您是否知道任何有用的提示(书籍、论文、视频...)?

你有一袋技巧"可以在这里发布吗?

编辑

到目前为止,这个问题收到了两个答案(@mzabsky 和 ​​Mr.Wizard),尽管两者都很有用,但我的担忧可能更为基本.因此,我发布了一个种类我无法做的事情的示例(或了解如何辨别其他人是如何做的).

我从

所以,一些问题,只是为了了解我的麻烦:

1)我把文字复制到我右边的.nb,格式化成一样的样式(文字),但是外观不同,所以我猜样式定义不一样.如何将样式定义从一个 .nb 复制到另一个?

2) 文本块下方的表格没有附加样式.它是如何格式化的?背景色是在哪里定义的?

我想要有关这些问题的阅读(或观看视频或其他内容)的指针.我不希望你在这里写一本关于 Mathematica 格式的书!

答案中发布的链接摘要

解决方案

我同意 mzabsky 在他的回答中所说的所有内容.这里有一些额外的东西:

我发现使用 TextDisplayFormula 单元格创建语句然后手动将 Mathematica 检查/证明分组到语句中很有用,然后折叠起来并可以在以下情况下显示你想要.

Writing Assistant Palette 有很多有用的结构,你可以可以借鉴.

最后,我发现制作自己的样式表非常有用,原因如下:1)内置的有点丑;2) 它确实可以帮助您了解笔记本的工作原理.

要查看我制作的样式表的示例(我并不声称它是完美的 - 我没有费心让它在所有屏幕环境中都可以工作)查看 ftp://ftp.physics.uwa.edu.au/pub/MATH2200/2010/.我在所有笔记中都使用了类似的样式表 - 我有许多研究项目主要包含在 Mma 笔记本中,例如 http://arxiv.org/abs/1102.3043.

和 Mr Wizard 一样,我也推荐 David Park 的笔记 作为起点.此外,您应该通过转到格式"菜单并单击编辑样式表"来研究您喜欢的样式表.不要忘记通过样式表级联(版本 6 及更高版本)跟踪链接.

回答编辑中的问题:查看笔记本的样式表后,您可以保存、编辑它并在您自己的文档中使用它.样式表$UserBaseDirectory/SystemFiles/FrontEnd/StyleSheets 在菜单中自动可用.然后,您只需从菜单中选择该样式表即可在任何笔记本中使用该样式表.

您发布的屏幕截图中的格式都包含在样式表中.这包括表格中的灰色背景.

附录:

向他人分发笔记本时,如果样式表在笔记本外部,那么其他人将不会像您一样看到它.要将样式表包含到当前笔记本中,您需要像

这样的代码

ss = 样式定义/.选项[评估笔记本[]]fn = ToFileName[{$UserBaseDirectory, "SystemFiles", "FrontEnd", "StyleSheets"}, ss]如果[文件存在Q[fn],style=Get[fn];SetOptions[EvaluationNotebook[],StyleDefinitions->style];,打印["找不到文件"]]

(假设文件存放在常规位置)

这是一个 EmbedStylesheet.m,它是上述内容的改进版本.

I use Mma mainly to solve relatively small problems.

I want to start using it also to prepare my presentations and documents, but I am having troubles to learn how to do it from the embedded help, and I guess some good resources may be available elsewhere.

Do you know any useful pointers (books, papers, videos ...)?

Do you have a "bag of tricks" to post here?

Edit

This question received two answers so far (@mzabsky's and Mr.Wizard's) and although both are useful, perhaps my concerns are much more basic. So I am posting an example of the kind of things I am unable to do (or understand how to discern how others did them).

I took the following example from The Mathematica Journal (the notebook at the left on the following image - click on the image to see full size):

So, some issues, just to get the idea of my troubles:

1) I copied the text to my .nb on the right, formatted it with the same style (text), but the appearance is different, so I guess the style definition is different. How can I copy the style definitions from one .nb to the other?

2) The table below the text block doesn't have an attached style. How was it formatted? Where is the background color defined?

I would like pointers to read (or videos to look, or whatever) about these issues. I don't want you to write down here a book on Mathematica formatting!

Summary of the links posted in answers

解决方案

I agree with all that mzabsky said in his answer. Here's a few of extra things:

I find it useful to make statements using a Text or DisplayFormula cell then manually group a Mathematica check/proof to the statement which is then collapsed and can be displayed when you want.

The Writing Assistant Palette has quite a few useful constructions in it that you can learn from.

Finally, I found it really useful to make my own style sheet for a couple reasons: 1) the built-in ones are a bit ugly; 2) it really helps you to understand how the notebooks work.

To see examples of the stylesheet I made (which I don't claim to be perfect - I didn't bother making it work in all screen environments) look at some of the files in ftp://ftp.physics.uwa.edu.au/pub/MATH2200/2010/. I use a similar stylesheet in all of my notes - I have many research projects primarily contained in Mma notebooks, eg http://arxiv.org/abs/1102.3043.

Like Mr Wizard, I also recommend David Park's notes as a starting point. Also, you should study stylesheets that you like by going to the Format menu and clicking "Edit Stylesheet". Don't forget to follow the links through the cascade of stylesheets (version 6 onwards).

To answer the questions in your edit: Once you are viewing a notebook's stylesheet, you can save it, edit it, and use it in your own documents. Stylesheets in $UserBaseDirectory/SystemFiles/FrontEnd/StyleSheets are automatically available in the menu. You can then use that stylesheet in any notebook by simply selecting it from the menu.

The formating in the screenshot that you posted is all contained in the stylesheet. This includes the grey background in the table.

Addendum:

When distributing notebooks to others, if the stylesheet is external from the notebook, then other people will not see it as you do. To include the stylesheet into the current notebook, you need code like

ss = StyleDefinitions /. Options[EvaluationNotebook[]]
fn = ToFileName[{$UserBaseDirectory, "SystemFiles", "FrontEnd",  "StyleSheets"}, ss]

If[FileExistsQ[fn],
     style=Get[fn];SetOptions[EvaluationNotebook[],StyleDefinitions->style];,
     Print["Can not find file"]]

(Assuming the file is in stored in the conventional place)

Here's an EmbedStylesheet.m that is an improved version of the above.

这篇关于使用 Mathematica 构建演示文稿和文档的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆