Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8554173
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 11, 20262026-06-11T14:49:14+00:00 2026-06-11T14:49:14+00:00

I have 1024 X 256 polar data (rows – radius, columns angle) that I

  • 0

I have 1024 X 256 polar data (rows – radius, columns angle) that I need to plot as an image. There is an m-file I got from the file-exchange that can do this (clickhere). However, it is really slow for large images. I believe there is a fast way to do this using the surf function that I am struggling with. (See code below)

data = data; % load any polar data

depth = 4.5; %imaging depth in mm

offset = 0.5;

theta = [(0:2*pi/size(data,2):2*pi-1/size(data,2))]*180/pi;

rho = [0:(depth-offset)/size(data,1):(depth-offset)-1/size(data,1)] + offset;

[THETA,RR] = meshgrid(theta,rho);

[A,B] = pol2cart(THETA,RR);

figure

surf(A,B,data,'edgecolor','none'),

view(0,90)

xlabel('x [mm]')

ylabel('y [mm]')

axis tight

The result appears to be incorrect.

Any idea what I am doing wrong?
Thanks!

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-11T14:49:15+00:00Added an answer on June 11, 2026 at 2:49 pm

    Yep, your problem is simple:

    pol2cart Transform polar to Cartesian coordinates.
        [X,Y] = pol2cart(TH,R) transforms corresponding elements of data
        stored in polar coordinates (angle TH, radius R) to Cartesian
        coordinates X,Y.  The arrays TH and R must the same size (or
        either can be scalar).  ***TH must be in radians***.
    

    Solution: Remove the 180/pi

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a background image that is 1024 x 1024 pixels; the reason for
I have a 1024*768px image that I want to use as a background for
i have a 1024 x 1024 image I use for a texture in my
Here's the situation: I have a two images that are over 1024 in width
I have a function that receives a power of two value. I need to
For example, I have an 1024*768 JPEG image. I want to estimate the size
I have a function that generates a BouncyCastle RSA key pair. I need to
I have observed while setting heap size people prefer the values 64,128,256,1024.. . If
I have a data frame that looks like: > ta ranks omp ALLA1 1
I have variable WCHAR sDisplayName[1024]; How can I check if sDisplayName contains the string

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.