From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.comp.tex.context/99871 Path: news.gmane.org!.POSTED!not-for-mail From: Fabrice Couvreur Newsgroups: gmane.comp.tex.context Subject: Re: Problem with \definemathmatrix Date: Thu, 18 Jan 2018 18:21:45 +0100 Message-ID: References: Reply-To: mailing list for ConTeXt users NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="===============8933943288644433086==" X-Trace: blaine.gmane.org 1516296035 10958 195.159.176.226 (18 Jan 2018 17:20:35 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Thu, 18 Jan 2018 17:20:35 +0000 (UTC) To: mailing list for ConTeXt users Original-X-From: ntg-context-bounces@ntg.nl Thu Jan 18 18:20:31 2018 Return-path: Envelope-to: gctc-ntg-context-518@m.gmane.org Original-Received: from zapf.boekplan.nl ([5.39.185.232] helo=zapf.ntg.nl) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ecDrV-0002F9-8I for gctc-ntg-context-518@m.gmane.org; Thu, 18 Jan 2018 18:20:25 +0100 Original-Received: from localhost (localhost [127.0.0.1]) by zapf.ntg.nl (Postfix) with ESMTP id C45398A0DCE; Thu, 18 Jan 2018 18:21:59 +0100 (CET) X-Virus-Scanned: Debian amavisd-new at zapf.boekplan.nl Original-Received: from zapf.ntg.nl ([127.0.0.1]) by localhost (zapf.ntg.nl [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id aw9K9JLvmJxW; Thu, 18 Jan 2018 18:21:59 +0100 (CET) Original-Received: from zapf.ntg.nl (localhost [IPv6:::1]) by zapf.ntg.nl (Postfix) with ESMTP id 0379B8A1A57; Thu, 18 Jan 2018 18:21:59 +0100 (CET) Original-Received: from localhost (localhost [127.0.0.1]) by zapf.ntg.nl (Postfix) with ESMTP id 3BE4C8A1A4B for ; Thu, 18 Jan 2018 18:21:58 +0100 (CET) X-Virus-Scanned: Debian amavisd-new at zapf.boekplan.nl Original-Received: from zapf.ntg.nl ([127.0.0.1]) by localhost (zapf.ntg.nl [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id lVY8BLHF47x0 for ; Thu, 18 Jan 2018 18:21:57 +0100 (CET) Original-Received: from mail-wm0-f44.google.com (mail-wm0-f44.google.com [74.125.82.44]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by zapf.ntg.nl (Postfix) with ESMTPS id 5A6008A0DCE for ; Thu, 18 Jan 2018 18:21:47 +0100 (CET) Original-Received: by mail-wm0-f44.google.com with SMTP id x4so3690737wmc.0 for ; Thu, 18 Jan 2018 09:21:47 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:in-reply-to:references:from:date:message-id:subject:to; bh=LbGkj3n5h8r+9J/tb4KQlLxuEC7YrGdfBKf9/NoME+s=; b=YvB4F0jSvBy/RpYYFs2PUmyvHJ/QvvKL5YKUPNBNhzi7tVJdNFYQG7cx6x7bZ84jW7 20QfnZdLAZq03A9s5bekuUurJhAs5fqbfKulSU/Bs2rgf1jI5U2v26bLwpd7zOi/uYgP HRr3WZwciIZkQNBmQGUbR774o4J6veKwlc3/i3nLYqjf4dG1PswoiMV2yety4xYCM3AE qmvHsiGsVUSA74I2xZlNUK40473oOVmPgi6CbxNQAfVuU3rWMm87AfT5qaqlYKOxm4vg rs4uq6rjxcMZVmhEPGo3XeDuKt/UVV/TyqH4AnGDHJLJSAFpLMPw8hxojs3N3M+5yj3K 0mbw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to; bh=LbGkj3n5h8r+9J/tb4KQlLxuEC7YrGdfBKf9/NoME+s=; b=GTys23VC5fbHuSBy9wOU7oqqW/XtDrQCJyyMSef5zL5juKb8sbagWq7C3DxDKFZt0/ BgwBXUERVoUbXhncpHmKAyTxtEZeeXPEhKeWLlQtlzwJ8JqUxNkjfjoCwbU7lctv+jEB gfsBpSjurQgdV8ZFknwmoJuk0toHGuOENa2b/MmPr7ZsGtfDvLKR9/dVmN5vmQ4PGxhH p4vjyVrhTrg3/CX5YYl6cBN8HBXqDX2Mfe3NM0nQ6h2Zu6LSnLruN+oe2wYVB8XoIwim crX21oa13HO9SQmuIzjvYfAyZgXM4PzC7LiIrlVjo1c6FrAAdvn0++CpQQVnz314TZSW dsWQ== X-Gm-Message-State: AKwxytc223H5IaV0kmBIaZhauawg43Q/vmdfEngzZMAv3LNrzNzKv3I0 2nvUJLh19oz1gii/D5gXeFwCkrDQZ/pw3xC28QCLrQ== X-Google-Smtp-Source: ACJfBouMgOWi+EUnvBSIY4LYLDShqv6Rb91iKHAtde9/KbKNNA5WazyYlzuec6uldoY3nuVPmQ+JI58REsmnIYKZD14= X-Received: by 10.80.183.34 with SMTP id g31mr8831892ede.191.1516296106520; Thu, 18 Jan 2018 09:21:46 -0800 (PST) Original-Received: by 10.80.244.249 with HTTP; Thu, 18 Jan 2018 09:21:45 -0800 (PST) In-Reply-To: X-BeenThere: ntg-context@ntg.nl X-Mailman-Version: 2.1.16 Precedence: list List-Id: mailing list for ConTeXt users List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: ntg-context-bounces@ntg.nl Original-Sender: "ntg-context" Xref: news.gmane.org gmane.comp.tex.context:99871 Archived-At: --===============8933943288644433086== Content-Type: multipart/alternative; boundary="94eb2c19507ecdb6b80563103200" --94eb2c19507ecdb6b80563103200 Content-Type: text/plain; charset="UTF-8" Hello, Thank you. @Adytan This module is not part of context standalone, in which directory is it better to put it ? Fabrice 2018-01-18 4:53 GMT+01:00 Aditya Mahajan : > On Wed, 17 Jan 2018, Fabrice Couvreur wrote: > > Hello, >> This macro that is not mine worked very well. I just tested the following >> file and there is a problem. >> > > Otared has already answered your question but ... > > \math{M^3=\startpmatrix >> \NC 2 \NC 3 \NC 6 \NC 4 \NC 2 \NC 7 \NC 3 \NC 1 \NR >> \NC 3 \NC 0 \NC 1 \NC 1 \NC 2 \NC 3 \NC 6 \NC 4 \NR >> \NC 6 \NC 1 \NC 4 \NC 4 \NC 4 \NC 9 \NC 10 \NC 6 \NR >> \NC 4 \NC 1 \NC 4 \NC 4 \NC 5 \NC 8 \NC 8 \NC 3 \NR >> \NC 2 \NC 2 \NC 4 \NC 5 \NC 2 \NC 7 \NC 3 \NC 1 \NR >> \NC 7 \NC 3 \NC 9 \NC 8 \NC 7 \NC 8 \NC 10 \NC 3 \NR >> \NC 3 \NC 6 \NC 10 \NC 8 \NC 3 \NC 10 \NC 4 \NC 1 \NR >> \NC 1 \NC 4 \NC 6 \NC 3 \NC 1 \NC 3 \NC 1 \NC 0 \NR >> >> \stoppmatrix} >> > > If you type a lot of such matrices, you might find the attached module > interesting. Using it you can use matlab-like syntax for writing matrices: > > \usemodule[simplematrix] > \definesimplematrix[MATRIX][fence=parenthesis, align=middle] > > \starttext > $\MATRIX{1,2,3,4;5,6,7,8;9,10,11,12}$ > \stoptext > > Aditya > ____________________________________________________________ > _______________________ > If your question is of interest to others as well, please add an entry to > the Wiki! > > maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/ > listinfo/ntg-context > webpage : http://www.pragma-ade.nl / http://context.aanhet.net > archive : https://bitbucket.org/phg/context-mirror/commits/ > wiki : http://contextgarden.net > ____________________________________________________________ > _______________________ > --94eb2c19507ecdb6b80563103200 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
Hello,
Thank you.
@Adytan This module is not part of context standalone, in which = directory is it better to put it ?
Fabrice
<= /div>

2018-01-18 4= :53 GMT+01:00 Aditya Mahajan <adityam@umich.edu>:
On Wed, 17 Jan 2018, Fabrice Couvr= eur wrote:

Hello,
This macro that is not mine worked very well. I just tested the following file and there is a problem.

Otared has already answered your question but ...

\math{M^3=3D\startpmatrix
=C2=A0 =C2=A0 =C2=A0 \NC 2 \NC 3 \NC 6=C2=A0 \NC 4 \NC 2 \NC 7=C2=A0 \NC 3= =C2=A0 \NC 1 \NR
=C2=A0 =C2=A0 =C2=A0 \NC 3 \NC 0 \NC 1=C2=A0 \NC 1 \NC 2 \NC 3=C2=A0 \NC 6= =C2=A0 \NC 4 \NR
=C2=A0 =C2=A0 =C2=A0 \NC 6 \NC 1 \NC 4=C2=A0 \NC 4 \NC 4 \NC 9=C2=A0 \NC 10= \NC 6 \NR
=C2=A0 =C2=A0 =C2=A0 \NC 4 \NC 1 \NC 4=C2=A0 \NC 4 \NC 5 \NC 8=C2=A0 \NC 8= =C2=A0 \NC 3 \NR
=C2=A0 =C2=A0 =C2=A0 \NC 2 \NC 2 \NC 4=C2=A0 \NC 5 \NC 2 \NC 7=C2=A0 \NC 3= =C2=A0 \NC 1 \NR
=C2=A0 =C2=A0 =C2=A0 \NC 7 \NC 3 \NC 9=C2=A0 \NC 8 \NC 7 \NC 8=C2=A0 \NC 10= \NC 3 \NR
=C2=A0 =C2=A0 =C2=A0 \NC 3 \NC 6 \NC 10 \NC 8 \NC 3 \NC 10 \NC 4=C2=A0 \NC = 1 \NR
=C2=A0 =C2=A0 =C2=A0 \NC 1 \NC 4 \NC 6=C2=A0 \NC 3 \NC 1 \NC 3=C2=A0 \NC 1= =C2=A0 \NC 0 \NR

=C2=A0 =C2=A0 \stoppmatrix}

If you type a lot of such matrices, you might find the attached module inte= resting. Using it you can use matlab-like syntax for writing matrices:

\usemodule[simplematrix]
\definesimplematrix[MATRIX][fence=3Dparenthesis, align=3Dmiddle]

\starttext
$\MATRIX{1,2,3,4;5,6,7,8;9,10,11,12}$
\stoptext

Aditya

______________________________________________= _____________________________________
If your question is of interest to others as well, please add an entry to t= he Wiki!

maillist : ntg-context@ntg.nl / <= a href=3D"http://www.ntg.nl/mailman/listinfo/ntg-context" rel=3D"noreferrer= " target=3D"_blank">http://www.ntg.nl/mailman/listinfo/ntg-context=
webpage=C2=A0 : http://www.pragma-ade.nl / http://context.aanhet.net=
archive=C2=A0 : https://bitbucket.org/phg/cont= ext-mirror/commits/
wiki=C2=A0 =C2=A0 =C2=A0: http://contextgarden.net
_________________________________________________________________= __________________

--94eb2c19507ecdb6b80563103200-- --===============8933943288644433086== Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: base64 Content-Disposition: inline X19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19f X19fX19fX19fX19fX19fX19fX19fX19fX18KSWYgeW91ciBxdWVzdGlvbiBpcyBvZiBpbnRlcmVz dCB0byBvdGhlcnMgYXMgd2VsbCwgcGxlYXNlIGFkZCBhbiBlbnRyeSB0byB0aGUgV2lraSEKCm1h aWxsaXN0IDogbnRnLWNvbnRleHRAbnRnLm5sIC8gaHR0cDovL3d3dy5udGcubmwvbWFpbG1hbi9s aXN0aW5mby9udGctY29udGV4dAp3ZWJwYWdlICA6IGh0dHA6Ly93d3cucHJhZ21hLWFkZS5ubCAv IGh0dHA6Ly9jb250ZXh0LmFhbmhldC5uZXQKYXJjaGl2ZSAgOiBodHRwczovL2JpdGJ1Y2tldC5v cmcvcGhnL2NvbnRleHQtbWlycm9yL2NvbW1pdHMvCndpa2kgICAgIDogaHR0cDovL2NvbnRleHRn YXJkZW4ubmV0Cl9fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19f X19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19f --===============8933943288644433086==--