Skip to content
On Ubuntu 22.04 LTS...
 
Notifications
Clear all

On Ubuntu 22.04 LTS how to set a keyboard layout that matches a Japanese keyboard but inputs English characters?

1 Posts
1 Users
0 Likes
0 Views
Guest
Illustrious Member
Joined: 4 months ago
Posts: 57404
Topic starter  

I have a Japanese keyboard and am running Ubuntu 22.04.2 LTS (Arm64). I cannot find a matching keyboard layout for typing English. All the English keyboard options I've tried have much of the punctuation in incorrect places for the Japanese keyboard. I tried the "Japanese (Macintosh)" layout but it only inputs the kana characters printed on the key caps.

Windows has a "Japanese (QWERTY)" layout which matches the keyboard and produces English characters. What is the equivalent on Ubuntu?

Note, this question has nothing to do with Japanese input, i.e the IME (mozc). I am suffering there too. mozc is using the layout of the last keyboard selected before mozc so I still can't type the punctuation. I applied the fix suggested in Japanese (Mozc) Wrong Keyboard Layout but it has made no difference.


   
Quote

Unreplied Posts

Chromebook dying unexpectedly

My school provides me with a Chromebook.

Today, I closed the lid, then opened it up, expecting to see the lock screen, but instead, I saw where I last left off. I thought it might be because I had used the super zoom (ctrl+alt+brightness) because that usually happens, but instead of working again, it just turned off, and won’t turn back on.

It is charging but should show the low battery error, which it does not.

Find orthogonal vectors in relation to span

$begingroup$

Consider $R^3$ as an inner product space in relation to scalarmultiplication. Find all vectors in the subspace

$$Spanbigg(bigg[begin{matrix}1\2\1
end{matrix}bigg],bigg[begin{matrix}3\4\1
end{matrix}bigg]bigg)subseteq R^3,$$

which are orthogonal to the vector $bigg[begin{matrix}-1\1\1
end{matrix}bigg]$

Any help will be appreciated. I tried finding the random vector $v=bigg[begin{matrix}x_1\x_2\x_3
end{matrix}bigg]$
in the plane which i found to be ${x_3cdotbigg[begin{matrix}1\-1\1
end{matrix}bigg]bigg}$
but i dont know where to go from here.

$endgroup$

I derived a formula for [x!]’ is it correct?

$begingroup$

The starting point was that $ Gamma'(x+1)=Gamma(x+1)psi(x+1)$ where $psi(x+1)=-gamma+H_{x}$ . Hence $$ [x!]’ = x!biggl[-gamma+sum_{k=1}^{x}frac{1}{k}biggl]$$ For example $ [4!]’ = 24[-gamma+1+1/2+1/3+1/4]$ which gives 36.1462 that, put in the tangent equation, gives us exactly the tangent for x=4! Let me know if I made any mistakes in the derivation/generalization!

$endgroup$

An inequality about the 2-Wasserstein distance

$begingroup$

Let $W_2(mu,nu)$ denote the $2$-Wasserstein distance between two given probability measures $mu$ and $nu$ on $mathbb R^n$. For a probability measure $mu$ and $f:mathbb R^nto mathbb R^n$, let $f_{#}mu=mucirc f^{-1}$ denote the push-forward of $mu$ under $f$, i.e. $(f_{#}mu)(B)=mu(f^{-1}(B))$ for every Borel set $B$ in $mathbb R^n$. Why does the following inequality hold true?
$$W^2_2(f_{#}mu,g_{#}mu)leq int_{mathbb R^n}|f(x)-g(x)|^2,dmu(x) $$
for all $mu$-measurable functions $f,g:mathbb R^ntomathbb R^n$.

Some comment: the product measure $f_{#}muotimes g_{#}mu$ is a so-called transport plan and by definition of the Wasserstein distance
$$W^2_2(f_{#}mu,g_{#}mu)leq int_{mathbb R^ntimes mathbb R^n}|x-y|^2,d(f_{#}muotimes g_{#}mu)(x,y)=int_{mathbb R^ntimes mathbb R^n}|f(x)-g(y)|^2,dmu(x),dmu(y).$$

$endgroup$

Is it possible to set up a task that will trigger only when a file is copied or moved into a specific folder?

My overall goal is to get a notification every time a file is copied or moved into a specific folder. I would like to try and avoid using external tools if possible. In order to achieve that I’ve created a task in task manager. This task should run every time a user copies or moves a file into this folder. I’m using the XML script that you can see below for the trigger.

Here is what ChatGPT spit out after several tries and refining of the request:

<QueryList>
  <Query Id="0" Path="Security">
    <Select Path="Security"> 
            *[System[(EventID=4663 or EventID=4660) and 
                (EventData/Data[@Name='AccessMask'] = '0x2' or 
                EventData/Data[@Name='AccessMask'] = '0x1') and 
                (EventData/Data[@Name='ObjectType'] = 'File' or 
                EventData/Data[@Name='ObjectType'] = 'File (AD)') and 
                (EventData/Data[@Name='ObjectName'] = 'C:TA Data' or 
                starts-with(EventData/Data[@Name='ObjectName'], 'C:TA Data\'))]] 
    </Select>
  </Query>
</QueryList>

When I copy or move a file into the folder the task doesn’t run.

Can someone help please?

Monoid with torsion elements

$begingroup$

I am currently studying construction of the Grothendieck group of a commutative monoid $M$. I was looking for an example of a monoid that is torsion, namely, I have the following query.

Does there exist a monoid $M$ (written multiicatively with identity element denoted by $1$) that is not a group such that $x in M$ implies $x^n = 1$ for some $n in mathbb{N}$?

$endgroup$

paging function for similar posts shows the right links when hovering, but stays on page 1

i show similar posts based on tags:

  //similar posts
  $postID = get_queried_object_id();
  $tags = wp_get_post_tags($postID);
  foreach ($tags as $tag) {
      //make array $xtag
      $xtag[] = $tag->slug;
      $count_tag = $tag->count;
  }   


 $paged = ( get_query_var( 'paged' ) ) ? get_query_var( 'paged' ) : 1;
            //echo $paged;
            $args = array( 
                    'exclude'   => $postID,
                    'order' => 'ASC',
                    'orderby' => 'name',
                    'posts_per_page' => 2,
                    'paged' => $paged,
                    'tax_query'  => array(
                        array(
                            'taxonomy'  => 'post_tag',
                            'field'     => 'slug',
                            'terms'     =>  $xtag //apply $xtag array
                        )
                    )
                );

$customPostQuery = new WP_Query($args);
//checking the max number of pages
echo $customPostQuery->max_num_pages;

//etc. printing the posts in a foreach loop

This works. Then i call a paging function, that should show similar posts by page:

if (function_exists("similar_post_pagination")) {                            
    similar_post_pagination($customPostQuery->max_num_pages);                             
}

This is the similar_post_pagination function. It prints the pagination and when hovering the links also shows the correct links, but stays on page 1. I noticed that global $wp_query is empty. Apperently nothing happens here.

function similar_post_pagination($pages = "", $range = 2) { 
 
            $showitems = $range * 1 + 1;

            global $paged;
            if (empty($paged)) {
                $paged = 1;
            }

            if ($pages == "") {
               global $wp_query;
               **//this is empty**
               $pages = $wp_query->max_num_pages;
               echo 'empty $pages '.$pages;
               if (!$pages) {
                   $pages = 1;
                }
            }

            if (1 != $pages) {
                echo "<div class='archiv-pager'>";

                if ($paged > 2) {
                   echo "<a class='page-numbers' title='" .
                       $first ."' href='" . get_pagenum_link(1) . "'><<</a><span>| </span>";
                    }

                if ($paged > 1) {
                   echo "<a class='page-numbers' title='" . $prev . "' href='" . get_pagenum_link($paged - 1) . "'>< </a>";
                    }

               for ($i = 1; $i <= $pages; $i++) {
                   $delimiter = "  ";
                   if ($i > 1) {
                       $delimiter = "•  ";
                   } else {
                       $delimiter = "";
                    }
                   if (
                       1 != $pages &&
                            (!($i >= $paged + $range + 1 || $i <= $paged - $range - 1) ||
                           $pages <= $showitems)
                    ) {
                       if ($paged == $i) {
                           echo $delimiter . "<span class='page-numbers current'>" . $i . "</span>";
                       } else {
                           echo $delimiter . "<a class='page-numbers inactive' title='" . $page . $i . "' href='" . get_pagenum_link($i) . "' >" . $i . "</a>";
                       }
                    }
                }
               if ($paged < $pages) {
                   echo "<a class='page-numbers' title='" . $next . "' href='" . get_pagenum_link($paged + 1) . "'> ></a>";
                    }
               if ($paged + 1 < $pages) {
                   echo "<span>| </span><a class='page-numbers' title='" . $last . "' href='" . get_pagenum_link($pages) . "'>>></a>";
                }
                echo "</div>";
                } else {
                 echo '<div class="dummy-pager"></div>';
             }
         }

What do i have to use in this function for the pagination to work? Another query? Is it a scope issue? The same function works for archiv pages, but not for the similar posts.
Sorry about the length of this question and thanks for your interest. gurky

Share: