« first day (962 days earlier)      last day (3954 days later) » 
00:00 - 19:0019:00 - 00:00

12:21 AM
@NicolaTalbot Thanks! Will give it a try
 
@Werner I haven't followed all of this too carefully, but could you use pdfcrop instead?
 
@AlanMunn Also an option, thanks! I'm working on the ruby replacement of %%BoundingBox first... It should be quick.
 
12:37 AM
@AlanMunn Yay for pdfcrop!
 
1:16 AM
@Werner I also have to make the change from \thepage to \value{page} in some example(s) of the documentation of the package. Thanks for reminding me!
 
@Werner Yes, another great Heiko production.
 
@AlanMunn I recall now why I was using epstool instead of pdfcrop. I want to use a bounding box from a different EPS occasionally. Now I have to extract the bounding box using something like sed and pass that to pdfcrop since it takes a --bbox.
@GonzaloMedina From background?
 
2:02 AM
@Werner yes.
 
A quick search on the site suggested that it's not possible but I'd still like to ask: can the breqn package be switched off for the whole document except for where it's actually used?
I have this one equation I do not want to line wrap by hand.
But I don't want to buy this convenience in one single equation with the inconvenience of coping with all the strange error messages that breqn produces elsewhere.
Can I have both? And a pony? Or will I just have to face the hard truth that I'll have to hand wrap this equation?
Is there maybe an alternative?
some script that I put my equation into and it magically produces a beautified, line-wrapped and indented equation as LaTeX snippet?
I feel like I'm still asking for a pony ...
 
2:24 AM
@Christian What error messages? The original amsmath environments still work as they would without breqn.
 
@Qrrbrbirlbel They don't seem to.
! Argument of \text@ has an extra }.
<inserted text>
                \par
l.535   \text{\textit{accuracy}}_\text
                                      {sym} = \frac{1}{N} \sum_{i=1}^{N}
 
@Christian Try \text{\textit{accuracy}}_{\text{sym}}.
 
@Qrrbrbirlbel Ok thanks, I'm going to ... but this was the very first equation in that chapter and it already failed ... that discouraged me somewhat from using the package :/
! Argument of \select@group has an extra }.
<inserted text>
                \par
l.155 ...frac{y\maxsub}{\sqrt{S s_\mathit{max}^2}}
Just compiled without \includeonly and I got an earlier error
@Qrrbrbirlbel Your fix for the other error works though :)
But the apparent frequency of errors still conjures up this image of me sitting through the rest of the night fixing strange errors throughout my 300 page thesis that weren't there without breqn.
 
2:54 AM
@Qrrbrbirlbel Well, even when compiling just that one chapter which works now, I get Package breqn Error: eq@repack penalty neq 0,1,2,3 for the equation in question. So it doesn't seem to be worth it :/
Seems that beast is too tough for Skynet and good old human brain is needed :/
 
@Christian Huh, I really never used breqn (although I like the way it approaches things). Something though feels fishy. Packages up-to-date?
 
Same problem I already had with Wolfram Alpha which I tried to convince to simplify my stuff.
Ran into timeouts and length limitations all the time
@Qrrbrbirlbel Dunno, \ProvidesExplPackage{breqn}{2012/05/10}{0.98b}{Breaking equations}
But it's not that I'm the first person to run into these problems.
2
Q: internal error in breqn package with dseries/dmath* pair

Peeter JootAs an experiment, I took some equations that I'd manually split using aligned like so: \begin{equation}\label{eqn:fourierSeries:30} \begin{aligned} \int_a^b \phi(x) e^{-i \omega m x} dx &= \sum c_k \int_a^b e^{i \omega (k -m) x} dx \\ &= c_m (b - a) + \sum_{k \ne m} \frac{e^{i \omega(k-m) b} - e...

5
A: Why is adding \usepackage{breqn}, even if not used, causes LaTeX compile errors in some places?

egregThe breqn package changes the definition of \sum (and of almost all other commands for math mode). The definition it uses is (using the output of \show) > \sum=\protected\long macro: ->\@sym \sum \math_sym_COs:Nn \mg@cop {50}. The macro \@sym is the same as \@gobble, at least between \[ and \]...

 
@Christian Unfortunate. :(
You can’t have it all, can you?
 
No, I guess not
Well, I'm just going to use multline.
Throw in some linebreaks and hope nobody complains
it's just a "see, I told you you don't want to go there" equation anyway
so the uglier the thing is, the better it proves my point ;)
 
@Christian You could just randomly color every letter:
13
A: LaTeX color setting for math mode

user700902With no warranty of any kind! \documentclass{article} \usepackage{color} \makeatletter \def\colorizemath #1#2{% \expandafter\mathchardef\csname orig:math:#1\endcsname\mathcode`#1 \mathcode`#1="8000 \toks@\expandafter{\csname orig:math:#1\endcsname}% \begingroup \lccode`~...

 
3:05 AM
lol
 
I have even attributed to that madness: tex.stackexchange.com/a/100645/16595
 
impressive :) but that'd be too obvious
 
@Christian You may hand out sickness bags:
41
A: Blur the text so it's not readable

Gonzalo MedinaUsing a variation of the technique Dissecting paragraphs with \lastbox described in Section 5.9.6 of TeX by Topic, you can produce a blur effect; the idea is to use two copies for each line and typeset the line and its copies superimposed: \documentclass{article} \usepackage{lipsum} \newbox\fli...

 
Good lord.
 
Any sed experts?
 
3:10 AM
@Werner I'm out … Good night.
 
pdfcrop allows for a --bbox <left> <bottom> <right> <top> key. I'd like to extract the %%BoundingBox from one EPS file and use/port that as the --bbox key to pdfcrop.
 
@Qrrbrbirlbel Night!
@Werner Can't you just use something like grep BoundingBox | cut -d: -f2?
if the format is the same that is
looks like it might be but I'm no eps expert
 
What is cut?
 
It cuts characters or so called fields
yes, that
one of the basic UNIX tools
 
Okay, I'm not familiar with that.
 
3:16 AM
way easier to use than awk or sed when you don't need those more powerful tools
in the above case you tell it to use : as the field delimiter and only use the second field
you could also use -f2- for example if you wanted to discard the first field but use all remaining
or -f2-5 etc.
just as an example
and cut -c5-20 does the same with characters, cutting out characters 5 to 20 in every line
very nice for tabular data
like from ls -l for example
 
3:37 AM
Here is a simple example of some issues with latex->HTML conversions. I write latex document using \documentclass[twocolumn] When converted to HTML, it comes out as one column. So, to make it come out as if it was 2 columns in HTML, I have to write everything in a table with 2 columns. But I do not want to use table, I want page with 2 columns in the sense of \documentclass[twocolumn] So I have to make 2 version of the same latex document, one for HTML and for pdf
and when I change something in one, I have to remember to make the same changes in the second.
 
 
2 hours later…
6:01 AM
@Nasser do you realize that if your document is longer, your readers will have to scroll several screens up after reading first column? I don't think many of them will appreciate that :)
@Nasser but if you really want it, try something like:
\Preamble{xhtml}
\begin{document}
 
@michal.h21 You will not believe what I just discovered about htlatex
 
\Css{body{column-count:2;}}
\EndPreamble
 
@michal.h21 Ok, will try that ! thanks.
 
but I haven't tested if it really works, just add css columns property to body element
see developer.mozilla.org/en-US/docs/Web/Guide/CSS/… and try to use css properties fromt that
@Nasser what did you discovered?
 
@michal.h21 I have suffered with bad png quality for math for long time. I just found by trial and error a fix which improved the math png 100% I am still stunned by it
I can;t believe it
I changed this line

 <dvipng>
G.png
Gdvipng -T tight -x 1400 -D 72 -bg Transparent -pp %%2:%%2 %%1 -o %%3
to....
 <dvipng>
G.png
Gdvipng -T tight -x 1400 -D 96 -bg Transparent -pp %%2:%%2 %%1 -o %%3
WOW !!! The math png now is SO MUCH BETTER, very shapr, and clean. Before, I suffered with bad quality math for long time.
I even saw your post on the Tex about changing to use dvipng
but even you did not mention to do this change from 72 to 96 :)
You might want to talk to someone to make this change permanent in tex4ht.env?
 
6:09 AM
@Nasser there is a big problem with these images that these days, with high resolution displays like retina, even 96 dpi is not enough
and we need to place to html image dimensions, so the are rendered corectly on devices with various resolutions
 
@michal.h21 I am just saying 96 is so MUCH better than 72. Math looks so much better now.
 
@Nasser of course, 72 dpi is not enough
 
I do not know the details. I just know on my computer, the HTML pages now look so much better. I mean the math. I can make you a screen shot if you like to see.
I am now rebuilding my whole web site with this new setting
 
I just saw you have new texlive, can you test please if make4ht is running correctly? there is new version of luatex and it has some non backward compatible changes
 
@michal.h21 Yes, but texlive 2013 is still not on the mirror site. I just tried it. It still says 2012. May be tommorow it will be.
I will test everything when it is there. I have new Vbox machine just for this.
@michal.h21 You might like to consider updating your answer here tex.stackexchange.com/questions/43772/… and mention the possibility of trying 96 vs. 72 in your answer there. Since someone looking for help on this issue, will see this. That is what I saw also...
 
6:16 AM
@Nasser I am sure it looks better 72 dpi is not enough these days
 
Your answer was the first hit on google when I was searching for this topic. So it will be good to mention this in there. It might help others
I was looking for way to improve the png used for math and tried this change and it worked.
 
@Nasser you might also consider use of svg as is described at the end of the answer, maybe it can work for you. as svg is vector format it doesn't have problems with bad rendering
 
@michal.h21 Yes, I saw your notes. but SVG looked fuzzy on the screen. By your own example on your web page.
I can't find the page now. It is on your project page where make4ht is. WIll look for it
 
@Nasser problem is that svg rendering depends on the browser, some have better support than others
 
@michal.h21 OK. But i am now VERY HAPPY with texht and png images for math. with 96 dpi, it is very good. no need for mathjax or anything else. This was the main problem for me all along. Now it is solved :)
 
6:31 AM
@Nasser ok :) I edited my answer, now it is with 96 dpi
 
@michal.h21 great! that should help someone I am sure.
I used to use latex2html for years before I switched to tex4ht. I always had problems with math equations there also. It also used png images.
 
@Nasser there is a lot of options in dvipng, you may play with them to see what has best results: linux.die.net/man/1/dvipng
 
@michal.h21 YEs, I know, that is how I found about 96. I was reading that man page :) I was actually trying to see if I can change the bit-dept. It is now 4. I was trying to see if I can change it to 24 hoping that might improve things, when I noticed the dpi number, then said let me try that first
But your post about using dvipng instead of the convert was very useful.
 
kan
7:33 AM
Oops!!
$    sutlmgr update --all
    [sudo] password for knsam:
    tlmgr: The TeX Live versions supported by the repository
      (2013--2013)
    do not include the version of the local installation
      (2012).
@egreg would know what I am doing wrong... :)
 
8:11 AM
@Nasser using png for math is just so wrong (but you know that:-)
 
@DavidCarlisle Well, may be. I am struggling now with a bigger problem :( Tex exceeded capacity
(/usr/share/texlive/texmf-dist/tex/latex/amsfonts/umsb.fd)
(/usr/share/texmf/tex/latex/lm/t1lmtt.fd) (./HW2_solution.4ct)
l.18 --- TeX4ht warning --- Cannot determine size of graphic in problem_1_descr
iption.png (no BoundingBox) ---
l.32 --- TeX4ht warning --- Cannot determine size of graphic in prob1_parta.png
 (no BoundingBox) ---
[3] [4]
l.75 --- TeX4ht warning --- Cannot determine size of graphic in problem_2_descr
iption.png (no BoundingBox) ---
l.80 --- TeX4ht warning --- Cannot determine size of graphic in problem_2_part_
I have no idea why. But I am working on it for last 2 hrs. Never seen this one before. tex4ht stops generating the HTML when this happens
 
@Nasser you can increase the inout stack in texmf.cnf (search fro that error message on this site) but if you hit 5000 ypu may be in an infinite loop so making it 50000 just means it takes longer to crash
 
I have no idea why it happens only on this one file really. This file uses \usepackage{breqn} I wonder if this has anyting to do with it. I only include 4 images and then it dies. \includegraphics{prob1_parta.png}
 
8:26 AM
@Nasser using breqn and tex4ht together is probably adventurous:-)
 
@DavidCarlisle I always like to be on the front line !
if I can't figure this out, I'll remove breqn. The problem is I change all my equations from align* to dmath* and there are many of them. I did not keep a copy, so I have to redo them all. Not a problem. I still do not know if this is what causing this file to fail with tex exceeded capacity, but that is the only file that has this package. The PDF is fine, just the HTML is not coming up complete.
 
@Nasser what you ought to do id lose brekn and define dmath to just be [ in htl mode and then let mathjax or the mathml renderer to the line breaking later as it makes no sense to linebreak as an image in html to an unkown page size. But I may have mentioned that before. (And the implementation of line breaking in the browsers isn't really great yet)
 
kan
@egreg I have a working 2013 TL install! :)
 
@kan Hurray!
Switch to TL 2013 made. No updates available.
 
8:43 AM
@egreg Same here: as I said, if you kept up-to-date with the pretests then there was 'nothing to see here'
 
9:03 AM
@DavidCarlisle FOUND IT !! It was breqn package that was causing tex exceeded capacity with tex4ht !! I just removed the package, changed everything back from dmath to align and now the problem went away. No tex exceeded capacity on same file. That is all what I changed.
 
Enter command: I
Installing to: /usr/local/texlive/2013
 
9:23 AM
@DavidCarlisle Very interesting interview
 
9:36 AM
how is it possible that some code compiles while using standalone but throws a whole bunch of errors after insertig it into my main file?
 
10:03 AM
JUst a quuck question please In this:

%tex.stackexchange.com/questions/8434/…
%\DeclareMathSizes {t-size} {mt-size} {s-size} {ss-size}
%Basically, we instruct the use of a <mt-size> as the math
%text size, <s-size> as the script size and <ss-size> the
%scriptscript size to be used in math, when <t-size> is the
%current text size. You can adjust the parameters to suit.
I found that script size means superscript size, ie x^this
But what is ss-size used for ?
and if the the correct values to use for 12pt document please?
I am using this now \DeclareMathSizes{12}{11}{7}{7}
Ok, I found it. ss-size is for subscript x_this and s-size used for superscipt x^this
 
10:19 AM
@Nasser a^{b^y} script script size
@Nasser no
@Nasser latex defaults are ` \DeclareMathSizes{\@xiipt}{\@xiipt}{8}{6}`
 
@DavidCarlisle We need to counterattack, let's interview you again. :)
 
@Nasser that is an odd choice you are making the normal math and subscripts smaller than the default (and the surrounding text) but making sub-sub scripts large
 
@DavidCarlisle but {8}{6} there are hardcoded?? What if one uses 12pt vs. 10pt? Should these not be propertional? This is for HTML only. Not PDF. With PDF I do not touch this stuff. I just use 12pt for class, that is all. But for HTML I have to change it since math comes out too large or too small if I do not try to fix it.
 
@DavidCarlisle I'm beginning to suspect you have that fav'ed somewhere for quick access. :)
 
10:24 AM
@Nasser No they are the sizes to use for 12pt text (that is the first argument)
 
I have these in my tex4ht config file now.
\DeclareMathSizes{12}{11}{7}{6}
\DeclareMathSizes{10}{9}{5}{4}
\DeclareMathSizes{11}{10}{6}{5}
 
Yay! TL2013 now installed. And I notice that the latest version of hobby got in, as did tikzmark and the others that I uploaded.
8
 
@PauloCereda no this time I just searched for "year old" :-0
 
@DavidCarlisle ooh! :)
@AndrewStacey Yay!
 
If I use \DeclareMathSizes{12}{12} that math comes out TOO big in HTML
 
10:25 AM
@Nasser so in each case you aresaying that the math fomt should be 1pt smaller than teh surrounding text font
 
Yes
This is a screen shot
 
@Nasser well you are using images so it looks horrible anyway
 
I am usin g.png
 
@Nasser quite
 
@David: ooh you were mentioned in the interview! :)
 
10:27 AM
the above is 12pt document, using \DeclareMathSizes{12}{11}{7}{6}
You can see that the math is still little larger than text.
but again, I do this only for HTML. I do not use this configuration for pdflatex. It is used only by htlatex
 
@Nasser It's an image and baselines are all wrong, size doesn't match, it's the expected behaviour if you use images for math, honestly I really wouldn't bother fine tuning the images.
 
if I make it {12}{12} it will TOO big. I make you a screen shot now with that....
 
@Nasser I really don't care: It looks like some text with some images inserted, it will always be wrong.
 
baseline issue is known. I think Michal trying to find a solution for it.
 
@Nasser The solution is not to use images for math.
 
10:34 AM
@DavidCarlisle I agree with you. But I do not want to use mathjax for now. (1) it takes long time to load, and also if I am connected to the net, it will switch to mathml I think or some other math. This way at least, it is the same all the time, and pages load up fast on my server.
i.e when I open my web page, it loads up fast. With mathjax, it will takes longer.
but will keep eye on mathjax, and keep trying. WHen it gets faster, I can always switch. I use makefiles, and easy to change.
Just change one config file. and rebuild.
 
@Nasser That actually isn't clear at all, if you have a lot of math (as we do) the size of the png files and the number of connections required to download them all can be comparable or slower than mathjax (if suitably configured)
 
@DavidCarlisle That is what I first thought. But in practice, the pages actualy load up faster. With Mathjax, the page loads, but I can see at the bottom that Mathjax is still working and sometimes it took a whole half a minute for the math to show. With .png, it is almost instantanous . May be the internet is getting good.
 
10:50 AM
@Nasser actually if you turn off that mathjax message box the perceived time is a lot less. Browsers always incrementally render so you can look at the top of the page before it has finished laying out the rest, but mathjax tells you it is doing it. And no I don't want 300000 png files in my documentation distribution.
@Nasser or you can use jqmath (quicker than mathjax not as pretty) or you can just use mathml and tell people to use a browser that conforms to standards (firefox and safari and just about internet explorer+mathplayer then you get direct mathml layout with no javascript delay at all)
 
@DavidCarlisle if they can somehow bundle mathjax into the browser itself, so it is transparant, that will be much better. i.e. ability to render math, using mathjax like way, if this can be build-in, no configuration or connection. Have the Browser javascript engine itself render latex, just like mathjax does it. Then it will be much faster.
Mathjax folks should talk the HTML5 group and the browsers companies to work on this.
 
@Nasser Use MathML and then do a browser test to see if it can handle MathML natively. If not, send it MathJaX. Note that the MathML conversion that MathJaX does is much faster than when it has to convert from raw TeX.
 
wow! There was a latex to HTML translator in 1993 !
 In those days Tim was sitting just a few offices down the corridor from where Sebastian and I were working; and already at the beginning of 1993 we had translated, with the active help of Tim, some rather complex LaTeX documents into HTML, using our own ad hoc set of LaTeX macros which translated LaTeX high-level commands into HTML equivalents (with formulae left as TeX inside the HTML).
 
@Nasser you are kidding right. We have been talking to the browser makers since 1998. With the honourable exception of mozilla they all hate mathematics (it is hard and they get more feedback asking to display cats on youtube)
@Nasser There was a time when latex2html output constituted a large fraction of the internet.
 
11:08 AM
@DavidCarlisle I know about l2h, I wrote a document on its installation which is used by many. I used it for few years. 12000.org/my_notes/l2hwin/index.htm
 
this may sound like a weird question; but is there a way to put divisions in a preamble? You see I have so much stuff in there I'd love an easy way to just access the points via some sort of label via the struture tree.
 
@Grey I've done something like this. using \let, is this what you mean by division?
 
@Nasser maybe not: i'm using texmaker and in the structure panel I'd like to see like an icon I can click to access that chuck of code in the preamble.
 
I see. I would not know then. I do not use texmaker.
I started using kile for latex editing. It is really nice.
 
@Grey the preamble shouldn't be that big:-) you can put any re-usable code in my-package-for-page-setup.sty my-package-for-fonts-and-layout.sty and whatever units make sense then the preamble just needs \usepackage{my-package-for-page-setup,my-package-for-fonts-and-layout}
 
11:21 AM
@DavidCarlisle interesting I didn't know that!. It's not so much the stys, but these custom commands that I have declared there you see.
 
Oh no, I'm stuck at 39 votes again!
@egreg: I read that all Italian players wanted to go to the beach in Recife, but they were scared of the sharks. :)
 
11:40 AM
@Grey yes but any commands you put in the preamble you can put in a local package file instead
 
kan
Two Davids.
 
I need a solution for this question: tex.stackexchange.com/questions/63307/…
 
@David the answer there is the answer, does it not work for you?
 
I'm sorry. The cuestion is this: tex.stackexchange.com/questions/119811/…
 
@David please don't put supplementary questions as answers, either edit the question with updated detail or add a comment to the other answer.
 
11:54 AM
Done
 
@David I was going to post a minipage solution but I see Andrew has done that already.
 
Thank, but in this solution the equation will not break accross pages
 
@PauloCereda I don't know. Are there sharks at Recife?
 
I use breqn package with \eqinterlinepenalty=0 and \intereqpenalty=0
 
@egreg A lot. :) A friend of mine who lives in Recife told me that although there are lots of sharks, they are usually harmless, as long as their boundaries are respected. :)
 
12:04 PM
@David sorry but breqn is an experimental package the author of which (who I counted as a friend) died. So if you use it you have to be prepared to dig into its internals if it doesn't do exactly what you want. If page breaking is a requirement you probably need to say that in the question. There are not many who really know breqns workings though, so you should not expect a speedy answer.
 
12:17 PM
@DavidCarlisle can I please ask you a quick question on longtable?
@DavidCarlisle please ignore. Found my error. sorry.
 
12:36 PM
Thank you very much David Carlisle. I will wait
 
!!/cricket
 
12:59 PM
does anyone use sublime editor for their latex work? I'm trying it out, but I've got so used to texmakers structure panel; does sublime have an alternative to this?
 
 
1 hour later…
2:24 PM
Guys, I thought of two names for the upcoming interviews: for the next interview, I though of Khaled Hosny, and the next one with Claudio Fiandrino.
 
@PauloCereda Two very interesting interviewees
 
@egreg We can reverse the order, of course. :)
 
!!/cricket
 
@AndrewStacey ooh just a minute!
!!/cricket
Psmith, the TeX bot, in fixed font mode: Let's take a look at the last cricket results:

- England 57/2 * v South Africa 175/10
- Netherlands 123/5 * v Nottinghamshire
- Leicestershire v Glamorgan 148/3 *
- Kent v Sussex

Our cricket expert David might explain these results later on.
Oh my, Subversion 1.8 features first-class renames! /faints
 
2:43 PM
@PauloCereda But everyone is moving to Git :-)
 
@JosephWright boo. :)
 
@PauloCereda You're good with thinking up images. Do you have any suggestions for a logo for my new app? My brain's gone blank.
 
@NicolaTalbot How about your cool parrot sit on a database and reading logs? :)
 
@PauloCereda Ooh! I'd have to work out a miniature version for the window icon.
 
3:03 PM
does anyone got experience with pgfplots and gnuplot?
 
@Rico A little bit
 
@Jake nice! right man right time!!
@Jake I need to do a nonlinear fitting. already found out that I have to do it with gnuplot
 
I can't remember, what are the MacTeX additions?
 
@Jake problem is, I dont know what kind of equation this is
 
@Rico Hehe, oh. Not even roughly?
 
3:13 PM
@Jake it should look like this:
@Jake what i have looks like this:
 
@PauloCereda The bits of the Mac set up that are not TeX Live itself
 
@JosephWright Ah thanks. Should I install them as well?
 
@Rico So have you tried fitting the Michaelis-Menten equation?
 
@PauloCereda Have you installed MacTeX 2013?
 
gnuplot: f(x) = a*x/(b+x)
fit f(x) 'data.csv' via a,b
Could I get the data table?
 
3:19 PM
sure
 
@JosephWright Only in my macbook. I'm downloading the ISO for my imac.
 
Konzentration      2            3           4
0.250 0.00222  5.58069E-05 3348.41629
0.225 0.00159  3.99498E-05 2398.190045
0.200 0.00161  4.02212E-05 2413.273002
0.175 0.00192  4.82655E-05 2895.927602
0.150 0.00173  4.34892E-05 2609.351433
0.125 0.00154  3.87129E-05 2322.775264
0.100 0.00156  3.92157E-05 2352.941176
0.075 0.00155  3.89643E-05 2337.85822
0.050 0.00133  3.34339E-05 2006.033183
0.025 0.000981 2.46606E-05 1479.638009
 
Ouch, I hate typing things on my ipad.
Thankfully I have vim here.
 
@Rico This gives me:
a               = 0.00205996       +/- 0.0001607    (7.802%)
b               = 0.028557         +/- 0.01067      (37.37%)
 
@Jake how do you solve this with latex?
 
3:23 PM
 
@JosephWright Should we hash this out 'too localized' discussion in chat for a bit instead of in the comments to the meta answer?
 
@Jake you need to use column 4 like this ` fit f(x) 'source6.dat' using 1:4 via a,b,0;`
 
@AlanMunn We could post a meta question about it. :) Oh wait...
 
@Rico Did you see tex.stackexchange.com/questions/29633/…? I did something similar there, using raw gnuplot
 
MacTeX 2013 install underway. It's nice to have a mirror on campus. FTP took 6mins.
 
3:28 PM
@AlanMunn Not fair. Definitely not fair.
@AlanMunn: ^^
Look how sad I am.
 
@Jake this is the example Im still trying to recover :)
 
@PauloCereda Pobrezinho.
 
@Jake
       \addplot+[raw gnuplot, draw=red, mark=none, smooth] gnuplot {
    	f(x) = a*x/(b+x);
       a=0;
       b=0;
       set fit errorvariables;
       fit f(x) 'source6.dat' using 1:4 via a,b;
       % Next, plot the function and specify plot range
       % The range should be approx. the same as the test.dat x range
       plot [x=0.1:1000] f(x);
       set print "parameters.dat"; % Open a file to save the parameters into
       print a, a_err; % Write the parameters to file
       print b, b_err;
 
@AlanMunn I was once in a lab connected to a gigabit network. I was downloading a Solaris ISO, it took 10 secs. I was like, "c'mon, this image must be corrupted." Nope.
 
@PauloCereda Yes we have gigabit in some parts of campus. I'm on wireless, so that limits me a bit.
Installation done.
 
3:35 PM
@Rico You need better starting values. a=1000 and b=1 worked for me:
\addplot[only marks, mark size=1.8, black] table [x index=0, y index=3] {tex-sx/data.csv};

\addplot+[raw gnuplot, red, mark=none, smooth] gnuplot {
    f(x)=a*x/(b+x);
    a=1000;
    b=1;
     fit f(x) 'tex-sx/data.csv' using 1:4 via a,b;
     plot [x=0:0.25] f(x);
};
 
@Jake NIIIIICE!!!
 
Nice fit, by the way, it's always really satisfying when the model matches the data so well.
 
@Jake thanks :) there are still 2 open questions, 1. why does the legendentry of you example not work :D and 2. where did you get the equation for f(x)
@Jake got the legend right
 
@Rico The equation was in the legend of the first image you posted, plus it said Michaelis-Menten plot in the first image's caption...
 
3:52 PM
@Jake oh... well this is embarrassing. should have seen this ...
 
@Rico Hehe!
So the legendentry issue is fixed?
 
@Jake now I need to do the linewever burg diagram, man i hate biotech :D
@Jake
 
@Rico Sweet!
 
@Jake any tips on how to draw those arrows:
 
4:05 PM
@Rico Hm, I was thinking of using tex.stackexchange.com/questions/21740/… for finding the intersections with the axes, but that example doesn't work for me anymore (says it doesn't know a path named a...)
 
@Jake ok not a problem, I'll explain it within the caption, what bothers me there has to be a way to use my existing data for producing those 1/x and 1/y
 
 
1 hour later…
5:12 PM
I somehow didn't understand the logic behind pgf very well ... I have this problem that must be quite basic but I can't figure out how to do it.
I want to plot a function that uses a custom function in pgfplots
Specifically, I want to plot a function that needs erf()
I tried declare function which didn't work and I tried this \pgfmathdeclarefunction implementation tex.stackexchange.com/a/107439/13450
didn't work either
I can plot the error function itself alright
but I can't plot a function using the error function
Could anyone who's more experienced in pgfplots sketch how to do this?
\documentclass[a5paper]{article}
\usepackage{pgfplots}
\usepackage{tikz}
\makeatletter
\pgfmathdeclarefunction{erf}{1}{%
  \begingroup
    \pgfmathparse{#1 > 0 ? 1 : -1}
    \edef\sign{\pgfmathresult}%
    \pgfmathparse{abs(#1)}
    \edef\x{\pgfmathresult}%
    \pgfmathparse{1/(1+0.3275911*\x)}
    \edef\t{\pgfmathresult}%
    \pgfmathparse{%
      1 - (((((1.061405429*\t -1.453152027)*\t) + 1.421413741)*\t
      -0.284496736)*\t + 0.254829592)*\t*exp(-(\x*\x))}
    \edef\y{\pgfmathresult}%
    \pgfmathparse{(\sign)*\y}
Clearly not like this.
Or should I turn this into a proper question?
Should look something like that (this is from Wolfram Alpha and no, it's not actually the function I want to plot) but instead I get a blank page.
I got so far as to get a plane.
 
@Christian There are a couple of issues: The syntax for declare function is declare function={f(\x,\y)=erf(\x)+erf(\y);} (you need to make the variables explicit); and you need to put % after all the lines in \pgfmathdeclarefunction, otherwise you introduce heaps of spurious white space.
Then it works:
\documentclass[border=5mm]{standalone}
\usepackage{pgfplots}
\usepackage{tikz}
\makeatletter
\pgfmathdeclarefunction{erf}{1}{%
  \begingroup%
    \pgfmathparse{#1 > 0 ? 1 : -1}%
    \edef\sign{\pgfmathresult}%
    \pgfmathparse{abs(#1)}%
    \edef\x{\pgfmathresult}%
    \pgfmathparse{1/(1+0.3275911*\x)}%
    \edef\t{\pgfmathresult}%
    \pgfmathparse{%
      1 - (((((1.061405429*\t -1.453152027)*\t) + 1.421413741)*\t
      -0.284496736)*\t + 0.254829592)*\t*exp(-(\x*\x))}%
    \edef\y{\pgfmathresult}%
 
5:28 PM
@Jake Whoa, great, thanks! :)
 
This is pretty neat, actually! Could you ask (and self-answer) a question about this? I'm sure this will come in handy for others as well.
 
I've been using that wrong syntax without problems so far.
For simpler plots that is
 
Yeah, but I think that only works for 2D plots?
And only in a PGFPlots context, I think, because the x is defined there.
I could be wrong, though.
 
No, actually it works for 3D plots as well. I was always a bit suspicious of just using x and y in the function definition and pgf would somehow figure out that these were the two variables to use
but as long as it worked I didn't question it too much
I'll turn this into a question if you think I might not be the only one with this problem.
I can let you answer it though.
Whatever you prefer.
 
@Christian I was actually thinking more of the error function, and less about the wrong syntax =)
 
5:31 PM
hehe ok
I stole the error function definition from another question though
 
Oh did you?
 
Yeah, I even linked to it above: tex.stackexchange.com/a/107439/13450
 
Ah, sweet! Sorry, I completely missed that
 
What I wrote myself was the much simpler definition as declare function= that I commented out in my code above
used the same approximation idea though
I first tried to approximate the thing using the Taylor series but that's hopeless
 
@Christian Ah yeah, I see! Maybe you could add that as an answer to the Erf question?
I'll upvote it =)
 
5:38 PM
g Ok, will do.
Great, with the correct syntax, even that declare function thing works.
 
@Christian Yeah, and that's much nicer than resorting to the low level PGF interface, in my opinion.
 
!!/battle
 
@egreg Psmith, the TeX bot: The current score is egreg 305 vs. 280 David. So far, egreg is winning.
 
@Christian Maybe you could throw in the nice 3D plot as well...
 
I see the e-mail to the MacTeX list announcing MacTeX 2013 explicitly mentions the mirroring and file date/size business :-)
 
5:47 PM
@Jake Yep, was going to do that anyway :)
 
@Jake got a minute?
 
Detexify is offline ? :/
oh now it works again
 
@Rico Sure!
 
@Jake since this is a hard one I would prefer going to the german speaking channel ;)
 
@Rico Let's go =)
 
5:51 PM
Thanks, that was quick :)
 
@Christian Mmmh, beautiful!
 
Thanks :)
 
It seems like there's transparency in the screenshot, but not in the code?
 
Yeah, I noticed the transparency, too. I've no idea where it comes from.
The output I rendered into the image is exactly from the code given.
I love how easy it is to make beautiful plots with PGF BTW. ... well, once you struggled with the syntax successfully that is ;)
 
@Christian Hehe, yeah! PGFPlots is pretty awesome. I just noticed that again after having to produce two plots in Excel recently. It's impossible to get them to line up nicely, so frustrating!
 
6:00 PM
Although for 2D plots I mostly use gnumeric. It has a really great graph wizard.
 
@Christian Ah, I think that might be the Evince renderer.
 
But of course the customization only goes so far with GUI-based tools.
adding transparency?
that's scary
I rendered the image using gimp actually
 
@Christian Yeah, it doesn't handle gradients very well.
Oh?
 
but might well be they're using the same engine
 
Maybe they use the same backend
Yeah =)
 
6:01 PM
yeah
although I was always very pleased with the gimp renderings so far
 
@Christian I've never actually used that. Might have to take a look at that. Is that like OpenOffice Calc?
 
nah, here the image looks just crappy ... especially when you zoom in
gnumeric? Yeah, it's an open source spreadsheet, too. But it is optimized for speed, precision and has its own graph wizard. And it's relatively easy to manually fix things in the XML that gnumeric uses as a native file format .. if all else fails I mean.
 
@Christian With that many samples, you might as well just use shader=faceted:
 
There's even a paper comparing different spreadsheets: jstatsoft.org/v34/i04/paper
@Jake Yeah, granted, I barely see a difference.
okular renders the current version just fine though
PDFs are very peculiar things.
 
@Christian Woah, go Gnumeric! That's pretty impressive
(from a very quick skim)
 
6:08 PM
Yeah, in some tests MS Excel wins but mostly it's gnumeric that rules :)
Updated the answer
the png became much smaller without interp
didn't notice that before my png got actually automatically turned into a jpg after uploading, probably because it was too large
so now it's much better
 
@Christian The PDF is, too! 899KB vs 58KB
 
wow
 
Good to know
 
didn't think it would make such a difference to define some gradients instead of just plain vertices
 
@Christian Yeah
 
6:14 PM
Wow, pretty bad thunderstorm overhead.
Anyway, I'm going to do some cooking. Hungry!
thanks for all the help, Jake :)
 
@Christian Pleasure!
 
6:37 PM
@Christian Loved the title of one of the referenced works in that one: It’s Easy to Produce Chartjunk Using Microsoft Excel 2007 but Hard to Make Good Graphs.
 
6:58 PM
@DavidCarlisle: Not good enough for a vote?
0
Q: Splitting a command syntax across a \newenvironment definition

ChatterjeeThis question is a direct follow-up to the question Can a \newcommand Definition Contain Braces as Substitution Text? I asked yesterday. The following example is once again a counter-intuitive one, to demonstrate what I wish to achieve. I'm trying to split the parbox syntax across the begin cod...

@PauloCereda: ...you should implement a !!/votebattle directive for PSmith as well.
 
00:00 - 19:0019:00 - 00:00

« first day (962 days earlier)      last day (3954 days later) »