Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[example] Add example "laplace equation" #6302

Merged
merged 12 commits into from
Oct 18, 2022
Merged

[example] Add example "laplace equation" #6302

merged 12 commits into from
Oct 18, 2022

Conversation

bismarckkk
Copy link
Contributor

This is a 2D-Simulation of fundamental solutions of Laplace equation
moer details on https://forum.taichi-lang.cn/t/topic/2879

@netlify
Copy link

netlify bot commented Oct 12, 2022

Deploy Preview for docsite-preview ready!

Name Link
🔨 Latest commit f9d8ec5
🔍 Latest deploy log https://app.netlify.com/sites/docsite-preview/deploys/634d6e11695081000928a1ff
😎 Deploy Preview https://deploy-preview-6302--docsite-preview.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site settings.

@CLAassistant
Copy link

CLAassistant commented Oct 12, 2022

CLA assistant check
All committers have signed the CLA.

@bismarckkk bismarckkk changed the title [example] add example "laplace equation" [example] Add example "laplace equation" Oct 12, 2022
Copy link
Contributor

@erizmr erizmr left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!!

python/taichi/examples/simulation/laplace_equation.py Outdated Show resolved Hide resolved
@neozhaoliang
Copy link
Contributor

Thanks! Please use Taichi's builtin utilities instead of reinventing the wheels~

Comment on lines 199 to 207
rotateMatrix = ti.Matrix(
[[
math.cos(vortexes[i].q * dt * 40 * _frame),
-math.sin(vortexes[i].q * dt * 40 * _frame)
],
[
math.sin(vortexes[i].q * dt * 40 * _frame),
math.cos(vortexes[i].q * dt * 40 * _frame)
]])
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for your advice! But this function is not in taichi-scope, taichi function can't be used. This function will call GUI API, so it can't be moved to taichi-scope. Is there any other way?

Co-authored-by: Zhao Liang <mathzhaoliang@gmail.com>
Copy link
Contributor

@neozhaoliang neozhaoliang left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

@neozhaoliang neozhaoliang merged commit bd5c455 into taichi-dev:master Oct 18, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants