Month: October 2025
The next chapter of the Microsoft–OpenAI partnership
Since 2019, Microsoft and OpenAI have shared a vision to advance artificial intelligence responsibly and make its benefits broadly accessible. What began as an investment in a research organization has grown into one of the most successful partnerships in our industry. As we enter the next phase of this partnership, we’ve signed a new definitive agreement that builds on our foundation, strengthens our partnership, and sets the stage for long-term success for both organizations.
First, Microsoft supports the OpenAI board moving forward with formation of a public benefit corporation (PBC) and recapitalization. Following the recapitalization, Microsoft holds an investment in OpenAI Group PBC valued at approximately $135 billion, representing roughly 27 percent on an as-converted diluted basis, inclusive of all owners – employees, investors, and the OpenAI Foundation. Excluding the impact of OpenAI’s recent funding rounds, Microsoft held a 32.5 percent stake on an as-converted basis in the OpenAI for-profit.
The agreement preserves key elements that have fueled this successful partnership – meaning OpenAI remains Microsoft’s frontier model partner and Microsoft continues to have exclusive IP rights and Azure API exclusivity until Artificial General Intelligence (AGI).
It also refines and adds new provisions that enable each company to independently continue advancing innovation and growth.
What has evolved:
- Once AGI is declared by OpenAI, that declaration will now be verified by an independent expert panel.
- Microsoft’s IP rights for both models and products are extended through 2032 and now include models post-AGI, with appropriate safety guardrails.
- Microsoft’s IP rights to research, defined as the confidential methods used in the development of models and systems, will remain until either the expert panel verifies AGI or through 2030, whichever is first. Research IP includes, for example, models intended for internal deployment or research only. Beyond that research IP does not include model architecture, model weights, inference code, finetuning code, and any IP related to data center hardware and software; and Microsoft retains these non-Research IP rights.
- Microsoft’s IP rights now exclude OpenAI’s consumer hardware.
- OpenAI can now jointly develop some products with third parties. API products developed with third parties will be exclusive to Azure. Non-API products may be served on any cloud provider.
- Microsoft can now independently pursue AGI alone or in partnership with third parties.
- If Microsoft uses OpenAI’s IP to develop AGI, prior to AGI being declared, the models will be subject to compute thresholds; those thresholds are significantly larger than the size of systems used to train leading models today.
- The revenue share agreement remains until the expert panel verifies AGI, though payments will be made over a longer period of time.
- OpenAI has contracted to purchase an incremental $250B of Azure services, and Microsoft will no longer have a right of first refusal to be OpenAI’s compute provider.
- OpenAI can now provide API access to US government national security customers, regardless of the cloud provider.
- OpenAI is now able to release open weight models that meet requisite capability criteria.
As we step into this next chapter of our partnership, both companies are better positioned than ever to continue building great products that meet real-world needs, and create new opportunity for everyone and every business.
The post The next chapter of the Microsoft–OpenAI partnership appeared first on The Official Microsoft Blog.
Since 2019, Microsoft and OpenAI have shared a vision to advance artificial intelligence responsibly and make its benefits broadly accessible. What began as an investment in a research organization has grown into one of the most successful partnerships in our industry. As we enter the next phase of this partnership, we’ve signed a new definitive…
The post The next chapter of the Microsoft–OpenAI partnership appeared first on The Official Microsoft Blog.Read More
Becoming Frontier: How human ambition and AI-first differentiation are helping Microsoft customers go further with AI
Over the past few years, we have driven remarkable progress accelerating AI innovation together with our customers and partners. We are achieving efficiency and productivity at scale to shape industries and markets around the world. It is time to demand more of AI to solve humanity’s biggest challenges by democratizing intelligence, obsolescing the mundane and unlocking creativity. This is the notion of becoming Frontier: to empower human ambition and find AI-first differentiation in everything we do to maximize an organization’s potential and our impact on society.
Microsoft’s technology portfolio ensures our customers can go further with AI on their way to becoming Frontier firms, using our AI Transformation success framework as their guide. Our AI business solutions are dramatically changing how people gain actionable insights from data — fusing the capabilities of AI agents and Copilots while keeping humans at the center. We have the largest, most scalable, most capable cloud and AI platform in the industry for our customers to build upon their aspirations. We remain deeply focused on ensuring AI is used responsibly and securely, and embed security into everything we do to help our customers prioritize cybersecurity and guard against threats.
We are fortunate to work with thousands of customers and partners around the world — across every geography and industry. I am pleased to share some of the customer stories being showcased at our recently opened Experience Center One facility — each exemplifying the path to becoming Frontier.
Driven by a commitment to innovation, sustainability and operational excellence, ADNOC is helping meet the world’s growing energy demands safely and reliably, while accelerating decarbonization efforts. To empower its workforce, the company introduced OneTalent — a unified AI-powered platform consolidating over 16 legacy HR processes into a single, intelligent system that furthers its dedication to nurturing talent, aligning people with strategic goals and turning every member of its workforce into an AI collaborator. Partnering with Microsoft and AIQ, ADNOC applied AI across its operations to reimagine everything from seismic analysis to predictive maintenance. ENERGYai and Neuron 5 — AI-powered platforms built natively on Azure OpenAI — turn complexity into actionable insights. The platforms use predictive models to reduce downtime — by as much as 50% at one plant. They are also using autonomous agents to optimize energy use; unlocking data-driven insights that have accelerated energy workflows from months or years to just days or minutes.
Asset manager and technology provider BlackRock has been on a journey to infuse AI to level up how its organization operates across three key pillars: how they invest, how they operate and how they serve clients. To accelerate this mission, they partnered with Microsoft to transform processes across the investment management lifecycle by integrating cloud and AI technologies alongside its Aladdin platform. Embedded across 20 applications and accessed by tens of thousands of users, the Aladdin platform’s AI capabilities deliver functionally relevant tools to help redefine workflows for different types of financial service professionals. Client relationship managers are saving hours per client, reducing duplication and improving accuracy by evaluating CRM and market data to generate personalized client briefs and opportunity analyses using natural language processing — supported by verification and review methods that facilitate accuracy and compliance. Investment compliance officers are streamlining portfolio onboarding and compliance guideline coding, saving time on more straightforward tasks to focus on complex, investigative tasks. Portfolio managers can access data, analytics, research summaries, cash balances and more through AI-powered chat capabilities; enabling faster, more informed decision-making aligned with client mandates. With accelerated insights, improved data quality and enhanced risk management, BlackRock and its clients gain an advantage while enhancing client service, compliance and portfolio management.
To build on its culture of innovation and enable hyper-relevant messaging at scale, multinational advertising and media agency dentsu built a cutting-edge solution using Azure OpenAI: dentsu.Connect — a unified OS for its applications. By leveraging the power of AI across the entire campaign lifecycle, clients can build and execute campaigns while predicting marketers’ next best impact with confidence and precision. This end-to-end platform drives data connectivity and ensures seamless interoperability with clients’ technology and data stacks to maximize and drive brand relevance across content, production and media activation while aligning every action with business goals. dentsu.Connect helps minimize the gap between insights and action with speed and precision. Since launching, users have increased operational efficiency by 25%, improved business outcomes by 30% and quickened decision-making and data-driven AI insight generation by 125X.
Water management solutions and services partner Ecolab is harnessing the power of data-driven solutions to enable organizations to reduce water consumption, maximize system performance and optimize operating costs. Using Microsoft Azure and IoT services, the company built ECOLAB3D: an intelligent cloud platform that unifies diverse and dispersed IoT data to visualize and optimize water systems remotely. By providing actionable insights for real-time optimization across multiple assets and sites, Ecolab partners with global leaders such as Microsoft to collectively drive hundreds of millions in operational savings — while conserving more than 226 billion gallons of water annually; equivalent to the drinking water needs of nearly 800 million people. Delivering solutions across diverse industries, Ecolab is also a trusted partner for foodservice locations, helping balance labor costs with customer satisfaction. Its cloud-based platform Ecolab RushReady transforms data into an AI-enabled dashboard that improves daily operations by delivering actionable insights. In an Ecolab customer case study, this helped improve speed of service and sales labor per hour, resulting in increased profit of more than 10%. From data centers to dining rooms, Ecolab delivers intelligent, scalable solutions that transform operations for greater efficiency and measurable impact.
Leveraging Microsoft’s AI solutions across its portfolio, Epic built agentic “personas” to support care teams and patients, improve operations and financial performance and advance the practice of medicine. By summarizing patient records and automatically drafting clinical notes, one organization found that “Art” decreased after-hours documentation for clinicians by 60%, reduced burnout by 82% and helped them focus more on patient care. Care teams can also track long-term patient health and better plan treatment for chronic conditions, while nurses can perform wound image analysis automatically with 72% greater precision than manual methods. At one hospital, AI review of routine chest X-rays led to earlier discovery of over 100 cases of lung cancer, increasing the detection rate to 70% compared to the 27% national average. To support back-end operations, organizations are using “Penny” to improve the revenue cycle — resulting in $3.4 million in additional revenue at one regional network services provider. Epic also developed “Emmie” to have conversational interactions with patients and more easily help them schedule appointments and ask questions. Epic is leveraging Azure Fabric for the Cosmos platform to bring together anonymized data from more than 300 million patients, including 13 million with rare diseases, so physicians can connect with peers who have treated similar cases to improve rare disease diagnosis and select the most effective treatment.
To reduce professional burnout and accelerate scale across the industry, Harvey built an AI platform to automate legal research, contract reviews and document analysis. Harvey Assistant assists attorney searches across large document sets to identify specific clauses or provisions within seconds instead of hours. To support large-scale analysis, Harvey Vault manages and analyzes up to 100,000 files per project for complex tasks like litigation, while Harvey Workflows automates routine yet critical tasks into smaller AI-managed steps. With the integration of the newly expanded Microsoft Word add-in, AI capabilities provide legal teams with the ability to edit 100-plus page documents with a single query, enabling centrally controlled document compliance reviews that enhance efficiency while reducing risk. With more than 74,000 legal professionals using the platform, Harvey is helping them streamline workflows, reduce administrative burden and combat attorney fatigue — with the average user saving up to 25 hours of time per month.
To revolutionize drug discovery, biotech company Insilico Medicine is leveraging AI across its entire development pipeline — from target identification to molecule design and clinical trials. The company created Pharma.AI to accelerate research while reducing costs and improving success rates in emerging novel therapies — with developmental candidate timelines reduced from 2.5-4.5 years to 9-18 months for more than 20 therapeutic programs. The integrated AI platforms built with Azure AI Foundry manage complex biological data, identify disease-relevant targets and advance candidates to clinical trials — accelerating research in what is traditionally a slow, costly and complex pharmaceutical R&D process. They enable researchers to analyze genetic data and identify drug targets with AI-generated reports to facilitate business case development; use physics-based models to evaluate candidates for potency, safety and synthesizability; integrate with specialized large language models for drug discovery; and combine AI agents with structured workflows to reduce document drafting time by over 85% while improving first-pass quality of scientific documents by 60%.
To enhance manufacturing operations in a fast-paced and complex industry, global consumer foods producer Kraft Heinz partnered with Microsoft to embed AI and machine learning across its production facilities, resulting in smarter decision-making and operational improvements. The company built an AI-powered platform — Plant Chat — providing real-time insights on the factory floor and reducing downtime to enable faster, more confident decision-making with proactive guidance. The solution analyzes over 300 variables and allows operators to interact via natural language to improve consistency, reduce guesswork, decrease waste and maintain compliance — even for less experienced operators. Since implementation and collectively with other initiatives, these efforts have resulted in a 40% reduction in supply-chain waste, a 20% increase in sales forecast accuracy and a 6% product-yield improvement across all North American manufacturing sites through the third quarter of 2024. Combined with further operational improvements, this work has yielded more than $1.1 billion in gross efficiencies from 2023 through the third quarter of 2024.
To redefine work and scale intelligent automation globally, digital native Manus AI developed an advanced autonomous AI system designed to understand user intent and execute complex workflows independently across various domains. The solution leverages a multi-agent architecture through Microsoft Azure AI Foundry to deliver scalable, versatile task automation for millions of users worldwide. Its Wide Research capability deploys specialized sub-agents to rapidly perform large-scale, multi-dimensional research tasks; saving significant time and delivering actionable insights to make complex analysis accessible and efficient for strategic decision-making. Manus AI can also build dynamic dashboards so organizations can visualize trends, anomalies and market insights in real-time; driving strategic planning with reliable, up-to-date information. The multimodel image editing and creation capabilities also allow users to support brand consistency and enable marketers and product teams to iterate rapidly.
To advance automotive innovation, stabilize supply chain volatility, simplify production complexity and meet sustainability demands, Mercedes-Benz scaled AI innovation across its global production network. The MO360 data platform connects over 30 car plants worldwide to the Microsoft Cloud, enabling real-time data access, global optimization and analytics. The Digital Factory Chatbot Ecosystem uses a multi-agent system to empower employees with collaborative insights, and Paint Shop AI leverages machine learning simulations to diagnose efficiency declines and reduce energy consumption of the buildings and machines — including 20% energy savings in the Rastatt paint shop. Using NVIDIA Omniverse on Azure, Mercedes-Benz created large-scale factory digital twins for visualization, testing and optimization of production lines — enabling agile planning and continuous improvement. The MBUX Virtual Assistant embedded in over 3 million vehicles, powered by Microsoft’s ChatGPT and Bing Search, offers natural, conversational voice interactions and integrates Microsoft 365 Copilot with Teams directly into vehicles to enable mobile workspaces.
U.S. stock exchange and financial services technology company Nasdaq integrated AI capabilities into its Nasdaq Boardvantage platform to help corporate governance teams and board members save time, reduce information overload, improve decision-making and enhance board meeting preparation and governance workflows. The board management platform is used by leadership teams at over 4,000 organizations worldwide to centralize activities like meeting planning, agenda building, decision support, resolution approval, voting and signatures. Using Azure OpenAI GPT-4o mini, the AI Summarization feature helps board secretaries significantly reduce manual effort, saving hundreds of hours annually with accuracy between 91% to 97%. AI Meeting Minutes helps governance teams draft minutes by processing agendas, documents and notes while allowing for customization of length, tone and anonymization; accelerating post-meeting workflows and saving up to five hours per meeting.
As customers seek to use AI more to shop and search for products, luxury lifestyle company Ralph Lauren developed a personal, frictionless, inspirational and accessible solution to blend fashion with cutting-edge AI. Working with Microsoft, Ralph Lauren developed Ask Ralph: an AI-powered conversational tool providing styling tips and outfit recommendations from across the Polo Ralph Lauren brand. Powered by Azure OpenAI, the AI tool uses a natural language search engine to adapt dynamically to specific language inputs and interpret user intent to improve accuracy. It supports complex queries with exploratory or nuanced information needs with contextual understanding; and can discern tone, satisfaction and intent to refine recommendations. The tool also picks up on cues like location-based insights or event-driven needs. With Ask Ralph, customers can now reimagine how they shop online by putting the brand’s unique and iconic take on style right into their own hands.
Industrial automation and digital transformation expert Rockwell Automation is integrating AI and advanced analytics into its products to help manufacturers adapt seamlessly to market changes, reduce risk and develop agentic AI capabilities to support innovation and growth. FactoryTalk Design Studio
Copilot, a cloud-based environment for programming, enables rapid updates to code for evolving production needs — reducing complex coding tasks from days to minutes. Rockwell’s digital twin software, Emulate3D®, creates physics-based models for virtual testing of automation code and AI, reducing costly real-world errors and production risks while cutting on-site commissioning times by 50%. With the integration of NVIDIA Omniverse — a collaborative, large-scale digital twin platform — users can perform multi-user factory design and testing to facilitate cross-disciplinary collaboration, address industry challenges and unlock opportunities through digital simulation before real-world deployment.
To enable a cleaner, more resilient energy future, Schneider Electric is powering AI-driven industry innovation by addressing grid stability and enterprise sustainability challenges. Built using Microsoft Azure, the company developed solutions for organizations to act faster and smarter while delivering measurable improvements in grid reliability and enterprise ESG management. Resource Advisor Copilot transforms raw ESG and energy data into actionable insights via natural language queries to support knowledge-based and system data questions; saving sustainability managers hundreds of hours annually in data analysis and reporting tasks in early testing. Grid AI Assistant allows operators to interact with complex grids using natural language to improve response times and accuracy during critical events; reducing outages by 40% and speeding up application deployment by 60%. Schneider Electric’s integration of AI tools reflects a strategic approach to digitally transforming energy management, addressing both operational resilience and sustainability imperatives.
To enhance personalized learning, streamline operations and support educators with innovative technology, the State of São Paulo’s Department of Education (SEDUC) partnered with Microsoft to equip schools with cloud and AI solutions — including Azure OpenAI, Microsoft 365, Azure and Dynamics 365. SEDUC is applying responsible AI solutions at scale to address sector priorities like delivering timely, high-quality formative feedback and reducing repetitive administrative work. With Essay Grader, teachers automate portions of grading and receive suggested feedback, freeing time for lesson design and individual support. With Question Grader, students can answer questions more openly with their own perspectives and reasoning while still receiving curated feedback typically reserved for extensive exams. By leveraging these AI-powered solutions, SEDUC is improving learning outcomes, boosting efficiency and strengthening teacher impact — anchored in equity, transparency and sound governance.
Australia’s leading telecommunications company, Telstra, is transforming its customer service operations to improve the experience for its customers and the people that serve them. One of the biggest pain points for teams is navigating multiple systems to identify and resolve a customer issue — leading to long handling times and reliance on how team members interpret various data sources. By leveraging AI solutions built on Azure OpenAI and Microsoft 365 Copilot, the company is enabling instant knowledge access and streamlined workflows. With One Sentence Summary, agents have a concise overview of customer interactions to improve efficiency and customer satisfaction — reducing call handling time by over one minute and repeat contacts by nearly 10%. Ask Telstra provides AI-generated responses from Telstra’s knowledge base in near real-time to assist agents with accurate product, plan and troubleshooting information across a wide variety of topics during calls; facilitating seamless agent-customer interactions with AI assistance.
As one of the largest leading global automakers, Toyota is pioneering AI intelligence in manufacturing with O-beya System: a multi-agent AI system simulating expert discussions virtually. Based on decades of engineering knowledge, the solution fosters a collaborative project management approach to enhance problem-solving and innovation in vehicle development while identifying key challenges to help analyze and diagnose problems. O-beya can auto-select AI agents in fields like fuel efficiency, drivability, noise and vibration, energy management and power management to pinpoint causes and suggest solutions. The system also offers interactive features; including prompt history, term explanations and creative summaries to further enable engineers to explore and validate mitigation strategies efficiently. The system leverages Microsoft Azure OpenAI, Azure AI Search and Azure Cosmos DB to analyze internal design data and help Toyota accelerate innovation, preserve institutional knowledge and resolve complex engineering issues faster. Since January 2024, over 800 powertrain engineers have accessed the system, utilizing it hundreds of times monthly across multiple business units.
As we seek to help our customers realize their AI ambitions, our mission remains unchanged: to empower every person and every organization on the planet to achieve more. We are at our best as a company when we put our technology to work for others. As you move forward on your AI journey, ask what AI can do for your organization and what it means to demand more from it. Leveraging the Microsoft portfolio, together we can do more to positively impact society; going beyond efficiency and productivity to solve for humanity’s biggest challenges. I look forward to partnering with you on your path to becoming Frontier.
The post Becoming Frontier: How human ambition and AI-first differentiation are helping Microsoft customers go further with AI appeared first on The Official Microsoft Blog.
Over the past few years, we have driven remarkable progress accelerating AI innovation together with our customers and partners. We are achieving efficiency and productivity at scale to shape industries and markets around the world. It is time to demand more of AI to solve humanity’s biggest challenges by democratizing intelligence, obsolescing the mundane and…
The post Becoming Frontier: How human ambition and AI-first differentiation are helping Microsoft customers go further with AI appeared first on The Official Microsoft Blog.Read More
Discrepancy in sparse matrix math, when NaN’s present
I expect result1 and result2 below to be identical, but they aren’t. The discrepancy must be a bug, right? I’m working in R2024b, but the Run output below shows the issue exists as well in whatever the Matlab online engine is now running.
n = 5; m = 3;
S = sparse(n, m);
v=nan(n, 1);
D=sparse(diag(v));
result1=full(v.*S) %correct
result2=full(D*S) %incorrectI expect result1 and result2 below to be identical, but they aren’t. The discrepancy must be a bug, right? I’m working in R2024b, but the Run output below shows the issue exists as well in whatever the Matlab online engine is now running.
n = 5; m = 3;
S = sparse(n, m);
v=nan(n, 1);
D=sparse(diag(v));
result1=full(v.*S) %correct
result2=full(D*S) %incorrect I expect result1 and result2 below to be identical, but they aren’t. The discrepancy must be a bug, right? I’m working in R2024b, but the Run output below shows the issue exists as well in whatever the Matlab online engine is now running.
n = 5; m = 3;
S = sparse(n, m);
v=nan(n, 1);
D=sparse(diag(v));
result1=full(v.*S) %correct
result2=full(D*S) %incorrect sparse, nan, bug?, numeric MATLAB Answers — New Questions
Why do I get an “Unrecognized method, property, or field ‘IsInterface'” error when accessing NET.assembly properties with .NET 9
With .NET 9, I am attempting to get the properties of a NET.Assembly (like Classes or Interfaces), but this throws an error. For example,
>> asmInfo = NET.addAssembly("System.Windows.Forms");
>> asmInfo.Classes
Unrecognized method, property, or field ‘IsInterface’ for class ‘System.RuntimeType’.
…
This same code works with .NET 8. Why am I getting an error with .NET 9?With .NET 9, I am attempting to get the properties of a NET.Assembly (like Classes or Interfaces), but this throws an error. For example,
>> asmInfo = NET.addAssembly("System.Windows.Forms");
>> asmInfo.Classes
Unrecognized method, property, or field ‘IsInterface’ for class ‘System.RuntimeType’.
…
This same code works with .NET 8. Why am I getting an error with .NET 9? With .NET 9, I am attempting to get the properties of a NET.Assembly (like Classes or Interfaces), but this throws an error. For example,
>> asmInfo = NET.addAssembly("System.Windows.Forms");
>> asmInfo.Classes
Unrecognized method, property, or field ‘IsInterface’ for class ‘System.RuntimeType’.
…
This same code works with .NET 8. Why am I getting an error with .NET 9? MATLAB Answers — New Questions
Evaporator heat-flow reversed in refrigerant loop model (Simscape)
Hello everyone,
I’m currently modeling a refrigerant test loop in Simscape. The flow path is:
High-pressure reservoir → condenser → short pipe → valve (TXV or EXV) → short pipe → evaporator → low-pressure reservoir. All parameters are set to realistic values (pressures, diameters, temperatures, etc.).
The issue I’m facing is that the evaporator appears to be removing heat from the refrigerant instead of adding it, the temperature at port B is higher than at port A, even though the evaporator’s ambient is hotter. This causes downstream effects such as superheat decreasing when the valve closes, which is the opposite of physical behavior. Meanwhile, the condenser behaves correctly (temperature drops from port A → B as it rejects heat). Has anyone seen this before or know why the evaporator heat direction might flip in Simscape?Hello everyone,
I’m currently modeling a refrigerant test loop in Simscape. The flow path is:
High-pressure reservoir → condenser → short pipe → valve (TXV or EXV) → short pipe → evaporator → low-pressure reservoir. All parameters are set to realistic values (pressures, diameters, temperatures, etc.).
The issue I’m facing is that the evaporator appears to be removing heat from the refrigerant instead of adding it, the temperature at port B is higher than at port A, even though the evaporator’s ambient is hotter. This causes downstream effects such as superheat decreasing when the valve closes, which is the opposite of physical behavior. Meanwhile, the condenser behaves correctly (temperature drops from port A → B as it rejects heat). Has anyone seen this before or know why the evaporator heat direction might flip in Simscape? Hello everyone,
I’m currently modeling a refrigerant test loop in Simscape. The flow path is:
High-pressure reservoir → condenser → short pipe → valve (TXV or EXV) → short pipe → evaporator → low-pressure reservoir. All parameters are set to realistic values (pressures, diameters, temperatures, etc.).
The issue I’m facing is that the evaporator appears to be removing heat from the refrigerant instead of adding it, the temperature at port B is higher than at port A, even though the evaporator’s ambient is hotter. This causes downstream effects such as superheat decreasing when the valve closes, which is the opposite of physical behavior. Meanwhile, the condenser behaves correctly (temperature drops from port A → B as it rejects heat). Has anyone seen this before or know why the evaporator heat direction might flip in Simscape? simscape MATLAB Answers — New Questions
How to detect and prevent antivirus from affecting MATLAB and Simulink performance?
I suspect that my antivirus software is impacting the performance of MATLAB and Simulink. Is there something that I can do to detect this and to help prevent this type of interference? I suspect that my antivirus software is impacting the performance of MATLAB and Simulink. Is there something that I can do to detect this and to help prevent this type of interference? I suspect that my antivirus software is impacting the performance of MATLAB and Simulink. Is there something that I can do to detect this and to help prevent this type of interference? antivirus, slow, simulink, ui MATLAB Answers — New Questions
Auto-Updating Teams Work Location is Not Employee Monitoring
Setting Teams Work Location by Reference to a Wi-Fi Network
I’m amazed at some of the commentary flowing from MC1081568 (last updated 24 October 2025, Microsoft 365 roadmap item 488800) about a new Teams feature to automatically set a work location based on connecting to a Wi-Fi network or known peripherals such as Teams Rooms devices. The way some people described it, you’d think that this is tantamount to Microsoft making a method available for managers to keep an eye on employee work habits. The simple truth is that automation work location detection is not, and anyone who thinks that it is reveals a woeful lack of knowledge about how Teams works.
Setting work location has been a feature in Teams and Outlook for quite a while (Figure 1). The idea is that people can collaborate more effectively with co-workers if everyone knows where everyone is. Knowing where people are is important from a support perspective too, especially when Teams Phone serves as the corporate phone system.

Today, users must set their location manually. I forget to do so as a matter of course, just like I suspect many others do. But Teams knows when people connect to a work network. At least, it can if automatic detection is configured in Microsoft Places. In addition, the tenant must configure a Teams work location detection policy to enable automatic detection because by default, the feature is off.
Managing the Work Location Detection Policy with PowerShell
To configure the policy, connect to Microsoft Teams PowerShell and either run the Set-CsTeamsWorkLocationDetectionPolicy to switch automatic detection on by default for all users or (recommended) run the New-CsTeamsWorkLocationDetectionPolicy cmdlet to create a new work location detection policy and assign that policy to the users who you want the policy to apply to. This command creates a new policy:
New-CsTeamsWorkLocationDetectionPolicy -Identity AutoDetectNetwork -EnableWorkLocationDetection $true
To assign the policy to user accounts, use the Grant-CsTeamsWorkLocationDetectionPolicy cmdlet:
Grant-CsTeamsWorkLocationDetectionPolicy -Identity Lotte.Vetler@office365itpros.com -Policy AutoDetectNetwork
The Get-CsTeamsWorkLocationDetectionPolicy reports which work location detection policies enable automatic detection:
Identity EnableWorkLocationDetection -------- --------------------------- Global False Tag:NetworkDetectOn True Tag:AutoDetectNetwork True
It’s important to remember that Teams clears location information at the end of the working day and does not update locations outside working hours (based on Outlook settings).
Keeping an Eye on User Locations
For those who suspect that managers will monitor their locations to check where people are, my response is that managers can do this today by checking the user profiles for their employees where their location is displayed (Figure 2).

Having been a senior manager in several organizations, my view is that any manager that devotes time to this kind of checking needs to reevaluate how they allocate their time. It is something that might be justified when monitoring a problem employee, but not elsewhere. If people are really worried about management oversight, they can use the Teams browser or mobile clients. Detecting location automatically only works for the Teams desktop clients for Windows and MacOS.
Privacy is Important
People are right to worry about their privacy, and they should understand the potential impact of new functionality on how they work. In this case, I don’t think that there’s much to complain about. There are better tools available if an organization wants to monitor employee productivity. Automation work location detection by Teams to register if someone is in the office is not going to worry the people who build employee monitoring software. It shouldn’t worry you either.
Learn about managing Teams and the rest of Microsoft 365 by subscribing to the Office 365 for IT Pros eBook. Use our experience to understand what’s important and how best to protect your tenant
Simulink on Windows 11 cannot talk to WSL2 app over UDP sockets
Hi,
I’m running a Simulink model on Windows 11 Pro that has "UDP Send" blocks. The "UDP Send" block will send UDP packets to the address and port you specify. I am trying to communicate from an executing Simulink model over UDP to a simple UDP client running on WSL2. My WSL2 system is configured for mirrored networking with loopback addressing enabled. However, I cannot receive any packets on my WSL2 UDP client, although when I run the exact same program ported to Windows it works perfectly fine. I can send UDP packets manually from Windows 11 to WSL2 on the command line in PowerShell, so I know the network path is fine. Something about the Simulink UDP implementation is unusual in that is does not send UDP packets to sockets in my WSL2 environment. I have tried so many things (using physical IP address, broadcast, loopback, etc.) and I have disabled checksums in WSL2 and temporarily turned off the both the Windows Defender firewall and Hyper-V firewall. Nothing works. Anyone have any ideas?
Thanks,
-LukeHi,
I’m running a Simulink model on Windows 11 Pro that has "UDP Send" blocks. The "UDP Send" block will send UDP packets to the address and port you specify. I am trying to communicate from an executing Simulink model over UDP to a simple UDP client running on WSL2. My WSL2 system is configured for mirrored networking with loopback addressing enabled. However, I cannot receive any packets on my WSL2 UDP client, although when I run the exact same program ported to Windows it works perfectly fine. I can send UDP packets manually from Windows 11 to WSL2 on the command line in PowerShell, so I know the network path is fine. Something about the Simulink UDP implementation is unusual in that is does not send UDP packets to sockets in my WSL2 environment. I have tried so many things (using physical IP address, broadcast, loopback, etc.) and I have disabled checksums in WSL2 and temporarily turned off the both the Windows Defender firewall and Hyper-V firewall. Nothing works. Anyone have any ideas?
Thanks,
-Luke Hi,
I’m running a Simulink model on Windows 11 Pro that has "UDP Send" blocks. The "UDP Send" block will send UDP packets to the address and port you specify. I am trying to communicate from an executing Simulink model over UDP to a simple UDP client running on WSL2. My WSL2 system is configured for mirrored networking with loopback addressing enabled. However, I cannot receive any packets on my WSL2 UDP client, although when I run the exact same program ported to Windows it works perfectly fine. I can send UDP packets manually from Windows 11 to WSL2 on the command line in PowerShell, so I know the network path is fine. Something about the Simulink UDP implementation is unusual in that is does not send UDP packets to sockets in my WSL2 environment. I have tried so many things (using physical IP address, broadcast, loopback, etc.) and I have disabled checksums in WSL2 and temporarily turned off the both the Windows Defender firewall and Hyper-V firewall. Nothing works. Anyone have any ideas?
Thanks,
-Luke socket, udp, wsl2, simulink, packet, firewall MATLAB Answers — New Questions
Why do Nan values greatly increase the cost of sparse multiplication
Consider this code:
clear; close all;
n = 1e6;
m = 1e3;
s = 1e-3;
p = round(s^2 * n * m);
I = randperm(n, p);
J = randperm(m, p);
phi = sparse(I, J, 1, n, m);
Gx = randn(n, 1);
for k = 1:3
tic
L = Gx .* phi;
toc
end
Gx(1) = NaN;
for k = 1:3
tic
L = Gx .* phi;
toc
end
Now consider the output on my macbook pro M1 running Matlab 2024a (so through rosetta).
Elapsed time is 0.001591 seconds.
Elapsed time is 0.000291 seconds.
Elapsed time is 0.000282 seconds.
Elapsed time is 0.573762 seconds.
Elapsed time is 0.548177 seconds.
Elapsed time is 0.560880 seconds.
Notice the very large difference in computation times between the no-NaN version of Gx and the version that contains a single NaN value.
The solution is quite obvious, just remove the NaN values with your favorite method (isnan, isfinite, etc.). So this is not my question.
What intregues me is:
why the computation time changes so drastically?Consider this code:
clear; close all;
n = 1e6;
m = 1e3;
s = 1e-3;
p = round(s^2 * n * m);
I = randperm(n, p);
J = randperm(m, p);
phi = sparse(I, J, 1, n, m);
Gx = randn(n, 1);
for k = 1:3
tic
L = Gx .* phi;
toc
end
Gx(1) = NaN;
for k = 1:3
tic
L = Gx .* phi;
toc
end
Now consider the output on my macbook pro M1 running Matlab 2024a (so through rosetta).
Elapsed time is 0.001591 seconds.
Elapsed time is 0.000291 seconds.
Elapsed time is 0.000282 seconds.
Elapsed time is 0.573762 seconds.
Elapsed time is 0.548177 seconds.
Elapsed time is 0.560880 seconds.
Notice the very large difference in computation times between the no-NaN version of Gx and the version that contains a single NaN value.
The solution is quite obvious, just remove the NaN values with your favorite method (isnan, isfinite, etc.). So this is not my question.
What intregues me is:
why the computation time changes so drastically? Consider this code:
clear; close all;
n = 1e6;
m = 1e3;
s = 1e-3;
p = round(s^2 * n * m);
I = randperm(n, p);
J = randperm(m, p);
phi = sparse(I, J, 1, n, m);
Gx = randn(n, 1);
for k = 1:3
tic
L = Gx .* phi;
toc
end
Gx(1) = NaN;
for k = 1:3
tic
L = Gx .* phi;
toc
end
Now consider the output on my macbook pro M1 running Matlab 2024a (so through rosetta).
Elapsed time is 0.001591 seconds.
Elapsed time is 0.000291 seconds.
Elapsed time is 0.000282 seconds.
Elapsed time is 0.573762 seconds.
Elapsed time is 0.548177 seconds.
Elapsed time is 0.560880 seconds.
Notice the very large difference in computation times between the no-NaN version of Gx and the version that contains a single NaN value.
The solution is quite obvious, just remove the NaN values with your favorite method (isnan, isfinite, etc.). So this is not my question.
What intregues me is:
why the computation time changes so drastically? sparse, mtimes MATLAB Answers — New Questions
help with a heat map
Hello, I have been trying to create a heat map with the following characteristics: variation of the magnitude of the increase in vertical effort in a mesh every 1 cm for point, linear, and distributed rectangular loads. I am a civil engineer and hope you can help me.heat mapHello, I have been trying to create a heat map with the following characteristics: variation of the magnitude of the increase in vertical effort in a mesh every 1 cm for point, linear, and distributed rectangular loads. I am a civil engineer and hope you can help me.heat map Hello, I have been trying to create a heat map with the following characteristics: variation of the magnitude of the increase in vertical effort in a mesh every 1 cm for point, linear, and distributed rectangular loads. I am a civil engineer and hope you can help me.heat map heat map MATLAB Answers — New Questions
Sending Emails with MATLAB
Hello,
I am currently running a script in matlab that sends an email out when it is through with a .pdf attachment. This was working flawlessly two days ago and now I can’t seem to get it to work.
I am recieving the following error message:
Error using sendmail (line 175)
530 5.7.57 Client not authenticated to send mail. [BLAP220CA0019.NAMP220.PROD.OUTLOOK.COM]
Here is my code:
mail = ’email@address.com’; % false email for forum
password = ‘password’; % false pass for forum
mailingList = {‘people@email.com’}; % false email for forum
server = ‘smtp-mail.outlook.com’;
props = java.lang.System.getProperties;
props.setProperty(‘mail.smtp.port’,’587′);
props.setProperty(‘mail.smtp.starttls.enable’,’true’);
setpref(‘Internet’,’E_mail’,mail);
setpref(‘Internet’,’SMTP_Server’,server);
setpref(‘Internet’,’SMTP_Username’,mail);
setpref(‘Internet’,’SMTP_Password’,password);
messageBody = sprintf(‘ Good morning team!’);
messageBody = sprintf(‘%snn Here is the data analysis from yesterdays data. Have a great day!’, messageBody);
messageBody = sprintf(‘%snn – Brian Gregory’, messageBody);
messageBody = sprintf(‘%snnn *This email was generated and sent automatically via MATLAB’, messageBody);
sendmail(mailingList, …
"Data Analysis – "+date, …
messageBody,fileDir7);Hello,
I am currently running a script in matlab that sends an email out when it is through with a .pdf attachment. This was working flawlessly two days ago and now I can’t seem to get it to work.
I am recieving the following error message:
Error using sendmail (line 175)
530 5.7.57 Client not authenticated to send mail. [BLAP220CA0019.NAMP220.PROD.OUTLOOK.COM]
Here is my code:
mail = ’email@address.com’; % false email for forum
password = ‘password’; % false pass for forum
mailingList = {‘people@email.com’}; % false email for forum
server = ‘smtp-mail.outlook.com’;
props = java.lang.System.getProperties;
props.setProperty(‘mail.smtp.port’,’587′);
props.setProperty(‘mail.smtp.starttls.enable’,’true’);
setpref(‘Internet’,’E_mail’,mail);
setpref(‘Internet’,’SMTP_Server’,server);
setpref(‘Internet’,’SMTP_Username’,mail);
setpref(‘Internet’,’SMTP_Password’,password);
messageBody = sprintf(‘ Good morning team!’);
messageBody = sprintf(‘%snn Here is the data analysis from yesterdays data. Have a great day!’, messageBody);
messageBody = sprintf(‘%snn – Brian Gregory’, messageBody);
messageBody = sprintf(‘%snnn *This email was generated and sent automatically via MATLAB’, messageBody);
sendmail(mailingList, …
"Data Analysis – "+date, …
messageBody,fileDir7); Hello,
I am currently running a script in matlab that sends an email out when it is through with a .pdf attachment. This was working flawlessly two days ago and now I can’t seem to get it to work.
I am recieving the following error message:
Error using sendmail (line 175)
530 5.7.57 Client not authenticated to send mail. [BLAP220CA0019.NAMP220.PROD.OUTLOOK.COM]
Here is my code:
mail = ’email@address.com’; % false email for forum
password = ‘password’; % false pass for forum
mailingList = {‘people@email.com’}; % false email for forum
server = ‘smtp-mail.outlook.com’;
props = java.lang.System.getProperties;
props.setProperty(‘mail.smtp.port’,’587′);
props.setProperty(‘mail.smtp.starttls.enable’,’true’);
setpref(‘Internet’,’E_mail’,mail);
setpref(‘Internet’,’SMTP_Server’,server);
setpref(‘Internet’,’SMTP_Username’,mail);
setpref(‘Internet’,’SMTP_Password’,password);
messageBody = sprintf(‘ Good morning team!’);
messageBody = sprintf(‘%snn Here is the data analysis from yesterdays data. Have a great day!’, messageBody);
messageBody = sprintf(‘%snn – Brian Gregory’, messageBody);
messageBody = sprintf(‘%snnn *This email was generated and sent automatically via MATLAB’, messageBody);
sendmail(mailingList, …
"Data Analysis – "+date, …
messageBody,fileDir7); email, error, matlab MATLAB Answers — New Questions
Get references and check for shadowed files before opening a model
If I open a model with load_system() I eventually get a lot of warnings caused by referenced dictionaries, libraries, etc. that have shadowed files on the path.
How do I find all those shadowed files before using load_system() so that I can take care of those shadowed files and eventually remove them or from the path?
(Clearing the whole path is not acceptable!)
Thanks for your suggestions.If I open a model with load_system() I eventually get a lot of warnings caused by referenced dictionaries, libraries, etc. that have shadowed files on the path.
How do I find all those shadowed files before using load_system() so that I can take care of those shadowed files and eventually remove them or from the path?
(Clearing the whole path is not acceptable!)
Thanks for your suggestions. If I open a model with load_system() I eventually get a lot of warnings caused by referenced dictionaries, libraries, etc. that have shadowed files on the path.
How do I find all those shadowed files before using load_system() so that I can take care of those shadowed files and eventually remove them or from the path?
(Clearing the whole path is not acceptable!)
Thanks for your suggestions. shadowed files MATLAB Answers — New Questions
Stealing Access Token Secrets from Teams is Hard Unless a Workstation is Compromised
French Security Company Highlights Stealing Teams Access Tokens from the Local State File
On October 23, 2025, a French security company called Randorisec, published an article about stealing Microsoft Teams access tokens in 2025. Over the next few hours, I received several messages asking if the news as reported was serious and required action. My response was “Nope.”
I don’t think that the article surfaces any new information. More importantly, the compromise as described is only possible if attackers first manage to gain control over a workstation running Teams. In that scenario, the problem is more serious than fetching a few access tokens to use to send messages with the Graph API. Let’s discuss what the article reveals and why I’m sanguine about its findings.
The Teams Local State File
The discussion centers on fetching content from the local state file used by Teams, which is found in:
%LocalAppData%PackagesMSTeams_8wekyb3d8bbweLocalCacheMicrosoftMSTeamsEBWebViewLocal State
The article explains how to fetch and decrypt cookies protected using the Chromium Data Protection API (DPAPI), which in turn are used to fetch access tokens. I’m not sure that there’s anything new here because I found several articles to explain the process (here’s a good example). Chromium-based browsers use JSON-formatted local state files to store information needed for browser sessions, including encrypted keys used to protect sensitive information like user passwords.
Why Does Teams Use a Local State File?
What people might not understand is why Teams uses a local state file to hold information about the current client configuration, software version, other client settings, and encrypted content (Figure 1). The answer is that the Teams V2 client architecture depends on the WebView2 component. WebView2 uses the Edge rendering engine to display content within apps, including Teams, the new Outlook for Windows, and features shared between Outlook clients like the Room Finder. Microsoft includes the WebView2 component with Office and other products.

Because the Teams clients are deeply integrated with WebView2, it makes sense to adopt other Chromium constructs, like the local state file and DPAPI, and that’s probably why you end up with a Teams-specific local state file that behaves much like the local state file used by Chromium browsers.
Access Tokens for Teams
Eventually, the researchers end up with access tokens that can be used to interact with Teams via the Graph API. Getting to the access tokens requires fetching them from the cookies SQLlite database. This file is found in the %LocalAppData%PackagesMSTeams_8wekyb3d8bbweLocalCacheMicrosoftMSTeamsEBWebViewWV2Profile_tfwNetwork folder and is locked when a Teams client is active.
The assertion that they can use the tokens to send email is erroneous. As pointed out in the article, the tokens are for use with Teams, not Exchange Online, so the permissions granted in the tokens do not permit use of the Mail Send API.
Local State File is Inaccessible Unless a Device is Compromised
Don’t get me wrong. Security researchers do a great job of finding weaknesses in products before attackers figure out how to use those weaknesses to do damage. I applaud the efforts of the Randorisec team, but I just don’t think that there’s anything surprising to become too concerned about. The attempt to hype the problem by Cyber Security News is also regretable. I wonder if either the researchers or reporter actually know anything about how Teams works, but hey, all publicity is good.
I keep on going back to the simple fact that before an attacker can access the Teams local state file and cookies database, they’ve broken into the workstation and therefore have full access to whatever’s on that device. In all probability, they can start the Teams client and can send chats and channel messages without needing to fetch and decrypt information.
The best defence is to stop attackers from compromising user accounts by deploying strong multifactor authentication. If you can do that, you shouldn’t need to worry about the details of Teams, WebView2, and the cookies file.
So much change, all the time. It’s a challenge to stay abreast of all the updates Microsoft makes across the Microsoft 365 ecosystem. Subscribe to the Office 365 for IT Pros eBook to receive insights updated monthly into what happens within Microsoft 365, why it happens, and what new features and capabilities mean for your tenant.
Correcting effects of Humidity on sensors
Hi All
I have gas sensor, that gets effected by hummdity that needs to be corrected. So was hoping to see if we can correct this ?
How can i run my code on the this support forum with my data file, so it can be run?Hi All
I have gas sensor, that gets effected by hummdity that needs to be corrected. So was hoping to see if we can correct this ?
How can i run my code on the this support forum with my data file, so it can be run? Hi All
I have gas sensor, that gets effected by hummdity that needs to be corrected. So was hoping to see if we can correct this ?
How can i run my code on the this support forum with my data file, so it can be run? matlab MATLAB Answers — New Questions
Defining Global Variables in the function
Hi. MATLAB Community. I am trying to get the following code to work. I’m working on a toy example that I hope to get running correctly before applying it to a larger numerical project. The issue I’m facing is that the values of k and rho_0 are not updating properly when I Area_Integral from the command window for different values of k and rho_0 (I am selecting k and rho_0 values so it stays in the if loop of the Area_Integral file. I uploaded the code for the various scripts I am using. When I write this in the command window, Area_Integral (1,0.4) and then Area_Integral (1.5,0.4) the value of k is not updated for the later case.
function out = Area_Integral(k, rho_0)
global k rho_0
if k>=1-rho_0^2
theta_array = linspace(0,pi/2,101);
root = zeros(size(theta_array));
for ii = 1:length(theta_array)
theta = theta_array(ii);
root(ii) = mnhf_secant(@poly4,[0.4 0.8],1e-8,0); %% Note: values of k, r0 and theta must be made accessible to poly4
end
out = 2*trapz(theta_array,root);
else
r_upperlim = sqrt(1+rho_0^2+sqrt(k^2+4*rho_0^2));
r_lowerlim = sqrt(1+rho_0^2-sqrt(k^2+4*rho_0^2));
fun_A2 = @(r) acos((r.^4+(1-rho_0^2)^2-k^2)./2./r.^2-rho_0^2).*r;
out = integral(fun_A2,r_lowerlim,r_upperlim);
end
if rho_0 == 1 && k <= 1e-12
out = pi;
end
end
function f = poly4(x)
global k rho_0 theta
disp([‘Values: k=’ num2str(k) ‘, rho_0=’ num2str(rho_0) ‘, theta=’ num2str(theta) ‘, x=’ num2str(x)])
disp([‘size(x): ‘ num2str(size(x))])
disp([‘size(k): ‘ num2str(size(k))])
disp([‘size(rho_0): ‘ num2str(size(rho_0))])
disp([‘size(theta): ‘ num2str(size(theta))])
k
%Equation B3 from Shuo and Li (LF20B)
f = (x.^2-2.*x.*cos(theta)+1-rho_0^2).*(x.^2-2.*x.*cos(theta+pi)+1-rho_0^2)-k.^2;
disp([‘f = ‘ num2str(f)])
end
function r=mnhf_secant(Fun,x,tol,trace)
%MNHF_SECANT finds the root of "Fun" using secant scheme.
%
% Fun – name of the external function
% x – vector of length 2, (initial guesses)
% tol – tolerance
% trace – print intermediate results
%
% Usage mnhf_secant(@poly1,[-0.5 2.0],1e-8,1)
% poly1 is the name of the external function.
% [-0.5 2.0] are the initial guesses for the root.
% Check inputs.
if nargin < 4, trace = 1; end
if nargin < 3, tol = 1e-8; end
if (length(x) ~= 2)
error(‘Please provide two initial guesses’)
end
f = feval(Fun,x); % Fun is assumed to accept a vector
for i = 1:100
x3 = x(1)-f(1)*(x(2)-x(1))/(f(2)-f(1)); % Update the guess.
f3 = feval(Fun,x3); % Function evaluation.
if trace, fprintf(1,’%3i %12.5f %12.5fn’, i,x3,f3); end
if abs(f3) < tol % Check for convergenece.
r = x3;
return
else % Reset values for x(1), x(2), f(1) and f(2).
x(1) = x(2); f(1) = f(2); x(2) = x3; f(2) = f3;
end
end
r = NaN;Hi. MATLAB Community. I am trying to get the following code to work. I’m working on a toy example that I hope to get running correctly before applying it to a larger numerical project. The issue I’m facing is that the values of k and rho_0 are not updating properly when I Area_Integral from the command window for different values of k and rho_0 (I am selecting k and rho_0 values so it stays in the if loop of the Area_Integral file. I uploaded the code for the various scripts I am using. When I write this in the command window, Area_Integral (1,0.4) and then Area_Integral (1.5,0.4) the value of k is not updated for the later case.
function out = Area_Integral(k, rho_0)
global k rho_0
if k>=1-rho_0^2
theta_array = linspace(0,pi/2,101);
root = zeros(size(theta_array));
for ii = 1:length(theta_array)
theta = theta_array(ii);
root(ii) = mnhf_secant(@poly4,[0.4 0.8],1e-8,0); %% Note: values of k, r0 and theta must be made accessible to poly4
end
out = 2*trapz(theta_array,root);
else
r_upperlim = sqrt(1+rho_0^2+sqrt(k^2+4*rho_0^2));
r_lowerlim = sqrt(1+rho_0^2-sqrt(k^2+4*rho_0^2));
fun_A2 = @(r) acos((r.^4+(1-rho_0^2)^2-k^2)./2./r.^2-rho_0^2).*r;
out = integral(fun_A2,r_lowerlim,r_upperlim);
end
if rho_0 == 1 && k <= 1e-12
out = pi;
end
end
function f = poly4(x)
global k rho_0 theta
disp([‘Values: k=’ num2str(k) ‘, rho_0=’ num2str(rho_0) ‘, theta=’ num2str(theta) ‘, x=’ num2str(x)])
disp([‘size(x): ‘ num2str(size(x))])
disp([‘size(k): ‘ num2str(size(k))])
disp([‘size(rho_0): ‘ num2str(size(rho_0))])
disp([‘size(theta): ‘ num2str(size(theta))])
k
%Equation B3 from Shuo and Li (LF20B)
f = (x.^2-2.*x.*cos(theta)+1-rho_0^2).*(x.^2-2.*x.*cos(theta+pi)+1-rho_0^2)-k.^2;
disp([‘f = ‘ num2str(f)])
end
function r=mnhf_secant(Fun,x,tol,trace)
%MNHF_SECANT finds the root of "Fun" using secant scheme.
%
% Fun – name of the external function
% x – vector of length 2, (initial guesses)
% tol – tolerance
% trace – print intermediate results
%
% Usage mnhf_secant(@poly1,[-0.5 2.0],1e-8,1)
% poly1 is the name of the external function.
% [-0.5 2.0] are the initial guesses for the root.
% Check inputs.
if nargin < 4, trace = 1; end
if nargin < 3, tol = 1e-8; end
if (length(x) ~= 2)
error(‘Please provide two initial guesses’)
end
f = feval(Fun,x); % Fun is assumed to accept a vector
for i = 1:100
x3 = x(1)-f(1)*(x(2)-x(1))/(f(2)-f(1)); % Update the guess.
f3 = feval(Fun,x3); % Function evaluation.
if trace, fprintf(1,’%3i %12.5f %12.5fn’, i,x3,f3); end
if abs(f3) < tol % Check for convergenece.
r = x3;
return
else % Reset values for x(1), x(2), f(1) and f(2).
x(1) = x(2); f(1) = f(2); x(2) = x3; f(2) = f3;
end
end
r = NaN; Hi. MATLAB Community. I am trying to get the following code to work. I’m working on a toy example that I hope to get running correctly before applying it to a larger numerical project. The issue I’m facing is that the values of k and rho_0 are not updating properly when I Area_Integral from the command window for different values of k and rho_0 (I am selecting k and rho_0 values so it stays in the if loop of the Area_Integral file. I uploaded the code for the various scripts I am using. When I write this in the command window, Area_Integral (1,0.4) and then Area_Integral (1.5,0.4) the value of k is not updated for the later case.
function out = Area_Integral(k, rho_0)
global k rho_0
if k>=1-rho_0^2
theta_array = linspace(0,pi/2,101);
root = zeros(size(theta_array));
for ii = 1:length(theta_array)
theta = theta_array(ii);
root(ii) = mnhf_secant(@poly4,[0.4 0.8],1e-8,0); %% Note: values of k, r0 and theta must be made accessible to poly4
end
out = 2*trapz(theta_array,root);
else
r_upperlim = sqrt(1+rho_0^2+sqrt(k^2+4*rho_0^2));
r_lowerlim = sqrt(1+rho_0^2-sqrt(k^2+4*rho_0^2));
fun_A2 = @(r) acos((r.^4+(1-rho_0^2)^2-k^2)./2./r.^2-rho_0^2).*r;
out = integral(fun_A2,r_lowerlim,r_upperlim);
end
if rho_0 == 1 && k <= 1e-12
out = pi;
end
end
function f = poly4(x)
global k rho_0 theta
disp([‘Values: k=’ num2str(k) ‘, rho_0=’ num2str(rho_0) ‘, theta=’ num2str(theta) ‘, x=’ num2str(x)])
disp([‘size(x): ‘ num2str(size(x))])
disp([‘size(k): ‘ num2str(size(k))])
disp([‘size(rho_0): ‘ num2str(size(rho_0))])
disp([‘size(theta): ‘ num2str(size(theta))])
k
%Equation B3 from Shuo and Li (LF20B)
f = (x.^2-2.*x.*cos(theta)+1-rho_0^2).*(x.^2-2.*x.*cos(theta+pi)+1-rho_0^2)-k.^2;
disp([‘f = ‘ num2str(f)])
end
function r=mnhf_secant(Fun,x,tol,trace)
%MNHF_SECANT finds the root of "Fun" using secant scheme.
%
% Fun – name of the external function
% x – vector of length 2, (initial guesses)
% tol – tolerance
% trace – print intermediate results
%
% Usage mnhf_secant(@poly1,[-0.5 2.0],1e-8,1)
% poly1 is the name of the external function.
% [-0.5 2.0] are the initial guesses for the root.
% Check inputs.
if nargin < 4, trace = 1; end
if nargin < 3, tol = 1e-8; end
if (length(x) ~= 2)
error(‘Please provide two initial guesses’)
end
f = feval(Fun,x); % Fun is assumed to accept a vector
for i = 1:100
x3 = x(1)-f(1)*(x(2)-x(1))/(f(2)-f(1)); % Update the guess.
f3 = feval(Fun,x3); % Function evaluation.
if trace, fprintf(1,’%3i %12.5f %12.5fn’, i,x3,f3); end
if abs(f3) < tol % Check for convergenece.
r = x3;
return
else % Reset values for x(1), x(2), f(1) and f(2).
x(1) = x(2); f(1) = f(2); x(2) = x3; f(2) = f3;
end
end
r = NaN; global variables MATLAB Answers — New Questions
How exchange values between Simulink and App Designer?
I am currently using App designer for the first time to create an interface for a Simulink model. This app must be capable of both monitoring the Simulink continuously (aka: change lamp colour once value output is greater than one) and inputting information into the Simulink (aka: switches that stop/start particular Simulink functions).
Getting switches to control the Simulink was simple, but I am struggling with getting the app to constantly monitor the Simulink. The closest I have gotten is using event listeners (add_exec_event_listener). However, when they are just based in the app I seem to need to be continuously doing a triggering event in the app to run the code which is not a viable option. An alternative I found was to put the listeners inside Model Properties, Callbacks but then the other parts of the app seem to refuse to run (Switch no longer interact with Simulink).
As this is my first time using app I do not know if this is due to failings on my own part or limitations of the system. If anyone know if this is possible with event listeners, could you let me know so I can continue working on my code. Or if they know this won’t work and can offer alternative suggestions that would be incredible.I am currently using App designer for the first time to create an interface for a Simulink model. This app must be capable of both monitoring the Simulink continuously (aka: change lamp colour once value output is greater than one) and inputting information into the Simulink (aka: switches that stop/start particular Simulink functions).
Getting switches to control the Simulink was simple, but I am struggling with getting the app to constantly monitor the Simulink. The closest I have gotten is using event listeners (add_exec_event_listener). However, when they are just based in the app I seem to need to be continuously doing a triggering event in the app to run the code which is not a viable option. An alternative I found was to put the listeners inside Model Properties, Callbacks but then the other parts of the app seem to refuse to run (Switch no longer interact with Simulink).
As this is my first time using app I do not know if this is due to failings on my own part or limitations of the system. If anyone know if this is possible with event listeners, could you let me know so I can continue working on my code. Or if they know this won’t work and can offer alternative suggestions that would be incredible. I am currently using App designer for the first time to create an interface for a Simulink model. This app must be capable of both monitoring the Simulink continuously (aka: change lamp colour once value output is greater than one) and inputting information into the Simulink (aka: switches that stop/start particular Simulink functions).
Getting switches to control the Simulink was simple, but I am struggling with getting the app to constantly monitor the Simulink. The closest I have gotten is using event listeners (add_exec_event_listener). However, when they are just based in the app I seem to need to be continuously doing a triggering event in the app to run the code which is not a viable option. An alternative I found was to put the listeners inside Model Properties, Callbacks but then the other parts of the app seem to refuse to run (Switch no longer interact with Simulink).
As this is my first time using app I do not know if this is due to failings on my own part or limitations of the system. If anyone know if this is possible with event listeners, could you let me know so I can continue working on my code. Or if they know this won’t work and can offer alternative suggestions that would be incredible. app designer, simulink, event listener MATLAB Answers — New Questions
Unrecognized method, property, or field ‘ReferencePoint’ for class ‘DrivingStrategy’.
I am getting this error while trying to run the example code at GitHub – mathworks/OpenTrafficLab: OpenTrafficLab is a MATLAB environment capable of simulating simple traffic scenarios with modular vehicle and junction controllers.
The lastb code block is the one returning the error
%Advance the Scenario
while advance(scenario)
plotOpenPaths(trafficLight)
drawnow limitrate
end
Unrecognized method, property, or field ‘ReferencePoint’ for class ‘DrivingStrategy’.
Error in driving.scenario.DefaultScenario/actorPoses (line 23)
if isa(obj.Scenario.Actors(i),"driving.scenario.Vehicle") && ~isa(motionStrategy,"driving.scenario.Stationary") && isequal(motionStrategy.ReferencePoint, "front-axle")
Error in drivingScenario/actorPoses (line 51)
a = actorPoses(obj.Scenario);
Error in drivingScenario/setUpSensorSimulation (line 474)
obj.SensorSimulation.addActors(actorProfiles(obj), actorPoses(obj));
Error in driving.scenario.DefaultScenario/advance (line 8)
setUpSensorSimulation(obj.Scenario);
Error in drivingScenario/advance (line 42)
running = advance(obj.Scenario);I am getting this error while trying to run the example code at GitHub – mathworks/OpenTrafficLab: OpenTrafficLab is a MATLAB environment capable of simulating simple traffic scenarios with modular vehicle and junction controllers.
The lastb code block is the one returning the error
%Advance the Scenario
while advance(scenario)
plotOpenPaths(trafficLight)
drawnow limitrate
end
Unrecognized method, property, or field ‘ReferencePoint’ for class ‘DrivingStrategy’.
Error in driving.scenario.DefaultScenario/actorPoses (line 23)
if isa(obj.Scenario.Actors(i),"driving.scenario.Vehicle") && ~isa(motionStrategy,"driving.scenario.Stationary") && isequal(motionStrategy.ReferencePoint, "front-axle")
Error in drivingScenario/actorPoses (line 51)
a = actorPoses(obj.Scenario);
Error in drivingScenario/setUpSensorSimulation (line 474)
obj.SensorSimulation.addActors(actorProfiles(obj), actorPoses(obj));
Error in driving.scenario.DefaultScenario/advance (line 8)
setUpSensorSimulation(obj.Scenario);
Error in drivingScenario/advance (line 42)
running = advance(obj.Scenario); I am getting this error while trying to run the example code at GitHub – mathworks/OpenTrafficLab: OpenTrafficLab is a MATLAB environment capable of simulating simple traffic scenarios with modular vehicle and junction controllers.
The lastb code block is the one returning the error
%Advance the Scenario
while advance(scenario)
plotOpenPaths(trafficLight)
drawnow limitrate
end
Unrecognized method, property, or field ‘ReferencePoint’ for class ‘DrivingStrategy’.
Error in driving.scenario.DefaultScenario/actorPoses (line 23)
if isa(obj.Scenario.Actors(i),"driving.scenario.Vehicle") && ~isa(motionStrategy,"driving.scenario.Stationary") && isequal(motionStrategy.ReferencePoint, "front-axle")
Error in drivingScenario/actorPoses (line 51)
a = actorPoses(obj.Scenario);
Error in drivingScenario/setUpSensorSimulation (line 474)
obj.SensorSimulation.addActors(actorProfiles(obj), actorPoses(obj));
Error in driving.scenario.DefaultScenario/advance (line 8)
setUpSensorSimulation(obj.Scenario);
Error in drivingScenario/advance (line 42)
running = advance(obj.Scenario); automated driving toolbox MATLAB Answers — New Questions
What frame of reference is the CG input to the IMU in Aerospace pack?
Hi there, I am working with the IMU block in simulink where I need to connect to the CG (center of gravity) input. My question is thus, is it in the fram of reference relative to my objects coordiantes (e.g. robot, drone, ect) or is it in the frame of reference of my global coordinate system, and is it dynamic, by which I mean, does it need the (e.g) the robots current location (and then of course relative the correct frame of reference)? It wasn’t clear to me in the documentation, so I thought I would ask the question here. Thanks in advance.Hi there, I am working with the IMU block in simulink where I need to connect to the CG (center of gravity) input. My question is thus, is it in the fram of reference relative to my objects coordiantes (e.g. robot, drone, ect) or is it in the frame of reference of my global coordinate system, and is it dynamic, by which I mean, does it need the (e.g) the robots current location (and then of course relative the correct frame of reference)? It wasn’t clear to me in the documentation, so I thought I would ask the question here. Thanks in advance. Hi there, I am working with the IMU block in simulink where I need to connect to the CG (center of gravity) input. My question is thus, is it in the fram of reference relative to my objects coordiantes (e.g. robot, drone, ect) or is it in the frame of reference of my global coordinate system, and is it dynamic, by which I mean, does it need the (e.g) the robots current location (and then of course relative the correct frame of reference)? It wasn’t clear to me in the documentation, so I thought I would ask the question here. Thanks in advance. aerospace, simulink, input MATLAB Answers — New Questions
How can I extract the time length (in miliseconds) between two audio signals?
I have a psychology experiment paradigm which asks participants to give a verbal response immediately after they hear a beep sound. Participants may or may not respond to the beep, and their response could be quick or slow. I need to extract the time length between the end of the beep sound and the start of their verbal response. Such time length should be measured in miliseconds as the total time allowed for each response was 3 seconds (3000 ms). There are hundreds of trials so I would like to find a way to do the extraction automatically. How should I achieve this? Carload thanks to any suggestions!I have a psychology experiment paradigm which asks participants to give a verbal response immediately after they hear a beep sound. Participants may or may not respond to the beep, and their response could be quick or slow. I need to extract the time length between the end of the beep sound and the start of their verbal response. Such time length should be measured in miliseconds as the total time allowed for each response was 3 seconds (3000 ms). There are hundreds of trials so I would like to find a way to do the extraction automatically. How should I achieve this? Carload thanks to any suggestions! I have a psychology experiment paradigm which asks participants to give a verbal response immediately after they hear a beep sound. Participants may or may not respond to the beep, and their response could be quick or slow. I need to extract the time length between the end of the beep sound and the start of their verbal response. Such time length should be measured in miliseconds as the total time allowed for each response was 3 seconds (3000 ms). There are hundreds of trials so I would like to find a way to do the extraction automatically. How should I achieve this? Carload thanks to any suggestions! signal processing, audio signal processing MATLAB Answers — New Questions
How to make the quiver() arrow head size fixed?
Hi all-
When I use the quiver() function to plot an arrow in my scatterplot, I noticed that the size of the arrow head is different, depending on how big the arrow itself is (its length basically).
Any ideas on how to make the arrow head size fixed independent of the arrow length? Or if it is at least possible to do?
Best.Hi all-
When I use the quiver() function to plot an arrow in my scatterplot, I noticed that the size of the arrow head is different, depending on how big the arrow itself is (its length basically).
Any ideas on how to make the arrow head size fixed independent of the arrow length? Or if it is at least possible to do?
Best. Hi all-
When I use the quiver() function to plot an arrow in my scatterplot, I noticed that the size of the arrow head is different, depending on how big the arrow itself is (its length basically).
Any ideas on how to make the arrow head size fixed independent of the arrow length? Or if it is at least possible to do?
Best. quiver, arrow, size, length, scatter, plot MATLAB Answers — New Questions









