network – Thunderbolt Bridge not connected

I need to transfer a lot of files between two 2019 MacBook Pros, but when I connect them using a Thunderbolt cable, the bridge never connects and assigns an IP via DHCP.

I tried manually assigning an IP and subnet mask to both of them, but still can’t connect them.

What is wrong here?

Assign IP Address to computer connected to switch from Router?

I have a bunch of computers connected to a switch whose ip address i have already configured…
Am trying to assign an ip address and sub net mask to a single machine on the subnet from the router.
I have the idea of trying to access the fast ether net from the router but how can i, when the interfaces are connected to the switch?

Is it mandatory to have monitor connected to remote desktop system?

I plan to do a remote desktop to another system from my laptop. In my laptop I have an additional monitor connected. When I do remote desktop I plan to use “Use all my monitors for remote session” option so that remote system detects 2 monitors. In this setup, is it mandatory to have a physical monitor connected to the remote system? Can I connect to a system without any physical monitors and it will use both monitors connected to my laptop? Both laptop and Remote system are running on Windows.

graphics card – Why does my GPU fail to detect a monitor connected through a DP-HDMI adapter?

I have a Gigabyte 1080Ti with 1x HDMI and 3x DisplayPort outputs and I’m trying to do a triple monitor setup with three HDMI monitors (LG 23MP68VQ) using two DisplayPort to HDMI adapters, but for some reason, the monitors connected via the adapters always display “No Signal”

I have confirmed each of the GPU’s output ports to be working if I use a straight DP-DP or HDMI-HDMI adapter, but anything that is supposed to do signal conversion refuses to work. I have used cheap DisplayPort to HDMI cables as well as DisplayPort to HDMI adapters certified for the highest version of DP, connected to premium HDMI cables to no avail.

If you replace the 1080Ti with a 1660 Super, the desired configuration will output to all monitors no problem.

Potentially Important: I have successfully output video on the 1080Ti using the DisplayPort to HDMI adapter on only two instances:

  1. When my monitors are a spare monitor that uses DisplayPort, an HDMI monitor via HDMI and another HDMI monitor via DP-HDMI adapter. When I remove the native DisplayPort connection, the HDMI monitor connected via adapter stops receiving signal as well. The second monitor connected HDMI-HDMI works just fine.
  2. Rarely, when I boot up the computer, the POST messages appear on the DisplayPort-HDMI monitor instead of the main (HDMI) one. Once the OS boots up, the signal is lost.

I have tried:

  1. power cycling the monitors
  2. a clean reinstall of display drivers.
  3. DisplayPort firmware upgrade tool provided by NVidia.
  4. changing GPU power management to favor performance
  5. manually configuring the monitors to check HDMI inputs
  6. rotating the cables between the available ports on the GPU
  7. spamming “detect displays” on both Nvidia control panel and Windows settings (Extend Screen, too).
  8. NVidia control panel’s TV detection function

What I have not tried, and would like to avoid, is looking for active adapters because they are actually very hard to source where I am from, and based on my understanding, these are unnecessary.

It seems to be some sort of glitch specific to the exact combination of hardware I’m using and if there was a way to more deeply troubleshoot and get to the root cause I would very much appreciate it. The R9 290 I upgraded from does not have this problem and it is incredibly vexing. Any leads would be much appreciated.

TL;DR – 1080Ti won’t output to HDMI monitor from DisplayPort out via adapter/converter cable. Native DP-DP, HDMI-HDMI connections work fine. Cable setup outputs to monitors just fine if connected to 1660 Super.

Prove that for any connected graph G there exists a graph H such that G≅Z[H]

Prove that for any connected graph $G$ there exists a graph $H$ such that $Gcong Z(H)$ (are isomorphic), where $Z(H)$ denotes the graph induced by the center of $H$.

For this exercise… well, I don’t even know where to start. Suggestions…?!?

c# – Connecting multiple device/client with server and communicating with these connected devices?

Actually I have a written a code to established a multiple client/device connection with server. My code established a multiple a connection with server and shows me a list of connected clients after When I select a connected device and try to send messages to client it’s working fine but When I try to receive a messages from client it’s not working.

Here is my Code:

Below code established a multiple client/devices connection with server

private void btnstart_Click(object sender, EventArgs e)
          {
    
    
                  string Systemip = getlocalip();
                  txtinfo.Text = "Server IP:" + Systemip + Environment.NewLine;
                  var portno = Int32.Parse("8010");
    
                  String a = "";
    
                  IPAddress ip = IPAddress.Parse(Systemip);
                  server = new TcpListener(ip, portno);
                  server.Start();
    
                 //here environment.newline means, display msg to next line.
                  txtinfo.AppendText("Server started waiting for client.............." + Environment.NewLine);
              counter = 0;
              f = new Form1();
              Thread newone = new Thread(loop);
              newone.Start();
    
    
          }
          public delegate void messageone();
          public void mess()
          {
    
              richtxtbddata.AppendText(counter + "clien connected" + Environment.NewLine);
              richtxtbddata.AppendText("The client is from IP address: " + ((IPEndPoint)socketforclient.RemoteEndPoint).Address.ToString() + Environment.NewLine);
          //    iplist.Items.Add(((IPEndPoint)socketforclient.RemoteEndPoint).Address.ToString());
              listBox1.Items.Add(counter);         //add this (((IPEndPoint)clientSocket.RemoteEndPoint).Address.ToString()); on the place of counter
          }
    
          public void loop(object obj)
          {
              connectobj = new List<Multipleconnect>();
    
              while (true)
              {
                  counter++;
    
                  socketforclient = server.AcceptSocket();
                 // ns = new NetworkStream(socketforclient);
                  connectobj.Add(new Multipleconnect
                  {
                      objectno = counter,
                      Skt = socketforclient,
                      nstream = new NetworkStream(socketforclient),
                      ip = ((IPEndPoint)socketforclient.RemoteEndPoint).Address.ToString()
                  });
    
                  //Box.AppendText(counter + "Client connected");
                  richtxtbddata.Invoke(new messageone(mess));
                  Thread UserThread = new Thread(new ThreadStart(() => f.User(socketforclient)));
                  UserThread.Start();
    
              }
          }
          public void User(Socket client)
          {
              while (true)
              {
                  try
                  {
                      byte() msg = new byte(1024);
                      int size = client.Receive(msg);
                      client.Send(msg, 0, size, SocketFlags.None);
                  }
                  catch (Exception ex)
                  {
                      txtinfo.Text = "Divice Disconnected";
                  }
    
              }
    
          }

Below code is for sending and receiving a messages but In this code messages sent client/device successfully but this code is not receive a messages from client/devices.

private void btnsend_Click(object sender, EventArgs e)
       {

       isNew = true;

           if (servermsg.Text != "") {

               ns = new NetworkStream(socketforclient);
               StreamWriter writer = new StreamWriter(ns);

               writer.WriteLine(servermsg.Text + Environment.NewLine);
               txtinfo.AppendText("Server:" + servermsg.Text + Environment.NewLine);
               writer.Flush();
               writer.Close();
           }


           ns = new NetworkStream(socketforclient);
           StreamReader sr = new StreamReader(ns);
           string myCompleteMessage = string.Empty;

           if (ns.DataAvailable)
           {
               myReadBuffer = new byte(2048);
               datafinal = new double(1);

               myCompleteMessage = Encoding.ASCII.GetString(myReadBuffer, 0, readbytes);

           }

           //runn();



           if (myCompleteMessage != "")
           {
              txtinfo.AppendText("Client:" + myCompleteMessage + Environment.NewLine + Environment.NewLine);
           }

       }

If You want a complete code, It is given below:

using System;
using System.Collections;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.IO;
using System.Linq;
using System.Net;
using System.Net.Sockets;
using System.Text;
using System.Threading;
using System.Threading.Tasks;
using System.Windows.Forms;

/// <summary>
/// single connection in working condition with old code.....
/// </summary>

namespace TCPSERVER
{
  
    public partial class Form1 : Form
    {
        List<Multipleconnect> connectobj;

        Form1 f;
        int counter = 0;
        NetworkStream ns;
        int i = 0;
        Socket socketforclient;
        TcpListener server;
        byte() myReadBuffer;
        int readbytes;
        int p = 0;
        int y;
        double() datafinal;
        double() yy;
        List<double> xx;
        string stop = "";
        Multipleconnect mulcon = new Multipleconnect();

        public Form1()
        {
            InitializeComponent();
            //txtserverip.Text = getlocalip();
         
            Featuresduringrun();
         //   Connnection();
        }

        private void btnstart_Click(object sender, EventArgs e)
        {
          
            
                string Systemip = getlocalip();
                txtinfo.Text = "Server IP:" + Systemip + Environment.NewLine;
                var portno = Int32.Parse("8010");
             
                String a = "";

                IPAddress ip = IPAddress.Parse(Systemip);
                server = new TcpListener(ip, portno);
                server.Start();

               //here environment.newline means, display msg to next line.
                txtinfo.AppendText("Server started waiting for client.............." + Environment.NewLine);
            counter = 0;
            f = new Form1();
            Thread newone = new Thread(loop);
            newone.Start();

 
        }
        public delegate void messageone();
        public void mess()
        {

            richtxtbddata.AppendText(counter + "clien connected" + Environment.NewLine);
            richtxtbddata.AppendText("The client is from IP address: " + ((IPEndPoint)socketforclient.RemoteEndPoint).Address.ToString() + Environment.NewLine);
        //    iplist.Items.Add(((IPEndPoint)socketforclient.RemoteEndPoint).Address.ToString());
            listBox1.Items.Add(counter);         //add this (((IPEndPoint)clientSocket.RemoteEndPoint).Address.ToString()); on the place of counter
        }

        public void loop(object obj)
        {
            connectobj = new List<Multipleconnect>();

            while (true)
            {
                counter++;

                socketforclient = server.AcceptSocket();
               // ns = new NetworkStream(socketforclient);
                connectobj.Add(new Multipleconnect
                {
                    objectno = counter,
                    Skt = socketforclient,
                    nstream = new NetworkStream(socketforclient),
                    ip = ((IPEndPoint)socketforclient.RemoteEndPoint).Address.ToString()
                });

                //Box.AppendText(counter + "Client connected");
                richtxtbddata.Invoke(new messageone(mess));
                Thread UserThread = new Thread(new ThreadStart(() => f.User(socketforclient)));
                UserThread.Start();

            }
        }
        public void User(Socket client)
        {
            while (true)
            {
                try
                {
                    byte() msg = new byte(1024);
                    int size = client.Receive(msg);
                    client.Send(msg, 0, size, SocketFlags.None);
                }
                catch (Exception ex)
                {
                    txtinfo.Text = "Divice Disconnected";
                }

            }




        }




        public static string getlocalip()
        {
            var host = Dns.GetHostEntry(Dns.GetHostName());
            foreach(var ip in host.AddressList)
            {
                if (ip.AddressFamily == AddressFamily.InterNetwork)
                {
                    return ip.ToString();
                }
            }
            return "not found any ip";
        }
 
        private void btnsend_Click(object sender, EventArgs e)
        {
            string aa = listBox1.SelectedItems(0).ToString();
            if (aa == null)
            {
                MessageBox.Show("Selexct a item");

            }
     

            
            if (servermsg.Text != "") {
               
                ns = new NetworkStream(socketforclient);
                StreamWriter writer = new StreamWriter(ns);
               
                writer.WriteLine(servermsg.Text + Environment.NewLine);
                txtinfo.AppendText("Server:" + servermsg.Text + Environment.NewLine);
                writer.Flush();
                writer.Close();
            }
      

            ns = new NetworkStream(socketforclient);
            StreamReader sr = new StreamReader(ns);
            string myCompleteMessage = string.Empty;

            if (ns.DataAvailable)
            {
            myReadBuffer = new byte(2062);
            int rreadbytes = ns.Read(myReadBuffer, 0, myReadBuffer.Length);
            string Client2 = Encoding.ASCII.GetString(myReadBuffer, 0, rreadbytes);
            myCompleteMessage = Client2;

            }

          
            if (myCompleteMessage != "")
            {
               txtinfo.AppendText("Client:" + myCompleteMessage + Environment.NewLine + Environment.NewLine);
            }

        }










   
  

      
  
  

 
         
   
      
        private Form activeform = null;

     
        private void listBox1_SelectedIndexChanged(object sender, EventArgs e)
        {
            string aa = listBox1.SelectedItems(0).ToString();
            if (aa == null)
            {
                MessageBox.Show("Selexct a item");

            }
            ////  int endindex = aa.Length - 1;
            //// int b = aa.IndexOf("}");
            ////aa = aa.Substring(15, 13);

            foreach (var ob in connectobj)
            {
                if (ob.objectno.ToString() == aa)     //write ob.ip on the place of ob.objectno
                {
                    socketforclient = ob.Skt;
                    MessageBox.Show("yes");
                }
            }
        }

  
    }
}

Below code comes another class which is used to store the multiple client

using System;
using System.Collections.Generic;
using System.Linq;
using System.Net.Sockets;
using System.Text;
using System.Threading.Tasks;

namespace TCPSERVER
{
    class Multipleconnect
    {
        public int objectno;
        public Socket Skt;
        public string ip;
        public NetworkStream nstream;
    }
}

c# – How to connect multiple device/client with server and how communicate with these connected devices?

Actually I have a written a code to established a multiple client/device connection with server. My code established a multiple a connection with server and shows me a list of connected clients after When I select a connected device and try to send messages to client it’s working fine but When I try to receive a messages from client it’s not working.

Here is my Code:

Below code established a multiple client/devices connection with server

private void btnstart_Click(object sender, EventArgs e)
          {
    
    
                  string Systemip = getlocalip();
                  txtinfo.Text = "Server IP:" + Systemip + Environment.NewLine;
                  var portno = Int32.Parse("8010");
    
                  String a = "";
    
                  IPAddress ip = IPAddress.Parse(Systemip);
                  server = new TcpListener(ip, portno);
                  server.Start();
    
                 //here environment.newline means, display msg to next line.
                  txtinfo.AppendText("Server started waiting for client.............." + Environment.NewLine);
              counter = 0;
              f = new Form1();
              Thread newone = new Thread(loop);
              newone.Start();
    
    
          }
          public delegate void messageone();
          public void mess()
          {
    
              richtxtbddata.AppendText(counter + "clien connected" + Environment.NewLine);
              richtxtbddata.AppendText("The client is from IP address: " + ((IPEndPoint)socketforclient.RemoteEndPoint).Address.ToString() + Environment.NewLine);
          //    iplist.Items.Add(((IPEndPoint)socketforclient.RemoteEndPoint).Address.ToString());
              listBox1.Items.Add(counter);         //add this (((IPEndPoint)clientSocket.RemoteEndPoint).Address.ToString()); on the place of counter
          }
    
          public void loop(object obj)
          {
              connectobj = new List<Multipleconnect>();
    
              while (true)
              {
                  counter++;
    
                  socketforclient = server.AcceptSocket();
                 // ns = new NetworkStream(socketforclient);
                  connectobj.Add(new Multipleconnect
                  {
                      objectno = counter,
                      Skt = socketforclient,
                      nstream = new NetworkStream(socketforclient),
                      ip = ((IPEndPoint)socketforclient.RemoteEndPoint).Address.ToString()
                  });
    
                  //Box.AppendText(counter + "Client connected");
                  richtxtbddata.Invoke(new messageone(mess));
                  Thread UserThread = new Thread(new ThreadStart(() => f.User(socketforclient)));
                  UserThread.Start();
    
              }
          }
          public void User(Socket client)
          {
              while (true)
              {
                  try
                  {
                      byte() msg = new byte(1024);
                      int size = client.Receive(msg);
                      client.Send(msg, 0, size, SocketFlags.None);
                  }
                  catch (Exception ex)
                  {
                      txtinfo.Text = "Divice Disconnected";
                  }
    
              }
    
          }

Below code is for sending and receiving a messages but In this code messages sent client/device successfully but this code is not receive a messages from client/devices.

private void btnsend_Click(object sender, EventArgs e)
       {

       isNew = true;

           if (servermsg.Text != "") {

               ns = new NetworkStream(socketforclient);
               StreamWriter writer = new StreamWriter(ns);

               writer.WriteLine(servermsg.Text + Environment.NewLine);
               txtinfo.AppendText("Server:" + servermsg.Text + Environment.NewLine);
               writer.Flush();
               writer.Close();
           }


           ns = new NetworkStream(socketforclient);
           StreamReader sr = new StreamReader(ns);
           string myCompleteMessage = string.Empty;

           if (ns.DataAvailable)
           {
               myReadBuffer = new byte(2048);
               datafinal = new double(1);

               myCompleteMessage = Encoding.ASCII.GetString(myReadBuffer, 0, readbytes);

           }

           //runn();



           if (myCompleteMessage != "")
           {
              txtinfo.AppendText("Client:" + myCompleteMessage + Environment.NewLine + Environment.NewLine);
           }

       }

If You want a complete code, It is given below:

using System;
using System.Collections;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.IO;
using System.Linq;
using System.Net;
using System.Net.Sockets;
using System.Text;
using System.Threading;
using System.Threading.Tasks;
using System.Windows.Forms;

/// <summary>
/// single connection in working condition with old code.....
/// </summary>

namespace TCPSERVER
{
  
    public partial class Form1 : Form
    {
        List<Multipleconnect> connectobj;

        Form1 f;
        int counter = 0;
        NetworkStream ns;
        int i = 0;
        Socket socketforclient;
        TcpListener server;
        byte() myReadBuffer;
        int readbytes;
        int p = 0;
        int y;
        double() datafinal;
        double() yy;
        List<double> xx;
        string stop = "";
        Multipleconnect mulcon = new Multipleconnect();

        public Form1()
        {
            InitializeComponent();
            //txtserverip.Text = getlocalip();
         
            Featuresduringrun();
         //   Connnection();
        }

        private void btnstart_Click(object sender, EventArgs e)
        {
          
            
                string Systemip = getlocalip();
                txtinfo.Text = "Server IP:" + Systemip + Environment.NewLine;
                var portno = Int32.Parse("8010");
             
                String a = "";

                IPAddress ip = IPAddress.Parse(Systemip);
                server = new TcpListener(ip, portno);
                server.Start();

               //here environment.newline means, display msg to next line.
                txtinfo.AppendText("Server started waiting for client.............." + Environment.NewLine);
            counter = 0;
            f = new Form1();
            Thread newone = new Thread(loop);
            newone.Start();

 
        }
        public delegate void messageone();
        public void mess()
        {

            richtxtbddata.AppendText(counter + "clien connected" + Environment.NewLine);
            richtxtbddata.AppendText("The client is from IP address: " + ((IPEndPoint)socketforclient.RemoteEndPoint).Address.ToString() + Environment.NewLine);
        //    iplist.Items.Add(((IPEndPoint)socketforclient.RemoteEndPoint).Address.ToString());
            listBox1.Items.Add(counter);         //add this (((IPEndPoint)clientSocket.RemoteEndPoint).Address.ToString()); on the place of counter
        }

        public void loop(object obj)
        {
            connectobj = new List<Multipleconnect>();

            while (true)
            {
                counter++;

                socketforclient = server.AcceptSocket();
               // ns = new NetworkStream(socketforclient);
                connectobj.Add(new Multipleconnect
                {
                    objectno = counter,
                    Skt = socketforclient,
                    nstream = new NetworkStream(socketforclient),
                    ip = ((IPEndPoint)socketforclient.RemoteEndPoint).Address.ToString()
                });

                //Box.AppendText(counter + "Client connected");
                richtxtbddata.Invoke(new messageone(mess));
                Thread UserThread = new Thread(new ThreadStart(() => f.User(socketforclient)));
                UserThread.Start();

            }
        }
        public void User(Socket client)
        {
            while (true)
            {
                try
                {
                    byte() msg = new byte(1024);
                    int size = client.Receive(msg);
                    client.Send(msg, 0, size, SocketFlags.None);
                }
                catch (Exception ex)
                {
                    txtinfo.Text = "Divice Disconnected";
                }

            }




        }




        public static string getlocalip()
        {
            var host = Dns.GetHostEntry(Dns.GetHostName());
            foreach(var ip in host.AddressList)
            {
                if (ip.AddressFamily == AddressFamily.InterNetwork)
                {
                    return ip.ToString();
                }
            }
            return "not found any ip";
        }
 
        private void btnsend_Click(object sender, EventArgs e)
        {
            string aa = listBox1.SelectedItems(0).ToString();
            if (aa == null)
            {
                MessageBox.Show("Selexct a item");

            }
     

            
            if (servermsg.Text != "") {
               
                ns = new NetworkStream(socketforclient);
                StreamWriter writer = new StreamWriter(ns);
               
                writer.WriteLine(servermsg.Text + Environment.NewLine);
                txtinfo.AppendText("Server:" + servermsg.Text + Environment.NewLine);
                writer.Flush();
                writer.Close();
            }
      

            ns = new NetworkStream(socketforclient);
            StreamReader sr = new StreamReader(ns);
            string myCompleteMessage = string.Empty;

            if (ns.DataAvailable)
            {
            myReadBuffer = new byte(2062);
            int rreadbytes = ns.Read(myReadBuffer, 0, myReadBuffer.Length);
            string Client2 = Encoding.ASCII.GetString(myReadBuffer, 0, rreadbytes);
            myCompleteMessage = Client2;

            }

          
            if (myCompleteMessage != "")
            {
               txtinfo.AppendText("Client:" + myCompleteMessage + Environment.NewLine + Environment.NewLine);
            }

        }










   
  

      
  
  

 
         
   
      
        private Form activeform = null;

     
        private void listBox1_SelectedIndexChanged(object sender, EventArgs e)
        {
            string aa = listBox1.SelectedItems(0).ToString();
            if (aa == null)
            {
                MessageBox.Show("Selexct a item");

            }
            ////  int endindex = aa.Length - 1;
            //// int b = aa.IndexOf("}");
            ////aa = aa.Substring(15, 13);

            foreach (var ob in connectobj)
            {
                if (ob.objectno.ToString() == aa)     //write ob.ip on the place of ob.objectno
                {
                    socketforclient = ob.Skt;
                    MessageBox.Show("yes");
                }
            }
        }

  
    }
}

Below code comes another class which is used to store the multiple client

using System;
using System.Collections.Generic;
using System.Linq;
using System.Net.Sockets;
using System.Text;
using System.Threading.Tasks;

namespace TCPSERVER
{
    class Multipleconnect
    {
        public int objectno;
        public Socket Skt;
        public string ip;
        public NetworkStream nstream;
    }
}

Rechecked luggage for a connected flight on the same airline & ticket

I’m traveling from Jamaica to Cancun, Mexico via Panama. Do I need to claim my checked bag in Panama or will my bags follow me right through to Mexico? I booked the flight on 1 ticket and it is with the same airline.

linux – Disable charging of connected USB device (phone)

I often use my phone as a mobile internet hotspot, which is connected via USB to my computer. This works fine, but unless the phone is already fully charged, it starts charging its battery from the notebook, draining the battery of the latter quite quickly. Since it is a USB-C port on both ends, I suspect that the charging current may even exceed 0.5A, leading to a fairly quick discharge of my notebook’s battery. I would prefer to completely disable charging of the phone when my notebook itself runs on battery power. A current limit to the USB’s minimum 0.1A would also be ok. Entirely disabling the port is not an option, as that would also disable USB tethering.

Question: How can I disable USB charging of a connected device or at least limit the current to 0.1A?

Notebook: Lenovo Thinkpad T480
OS: Ubuntu 20.04
Phone: Fairphone, running Android 8, not rooted

Thank you and best regards,
Philipp

reductions – Proving B-Min-Cost Strongly connected Subgraph is NP-Complete

We have a strongly connected directed graph where each edge has positive integer weights. We are also given a $B in mathbb{N}$. Does there exist a strongly connected subgraph where sum of edge weights $leq B$?

I’m not sure what NP-Complete problem to use. I tried subset sum, but it takes exponential time to build the graph I had in mind (yes/no tree with edge cost being the numbers in subset sum problem, and a final edge to root at end of every decision sequence). Any ideas? Is there a better NP-Complete problem to use?