How to align two ellipsoids along center and long axes?

I’m struggling to understand rotation/translation transforms as applied to things like spheres and ellipsoids. Take the following silly example.

Given this pair of random ellipsoids, how do I find a rotation/translation that aligns their centers and their long axes? (no matter that they differ in sizes, only care about their centers and long axes being aligned). Are the two possible geometric transformations equivalent? (Say, moving ellipsoid 1 to be aligned to the fixed ellipsoid 2, and vice versa?)

SeedRandom[1234]; twoRandomEllipsoids =    Table[{Ellipsoid[RandomReal[10, {3}], RandomReal[{1, 2}, 3]]}, {2}]; Graphics3D[{Opacity[0.2], twoRandomEllipsoids}, Axes -> True,   AxesLabel -> {x, y, z}] 

enter image description here

Thanks!

How to align a network graph to an image?

An arbitrary example:

Create a random image

Image[RandomReal[{0, 1}, {10, 10}], ImageSize -> Medium] 

enter image description here

Define some points and a graph to align

c = PixelValuePositions[%, White, .1] RandomGraph[Table[Length[c], 2]] 

enter image description here

Out[1]: {{2, 9}, {1, 8}, {1, 7}, {2, 7}, {9, 6}, {2, 2}} 

How can I align the nodes of a graph to coordinates on an image?

Ideally this would be a graph from a correlation matrix

RandomReal[{-1, 1}, Table[Length[c], 2]] // MatrixForm  

Does the wording of Darkvision align with accepted rules?

For this question let’s consider Dwarf racial feature Darkvision although the same wording is used for a number of different races.

The Dwarven Darkvision racial feature reads:

Darkvision
Accustomed to life underground, you have superior vision in dark and dim conditions. You can see in dim light within 60 feet of you as if it were bright light, and in darkness as if it were dim light. You can’t discern color in darkness, only shades of gray.

I understand that conventionally this means within 60 ft of you you can see in the dark/dim light. Reading the specific wording of the feature, however, it doesn’t seem to put a limit on the range of seeing in darkness as opposed to dim light?

"within 60 ft of you" appears to only modify the area that you can see in dim light. Removing that section leaves "You can see in darkness as if it were dim light." which provides no limitation on range.

You can see in dim light within 60 feet of you as if it were bright light, and in darkness as if it were dim light.

Compare this to

Within a range of 60 ft you can see in dim light as if it were bright light, and in darkness as if it were dim light

or else

You can see in dim light within 60 ft of you as if it were bright light, and in *darkness within that range as if it were dim light

Am I grammatically confused or does the RAW text disagree with the commonly accepted RAI interpretation?

How to align prefab to a accurate position with the best practice?

I’m making a plumber game, I have a pump prefab, and pipe section prefab, which allows the user to connect the pipe during game, the pipe needs to be connected seamlessly during game, which means pipe prefab needs to be aligned in pixel level, please check below enter image description here

User needs to add more and more pipe to connect the with each other, pipe is fixed length prefab.I’ve got choices,

1.Is the pipe prefab instantiated during game play a good practice? Because it might have many pipe prefabs, if the pipe goes a long way to another position, than there will needs to be so many pipe prefabs, compared to have procedrually generated pipe mesh during runtime, then a long pipe will not have to be cut off to the same small pieces?Which is good way to adpot?

2.If I use the same pipe prefabs to fabricate the piping system, how to accurately connect each other in pixel level, I can make the whole piping system in blender, then cut the system into pieces as my prefabs, then import to Unity as my first choice, this can do pixel level connection, but it seems to have better choice solely solved pixel level connection in Unity?

3.If I do it by generating the mesh during game play, then it could be complex especially it is hard to make elbow pipe mesh during runtime, or could you please advise me of some known library or package can do the work?

Can’t align core page Title

On SharePoint 2013, I’m trying to center-align the page title with a Content Editor web part. Sadly it doesn’t work. Here’s my code:

<style>     .ms-core-pageTitle{        text-align: center;     } </style> 

I need help to figure out why it’s not working because when I’m adding the code directly to F12 it’s working.

Best way to align number columns in a table that has a text column after

It is a common knowledge that number column in a table should be right-aligned, whereas text column — left.

In this example (taken from this article), you can see that there is a text column (Capital) that comes after number columns: Table

What would be the most readable and consistent way to align columns here, with the given constraint (text column should be at the end)? Keep the alignment left for all type of columns (as it is in the example) for the sake of consistency, or right-align the number columns, as it should be, and keep the last text column left-aligned?

Using CSS grid to align content in a non responsive div

My job is to supervise a junior developer, but I am mainly a javascript developer and my CSS skills are a bit basic. However, I spotted some things in his CSS code that seem unorthodox to me. He committed some CSS code similar to the one I post here:

<div class="label-item">     <div class="label-image-container">         <img src="www.aphoto.com"/>     </div>     <div class="label-info">          <span class="label-name">John</span>         <span class="description">John is an elephant</span>         <div>             <span class="size">1000 kg</span>             <span class="age">10 years old</span>         </div>     </div>     <div class="more-button">         <span> ... </span>     </div> </div> 

And the sass:

.label-item {   margin: .8rem;   display: grid;   grid-template-columns: 4.4rem 1fr 1.8rem;   grid-gap: 0 1rem;   background-color: grey;   align-items: center;   width: 300px;   height: 80px;   position: relative;    .label-image-container {     width: 50px;     height: 50px;     display: inline-block;      img {       max-width: 50px;       max-height: 50px;       float: left;       position: relative;       top: 50%;       left: 50%;       transform: translate(-50%, -50%);       height: auto;     }   }    .label-info {     display: grid;     position: relative;     grid-gap: .3rem;      .label-name {       font-size: 1.2rem;       line-height: 1.5rem;       height: 1.4rem;     }     .description, .size, .age {       font-size: 1rem;       display: inline-block;       float: left;     }      .age {       margin-left: .8rem;       float: right;     } }   .more-button {     height: 100%;     background-color: black;     color: white;     display: flex;     justify-content: center;     align-items: center;     flex-direction: column;     grid-row-end: span 1;   } } 

this is a codepen of this code: https://codepen.io/anon/pen/QXadMP

My questions are:

a. Is grid positioning appropriate to alight and place elements inside a div that is not the main website container. I know that it works, but is this best practice?

b. Is nested grids considered to be best practice (.label-info inside .label item)?

c. Is using ‘display: flex’ appropriate to use just to align the content of a div in center?