From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.comp.tex.context/117099 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: fv leung via ntg-context Newsgroups: gmane.comp.tex.context Subject: Re: Aaligned numbers in a matrix? Date: Mon, 27 Feb 2023 09:09:43 +0800 Message-ID: References: <727E4D90-5418-480A-B5D0-8C1E7F3AAD22@scorecrow.com> Reply-To: mailing list for ConTeXt users Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="===============3233670477726163300==" Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="36673"; mail-complaints-to="usenet@ciao.gmane.io" Cc: fv leung To: mailing list for ConTeXt users Original-X-From: ntg-context-bounces@ntg.nl Mon Feb 27 02:10:39 2023 Return-path: Envelope-to: gctc-ntg-context-518@m.gmane-mx.org Original-Received: from zapf.boekplan.nl ([5.39.185.232] helo=zapf.ntg.nl) by ciao.gmane.io with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1pWS2I-0009Mw-If for gctc-ntg-context-518@m.gmane-mx.org; Mon, 27 Feb 2023 02:10:38 +0100 Original-Received: from localhost (localhost [127.0.0.1]) by zapf.ntg.nl (Postfix) with ESMTP id 6622A38077C; Mon, 27 Feb 2023 02:10:10 +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 MLcBCp8j8TeU; Mon, 27 Feb 2023 02:10:09 +0100 (CET) Original-Received: from zapf.ntg.nl (localhost [127.0.0.1]) by zapf.ntg.nl (Postfix) with ESMTP id EA5EF3807A7; Mon, 27 Feb 2023 02:10:08 +0100 (CET) Original-Received: from localhost (localhost [127.0.0.1]) by zapf.ntg.nl (Postfix) with ESMTP id AE7D53806A6 for ; Mon, 27 Feb 2023 02:10:07 +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 9mPhcfAQ220J for ; Mon, 27 Feb 2023 02:10:06 +0100 (CET) Received-SPF: Pass (mailfrom) identity=mailfrom; client-ip=209.85.215.180; helo=mail-pg1-f180.google.com; envelope-from=fvleung@gmail.com; receiver= Original-Received: from mail-pg1-f180.google.com (mail-pg1-f180.google.com [209.85.215.180]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits)) (No client certificate requested) by zapf.ntg.nl (Postfix) with ESMTPS id 36CDF380680 for ; Mon, 27 Feb 2023 02:09:56 +0100 (CET) Original-Received: by mail-pg1-f180.google.com with SMTP id q189so2609502pga.9 for ; Sun, 26 Feb 2023 17:09:56 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=to:subject:message-id:date:from:in-reply-to:references:mime-version :from:to:cc:subject:date:message-id:reply-to; bh=48yN57Q1WoC4E99IaVDDmjRVwto7C9JesYnxGk6P/8U=; b=DSGIlJd0AYWTiCxcCyrKwxmPcCyK57ibSB06BshATmHAnoLnxyfhT9qFVIjFw2C6M9 wkKtJd2I3d7ui1i46yds78O+sL1UEazPcnfQU9XDEAPllbtNzprLHFEZ8UPw232hk3JK 0yfVhBINRydulvty74sc+vqS+eipD5+HqABtjCh6/NhAvEi4uLvS2JdwHEwIZaxUUwKl pvhVHwDtBt+/0OZNEMTA0/xevbTRxKZkgSe1iU8BTM99i3FdoQyywMtGCpL6yrdOrAUd hlp8rnz38FEjyHheVsnSYBBu4CBUm1E+Zn8G15MQqe/kRP9WPK3V0yiGPJIm5KDwTQ7I HWWQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=to:subject:message-id:date:from:in-reply-to:references:mime-version :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=48yN57Q1WoC4E99IaVDDmjRVwto7C9JesYnxGk6P/8U=; b=oRN/OVJga2KBHx/MVuudgjYi7oev++u0jWn61WFdOxECUkUSFjidhKfqoUtm0jytYf 4mK2HnaagYRRRBQqdJfzGNnBQLYV6zFCKrGQJbr7jjRNjF2mUL1iimVuiv3XD/7JYv8b F8qxQ48tm0rUO96ciKj2VkqkoEP6oFF8KGHKnHjI3DG62vnH487rMNtg4qZFzysQpTaO Tu8bHQ6dpDfmuCRDoUa2R0BiCPoTu3X1S/r7xvZzKFdBWFeYLSC4T1MmjbdfcPJcfnyn +Svy7Rpta7xV14pyhOEr8wdrV6eutMlKh0Ih27MmXZpreDLB8guA7WXDZLYkAB7Pogg4 t1yQ== X-Gm-Message-State: AO0yUKWrFQQzXmhhCwvUQIGJ5NF7o+09eDniVx3JPzKW1kqMfTeKZpUx 1db+5ASjm4xsEG/UnqUBF5irmZ0uj/TPLJQssjgBAyKa6fM= X-Google-Smtp-Source: AK7set90RRukxxZvxhipklGvGoQCmbRYw6eIIGUh+uvrcF03Ugl8uiADlQYtXIAF/7wI+mVWmjdIHS3K/j9hd1YxfaQ= X-Received: by 2002:aa7:87cf:0:b0:5a8:fc35:8e99 with SMTP id i15-20020aa787cf000000b005a8fc358e99mr5112775pfo.4.1677460194230; Sun, 26 Feb 2023 17:09:54 -0800 (PST) In-Reply-To: <727E4D90-5418-480A-B5D0-8C1E7F3AAD22@scorecrow.com> X-BeenThere: ntg-context@ntg.nl X-Mailman-Version: 2.1.26 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.io gmane.comp.tex.context:117099 Archived-At: --===============3233670477726163300== Content-Type: multipart/alternative; boundary="00000000000000868405f5a42310" --00000000000000868405f5a42310 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable See if this way suits you. \definemathmatrix[bmatrix] [matrix:brackets] [simplecommand=3Dbmatrix] \starttext $ a \rightarrow \bmatrix{1, \hfill 2, 3, \hfill 4; 2, \hfill 1, 4, \hfill 3; 3,-4, 1,-2; 4,-3, 2,-1} $ \stoptext Bruce Horrocks via ntg-context =E6=96=BC 2023=E5=B9=B4= 2=E6=9C=8827=E6=97=A5 =E9=80=B1=E4=B8=80 =E4=B8=8A=E5=8D=888:56=E5=AF=AB=E9=81=93=EF=BC=9A > I'm using the following MWE to produce a matrix: > > \definemathmatrix[bmatrix] > [matrix:brackets] > [simplecommand=3Dbmatrix] > \starttext > $ a \rightarrow > \bmatrix{1, 2, 3, 4; > 2, 1, 4, 3; > 3,-4, 1,-2; > 4,-3, 2,-1} $ > \stoptext > > The columns with negative numbers in are centred and I would rather have > them right-aligned so that the digits stack up above each other and the > negative signs stick out to the left, so to speak. Is there an easy way t= o > achieve this? > > =E2=80=94 > Bruce Horrocks > Hampshire, UK > > > _________________________________________________________________________= __________ > If your question is of interest to others as well, please add an entry to > the Wiki! > > maillist : ntg-context@ntg.nl / > https://www.ntg.nl/mailman/listinfo/ntg-context > webpage : https://www.pragma-ade.nl / http://context.aanhet.net > archive : https://bitbucket.org/phg/context-mirror/commits/ > wiki : https://contextgarden.net > > _________________________________________________________________________= __________ > --00000000000000868405f5a42310 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
See if this way suits you.
\definemathmatrix[bmatrix]<= br>=C2=A0 [matrix:brackets]
=C2=A0 [simplecommand=3Dbmatrix]
\startte= xt
$ a \rightarrow
=C2=A0 \bmatrix{1, \hfill 2, 3, \hfill 4;
=C2= =A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A02, \hfill 1, 4, \hfill 3;
=C2=A0 = =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A03,-4, 1,-2;
=C2=A0 =C2=A0 =C2=A0 =C2= =A0 =C2=A0 =C2=A04,-3, 2,-1} $
\stoptext

Bruce Horrocks via n= tg-context <ntg-context@ntg.nl= > =E6=96=BC 2023=E5=B9=B42=E6=9C=8827=E6=97=A5 =E9=80=B1=E4=B8=80 =E4=B8= =8A=E5=8D=888:56=E5=AF=AB=E9=81=93=EF=BC=9A
I'm using the following MWE to produce a ma= trix:

\definemathmatrix[bmatrix]
=C2=A0 [matrix:brackets]
=C2=A0 [simplecommand=3Dbmatrix]
\starttext
$ a \rightarrow
=C2=A0 \bmatrix{1, 2, 3, 4;
=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A02, 1, 4, 3;
=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A03,-4, 1,-2;
=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A04,-3, 2,-1} $
\stoptext

The columns with negative numbers in are centred and I would rather have th= em right-aligned so that the digits stack up above each other and the negat= ive signs stick out to the left, so to speak. Is there an easy way to achie= ve this?

=E2=80=94
Bruce Horrocks
Hampshire, UK

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

maillist : ntg-cont= ext@ntg.nl / https://www.ntg.nl/mailman/listinfo/= ntg-context
webpage=C2=A0 : https://www.pragma-ade.nl / http://context.aanhet.net
archive=C2=A0 :
https://bitbucket.org/phg/context-m= irror/commits/
wiki=C2=A0 =C2=A0 =C2=A0: https://contextgarden.net
___________________________________________________________________________= ________
--00000000000000868405f5a42310-- --===============3233670477726163300== Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: base64 Content-Disposition: inline X19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19f X19fX19fX19fX19fX19fX19fX19fX19fX18KSWYgeW91ciBxdWVzdGlvbiBpcyBvZiBpbnRlcmVz dCB0byBvdGhlcnMgYXMgd2VsbCwgcGxlYXNlIGFkZCBhbiBlbnRyeSB0byB0aGUgV2lraSEKCm1h aWxsaXN0IDogbnRnLWNvbnRleHRAbnRnLm5sIC8gaHR0cHM6Ly93d3cubnRnLm5sL21haWxtYW4v bGlzdGluZm8vbnRnLWNvbnRleHQKd2VicGFnZSAgOiBodHRwczovL3d3dy5wcmFnbWEtYWRlLm5s IC8gaHR0cDovL2NvbnRleHQuYWFuaGV0Lm5ldAphcmNoaXZlICA6IGh0dHBzOi8vYml0YnVja2V0 Lm9yZy9waGcvY29udGV4dC1taXJyb3IvY29tbWl0cy8Kd2lraSAgICAgOiBodHRwczovL2NvbnRl eHRnYXJkZW4ubmV0Cl9fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19f X19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fCg== --===============3233670477726163300==--