乐筑天下

搜索
欢迎各位开发者和用户入驻本平台 尊重版权,从我做起,拒绝盗版,拒绝倒卖 签到、发布资源、邀请好友注册,可以获得银币 请注意保管好自己的密码,避免账户资金被盗
查看: 47|回复: 1

[编程交流] İnterpolation problem

[复制链接]

1

主题

1

帖子

0

银币

初来乍到

Rank: 1

铜币
5
发表于 2022-7-5 19:44:54 | 显示全部楼层 |阅读模式
Hi everybody,
 
Basically I am looking for some help in finding an interpolation lisp that will work in the order below. Not sure if anyone has something like this already that they could share.
 
I am looking for an interpolation lisp that has steps in this order...
 
-click on first point which has elevation data
-click on the a bunch of points which do not have elevation data
-click on the last point which also has elevation data
-interpolate elevation data of points between first and last points depending on distance from the first  point
 
For example if the first point elevation is 10 and the last point elevation is 15. And there are 4 points between these two and every two points have  a distance of 5 betweem them:
 
Δx=5   Δx5   Δx5  Δx5   Δx5
   .-----.-----.-----.-----.-----.
   z=10                              z=15
 
after i click last point which has z=15
 
points between z=10 and z=15 will have z value of :
 
11
12
13
14
 
 
Thank You
回复

使用道具 举报

106

主题

1万

帖子

101

银币

顶梁支柱

Rank: 50Rank: 50

铜币
1299
发表于 2022-7-5 21:30:48 | 显示全部楼层
The only problem with what you want is you would need to pick pick pick as an auto selection would assign the wrong Z to a point as they are selected from the drawing in creation order not visual order. Here is a start. Running out of time.
 
  1. (setq pt1 (getpoint "\nPick pt1"))(setq pt2 (getpoint "\nPick pt2"))(setq diff (- (nth 2 pt1)(nth 2 pt2)))(alert  (strcat "difference is " (rtos diff 2 3)))
回复

使用道具 举报

发表回复

您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

  • 微信公众平台

  • 扫描访问手机版

  • 点击图片下载手机App

QQ|关于我们|小黑屋|乐筑天下 繁体中文

GMT+8, 2025-7-4 14:10 , Processed in 1.131492 second(s), 67 queries .

© 2020-2025 乐筑天下

联系客服 关注微信 帮助中心 下载APP 返回顶部 返回列表