닫기

writing two matrices in a clear and nice way

image

I want to be more precise in writing these two matrices



Here's a solution using the matrix library of tikz for the drawing:



Here's the code:

As you can tell from the code, building the matrix in tikz allows for very precise control and drawing. You could change/shift every little detail of my drawing to your personal liking. The finetuning potential seems to be endless. It's a worthwhile investment to learn to make matrices with tikz if your matrices involve heavy usage of drawings. Alternatively, the nicematrix package can be used to achieve something similar since it uses tikz under the hood, but I don't know if you can finetune it as much.

Here's another way to create diagonal matrix with single 0's at upper and lower triangles. The solution below requires a bit of knowledge of nicematrix and tikz:

The code:



EDIT. The following code will typeset two equations in one line including equation numbers

A starred version of equation environment, that is equation*, typesets everything the same, with one exception that eq. number is not included. It's worth mentioning the shorter notation \[...\] can also be used, which is equivalent of equation* env.

The \quad and \qquad add some space between equations. Otherwise, they would stick together. More precisely, a macro \hspace{} will add a specific space, e.g. 1cm, 1mm, 3pt, etc. \quad and \qquad are equivalent of \hspace{1em} and \hspace{2em}, respectively.

A simple solution without additional packages: We first define a "big zero" with null dimensions so that it does not mess up the line spacing, and then place it in an appropriate location in the array.

Since the second matrix is rather small, there is not much space to add a big zero, so manually adjusting the vertical positioning by \raisebox gives better results. You may actually consider making the matrix larger by repeating a few more diagonal elements.



With nicematrix.



AI에게 물어보기
#1 #2 #3 #4 #5 #6 #7 #8 #9 #10 #11 #12 #13 #14 #15 #16 #17 #18 #19 #20 #21 #22 #23 #24 #25 #26 #27 #28 #29 #30 #31 #32 #33 #34 #35 #36 #37 #38 #39 #40 #41 #42 #43 #44 #45 #46 #47 #48 #49 #50 #51 #52 #53 #54 #55 #56 #57 #58 #59 #60 #61 #62 #63 #64 #65 #66 #67 #68 #69 #70 #1 #2 #3 #4 #5 #6 #7 #8 #9 #10 #11 #12 #13 #14 #15 #16 #17 #18 #19 #20 #21 #22 #23 #24 #25 #26 #27 #28 #29 #30 #31 #32 #33 #34 #35 #36 #38 #39 #41 #42 #43 #44 #45 #46 #47 #48 #49 #50 #51 #53 #56 #58 #60 #62 #63 #67 #68 #70
어플전용 할인코드 호텔 8% 할인
선착순 마감 [아고다]
AGODADEAL8
클릭하면 자동복사
전세계 호텔 15% 할인코드
선착순 마감 [아고다]
AGODASPONSORED
클릭하면 자동복사